yasunari@ude:/mnt/linkstation/HackKit/unified/current$ diff -c hackkit_101128.sh
hackkit_101213.sh
*** hackkit_101128.sh Sun Nov 28 23:43:22 2010
--- hackkit_101213.sh Mon Dec 13 21:43:45 2010
***************
*** 85,95 ****
if [ $RAID = yes ]
then
! mkdir $MOUNTPOINT/.buffalo
! mv $MOUNTPOINT/lib/modules $MOUNTPOINT/.buffalo
rm -fr $MOUNTPOINT/*
mkdir $MOUNTPOINT/lib
! mv $MOUNTPOINT/.buffalo/modules $MOUNTPOINT/lib
rmdir $MOUNTPOINT/.buffalo
fi
--- 85,97 ----
if [ $RAID = yes ]
then
! mkdir $MOUNTPOINT/.buffalo/modules
! mv $MOUNTPOINT/lib/modules/`uname -r` $MOUNTPOINT/.buffalo/modules
rm -fr $MOUNTPOINT/*
mkdir $MOUNTPOINT/lib
! mkdir $MOUNTPOINT/lib/modules
! mv $MOUNTPOINT/.buffalo/modules/`uname -r` $MOUNTPOINT/lib/modules
! rmdir $MOUNTPOINT/.buffalo/modules
rmdir $MOUNTPOINT/.buffalo
fi
***************
*** 377,383 ****
echo copying /lib/modules ...
cd /
! tar cf - lib/modules | (cd $MOUNTPOINT ; tar xvf -)
}
#---------------------------------------------------------
--- 379,385 ----
echo copying /lib/modules ...
cd /
! tar cf - lib/modules/`uname -r` | (cd $MOUNTPOINT ; tar xvf -)
}
#---------------------------------------------------------
yasunari@ude:/mnt/linkstation/HackKit/unified/current$
root@LS-XHL8DF:~#
root@LS-XHL8DF:~# date Tue Dec 21 22:30:55 JST 2010 root@LS-XHL8DF:~#合ってる
ん?ssh が切れた。
再度 SSH
yasunari@sil:~$ ssh -l root brick ssh: connect to host brick port 22: Connection refused yasunari@sil:~$ん?
yasunari@sil:~$ ssh -l root brick root@LS-XHL8DF:~#再起動すると ssh できる
root@LS-XHL8DF:~# !tail tail -f /var/log/messages : : Dec 21 22:39:43 LS-XHL8DF kernel: usb 1-1: new high speed USB device using ehci_marvell and address 2 Dec 21 22:39:43 LS-XHL8DF kernel: usb 1-1: configuration #1 chosen from 1 choice Dec 21 22:39:43 LS-XHL8DF kernel: scsi2 : SCSI emulation for USB Mass Storage devices Dec 21 22:39:48 LS-XHL8DF kernel: scsi 2:0:0:0: Direct-Access ViPowER VP-89118(SD1) 2.10 PQ: 0 ANSI: 4 Dec 21 22:39:48 LS-XHL8DF kernel: sd 2:0:0:0: Attached scsi generic sg1 type 0 Dec 21 22:39:48 LS-XHL8DF kernel: sd 2:0:0:0: [sdb] 312581808 512-byte logical blocks: (160 GB/149 GiB) Dec 21 22:39:48 LS-XHL8DF kernel: sd 2:0:0:0: [sdb] Write Protect is off Dec 21 22:39:48 LS-XHL8DF kernel: sd 2:0:0:0: [sdb] Assuming drive cache: write through Dec 21 22:39:48 LS-XHL8DF kernel: sd 2:0:0:0: [sdb] Assuming drive cache: write through Dec 21 22:39:48 LS-XHL8DF kernel: sdb: sdb1 sdb2 sdb3 sdb4 Dec 21 22:39:48 LS-XHL8DF kernel: sd 2:0:0:0: [sdb] Assuming drive cache: write through Dec 21 22:39:48 LS-XHL8DF kernel: sd 2:0:0:0: [sdb] Attached SCSI disk Dec 21 22:39:50 LS-XHL8DF kernel: kjournald starting. Commit interval 5 seconds Dec 21 22:39:50 LS-XHL8DF kernel: EXT3-fs warning: checktime reached, running e2fsck is recommended Dec 21 22:39:50 LS-XHL8DF kernel: EXT3 FS on sdb1, internal journal Dec 21 22:39:50 LS-XHL8DF kernel: EXT3-fs: recovery complete. Dec 21 22:39:50 LS-XHL8DF kernel: EXT3-fs: mounted filesystem with writeback data mode. Dec 21 22:39:53 LS-XHL8DF nmbd[1809]: [2010/12/21 22:39:53, 0] nmbd/nmbd.c:terminate(58) Dec 21 22:39:54 LS-XHL8DF nmbd[1809]: Got SIGTERM: going down... Dec 21 22:39:54 LS-XHL8DF lprmd[1934]: exit.: sig=15 Dec 21 22:39:54 LS-XHL8DF twonky: Media Server script is begun. type=stop Dec 21 22:39:57 LS-XHL8DF twonky: stop Media Server Connection to brick closed by remote host. Connection to brick closed. yasunari@sil:~$ !ssh ssh -l root brick ssh: connect to host brick port 22: Connection refused yasunari@sil:~$うーん、やっぱり HDD をつなぐと ssh が切れて、 その後は Connection refused
困った
yasunari@sil:~$ ssh -l root brick root@LS-XHL8DF:~# df Filesystem 1k-blocks Used Available Use% Mounted on /dev/sda2 4993984 512680 4481304 10% / udev 10240 112 10128 1% /dev /dev/ram1 15360 140 15220 1% /mnt/ram /dev/sda1 996052 208720 787332 21% /boot /dev/usbdisk1_1 992036 28396 913644 3% /mnt/usbdisk1 /dev/disk1_6 187419036 360648 187058388 0% /mnt/disk1 root@LS-XHL8DF:~#やたぁー
root@LS-XHL8DF:~# umount /mnt/usbdisk1/ root@LS-XHL8DF:~#
root@LS-XHL8DF:~# parted -s /dev/sdb print Model: ViPowER VP-89118(SD1) (scsi) Disk /dev/sdb: 160GB Sector size (logical/physical): 512B/512B Partition Table: gpt Number Start End Size File system Name Flags 1 17.4kB 1024MB 1024MB ext3 primary 2 1024MB 6144MB 5120MB xfs primary 3 6144MB 7168MB 1024MB linux-swap primary 4 7168MB 160GB 153GB xfs primary root@LS-XHL8DF:~#
root@LS-XHL8DF:/mnt/disk1/share/hackkit# cat hackkit_config ADDRESS=192.168.2.49 HOSTNAME=brick root@LS-XHL8DF:/mnt/disk1/share/hackkit#
root@LS-XHL8DF:/mnt/disk1/share/hackkit# sh hackkit_101213.sh
PRODUCTID = 0x00000011
MACHINE LSXHL
formating hard drive ...
mke2fs 1.40.5 (27-Jan-2008)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
62720 inodes, 249995 blocks
12499 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=260046848
8 block groups
32768 blocks per group, 32768 fragments per group
7840 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376
Writing inode tables: done
Creating journal (4096 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 24 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
meta-data=/dev/sdb2 isize=256 agcount=8, agsize=156250 blks
= sectsz=512 attr=0
data = bsize=4096 blocks=1250000, 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 = 1023995904 bytes
meta-data=/dev/sdb4 isize=256 agcount=16, agsize=2332670 blks
= sectsz=512 attr=0
data = bsize=4096 blocks=37322720, imaxpct=25
= sunit=0 swidth=0 blks, unwritten=1
naming =version 2 bsize=4096
log =internal log bsize=4096 blocks=18223, version=1
= sectsz=512 sunit=0 blks, lazy-count=0
realtime =none extsz=4096 blocks=0, rtextents=0
mounting root file system ...
extracting hackkit archive ...
./
./var/
./var/lib/
./var/lib/apt/
./var/lib/apt/lists/
:
:
lib/modules/2.6.31.8-svn22059/modules.dep
lib/modules/2.6.31.8-svn22059/modules.order
lib/modules/2.6.31.8-svn22059/modules.ofmap
lib/modules/2.6.31.8-svn22059/modules.symbols
lib/modules/2.6.31.8-svn22059/modules.seriomap
creating usb ...
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/62720 files (9.1% non-contiguous), 6399/249995 blocks
mounting /boot ...
copying /boot ...
initrd.buffalo
uImage.buffalo
editing initrd ...
170752+1 records in
170752+1 records out
gunziping /mnt/debinst/boot/initrd.gz ...
gziping /mnt/debinst/boot/initrd ... wait 5 minutes
Image Name: initrd
Created: Tue Dec 21 22:56:14 2010
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 10875415 Bytes = 10620.52 kB = 10.37 MB
Load Address: 0x00000000
Entry Point: 0x00000000
unmount /boot ...
root@LS-XHL8DF:/mnt/disk1/share/hackkit#
でけた。
root@LS-XHL8DF:/mnt/disk1/share/hackkit# mkdir /tmp/root mkdir: cannot create directory '/tmp/root': File exists root@LS-XHL8DF:/mnt/disk1/share/hackkit# mount /dev/sdb2 /tmp/root root@LS-XHL8DF:/mnt/disk1/share/hackkit# ls /tmp/root/lib/modules/ 2.6.31.8-svn22059 root@LS-XHL8DF:/mnt/disk1/share/hackkit# uname -a Linux LS-XHL8DF 2.6.31.8-svn22059 #67 Mon Sep 13 09:42:55 JST 2010 armv5tel unknown root@LS-XHL8DF:/mnt/disk1/share/hackkit#OK! good going!
|
|
← HDD の増設 |
ハックの記録 LinkStation/玄箱 をハックしよう |
→ ハックキットの動作確認 |