kuro-box
  玄箱/Linkstation
    families
  HD-LAN
    入手
      flash
      取出
      HD-LAN vs HD-HLAN
    玄箱に変身
  HD-HGLAN
hardware
  Diag LED の点滅回数
  serial console
    9-KE connection
    clock speed
    shell
    mfdisk
      # mfdisk -h
      # mfdisk -c /dev/hda
      # mfdisk -p /dev/hda
      # mfdisk -e /dev/hda
      # mfdisk -p /dev/hda
      # mfdisk -c /dev/hda
  JTAG connection
    parallel port
    USB
  flash ROM
    firmbin.img
  firmimgtool
  しくみ
    玄箱
    LinkStation
      HD-HGLAN
    TeraStation
      TS-TGL
    Alert mode
    Info
  後のボタンを押しながら
  部品
    直列通信口
    電源
    ファン
NetBSD
  URL(1)
  改造の有無
  URL(2)
  getting stuff
  入手したら
    材料の説明
      binary 形式
    区画 (fdisk)
    Linux の設置
    20061027
    EM mode
      mfdisk
      ftp
    loader/install kernel
      /boot
      tools
      kernel
      nbloader
      boot selector2
      url
      ftp-get
    sysinst 起動
    sysinst (一部)
    multi-user
    自動起動
    rc2.d
    自動起動の解除
    message
  kuro_avrd
  bootsel2
    何をするもの
    起動の操作は
    設置
      Root Login
      操作
    設定
  無改造
    全体の流れ
    OS 設置後は
    /boot を用意する
    kuro_boot.conf
    sysinst by telnet
    chroot
    single user
      sshd
      telnet
      root
    20061027
      ftp
      nbloader/kernel
      boot selector
      kuro_boot.conf
      single user
      multi-user
      kuro_boot.conf
  packages
    pkg_info
  server
    samba
    netatalk
    NFS
    cvsync
    sendmail
  panic した時
  build.sh
    20070921
    20061019
    思いつくまま
SandPoint
  手順
  手順(別法)
files
  Buffalo
    kuro_102
    TS-TGL
problems
  20070917
  20061012
  sysinst 終了
  screen
  NFS 書込異常
  質問等
  ちょっとうっかり
    single user
boot code
  compile
    cross
      NetBSD
      powerpc-gnu-linux
  たつや版
    self
  U-Boot
  ts-tgl
玄箱/pro
    20081107
    20080624
    build
    boot
    dmesg
    日記から

Other language: ja | en |
hardware | TeraStation | software

Kuro-Box

Last Update: "2008/04/13 18:35:58 makoto"

bootsel2

boot selector (type 2)
http://www5.atwiki.jp/kuro-bsd/pages/69.html
download
http://kurobsd.ki.nu/download/boot/bootsel2/

What for ?

To boot the NetBSD on Kuro-box, LinkStation or TeraStation, you may need to type following command at Linux Root Prompt, either
insmod nbload_v3.o kernel=/boot/netbsd-KUROBOX_MD.bin
to invoke install kernel, or
insmod nbload_v3.o kernel=/boot/netbsd-KUROBOX.bin
for normal multi-user boot, or do nothing to continue Linux operation.
The boot selector 2 will do the same thing automatically.

It also unmounts the /boot and the re-mount by read-only, fsck won't happen at another power on. AVR will be taken care too.

Unless you have serial console attached, the boot selector is Essential. If you do have the serial console attached, it is optional, although it is very handly and useful for automatic-boot etc.

Normal Operation

Normal Operation (with boot selector 2) at Power On will be:
  1. Power On
  2. LED lights RED for three seconds
  3. While it is RED, push the Power Button TWICE (for example),
  4. The box will repeat the count (you pushed) by ON/OFF of lights.
  5. Depending on the counts (you pushed) the SELECTED kernel will be loaded and start.
If you do nothing after Power ON, the boot selector selects the pre-configured kernel in /etc/kuro_boot.conf.

Installation

