所以我在 Ubuntu 桌面上格式化了一个分区 ext4 驱动器。
我将它连接到另一台运行 Debian 的电脑,但无法安装它。
关于如何修复它有什么想法吗?
一些信息:
=> sudo mount -t ext4 /dev/sda1 /media/myuser/storage/
mount: wrong fs type, bad option, bad superblock on /dev/sda1,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so.
root@mydesktop2:/home/myuser/scripts/system# tail /var/log/messages
Feb 24 13:30:31 mydesktop2 kernel: [ 5577.110672] EXT4-fs (sda1): bad geometry: block count 244190390 exceeds size of device (244190389 blocks)
root@mydesktop2:/home/myuser/scripts/system# fdisk /dev/sda
Welcome to fdisk (util-linux 2.29.2).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Command (m for help): p
Disk /dev/sda: 931.5 GiB, 1000204885504 bytes, 1953525167 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x276b2fc9
Device Boot Start End Sectors Size Id Type
/dev/sda1 2048 1953525167 1953523120 931.5G 83 Linux
Command (m for help):
答案1
该问题似乎是由内核确定分区大小的方式不同引起的。如果您再次将驱动器连接到 Ubuntu 系统,您可以将resize2fs
文件系统缩小一块,以便可以将其安装到 Debian 内核上:
resize2fs /dev/sda1 244190389