Open Benjamin-Loison opened 1 month ago
df -h
does not return anything relevant.
sudo fdisk -l
...
Disk /dev/sda: 5.46 TiB, 6001175125504 bytes, 11721045167 sectors
Disk model: Expansion Desk
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
sudo gparted
GParted 1.5.0
configuration --enable-libparted-dmraid --enable-online-resize
libparted 3.6
/dev/mapper/nvme0n1p3_crypt: unrecognised disk label
sudo apt install -y apt-show-versions
Source: the Unix Stack Exchange answer 6286
apt-show-versions e2fsprogs
e2fsprogs:amd64/noble-updates 1.47.0-2.4~exp1ubuntu4.1 uptodate
e2fsprogs:i386 not installed
I suspect the disk to be NTFS.
On Linux Mint 22 Cinnamon Framework 13 VirtualBox Windows (trust) virtual machine even with 3 USB versions, nothing detected for each in This PC and Disk Management. Note that I paid attention not to mount the HDD on the host.
Should try on a native Windows. Same issue...
As administrator:
diskpart
Microsoft DiskPart version 10.0.22621.1
Copyright (C) Microsoft Corporation.
On computer: PEGASUS_WINDOWS
DISKPART> lis dis
Disk ### Status Size Free Dyn Gpt
Disk 0 Online 931 GB 1024 KB *
Maybe the disk was not correctly plugged.
Maybe I already opened a similar issue at Benjamin_Loison/linux/issues. Does not seem to be the case after a per title review.
sudo mount /dev/sda usb0
mount: /mnt/usb0: wrong fs type, bad option, bad superblock on /dev/sda, missing codepage or helper program, or other error.
dmesg(1) may have more information after failed mount system call.
dmesg
[76675.271525] sd 0:0:0:0: [sda] 11721045167 512-byte logical blocks: (6.00 TB/5.46 TiB)
[76675.271906] sd 0:0:0:0: [sda] Write Protect is off
[76675.271912] sd 0:0:0:0: [sda] Mode Sense: 4f 00 00 00
[76675.272185] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[76675.272386] sd 0:0:0:0: [sda] Preferred minimum I/O size 512 bytes
[76675.272394] sd 0:0:0:0: [sda] Optimal transfer size 33553920 bytes
[76675.286206] sd 0:0:0:0: [sda] Attached SCSI disk
[76675.551672] EXT4-fs (sda): bad geometry: block count 1465130646 exceeds size of device (1465130645 blocks)
sudo e2fsck /dev/sda
e2fsck 1.47.0 (5-Feb-2023)
The filesystem size (according to the superblock) is 1465130646 blocks
The physical size of the device is 1465130645 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort<y>? no
/dev/sda contains a file system with errors, check forced.
Pass 1: Checking inodes, blocks, and sizes
Inode 38 extent tree (at level 1) could be narrower. Optimize<y>? yes to all
Pass 1E: Optimizing extent trees
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/sda: ***** FILE SYSTEM WAS MODIFIED *****
/dev/sda: 1151814/183144448 files (0.1% non-contiguous), 1349520583/1465130646 blocks
sudo e2fsck /dev/sda
e2fsck 1.47.0 (5-Feb-2023)
The filesystem size (according to the superblock) is 1465130646 blocks
The physical size of the device is 1465130645 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort<y>?
DuckDuckGo and Google search for "bad geometry: block count" "exceeds size of device" differs by 1
"1465130646" "1465130645"
:
https://www.truenas.com/community/threads/troubleshooting-disk-format-warnings-in-truenas-scale.106051/page-4 https://bugzilla.redhat.com/show_bug.cgi?id=1344102 https://cloud.tencent.com/developer/ask/sof/116468043 https://www.truenas.com/community/threads/error-formating-hdd-from-4k-type-2-protection-to-512.106632/
gparted
Resize/Move does not seem block precise.
sudo fsck -b 32768 /dev/sda
fsck from util-linux 2.39.3
e2fsck 1.47.0 (5-Feb-2023)
The filesystem size (according to the superblock) is 1465130646 blocks
The physical size of the device is 1465130645 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort<y>? cancelled!
/dev/sda: ***** FILE SYSTEM WAS MODIFIED *****
/dev/sda: ********** WARNING: Filesystem still has errors **********
sudo sfdisk -d /dev/sda
sfdisk: /dev/sda: does not contain a recognized partition table
sudo fdisk -s /dev/sda
5860522583
gparted
Searching for file systems on /dev/sda takes a while.
When I stop it before it finishes:
sudo mount -t ext4 -o ro /dev/sda usb0
mount: /mnt/usb0: wrong fs type, bad option, bad superblock on /dev/sda, missing codepage or helper program, or other error.
dmesg(1) may have more information after failed mount system call.
sudo resize2fs /dev/sda
resize2fs 1.47.0 (5-Feb-2023)
Resizing the filesystem on /dev/sda to 1465130645 (4k) blocks.
resize2fs: Attempt to read block from filesystem resulted in short read while trying to resize /dev/sda
Please run 'e2fsck -fy /dev/sda' to fix the filesystem
after the aborted resize operation.
sudo mount -t ext4 -o ro /dev/sda usb0
mount: /mnt/usb0: wrong fs type, bad option, bad superblock on /dev/sda, missing codepage or helper program, or other error.
dmesg(1) may have more information after failed mount system call.
dmesg
...
EXT4-fs (sda): bad geometry: block count 1465130646 exceeds size of device (1465130645 blocks)
sudo e2fsck -fy /dev/sda
e2fsck 1.47.0 (5-Feb-2023)
The filesystem size (according to the superblock) is 1465130646 blocks
The physical size of the device is 1465130645 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort? yes
sudo e2fsck -f /dev/sda
e2fsck 1.47.0 (5-Feb-2023)
The filesystem size (according to the superblock) is 1465130646 blocks
The physical size of the device is 1465130645 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort<y>? no
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/sda: 1151814/183144448 files (0.1% non-contiguous), 1349520583/1465130646 blocks
sudo resize2fs /dev/sda
resize2fs 1.47.0 (5-Feb-2023)
Resizing the filesystem on /dev/sda to 1465130645 (4k) blocks.
resize2fs: Attempt to read block from filesystem resulted in short read while trying to resize /dev/sda
Please run 'e2fsck -fy /dev/sda' to fix the filesystem
after the aborted resize operation.
man resize2fs
sudo resize2fs -f /dev/sda
resize2fs 1.47.0 (5-Feb-2023)
Resizing the filesystem on /dev/sda to 1465130645 (4k) blocks.
resize2fs: Attempt to read block from filesystem resulted in short read while trying to resize /dev/sda
Please run 'e2fsck -fy /dev/sda' to fix the filesystem
after the aborted resize operation.
sudo resize2fs -b /dev/sda
resize2fs 1.47.0 (5-Feb-2023)
Please run 'e2fsck -f /dev/sda' first.
sudo sfdisk -luS /dev/sd?
Disk /dev/sda: 5.46 TiB, 6001175125504 bytes, 11721045167 sectors
Disk model: Expansion Desk
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
DuckDuckGo and Google results for "resize2fs: Attempt to read block from filesystem resulted in short read while trying to resize" "Either the superblock or the partition table is likely to be corrupt!"
do not seem to help much.
sudo mke2fs -n /dev/sda
mke2fs 1.47.0 (5-Feb-2023)
/dev/sda contains a ext4 file system
last mounted on /mnt/sata0 on Thu May 2 17:10:27 2024
Proceed anyway? (y,N) y
Creating filesystem with 1465130645 4k blocks and 183144448 inodes
Filesystem UUID: 6397dd91-f06e-4cf5-89c5-c495099a462e
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848, 512000000, 550731776, 644972544
sudo e2fsck -b 32768 -f /dev/sda
sudo e2fsck -b 32768 -f /dev/sda
https://www.debian-fr.org/t/erreur-gparted-redimensionner/78632/21
time sudo e2fsck -c /dev/sda; echo $?; matrix-commander-rs -m 'e2fsck finished!'
e2fsck 1.47.0 (5-Feb-2023)
https://www.linuxquestions.org/questions/linux-general-1/cannot-mount-hard-disk-block-count-exceeds-size-of-device-bad-partition-table-880149/ https://www.cgsecurity.org/wiki/Advanced_Find_ext2_ext3_Backup_SuperBlock https://www.cgsecurity.org/wiki/TestDisk https://www.truenas.com/community/threads/troubleshooting-disk-format-warnings-in-truenas-scale.106051/page-4 https://bugzilla.redhat.com/show_bug.cgi?id=1344102 https://cloud.tencent.com/developer/ask/sof/116468043 https://www.truenas.com/community/threads/error-formating-hdd-from-4k-type-2-protection-to-512.106632/ https://groups.google.com/g/alt-f/c/nuGn555lzVA/m/960dmg3b99IJ https://ubuntuforums.org/showthread.php?t=1820896
Maybe the issue comes from my adapter? Let us try to access it from a Debian 12 GNOME with SATA.
It works fine...
So can just work from this setup as it detects correctly my Linux Mint 22 Cinnamon Framework 13 M.2 disk:
Distribution
Not read.
Package version
Not read.
Frequency
Always
Bug description
With LDLC: PB00466755.
Steps to reproduce
Not read.
Expected behavior
Not read.
Additional information
No response