mdadm'
我通过dmraid 上的分区创建了 RAID 0威盛VT6421和西部数据硬盘。在该 RAID 上安装了 Ubuntu。现在,当我启动时,我会收到(initramfs)
ash 提示。
在那里,我必须写
mdadm --stop /dev/md1
mdadm --assemble --scan
并按Ctrl+D恢复。然后Ubuntu就可以正常加载了。
我想改变这种行为以节省时间。因此,我需要更改位于/scripts
初始 ramdisk 目录中的一些脚本。但我所知道的一切initramfs
都是它被压缩了。我查了一下update-initramfs
,但还没有找到线索。另外,我害怕在那里做某事,除非我知道自己在做什么。
如何更改 initramfs 脚本?
UPD:现在我知道我应该
gunzip -c initrd.img-3.13.0-24-generic | cpio -id
然后进行更改并重新创建它
find . | cpio -o | gzip -c >/boot/initrd.new.img-3.13.0-24-generic
但我仍然不知道应该编辑哪些脚本。
更新2:sudo parted -l
$ sudo parted -l
Model: JetFlash Transcend 32GB (scsi)
Disk /dev/sda: 32,1GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 131kB 32,1GB 32,1GB primary fat32 boot, lba
Model: WD My Passport 074A (scsi)
Disk /dev/sdb: 1000GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 1049kB 1000GB 1000GB primary ntfs
Model: ATA WDC WD1600JS-22M (scsi)
Disk /dev/sdc: 160GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 1049kB 160GB 160GB primary linux-swap(v1)
Error: Can't have a partition outside the disk!
Model: ATA WDC WD5000AAKS-0 (scsi)
Disk /dev/sde: 500GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
Error: /dev/mapper/via_ecedbfaihb6: unrecognised disk label
Model: Linux device-mapper (linear) (dm)
Disk /dev/mapper/via_ecedbfaihb5: 524MB
Sector size (logical/physical): 512B/512B
Partition Table: loop
Number Start End Size File system Flags
1 0,00B 524MB 524MB ext4
Error: Can't have a partition outside the disk!
Model: Linux device-mapper (linear) (dm)
Disk /dev/mapper/via_ecedbfaihb2: 167GB
Sector size (logical/physical): 512B/512B
Partition Table: loop
Number Start End Size File system Flags
1 0,00B 167GB 167GB ntfs
Model: Linux device-mapper (linear) (dm)
Disk /dev/mapper/via_ecedbfaihb1: 367MB
Sector size (logical/physical): 512B/512B
Partition Table: loop
Number Start End Size File system Flags
1 0,00B 367MB 367MB ntfs
Error: Can't have a partition outside the disk!
Model: Linux Software RAID Array (md)
Disk /dev/md1: 320GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 1049kB 6494MB 6493MB primary linux-swap(v1)
2 6494MB 27,5GB 21,0GB primary ext4
3 27,5GB 320GB 293GB primary ext4
转录:
/dev/sda
&/dev/sdb
每个 500GB 都被命名为 fakeraidvia_ecedbfaihb
,- Win8.1保留分区
via_ecedbfaihb1
(390MB), - Win 8.1系统分区
via_ecedbfaihb2
(160GB), - 扩展分区
via_ecedbfaihb3
, - Linux启动分区
via_ecedbfaihb5
(500MB), - mdadm 第一个分区
via_ecedbfaihb6
(159GB), - 数据分区
via_ecedbfaihb7
与其余空间 /dev/sdc1
mdadm 第二个分区(159GB),/dev/md1
由via_ecedbfaihb6和sdc1组成,/dev/md1p1
交换(6GB),/dev/md1p2
延长,/dev/md1p5
根(20GB),/dev/md1p6
家庭 (~300GB)