I have a hdd attached to my server. It’s sda but has 2 partitions so sda1 @16M and sda2 @3.6T It defaulted to being in the location /media/devmon so I kept that and it worked for ages. Suddenly the data is gone. I had files located here: /media/devmon/4tb_drive/kiwix/zim and that directory is now empty. But I put the drive into a Windows box, and everything was there.

When I run mount /dev/sda2 /media/devmon/ it says:

The disk contains an unclean file system (0, 0).
Metadata kept in Windows cache, refused to mount.
Falling back to read-only mount because the NTFS partition is in an
unsafe state. Please resume and shutdown Windows fully (no hibernation
or fast restarting.)
Could not mount read-write, trying read-only

I originally formatted this drive in Windows, is that the issue? Ideally I’d use btrfs or zfs not ntfs, but here we are.


How do I get access again?

  • muhyb@programming.dev
    link
    fedilink
    arrow-up
    1
    ·
    3 months ago

    If you can access it on Windows, that’s a good thing and all you need is a disk repair there. If you cannot access it even on Windows, you’ll need file recovery (and another 4TB disk).

    However, note that there is a good chance for NTFS disks to get corrupted on Linux if you unmount them without getting the notification that indicates it’s safe to remove the disk.

    So I really recommend you to find a temporary disk (or buy a new one) and copy everything to it and format your disk as a Linux file system of your choice and move your files to it, before you get a real headache with NTFS (talking out of experience).

    Also note that, it’s possible for NTFS disks become inaccessible if fastboot option is enabled for Windows on BIOS, if so disable it.