Score:0

EXT4 partition became empty after reboot - why? possible to fix?

cn flag

TLDR: I had a 1TB RAID1 partition containing 800GB of files before rebooting, now after rebooting, the partition is empty.

Hardware: dual SATA 1TB drives in RAID1 (ASUS PIKE card, which is a LSI card). O/S is on a separate 320GB SATA drive, not part of the RAID array.

O/S: Centos 7.6.1810 (x64)

Scenario: I cleanly powered off the system (poweroff). When powering back on, the system boots from the main OS partition (not on the RAID array), and mounts the RAID partition on /mnt/sdb1. But the /mnt/sdb1 directory contains NOTHING except the "lost+found" directory and a .Trash-1000.

df -Th reports: /dev/sdb1 ext4 917G 77M 870G 1% /mnt/sdb1

RAID firmware reports the array is functioning optimally (no failures, no out-of-sync errors)

fsck.ext4 reports: /dev/sdb1: clean, 16/61038592 files, 3884291/244140288 blocks

I attempted to restore various superblock backups but this yields no difference in files.

mke2fs -n /dev/sdb1 reports:

Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
61038592 inodes, 244140288 blocks
12207014 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=4294967296
7451 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks:
        32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
        4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
        102400000, 214990848

When restoring any of these, it then reports that the partition hasn't been cleanly unmounted and proceeds to run fsck, which reports some errors, which I "fix" when prompted.

After reboot and remount - still shows the lost+found directory and nothing else.

I tried the testdisk utility and it reports the ext4 partition but shows the following when attempting to list files:

   P ext4                     0   0  1 121576  93 53 1953124352 [RAID1]
Directory /

No file found, filesystem may be damaged.

The data is backed up, so it's not lost, but I really want to know why this happened, as I was under the impression ext4 was more resilient than this.

Thanks for any ideas or suggestions.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.