versions
The version to be installed depens on the type of BOX. Following table is as of 2008/04/10.
Type of box file
Kuro-box kuro-bootsel2.20070207.tar.gz
LinkStation
TeraStation (Silver) tera-bootsel2.20051119.tar.gz
TeraStation (Black) N/A (alteratively, use bootsel version 1 )(*1)
See bottom of page
Root Login
All the operation to install boot selector needs to be done with root privilege. Say, you need to login Linux with root privilege to do following installation. If you are installing to kuro-box without any hardware modification, you will login via telnet. In the case of Kuro-box, when after the really new box is installed, it automatically start with EM-mode (the link destination is in Japanese right now, sorry), you may be able to set root passwd. If your box is not Kuro-box, but LinkStation, or TeraStation, you may have some difficulty getting root privilege.
Operation
To install boot selector2, you may do ftp, tar, make install at Linux root prompt. The summary of actual operation may be as follows: (the number shown to the left is history number, not for type-in).
503 ftp ftp.ki.nu cd pub/NetBSD/kurobsd/boot/bootsel2 get kuro-bootsel2.20070207.tar.bz2 quit 505 tar jxf kuro-bootsel2.20061028.tar.bz2 507 cd kuro-bootsel2 509 make install
Detailed operation log follows:
Get the tar stuff (like kuro-bootsel2.20070207.tar.gz) from following by ftp: http://kurobsd.ki.nu/download/boot/bootsel2/
root@KURO-BOX:/home/makoto# ftp ftp.ki.nu ftp> cd pub/NetBSD/kurobsd/boot/bootsel2 ftp> ls 200 PORT command successful. 150 Opening ASCII mode data connection for '/bin/ls'. total 676 -rw-r--r-- 1 2030 0 434 Jan 25 2006 MD5 -rw-r--r-- 1 2030 0 362 Dec 3 2005 MD5.old -rw-r--r-- 1 2030 0 500 Jan 25 2006 RMD160 -rw-r--r-- 1 2030 0 417 Dec 3 2005 RMD160.old -rw-r--r-- 1 2030 0 9682 Sep 16 2005 kuro-bootsel2.20050916a.tar.bz2 -rw-r--r-- 1 2030 0 10788 Nov 9 2005 kuro-bootsel2.20051109.tar.bz2 -rw-r--r-- 1 2030 0 10901 Dec 3 2005 kuro-bootsel2.20051203.tar.bz2 -rw-r--r-- 1 2030 0 257509 Jan 25 2006 kuro-bootsel2.20060125.tar.bz2 -rw-r--r-- 1 2030 0 11462 Nov 19 2005 tera-bootsel2.20051119.tar.bz2 -rw-r--r-- 1 2030 0 11479 Nov 19 2005 tera-bootsel2.20051119a.tar.bz2 226 Transfer complete. ftp> get kuro-bootsel2.20061028.tar.bz2 ftp> quit
and then tar jxf, cd kuro-bootsel2 and make install
tar jxf kuro-bootsel2.20070207.tar.bz2 cd kuro-bootsel2 root@KURO-BOX:/home/makoto/kuro-bootsel2# make install mkdir -p /boot/tools cp kuro_swread kuro_morse /boot/tools/ cp kuro_bootsel2.sh /etc/init.d/ chmod 755 /etc/init.d/kuro_bootsel2.sh if [ -d /etc/rcS.d ]; then \ (cd /etc/rcS.d; ln -s ../init.d/kuro_bootsel2.sh S15kuro_bootsel2.sh) \ fi if [ -d /etc/rc.d/rcS.d ]; then \ (cd /etc/rc.d/rcS.d; ln -s ../init.d/kuro_bootsel2.sh S15kuro_bootsel2.sh) \ fi if [ -c /dev/ttyS1 ]; then \ sed 's/AVR00/ttyS1/' < kuro_boot.conf > /etc/kuro_boot.conf \ else \ cp kuro_boot.conf /etc/ \ fi /bin/sh: -c: line 2: syntax error: unexpected end of file make: *** [install] Error 2 root@KURO-BOX:/home/makoto/kuro-bootsel2# cat Ma
The problem shown the bottom of above operation has been fixed and should not occur with the version 20061028 or later.

setup

The setup of boot selector2 will be done at /etc/kuro_boot.conf

problem

