4

Upon clicking the windows partition in nautilus, i get this error thrown at me.

Error mounting /dev/sda4 at /media/zalgo/D8649C54649C36EA: Command-line `mount -t "ntfs" -o "uhelper=udisks2,nodev,nosuid,uid=1000,gid=1000" "/dev/sda4" "/media/zalgo/D8649C54649C36EA"' exited with non-zero exit status 14: The disk contains an unclean file system (0, 0).Metadata kept in Windows cache, refused to mount.Failed to mount '/dev/sda4': Operation not permitted The NTFS partition is in an unsafe state. Please resume and shutdown Windows fully (no hibernation or fast restarting), or mount the volume read-only with the 'ro' mount option.

I do not have fast boot or hibernation enabled on windows, if there are any commands that i should post the output of to help, please comment that.

This is not a duplicate of How can I access windows 10 partition in ubuntu when i cant get it to shut down in a "safe state"?, as the solution used there does not work here.

Zalgo
  • 482

4 Answers4

8

The solution I found that worked was a program called ntfsfix.

Install ntfs-3g with:

sudo apt-get install ntfs-3g

Then run the ntfsfix command on your NTFS partition.

For example:

ntfsfix /dev/sda4
Zalgo
  • 482
  • NOTE, this can damage the system, since it deletes the not cleanly unmounted state. Better restart into Windows and turn off fast-boot and disable hibernation witn powercfg -hibernate off – rubo77 Apr 08 '20 at 17:12
5

This seems to be an issue with windows 10. In windows 10 the kernel and the drivers hibernate by default even when you shutdown the system. To disable this, do the following.

  • Open control panel.(win key + r. Type control and hit enter)

  • While in icons view, click on System and Security then power options.

  • Click on Choose what the power buttons do on the Left hand side.

  • Uncheck turn on fast startup. (you may need to press change settings that are currently unavailable before this)

  • Click on save changes.

Ceda EI
  • 2,070
  • 2
    like i said, fast boot and hibernation are both already disabled. – Zalgo Aug 03 '16 at 14:04
  • How did you disable hibernation? You have to enter a powershell as Administrator and enter powercfg -hibernate off – rubo77 Apr 08 '20 at 17:13
1

Boot into Windows 10. Open a command terminal in administrative mode. If sda4 is your only Windows partition, type:

chkdsk c:/f

and approve your desire to run that at the next reboot of Windows. Reboot Windows now. Once done, you should be able to mount the partition in Ubuntu.

If you have other Windows partitions that you are trying to mount in Ubuntu, change the c: in the above command to the correct drive letter.

rubo77
  • 32,486
heynnema
  • 70,711
  • this was something i tried in the past, it didn't work, but i found the solution and i'm going to add it – Zalgo Aug 04 '16 at 06:18
-2

Well, it appears that your ntfs partition has problems! Possibly physical damage on disk. If you have a initialization device I suggest you try to use it to enter in administration mode and try to run something from Windows to fix the disk problem at first. After that, reinstall Windows and restore your Linux bootloader(grub or whatever) or you can reinstall Linux(after fix and/or reinstall Windows) without to format all system(depends how you organized your partitions).

  • i've reinstalled windows and other distros in the past, each one also has this error (although with slightly different messages). I doubt its physical damage, as i can still boot into windows and linux completely fine. – Zalgo Aug 03 '16 at 13:18
  • Well I have a 'dual boot' with Windows 10. Actually, this Windows 10 came from Windows 8.1 upgrade that came from Windows 8.0 upgrade and grub had no problem with that.

    I'm talking about three years with the same disk(too long to be safe). Besides, the message you post 'The disk contains an unclean file system' is a clue that your ntfs partition maybe has problems. Is the same hardware(disk) from the other times that you made upgrades? Anyways, I think if you can run some software like fsdk equivalent in Windows or even change your HDD/SSD could be a good trying.

    – Andre Carneiro Aug 03 '16 at 14:25
  • this hard drive is just barely older than 1 year, and replacing right now is not an option – Zalgo Aug 03 '16 at 14:28
  • 1
    Well, maybe this can help.

    link

    Is not the same problem. But they suggested tools you can use to find the problem as 'fsck', 'disktest', 'ntfsfix' and others.

    But I recommend you try something like chkdsk from Windows( I don't have any idea what this MS guys are using in this days...)

    Good luck!

    – Andre Carneiro Aug 03 '16 at 15:13
  • thanks! one of the solutions in that link (ntfsfix) worked perfectly. you should add it to your answer in case people in the future google this – Zalgo Aug 03 '16 at 16:30
  • 1
    The fact that a NTFS partition has the dirty bit set alone does not necessarily indicate any file system corruption. Reinstalling Windows and Linux is not necessary. – Andrea Lazzarotto Aug 03 '16 at 17:08