«前の日記(Saturday 24 March, 2007 ) 最新 次の日記(Wednesday 28 March, 2007 )» 編集

ここに日記はありません


Sunday 25 March, 2007 [長年日記]

_ [Kurobox] 玄箱のセットアップ(2)

最終的にはNetBSDでの運用を目的にしているのでLinuxの構成は何でも構わないが、標準状態のLinuxは最低限のものしか無くNetBSDを導入するにも不便だということなのでLinuxの構成を変更する。その方法の一つとしてDebianを導入する。ここでは事前準備としてHDDのパーティション構成を変更する。

セットアップの最後で再起動した玄箱にtelnetでrootとしてログインする。

~% telnet 192.168.1.x
Trying 192.168.1.x...
Connected to 192.168.1.x.
Escape character is '^]'.
Password:
Login incorrect

KURO-BOX login: root
Password:
Linux (none) 2.4.17_mvl21 #24 2004年 10月 19日 火曜日 17:17:03 JST ppc unknown
root@KURO-BOX:~# fdisk /dev/hda

The number of cylinders for this disk is set to 15017. There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with: 1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)

Command (m for help): p

Disk /dev/hda: 255 heads, 63 sectors, 15017 cylinders
Units = cylinders of 16065 * 512 bytes

Device Boot Start End Blocks Id System
/dev/hda1 1 261 2096451 83 Linux
/dev/hda2 262 293 257040 82 Linux swap
/dev/hda3 294 15017 118270530 83 Linux

Command (m for help): q

root@KURO-BOX:~# df
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/hda1 2063504 122280 1836404 7% /
/dev/hda3 116413420 32832 116380588 1% /mnt
root@KURO-BOX:~#

デフォルトでは/が2G、swapが256MB、残りが共有される領域として/mntにマウントされている。今回はNetBSDを導入するのでパーティションを変更してLinuxについては最低限の領域にしておく必要がある。

一旦/mntをアンマウントして/dev/hda3を作り直す。今回はHDDに余裕もあるので16GBを割り当てた。残りの100GB余りをNetBSDの領域とする。hda3をnewfsしてマウントし直す。

root@KURO-BOX:~# umount /mnt
root@KURO-BOX:~# fdisk /dev/hda

The number of cylinders for this disk is set to 15017. There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)

Command (m for help): d
(中略)

root@KURO-BOX:~# mke2fs -j /dev/hda3
mke2fs 1.22, 22-Jun-2001 for EXT2 FS 0.5b, 95/08/09
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
2101152 inodes, 4194973 blocks
209748 blocks (5.00%) reserved for the super user
First data block=0
129 block groups
32768 blocks per group, 32768 fragments per group
16288 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000

Writing inode tables: done
Creating journal (8192 blocks): done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 29 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
root@KURO-BOX:~#

/dev/hda3を作り直したことで共有ディレクトリが消えているので、/mnt/shareを作り直す。

root@KURO-BOX:~# ls /mnt/
lost+found
root@KURO-BOX:~# mkdir /mnt/share
root@KURO-BOX:~# cd /mnt/
root@KURO-BOX:/mnt# ls -al
total 28
drwxr-xr-x 4 root root 4096 Mar 25 14:50 .
drwxr-xr-x 17 root root 4096 Mar 24 20:03 ..
drwxr-xr-x 2 root root 16384 Mar 25 14:43 lost+found
drwxr-xr-x 2 root root 4096 Mar 25 14:50 share
root@KURO-BOX:/mnt# chmod 777 share
root@KURO-BOX:/mnt# ls -al
total 28
drwxr-xr-x 4 root root 4096 Mar 25 14:50 .
drwxr-xr-x 17 root root 4096 Mar 24 20:03 ..
drwxr-xr-x 2 root root 16384 Mar 25 14:43 lost+found
drwxrwxrwx 2 root root 4096 Mar 25 14:50 share
root@KURO-BOX:/mnt#

_ [Book] 夜の蝉

https://www.amazon.co.jp/dp/4488413021

「私と円紫さん」のシリーズだが、収録されている作品のうち「夜の蝉」だけは前に読んだ記憶がある。ダブって買ったわけではないし、他の本に収録されていたのかな。

ENOTECA Online(ワイン通販 エノテカ・オンライン) 29980円パソコン工房
リンクシェア アフィリエイト紹介プログラム