Posted: . At: 7:52 PM. This was 7 years ago. Post ID: 10935
Page permalink. WordPress uses cookies, or tiny pieces of information stored on your computer, to verify who you are. There are cookies for logged in users and for commenters.
These cookies expire two weeks after they are set.


How I fixed an external hard drive that was not cleanly unmounted in Windows.


To access an external hard disk drive that was attached to a Windows machine that was not properly shut down, and you cannot mount it in Windows, plug it into a Linux box. There are useful NTFS utilities on GNU/Linux that can fix this issue. I used this on Gentoo.

ntfsfix -d /dev/sdb1

This fixed the issue with the external hard disk drive and it was read straight away on Windows. I could not even see it at all in Windows with Disk Management as Administrator. Very strange behavior. A user should expect Windows to be able to see all hardware, but no. I could see all Linux partitions that are EXT4, but not a bugged NTFS partition? But this is how I fixed it anyway. The ntfsfix utility should be a part of the ntfs-3g package, and any modern system would already have this installed.

More information about the ntfsfix command on Linux.

http://manpages.ubuntu.com/manpages/precise/man8/ntfsfix.8.html.

I have also used this on ubuntu, I fixed a Windows partition that was not unmounted by Windows properly.

root@Yog-Sothoth:~# ntfsfix -d /dev/sdd1 
Mounting volume... The disk contains an unclean file system (0, 0).
Metadata kept in Windows cache, refused to mount.
FAILED
Attempting to correct errors... 
Processing $MFT and $MFTMirr...
Reading $MFT... OK
Reading $MFTMirr... OK
Comparing $MFTMirr to $MFT... OK
Processing of $MFT and $MFTMirr completed successfully.
Setting required flags on partition... OK
Going to empty the journal ($LogFile)... OK
Checking the alternate boot sector... OK
NTFS volume version is 3.1.
NTFS partition /dev/sdd1 was processed successfully.

Type this command to install ntfsfix.

4.4 Tue Oct 08 jason@Yog-Sothoth 0: $ sudo apt install ntfs-3g

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.