1

I recently moved over to using Ubuntu 20.04 from Windows 10, backed up files and everything. However, now on Ubuntu I am unable to modify files within my external drive. Running a few commands reveals the following:

/media/jacob/Storage/jmgra$ ntfsfix /media/jacob/Storage

Mounting volume… Error opening '/media/jacob/Storage': Is a directory FAILED Attempting to correct errors… Error opening '/media/jacob/Storage': Is a directory FAILED Failed to startup volume: Is a directory Error opening '/media/jacob/Storage': Is a directory Volume is corrupt. You should run chkdsk.

/media/jacob/Storage/jmgra$ mkdir test mkdir: cannot create directory 'test': Read-only file system

I want to be able to modify files on this drive again, but am not sure what the issue is. Any help appreciates.

mchid
  • 43,546
  • 8
  • 97
  • 150
  • 3
    Turn of fast startup in Windows, and open the drive in Windows. Then properly disconnect the drive, and try again in Ubuntu. – Archisman Panigrahi Jul 11 '21 at 05:56
  • Please don't post screenshots of terminal output. Please copy and paste the output into your question, highlight the code and then press CTRL+K to automatically format this as code in your question. – mchid Jul 11 '21 at 15:05
  • Is windows still installed? If so, see part one and two of my answer. If windows is no longer installed, see the last part of my answer. The problem here is that you are trying to use the mount point instead of the device name when using the ntfsfix command. However, if windows is installed, you do not need to use this command as you can disable fastboot and power down Windows properly. – mchid Jul 11 '21 at 15:45

1 Answers1

1

IF WINDOWS IS STILL INSTALLED:

First, log into Windows and disable fast startup.

Next, fully power down Windows completely and DO NOT hibernate. Make sure to completely power off.

Then, go into your BIOS settings and disable fastboot. Instructions for your make and model will vary so check with your computer manufacturer for the official documentation.

Finally, log into Windows again and then fully power down Windows completely and DO NOT hibernate. Make sure to completely power off.

When you log back into Ubuntu, you should be able to properly mount the NTFS partition without issue.


In order to access read write mode for your NTFS partition in Ubuntu, you will need to fully shut down windows as Ubuntu cannot access read write mode when the NTFS partition is in a hibernated state. This is because the hibernated state needs to be unchanged when it starts back up in Windows.

Fast boot and fast startup are essentially hibernated states so when these modes are enabled, the system will be hibernated when you attempt to fully shut down.

To summarize, you will need to fully shut down Windows before accessing your NTFS partition using Ubuntu because Ubuntu cannot access your NTFS partition while it is in a hibernated state.


IF WINDOWS IS NOT INSTALLED:

Now assuming you no longer have Windows installed, you will need to take a different approach. You should only follow this approach if Windows is no longer installed.

First, you will need to determine which device your NTFS partition is so run the following command:

lsblk -o NAME,FSTYPE,MOUNTPOINT | grep -i ntfs

This will output your device name which should be something like /dev/sda1 or /dev/sda2 or /dev/sdb1 or something else.

Next, you will need to unmount the drive if the drive is mounted so run the following command using the device name you found using the previous command. This example will use /dev/sda1 but you will need to use your device name instead.

sudo umount /dev/sda1

Now, you can run ntfsfix using the device name instead of the directory mount point as you did earlier.

sudo ntfsfix /dev/sda1

The ntfsfix command needs a device name, not a mount point or directory name as you used earlier. It is often said that in linux based operating systems, "everything is a file" and this is a good example. Your partition has a device name and this device is located in /dev/. Certain commands need to use the device name instead of the mount point (the directory where that device is mounted).

mchid
  • 43,546
  • 8
  • 97
  • 150