upgrade revision 1.6 1 1.6 perry $NetBSD: upgrade,v 1.6 1998/01/09 18:46:23 perry Exp $
2 1.6 perry
3 1.2 thorpej It is possible to easily upgrade your existing NetBSD/hp300 system
4 1.2 thorpej using the upgrade program in the miniroot. If you wish to upgrade
5 1.2 thorpej your system by this method, simply select the `upgrade' option once
6 1.2 thorpej the miniroot has booted. The upgrade program with then guide you
7 1.2 thorpej through the procedure. The upgrade program will:
8 1.2 thorpej
9 1.2 thorpej * Enable the network based on your system's current
10 1.2 thorpej network configuration.
11 1.2 thorpej
12 1.2 thorpej * Mount your existing filesystems.
13 1.2 thorpej
14 1.2 thorpej * Extract binary sets from the media of your choice.
15 1.2 thorpej
16 1.2 thorpej * Fixup your system's existing /etc/fstab, changing the
17 1.2 thorpej occurrences of `ufs' to `ffs' and let you edit the
18 1.2 thorpej resulting file.
19 1.2 thorpej
20 1.2 thorpej * Make new device nodes in your root filesystem.
21 1.2 thorpej
22 1.5 scottr * Don't forget to extract the `kern' set from the distribution.
23 1.2 thorpej NOTE: the existing kernel WILL NOT be backed up; doing
24 1.3 jtc so would be pointless, since older kernels may not be
25 1.4 carrel capable of running NetBSD _VER executables.
26 1.2 thorpej
27 1.2 thorpej * Install a new boot block.
28 1.2 thorpej
29 1.2 thorpej * Check your filesystems for integrity.
30 1.2 thorpej
31 1.2 thorpej While using the miniroot's upgrade program is the preferred method
32 1.2 thorpej of upgrading your system, it is possible to upgrade your system
33 1.2 thorpej manually. To do this, follow the following procedure:
34 1.2 thorpej
35 1.2 thorpej * Place _at least_ the `base' binary set in a filesystem
36 1.2 thorpej accessible to the target machine. A local filesystem
37 1.4 carrel is preferred, since the NFS subsystem in the NetBSD _VER
38 1.3 jtc kernel may be incompatible with your old binaries.
39 1.2 thorpej
40 1.4 carrel * Back up your pre-existing kernel and copy the _VER
41 1.2 thorpej kernel into your root partition.
42 1.2 thorpej
43 1.4 carrel * Reboot with the _VER kernel into single-user mode.
44 1.2 thorpej
45 1.2 thorpej * Check all filesystems:
46 1.2 thorpej
47 1.3 jtc /sbin/fsck -pf
48 1.2 thorpej
49 1.2 thorpej * Mount all local filesystems:
50 1.2 thorpej
51 1.2 thorpej /sbin/mount -a -t nonfs
52 1.2 thorpej
53 1.2 thorpej * If you keep /usr or /usr/share on an NFS server, you
54 1.2 thorpej will want to mount those filesystems as well. To do
55 1.2 thorpej this, you will need to enable the network:
56 1.2 thorpej
57 1.2 thorpej sh /etc/netstart
58 1.2 thorpej
59 1.3 jtc * Run the update(8) daemon, to ensure that new programs
60 1.3 jtc are actually stored on disk.
61 1.3 jtc
62 1.3 jtc update
63 1.2 thorpej
64 1.2 thorpej * Make sure you are in the root filesystem and extract
65 1.2 thorpej the `base' binary set:
66 1.2 thorpej
67 1.2 thorpej cd /
68 1.5 scottr tar --unlink -zxvpf /path/to/base.tgz
69 1.2 thorpej
70 1.2 thorpej NOTE: the `--unlink' option is _very_ important!
71 1.2 thorpej
72 1.2 thorpej * Install a new boot block:
73 1.2 thorpej
74 1.2 thorpej cd /usr/mdec
75 1.2 thorpej disklabel -B <root disk, e.g. sd0>
76 1.2 thorpej
77 1.2 thorpej * Sync the filesystems:
78 1.2 thorpej
79 1.2 thorpej sync
80 1.2 thorpej
81 1.2 thorpej * At this point you may extract any other binary sets
82 1.2 thorpej you may have placed on local filesystems, or you may
83 1.2 thorpej wish to extract additional sets at a later time.
84 1.2 thorpej To extract these sets, use the following commands:
85 1.2 thorpej
86 1.2 thorpej cd /
87 1.2 thorpej tar --unlink -zxvpf <path to set>
88 1.2 thorpej
89 1.2 thorpej NOTE: you SHOULD NOT extract the `etc' set if upgrading. Instead, you
90 1.2 thorpej should extract that set into another area and carefully merge the changes
91 1.2 thorpej by hand.
92