0

I erased my PC and clean installed Ubuntu 22.04 on my SSD. I plan on using my HDD for game/media storage. Since I also wiped the HDD before (free space) I used GParted to make a partition on the HDD, but it appears to be read only. I shouldn't have Windows 10 on my machine anymore and the HDD filesystem is ext4. Below is the output when I ran sudo fsck /dev/sda

fsck from util-linux 2.37.2
e2fsck 1.46.5 (30-Dec-2021)
ext2fs_open2: Bad magic number in super-block
fsck.ext2: Superblock invalid, trying backup blocks...
fsck.ext2: Bad magic number in super-block while trying to open /dev/sda

The superblock could not be read or does not describe a valid ext2/ext3/ext4 filesystem. If the device is valid and it really contains an ext2/ext3/ext4 filesystem (and not swap or ufs or something else), then the superblock is corrupt, and you might try running e2fsck with an alternate superblock: e2fsck -b 8193 <device> or e2fsck -b 32768 <device>

Found a gpt partition table in /dev/sda

So it appears my superblock is corrupt? Gparted does show my HDD as ext4 primary volume and has nothing else on it. Any ideas?

slugga
  • 3
  • 2
    You did not show command? Did you run fsck on sda a drive, not on the partition sda1? You can only run fsck or e2fsck on partitions. And once you format a partition you have to give yourself ownership & permissions to use it. https://askubuntu.com/questions/642504/ubuntu-14-04-is-not-booting-normaly-after-a-manual-hard-boot/642789#642789 Best to also create mount point & mount using fstab. https://askubuntu.com/questions/1013677/storing-data-on-second-hdd-mounting/1013700#1013700 – oldfred Aug 07 '22 at 22:28

1 Answers1

2

If you made a new ext4 partition, that partition would be "/dev/sda1", but you ran fsck on "/dev/sda", which is the whole device starting with a partition table, which of course is not a valid ext4 super-block. fsck gave you a hint on that in the last line of its output, telling you that it found said partition table instead.

So there's nothing wrong with your HDD, just with the argument to your fsck command.

Bachsau
  • 176