![ext4 分区有效,但 fdisk 没有显示有效的分区表](https://linux22.com/image/1080381/ext4%20%E5%88%86%E5%8C%BA%E6%9C%89%E6%95%88%EF%BC%8C%E4%BD%86%20fdisk%20%E6%B2%A1%E6%9C%89%E6%98%BE%E7%A4%BA%E6%9C%89%E6%95%88%E7%9A%84%E5%88%86%E5%8C%BA%E8%A1%A8.png)
我有一个 1TB 的磁盘,其中有一个 ext4 分区。
以下是 parted print all 命令的一些输出
Model: ATA Hitachi HDS72101 (scsi)
Disk /dev/sdb: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: loop
Number Start End Size File system Flags
1 0.00B 1000GB 1000GB ext4
但是 fdisk 报告说没有有效的分区
Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00000000
Disk /dev/sdb doesn't contain a valid partition table
testdisk /dev/sdb 报告
Disk /dev/sdb - 1000 GB / 931 GiB - CHS 121601 255 63
Current partition structure:
Partition Start End Size in sectors
Partition sector doesn't have the endmark 0xAA55
然后 testdisk deepscan 发现
Linux 0 0 1 121601 80 63 1953525168 [storage]
当我尝试在 testdisk 中添加此分区时,它没有执行任何操作,只是退出到显示没有分区的屏幕。
dumpe2fs -h /dev/sdb 返回以下信息
dumpe2fs 1.42.5 (29-Jul-2012)
Filesystem volume name: storage
Last mounted on: /mnt/storage
Filesystem UUID: 5889e47c-b13b-4157-9161-0e7a31095b12
Filesystem magic number: 0xEF53
Filesystem revision #: 1 (dynamic)
Filesystem features: has_journal ext_attr resize_inode dir_index
filetype extent flex_bg sparse_super large_file
huge_file uninit_bg dir_nlink extra_isize
Filesystem flags: signed_directory_hash
Default mount options: user_xattr acl
Filesystem state: clean
Errors behavior: Continue
Filesystem OS type: Linux
Inode count: 61054976
Block count: 244190646
Reserved block count: 12209532
Free blocks: 139902528
Free inodes: 60775208
First block: 0
Block size: 4096
Fragment size: 4096
Reserved GDT blocks: 965
Blocks per group: 32768
Fragments per group: 32768
Inodes per group: 8192
Inode blocks per group: 512
Flex block group size: 16
Filesystem created: Sat Sep 15 14:29:58 2012
Last mount time: Sat Jun 1 19:53:40 2013
Last write time: Sat Jun 1 22:29:09 2013
Mount count: 0
Maximum mount count: -1
Last checked: Sat Jun 1 22:29:09 2013
Check interval: 0 (<none>)
Lifetime writes: 79 GB
Reserved blocks uid: 0 (user root)
Reserved blocks gid: 0 (group root)
First inode: 11
Inode size: 256
Required extra isize: 28
Desired extra isize: 28
Journal inode: 8
Default directory hash: half_md4
Directory Hash Seed: 1d72f9a3-8c59-4b86-9e02-b9ab512ce90c
Journal backup: inode blocks
Journal features: journal_incompat_revoke
Journal size: 128M
Journal length: 32768
Journal sequence: 0x00009489
Journal start: 0
这是我每天使用的辅助数据驱动器。上面有我不想删除的数据。我不确定我是否应该担心这个问题,或者我是否不应该担心这个问题。磁盘可以正常工作,但我不知道它是否会发生故障。
问题:如果我想确保磁盘设置最佳,我该去哪里?
答案1
在我看来,您已将文件系统“原始”地放置在磁盘上,而没有使用任何分区表。这很不寻常且有限制,但它确实有效。如果您认为近期不需要缩小现有文件系统并添加新分区,我会保持原样,因为在此设置中添加分区表会很困难,甚至可能有点冒险。