玄箱のdebianインストール(自分でパーティション設定)
1.玄箱をEMモードに落とす
・背面の赤いボタンを長押し
・玄箱にログインして
# echo -n 'NGNG' > /dev/fl3
# reboot
2.パーティションの削除
# /sbin/mfdisk -e /dev/hda
3.パーティションの作成
debian用パーティションの作成
# /sbin/mfdisk -c /dev/hda
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-30401, default 1): [なにも入力せずenter]
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-30401, default 30401): +5000M
Command (m for help):
-
- -
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 2
First cylinder (12750-30401, default 12750): [なにも入力せずenter]
Using default value 12750
Last cylinder or +size or +sizeM or +sizeK (12750-30401, default 30401): +500M
Command (m for help):
-
- -
データ保存用パーティションの作成
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 3
First cylinder (14025-30401, default 14025): [なにも入力せずenter]
Using default value 14025
Last cylinder or +size or +sizeM or +sizeK (14025-30401, default 30401): [なにも入力せずenter]
Using default value 30401
Command (m for help):
-
- -
Command (m for help): t
Partition number (1-4): 2
Hex code (type L to list codes): 82
Changed system type of partition 2 to 82 (Linux swap)
-
- -
コマンドpで設定を確認。
予約したパーティションをwriteしてパーティションを書き込み。
Command (m for help): w
The partition table has been altered!
Syncing disks.
#
-
- -
Debianをインストールするパーティションをフォーマット。
# mke2fs -j /dev/hda1
次にスワップパーティション。
# mkswap /dev/hda2
次にデータ保存領域のパーティション。
# /sbin/mke2fs -j -m 0 /dev/hda3
念のために/hda3のパラメータを調整。
予約ファイルシステムをオフ。
# /sbin/tune2fs -m 0 /dev/hda3
各パーティションをマウント。
Debianをインストールするパーティションを /mntと する。
# /bin/mount -t ext3 /dev/hda1 /mnt
次に、データ保存領域を /mnt2 とする。
# /bin/mount -t ext3 /dev/hda3 /mnt2
dfコマンドで確認
# df -k
さて、次にDebianのインストールに入るための準備。
# mkdir /mnt2/share
として、mnt2にshareディレクトリを作成。
玄箱うぉううぉう♪からDebianのバイナリをダウンロード。
バイナリを/mnt2/shareにFTPで転送。
ユーザ名:パスワードはroot:root
/mnt ディレクトリに移動、バイナリの解凍
# cd /mnt
# tar xvzf /mnt2/share/debian_2006_06_10_dist.tgz
すべての端末からログインできるようにする。
# vi /mnt/etc/hosts.allow
-
- -
# /etc/hosts.allow: list of hosts that are allowed to access the system.
# See the manual pages hosts_access(5), hosts_options(5)
# and /usr/doc/netbase/portmapper.txt.gz
#
# Example: ALL: LOCAL @some_netgroup
# ALL: .foobar.edu EXCEPT terminalserver.foobar.edu
#
# If you're going to protect the portmapper use the name "portmap" for the
# daemon name. Remember that you can only use the keyword "ALL" and IP
# addresses (NOT host or domain names) for the portmapper. See portmap(8)
# and /usr/doc/portmap/portmapper.txt.gz for further information.
#
#ALL : 192.168.0.0/255.255.255.0
ALL : ALL : ALLOW
===
EMモードから通常起動に復帰するコマンドを打って再起動。
# echo -n 'OKOK' > /dev/fl3
# reboot