debian-minirootをセットアップ
自力で玄箱PRO仕様のDebian化はなかなか敷居が高そうなのでsushi-k氏が作成されたdebian-minirootを使用します。作業前には事前に
sushi-k日誌2で「KURO-BOX/PRO Debian化決定版?」をよく読み、必要な「gnutar_kuropro.gz」「debian_kit.tar.gz」「hddrootfs.tar.gz」「uImage.buffalo」の4ファイルを入手しておきます。
sushi-k氏のdebian-minirootを準備する
- \\kurobox-pro\shareへdebian_kit.tar.gzとgnutar_kuropro.gzを転送
- GNU tarの導入
~ # cd /mnt/disk1
/mnt/disk1 # rm /bin/tar
/mnt/disk1 # gzip -dc gnutar_kuropro.gz >/bin/tar
/mnt/disk1 # chmod a+x /bin/tar
- OABIなmkfs.ext3を含むDebian化キット導入
/mnt/disk1 # tar xvzpf debian_kit.tar.gz -C /
- \\kurobox-pro\mtd deviceへhddrootfs.tar.gzとuImage.buffaloとChangeMeDevHDDとChangeMyUbootEnvを転送
- HDDを初期化する
~ # /usr/local/bin/DiskDelete.sh
背面INITボタンを押してHDD環境をセットアップする
- 背面スイッチを長押しする
- 処理が動いているか不安なのでtopでモニタする
~ # top
- オレンジのランプが消えたら初期化終了なので一度シャットダウンする
~ # shutdown -h
Orion1 CPU = Low
=== KURO U-Boot. ===
** LOADER **
** KUROBOX BOARD: KURO_BOX LE (CFG_ENV_ADDR=fffff000)
U-Boot 1.1.1 (Apr 10 2007 - 18:10:08) Marvell version: 1.12.1 - TINY
DRAM CS[0] base 0x00000000 size 128MB
DRAM Total size 128MB
[256kB@fffc0000] Flash: 256 kB
Addresses 20M - 0M are saved for the U-Boot usage.
Mem malloc Initialization (20M - 16M): Done
NAND: 256 MB
Soc: 88F5182 A2
CPU: ARM926 (Rev 0) running @ 500Mhz
Orion 1 streaming disabled
SysClock = 250Mhz , TClock = 166Mhz
USB 0: host mode
USB 1: host mode
PCI 0: PCI Express Root Complex Interface
PCI 1: Conventional PCI, speed = 33000000
Net: egiga0 [PRIME]
Using 88E1118 phy
hit any key to switch tftp boot.
Hit any key to stop autoboot: 0
<<system_bootend>>
Hit any key to stop autoboot: 0
Reset IDE:
Marvell Serial ATA Adapter
Integrated Sata device found
Device 0: OK
Model: Hitachi HDT725050VLA360 Firm: V56OA52A Ser#:
VFB400R4C28DDA
Type: Hard Disk
Supports 48-bit addressing
Capacity: 476940.0 MB = 465.7 GB (976773168 x 512)
Using device ide0, partition 1
Loading from block device ide device 0, partition 1: Name: hda1
Type: U-Boot File:/uImage.buffalo
1717540 bytes read
<<stop_sound>>
## Booting image at 00100000 ...
Image Name: Linux-2.6.12.6-mda1
Created: 2007-04-22 7:17:43 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 1717476 Bytes = 1.6 MB
Load Address: 00008000
Entry Point: 00008000
Verifying Checksum ... OK
OK
Starting kernel ...
arg:console=ttyS0,115200 root=/dev/sda2 rw panic=5 BOOTVER=1.09
CONFIG_KUROBOX_PLATFORM CONFIG_KUROBOX_KUROBOX ---
Uncompressing Linux.......................................................
........................................................ done, booting the
kernel.
Linux version 2.6.12.6-mda1 (root@kurobox) (gcc version 4.1.2 20061115 (pr
erelease) (Debian 4.1.1-21)) #2 Sun Apr 22 16:16:39 JST 2007
CPU: ARM926EJ-Sid(wb) [41069260] revision 0 (ARMv5TEJ)
CPU0: D VIVT write-back cache
CPU0: I cache: 32768 bytes, associativity 1, 32 byte lines, 1024 sets
CPU0: D cache: 32768 bytes, associativity 1, 32 byte lines, 1024 sets
Machine: MV-88fxx81
Using UBoot passing parameters structure
Sys Clk = 250000000, Tclk = 166664740
Memory policy: ECC disabled, Data cache writeback
Built 1 zonelists
Kernel command line: console=ttyS0,115200 root=/dev/sda2 rw panic=5 BOOTVE
R=1.09
PID hash table entries: 1024 (order: 10, 16384 bytes)
Console: colour dummy device 80x30
Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
Memory: 128MB 0MB 0MB 0MB = 128MB total
Memory: 126208KB available (2987K code, 421K data, 108K init)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
NET: Registered protocol family 16
serial_initialize_ttyS1 (Debug): ttyS1 is initialized.
config_device_cs Error : Unknown board
CPU Interface
-------------
SDRAM_CS0 ....base 00000000, size 128MB
SDRAM_CS1 ....disable
SDRAM_CS2 ....disable
SDRAM_CS3 ....disable
PEX0_MEM ....base e0000000, size 128MB
PEX0_IO ....base f2000000, size 1MB
PCI0_MEM ....base e8000000, size 128MB
PCI0_IO ....base f2100000, size 1MB
INTER_REGS ....base f1000000, size 1MB
DEVICE_CS0 ....base fa000000, size 2MB
DEVICE_CS1 ....base f4000000, size 32MB
DEVICE_CS2 ....base fa800000, size 1MB
DEV_BOOCS ....base ff800000, size 8MB
CRYPTO ENG ....no such
Flash bankwidth 1, base ff800000, size 400000
KUROBOX FLASH size 4096[KB]
Marvell Development Board (LSP Version 1.10.3.patch5_DB_NAS)-- KUROBOX_B
OARD_KUROBOX Soc: 88F5182 A2
Detected Tclk 166664740 and SysClk 250000000
Marvell USB EHCI Host controller #0: c04d5b00
Marvell USB EHCI Host controller #1: c04d5a40
pexBarOverlapDetect: winNum 2 overlap current 0
mvPexInit:Warning :Bar 2 size is illigal
it will be disabled
please check Pex and CPU windows configuration
PCI: bus0: Fast back to back transfers enabled
PCI: bus1: Fast back to back transfers enabled
SCSI subsystem initialized
usbcore: registered new driver usbfs
usbcore: registered new driver hub
Use the XOR engines (offloading) for enhancing the following functions:
o RAID 5 Xor calculation
o kernel memcpy
o kenrel memzero
o copy user to/from kernel buffers
Number of XOR engines to use: 2
cesadev_init(c0012240)
Fast Floating Point Emulator V0.9 (c) Peter Teichmann.
inotify device minor=63
JFFS2 version 2.2. (NAND) (C) 2001-2003 Red Hat, Inc.
SGI XFS with no debug enabled
Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled
ttyS0 at MMIO 0x0 (irq = 3) is a 16550A
ttyS1 at MMIO 0x0 (irq = 4) is a 16550A
io scheduler noop registered
io scheduler anticipatory registered
io scheduler deadline registered
io scheduler cfq registered
RAMDISK driver initialized: 3 RAM disks of 32768K size 1024 blocksize
loop: loaded (max 8 devices)
Marvell Gigabit Ethernet Driver 'egiga':
o Ethernet descriptors in DRAM
o DRAM SW cache-coherency
o Checksum offload enabled
o Loading network interface ** egiga_init_module (6)
'eth0'
Intergrated Sata device found
scsi0 : Marvell SCSI to SATA adapter
scsi1 : Marvell SCSI to SATA adapter
Vendor: Hitachi Model: HDT725050VLA360 Rev: V56O
Type: Direct-Access ANSI SCSI revision: 03
SCSI device sda: 976773168 512-byte hdwr sectors (500108 MB)
SCSI device sda: drive cache: write back
SCSI device sda: 976773168 512-byte hdwr sectors (500108 MB)
SCSI device sda: drive cache: write back
sda: sda1 sda2 sda3 sda4
Attached scsi disk sda at scsi0, channel 0, id 0, lun 0
Attached scsi generic sg0 at scsi0, channel 0, id 0, lun 0, type 0
physmap flash device: 400000 at ff800000
Found: SST 39LF020
phys_mapped_flash: Found 1 x8 devices at 0x0 in 8-bit bank
number of JEDEC chips: 1
cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.
RedBoot partition parsing not available
NAND device: Manufacturer ID: 0x20, Chip ID: 0xda (ST Micro NAND 256MiB 3,
3V 8-bit)
Scanning device for bad blocks
Bad eraseblock 854 at 0x06ac0000
Using static partition definition
Creating 3 MTD partitions on "nand_mtd":
0x00000000-0x00400000 : "uImage"
0x00400000-0x04400000 : "rootfs"
0x04400000-0x10000000 : "extra"
usbmon: debugs is not available
ehci_platform ehci_platform.4523: EHCI Host Controller
ehci_platform ehci_platform.4523: new USB bus registered, assigned bus num
ber 1
ehci_platform ehci_platform.4523: irq 17, io mem 0x00000000
ehci_platform ehci_platform.4523: park 0
ehci_platform ehci_platform.4523: USB 0.0 initialized, EHCI 1.00, driver 1
0 Dec 2004
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
ehci_platform ehci_platform.16781: EHCI Host Controller
ehci_platform ehci_platform.16781: new USB bus registered, assigned bus nu
mber 2
ehci_platform ehci_platform.16781: irq 12, io mem 0x00000000
ehci_platform ehci_platform.16781: park 0
ehci_platform ehci_platform.16781: USB 0.0 initialized, EHCI 1.00, driver
10 Dec 2004
hub 2-0:1.0: USB hub found
hub 2-0:1.0: 1 port detected
USB Universal Host Controller Interface driver v2.2
Initializing USB Mass Storage driver...
usbcore: registered new driver usb-storage
USB Mass Storage support registered.
usbcore: registered new driver usbhid
drivers/usb/input/hid-core.c: v2.01:USB HID core driver
mice: PS/2 mouse device common for all mice
md: raid0 personality registered as nr 2
md: raid1 personality registered as nr 3
md: raid5 personality registered as nr 4
raid5: measuring checksumming speed
arm4regs : 309.200 MB/sec
8regs : 269.200 MB/sec
32regs : 200.000 MB/sec
raid5: using function: arm4regs (309.200 MB/sec)
md: md driver 0.90.1 MAX_MD_DEVS=256, MD_SB_DISKS=27
Buffalo Platform Linux Driver(Light) 0.01 installed.
MICON ctrl (C) BUFFALO INC. V.1.00 installed.
Kernel event proc (C) BUFFALO INC. V.1.00 installed.
MICON V2 (C) BUFFALO INC. V.1.00 installed.
NET: Registered protocol family 2
IP: routing cache hash table of 1024 buckets, 8Kbytes
TCP established hash table entries: 8192 (order: 4, 65536 bytes)
TCP bind hash table entries: 8192 (order: 3, 32768 bytes)
TCP: Hash tables configured (established 8192 bind 8192)
NET: Registered protocol family 1
NET: Registered protocol family 17
md: Autodetecting RAID arrays.
md: autorun ...
md: ... autorun DONE.
kjournald starting. Commit interval 5 seconds
EXT3 FS on sda2, internal journal
EXT3-fs: recovery complete.
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem).
Freeing init memory: 108K
INIT: version 2.86 booting
Activating swap...Adding 136544k swap on /dev/sda3. Priority:-1 extents:1
done.
Checking root file system...fsck 1.40-WIP (14-Nov-2006)
/dev/sda2 has gone 36051 days without being checked, check forced.
/dev/sda2: 8298/367616 files (0.8% non-contiguous), 204892/2939892 blocks
done.
EXT3 FS on sda2, internal journal
Setting the system clock..
Cleaning up ifupdown....
Loading device-mapper support.
Checking file systems...fsck 1.40-WIP (14-Nov-2006)
/dev/sda1: recovering journal
/dev/sda1: clean, 12/7056 files, 6718/56196 blocks
done.
Setting kernel variables...done.
Mounting local filesystems...kjournald starting. Commit interval 5 second
s
EXT3 FS on sda1, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
done.
Activating swapfile swap...done.
Setting up networking....
Configuring network interfaces...eth0: link down
done.
eth0: link up<5>, full duplex<5>, speed 100 Mbps<5>
INIT: Entering runlevel: 2
Starting system log daemon: syslogd.
Starting kernel log daemon: klogd.
* Not starting internet superserver: no services enabled.
Starting OpenBSD Secure Shell server: sshd.
Starting periodic command scheduler: crond.
Debian GNU/Linux 4.0 kurobox ttyS0
kurobox login: root
Password:
Last login: Fri Mar 9 16:42:48 2007 from localhost.localdomain on pts/0
Linux kurobox 2.6.12.6-mda1 #2 Sun Apr 22 16:16:39 JST 2007 armv5tejl
The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
kurobox:~#
- ホスト名をKUROBOX-PROに変更する(あとで再起動したあとに有効になる)
kurobox:~# vi /etc/hostname
#kurobox
KUROBOX-PRO
kurobox:~# vi /etc/hosts
#127.0.0.1 localhost.localdomain localhost kurobox
127.0.0.1 localhost.localdomain localhost KUROBOX-PRO
chmod 666 /dev/tty
chmod 4755 /bin/ping
mkdir /mnt/authtest
mkdir /mnt/boot
mkdir /mnt/disk1
mkdir /mnt/mtd
mkdir /mnt/nfs
mkdir /mnt/ram
mkdir /mnt/root
mkdir /mnt/rootfs
mkdir /mnt/usbdisk1
mkdir /mnt/usbdisk2
- ブートしたときに/dev/sda4を/mnt/disk1にマウントするようにfstabを編集する
kurobox:~# vi /etc/fstab
/dev/sda4 /mnt/disk1 ext3 defaults 1 1
kurobox:~# vi etc/network/interfaces
# Used by ifup(8) and ifdown(8). See the interfaces(5) manpage or
# /usr/share/doc/ifupdown/examples for more information.
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet dhcp
kurobox:~# ifdown eth0
kurobox:~# ifup eth0
- shutdown -h now コマンドでパワーダウンだけで終わってしまうので電源断できるようにする
kurobox:~# vi /etc/default/halt
#HALT=poweroff
HALT=halt
kurobox:~# shutdown -h now
最終更新日:2007-05-29
最終更新:2007年05月29日 13:44