次に LS-CL
root@LS-CL701:/mnt/disk1/share/hackkit# sh -x hackkit_010.sh + ADDRESS=192.168.2.47 + NETWORK=192.168.2.0 + NETMASK=255.255.255.0 + BROADCAST=192.168.2.255 + GATEWAY=192.168.2.1 + NAMESERVER=192.168.1.2 + HOSTNAME=hackkit + WORK=/mnt/disk1/share/hackkit + HACKKIT=/mnt/disk1/share/hackkit/hackkit_081122.tar.gz + MOUNTPOINT=/mnt/debinst + BOOTPARTITION=/dev/sdb1 + BOOTPARTITIONTYPE=ext3 + ROOTPARTITION=/dev/sdb2 + SWAPPARTITION=/dev/sdb3 + DATAPARTITION=/dev/sdb4 : : + edit_initrd + echo editing initrd ... editing initrd ... + dd if=/mnt/debinst/boot/initrd.buffalo of=/mnt/debinst/boot/initrd.gz bs=64 skip=1 dd: can't open '/mnt/debinst/boot/initrd.buffalo': No such file or directory + echo gunziping /mnt/debinst/boot/initrd.gz ... gunziping /mnt/debinst/boot/initrd.gz ... + gunzip /mnt/debinst/boot/initrd.gz gunzip: /mnt/debinst/boot/initrd.gz: No such file or directory + '[' '!' -d /tmp/root ']' + mkdir /tmp/root + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop0 ']' + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop1 ']' + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop2 ']' + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop3 ']' + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop4 ']' + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop5 ']' + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop6 ']' + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop7 ']' + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop8 ']' + mknod /dev/loop8 b 7 8 + for minor in 0 1 2 3 4 5 6 7 8 9 + '[' '!' -e /dev/loop9 ']' + mknod /dev/loop9 b 7 9 + mount -o loop /mnt/debinst/boot/initrd /tmp/root mount: mounting /mnt/debinst/boot/initrd on /tmp/root failed: No such file or directory + exit root@LS-CL701:/mnt/disk1/share/hackkit#あーぁ。
[yasunari@giga unified]$ diff -u hackkit_010.sh hackkit_012.sh --- hackkit_010.sh 2008-12-05 22:32:34.000000000 +0900 +++ hackkit_012.sh 2007-11-01 00:01:50.000000000 +0900 @@ -532,7 +532,7 @@ copy_boot() { echo copying /boot ... - (cd /boot ; tar cf - uImage.buffalo)|(cd $MOUNTPOINT/boot; tar xvf -) + (cd /boot ; tar cf - initrd.buffalo uImage.buffalo)|(cd $MOUNTPOINT/boot; tar xvf -) } #--------------------------------------------------------- [yasunari@giga unified]$
root@LS-CL701:/mnt/disk1/share/hackkit# umount /mnt/usbdisk1/ root@LS-CL701:/mnt/disk1/share/hackkit# sh hackkit_012.sh PRODUCTID = 0x0000000F formating hard drive ... mke2fs 1.40.5 (27-Jan-2008) Filesystem label= OS type: Linux Block size=1024 (log=0) Fragment size=1024 (log=0) 50200 inodes, 200780 blocks 10039 blocks (5.00%) reserved for the super user First data block=1 Maximum filesystem blocks=67371008 25 block groups 8192 blocks per group, 8192 fragments per group 2008 inodes per group Superblock backups stored on blocks: 8193, 24577, 40961, 57345, 73729 Writing inode tables: done Creating journal (4096 blocks): done Writing superblocks and filesystem accounting information: done This filesystem will be automatically checked every 25 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override. meta-data=/dev/sdb2 isize=256 agcount=8, agsize=62753 blks = sectsz=512 attr=0 data = bsize=4096 blocks=502024, imaxpct=25 = sunit=0 swidth=0 blks, unwritten=1 naming =version 2 bsize=4096 log =internal log bsize=4096 blocks=2560, version=1 = sectsz=512 sunit=0 blks, lazy-count=0 realtime =none extsz=4096 blocks=0, rtextents=0 Setting up swapspace version 1, size = 263204864 bytes meta-data=/dev/sdb4 isize=256 agcount=16, agsize=4845354 blks = sectsz=512 attr=0 data = bsize=4096 blocks=77525664, imaxpct=25 = sunit=0 swidth=0 blks, unwritten=1 naming =version 2 bsize=4096 log =internal log bsize=4096 blocks=32768, version=1 = sectsz=512 sunit=0 blks, lazy-count=0 realtime =none extsz=4096 blocks=0, rtextents=0 mounting root file system ... XFS mounting filesystem sdb2 extracting hackkit archive ... ./ ./var/ ./var/lib/ ./var/lib/apt/ : ./initrd/ creating miconapl ... creating kernelmon ... copying /lib/modules ... lib/modules/ lib/modules/2.6.22.7/ : : lib/modules/2.6.22.7/modules.seriomap creating usb ... umount: cannot umount /mnt/debinst: Device or resource busy checking /dev/sdb1 fsck 1.40.5 (27-Jan-2008) e2fsck 1.40.5 (27-Jan-2008) 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/sdb1: 11/50200 files (9.1% non-contiguous), 12002/200780 blocks mounting /boot ... kjournald starting. Commit interval 5 seconds EXT3 FS on sdb1, internal journal EXT3-fs: mounted filesystem with ordered data mode. copying /boot ... initrd.buffalo uImage.buffalo editing initrd ... 110543+1 records in 110543+1 records out gunziping /mnt/debinst/boot/initrd.gz ... gziping /mnt/debinst/boot/initrd ... wait 5 minutes Image Name: initrd Created: Sat Dec 6 12:11:00 2008 Image Type: ARM Linux RAMDisk Image (gzip compressed) Data Size: 7035151 Bytes = 6870.26 kB = 6.71 MB Load Address: 0x00000000 Entry Point: 0x00000000 unmount /boot ... root@LS-CL701:/mnt/disk1/share/hackkit#
umount: cannot umount /mnt/debinst: Device or resource busy が出ている。再度修正。
[yasunari@giga unified]$ diff -u hackkit_012.sh hackkit_013.sh --- hackkit_012.sh 2007-11-01 00:01:50.000000000 +0900 +++ hackkit_013.sh 2008-12-06 12:50:16.000000000 +0900 @@ -504,6 +504,7 @@ # / のアンマウント umount_root() { + cd / umount $MOUNTPOINT } #====================================================================== [yasunari@giga unified]$
root@LS-CL701:/mnt/disk1/share/hackkit# sh hackkit_013.sh :今度は正常にアンマウントできた。
: : ---- in hackkit linuxrc --- XFS mounting filesystem sda2 VFS: Mounted root (xfs filesystem). Trying to move old root to /initrd ... okay Freeing init memory: 120K INIT: version 2.86 booting Setting the system clock. Activating swap...Adding 257032k swap on /dev/sda3. Priority:-1 extents:1 across:257032k done. Setting the system clock. Cleaning up ifupdown.... Loading kernel modules...done. Checking file systems...fsck 1.41.3 (12-Oct-2008) fsck: cannot check /dev/sda4: fsck.xfs not found /dev/sda1: clean, 13/50200 files, 20978/200780 blocks done. Setting kernel variables (/etc/sysctl.conf)...done. Mounting local filesystems...kjournald starting. Commit interval 5 seconds EXT3 FS on sda1, internal journal EXT3-fs: mounted filesystem with ordered data mode. XFS mounting filesystem sda4 done. Activating swapfile swap...done. Setting up networking.... Configuring network interfaces...eth reg(9) val=0x0300 eth0: link down done. INIT: Entering runlevel: 2 Starting enhanced syslogd: rsyslogd. usbcore: registered new interface driver usbfs usbcore: registered new interface driver hub usbcore: registered new device driver usb ehci_marvell ehci_marvell.4523: Marvell Orion EHCI ehci_marvell ehci_marvell.4523: new USB bus registered, assigned bus number 1 eth0: link up, full duplex, speed 1 Gbps ehci_marvell ehci_marvell.4523: irq 17, io base 0xf1050100 ehci_marvell ehci_marvell.4523: USB 2.0 started, EHCI 1.00, driver 10 Dec 2004 usb usb1: configuration #1 chosen from 1 choice hub 1-0:1.0: USB hub found hub 1-0:1.0: 1 port detected ehci_marvell ehci_marvell.167817: Marvell Orion EHCI ehci_marvell ehci_marvell.167817: new USB bus registered, assigned bus number 2 ehci_marvell ehci_marvell.167817: irq 12, io base 0xf10a0100 ehci_marvell ehci_marvell.167817: USB 2.0 started, EHCI 1.00, driver 10 Dec 2004 usb usb2: configuration #1 chosen from 1 choice hub 2-0:1.0: USB hub found hub 2-0:1.0: 1 port detected USB Universal Host Controller Interface driver v3.0 Initializing USB Mass Storage driver... usbcore: registered new interface driver usb-storage USB Mass Storage support registered. usbcore: registered new interface driver usblp drivers/usb/class/usblp.c: v0.13: USB Printer Device Class driver Starting internet superserver: inetd. Starting periodic command scheduler: crond. Debian GNU/Linux lenny/sid hackkit ttyS0 hackkit login:fsck: cannot check /dev/sda4: fsck.xfs not found
とりあえず、xfsprogs をインストール。
hackkit:~# apt-get install xfsprogs Reading package lists... Done Building dependency tree Reading state information... Done Suggested packages: attr dvhtool quota xfsdump The following NEW packages will be installed: xfsprogs 0 upgraded, 1 newly installed, 0 to remove and 9 not upgraded. Need to get 1523kB of archives. After this operation, 3256kB of additional disk space will be used. Get:1 http://ftp.jp.debian.org lenny/main xfsprogs 2.9.8-1 [1523kB] Fetched 1523kB in 4s (315kB/s) Selecting previously deselected package xfsprogs. (Reading database ... 8549 files and directories currently installed.) Unpacking xfsprogs (from .../xfsprogs_2.9.8-1_armel.deb) ... Processing triggers for man-db ... Setting up xfsprogs (2.9.8-1) ... hackkit:~#再起動して、エラーが出なくなることを確認。
とりあえず、次。
|
← ハックキットの一本化のためのインストーラのデバッグ(1)LS-WSGL |
ハックの記録 LinkStation/玄箱 をハックしよう |
→ 衝撃に備えよ |