ftp not found
root@TS-TGL2B8:~# ftp ftp.ki.nu sh: ftp: command not found
use wget instead:
root@TS-TGL2B8:~# cd /tmp root@TS-TGL2B8:~# \ wget ftp://ftp.ki.nu/pub/NetBSD/kurobsd/boot/bootsel2/kuro-bootsel2.20070207.tar.bz2 --07:12:37-- ftp://ftp.ki.nu/pub/NetBSD/kurobsd/boot/bootsel2/kuro-bootsel2.20070207.tar.bz2 => `kuro-bootsel2.20070207.tar.bz2' Resolving ftp.ki.nu... done. Connecting to ftp.ki.nu[218.44.234.234]:21... connected. Logging in as anonymous ... Logged in! ==> SYST ... done. ==> PWD ... done. ==> TYPE I ... done. ==> CWD /pub/NetBSD/kurobsd/boot/bootsel2 ... done. ==> PORT ... done. ==> RETR kuro-bootsel2.20070207.tar.bz2 ... done. Length: 258,080 (unauthoritative) 100%[====================================>] 258,080 1.46M/s ETA 00:00 07:12:37 (1.46 MB/s) - `kuro-bootsel2.20070207.tar.bz2' saved [258080] root@TS-TGL2B8:/tmp#
make not found
root@TS-TGL2B8:/tmp# tar jxf kuro-bootsel2.20070207.tar.bz2 root@TS-TGL2B8:/tmp# cd kuro-bootsel2 root@TS-TGL2B8:/tmp/kuro-bootsel2# make install sh: make: command not found root@TS-TGL2B8:/tmp/kuro-bootsel2#
cat the Makefile and issue shell command by copy-paste line by line at install: target.
root@TS-TGL2B8:/tmp/kuro-bootsel2# cat Makefile all: kuro_swread kuro_morse clean: rm -f kuro_swread kuro_morse install: kuro_swread kuro_morse kuro_bootsel2.sh kuro_boot.conf mkdir -p /boot/tools cp kuro_swread kuro_morse /boot/tools/ cp kuro_bootsel2.sh /etc/init.d/ chmod 755 /etc/init.d/kuro_bootsel2.sh if [ -d /etc/rcS.d ]; then \ (cd /etc/rcS.d; ln -s ../init.d/kuro_bootsel2.sh S15kuro_bootsel2.sh) \ fi if [ -d /etc/rc.d/rcS.d ]; then \ (cd /etc/rc.d/rcS.d; ln -s ../init.d/kuro_bootsel2.sh S15kuro_bootsel2.sh) \ fi cp kuro_boot.conf /etc/ ... (omitted) ...
root@TS-TGL2B8:/tmp/kuro-bootsel2# mkdir -p /boot/tools root@TS-TGL2B8:/tmp/kuro-bootsel2# cp kuro_swread kuro_morse /boot/tools/ root@TS-TGL2B8:/tmp/kuro-bootsel2# cp kuro_bootsel2.sh /etc/init.d root@TS-TGL2B8:/tmp/kuro-bootsel2# chmod 755 /etc/init.d/kuro_bootsel2.sh root@TS-TGL2B8:/tmp/kuro-bootsel2# ls -ld /etc/rcS.d /etc/rc.d/rcS.d ls: /etc/rcS.d: No such file or directory drwxr-xr-x 2 root root 4096 Apr 9 07:10 /etc/rc.d/rcS.d root@TS-TGL2B8:/tmp/kuro-bootsel2# (cd /etc/rc.d/rcS.d; ln -s ../init.d/kuro_bootsel2.sh S15kuro_bootsel2.sh) root@TS-TGL2B8:/tmp/kuro-bootsel2# cp kuro_boot.conf /etc/
root@TS-TGL2B8:/tmp/kuro-bootsel2# grep kernel2 /etc/kuro_boot.conf* /etc/kuro_boot.conf:kernel2=/boot/netbsd-KUROBOX.bin /etc/kuro_boot.conf-orig:kernel2=/boot/netbsd.bin root@TS-TGL2B8:/tmp/kuro-bootsel2# /sbin/reboot
... This filesystem will be automatically checked every 29 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override. /dev/ttyS1 detected. ************************************************ Select the OS in 3 secs: (default is 1) 1: Linux 2: NetBSD(HDD:wd0) ** Default ** ** No.1 ** Checking all file systems... fsck 1.27 (8-Mar-2002) ... (will take a time to get login prompt) ... BUFFALO INC. TeraStation series TS-TGL(IENARI) TS-TGL2B8 login:
System Error E04
Can't Load Krnl
Last Update: Sat, 07 Jun 2014 13:16:17 GMT 1.66 2008/03/08