Last Update: "2006/11/04 17:02:30 makoto"
chroot
sysinst
が終了している時に、全てを mount して chroot すれば、single user と同じ環境で作業が可能になり
ます。
そこで
無改造の表
で言えば、1 で入って 2 に移行して作業します。
下記は、その操作例です。
ttyr1:makoto@mini 0:47:01/061024(> telnet kuro 60023
Trying 192.168.1.10...
Connected to kuro.example.com
Escape character is '^]'.
4.4 BSD UNIX () (ttyp0)
login: root
ROOT LOGIN (root) ON ttyp0 FROM mini.ki.nu
Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
The NetBSD Foundation, Inc. All rights reserved.
Copyright (c) 1982, 1986, 1989, 1991, 1993
The Regents of the University of California. All rights reserved.
This is the KURO-BOX emergency boot. Please take with care.
# df
Filesystem 512-blocks Used Avail Capacity Mounted on
/dev/md0a 3935 3670 265 93% /
mfs:17 15295 1 14530 0% /tmp
# disklabel wd0
# /dev/rwd0d:
type: unknown
disk: WDC WD1600JB-00
label:
flags:
bytes/sector: 512
sectors/track: 63
tracks/cylinder: 16
sectors/cylinder: 1008
cylinders: 310101
total sectors: 312581808
rpm: 3600
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0 # microseconds
track-to-track seek: 0 # microseconds
drivedata: 0
16 partitions:
# size offset fstype [fsize bsize cpg/sgs]
a: 1024128 4707045 4.2BSD 1024 8192 0 # (Cyl. 4669*- 5685*)
b: 514072 4192973 swap # (Cyl. 4159*- 4669*)
c: 307869660 4707045 unused 0 0 # (Cyl. 4669*- 310095*)
d: 312581808 0 unused 0 0 # (Cyl. 0 - 310100)
e: 4192902 63 Linux Ext2 0 0 # (Cyl. 0*- 4159*)
f: 1024128 5731173 swap # (Cyl. 5685*- 6701*)
g: 8192016 6755301 4.2BSD 2048 16384 0 # (Cyl. 6701*- 14828*)
h: 10240272 14947317 4.2BSD 2048 16384 0 # (Cyl. 14828*- 24987*)
i: 287389116 25187589 4.2BSD 2048 16384 0 # (Cyl. 24987*- 310095*)
# mount /dev/wd0a /mnt
# mount /dev/wd0g /mnt/usr
# mount /dev/wd0h /mnt/var
# cat /mnt/etc/fstab
# NetBSD /etc/fstab
# See /usr/share/examples/fstab/ for more examples.
/dev/wd0a / ffs rw 1 1
/dev/wd0b none swap sw 0 0
# /dev/wd0e /mnt ??? rw,noauto 0 0
/dev/wd0f none swap sw 0 0
/dev/wd0g /usr ffs rw 1 2
/dev/wd0h /var ffs rw 1 2
/dev/wd0i /export ffs rw 1 2
kernfs /kern kernfs rw
procfs /proc procfs rw,noauto
# chroot /mnt
# pwd
/
# df -k
Filesystem 1K-blocks Used Avail Capacity Mounted on
/dev/wd0a 496295 17874 453607 3% /
/dev/wd0g 4032278 226530 3604136 5% /usr
/dev/wd0h 5040374 792 4787564 0% /var
#
この後に
single user mode で
いくつか設定します。
|