Fix systat -netstat and remove the dependency on KVM for this part.
[dragonfly.git] / UPDATING
... / ...
CommitLineData
1$DragonFly: src/UPDATING,v 1.8 2004/10/27 02:51:41 dillon Exp $
2
3Updating Information for DragonFly users.
4
5This file should warn you of any pitfalls which you might need to work around
6when trying to update your DragonFly system.
7
8If you discover any problem, please contact the bugs@lists.dragonflybsd.org
9mailing list with the details.
10
11------------------------------------------------------------------------------
12
13> Required user and group IDs when upgrading from either FreeBSD or DragonFly
14---------------------
15
16The following users may be missing from your password file. Use vipw and
17add any that are missing:
18
19smmsp:*:25:25::0:0:Sendmail Submission User:/var/spool/clientmqueue:/sbin/nologin
20
21The following groups may be missing from your group file. Use vi /etc/group
22and add any that are missing:
23
24smmsp:*:25:
25authpf:*:63:
26
27
28> Upgrading to DragonFly from FreeBSD
29---------------------
30
31You can build the DragonFly world and DragonFly kernels on a FreeBSD-4.x or
32FreeBSD-5.x machine and then install DragonFly over FreeBSD, replacing
33FreeBSD. Note that the DragonFly buildworld target does not try to reuse
34make depend information, it starts from scratch, so no pre-cleaning of the
35object hierarchy is necessary.
36
37 # get the CVS pository (it is placed in /home/dcvs, 500MB).
38 # Please use the -h option and a mirror site to pull the
39 # initial repository, but feel free to use the main repository
40 # machine to pull updates.
41 cvsup /usr/share/examples/cvsup/DragonFly-supfile
42 # install the source from the CVS hierarchy (remove preexisting
43 # FreeBSD src first) (500MB)
44 cd /usr
45 rm -rf src
46 cvs -R -d /home/dcvs checkout src
47 cvs -R -d /home/dcvs checkout dfports
48
49 # build it (500MB used in /usr/obj)
50 #
51 cd /usr/src
52 make buildworld
53 make buildkernel KERNCONF=<KERNELNAME>
54
55Once you have built DragonFly you have to install it over FreeBSD. Since
56DragonFly does not track changes made by FreeBSD to its include file
57hierarchy and include file pollution can cause all sorts of unexpected
58compilation issues to come up, it is best to wipe your include hierarchy
59prior to installing DragonFly. Note that you should not wipe any installed
60FreeBSD header files or binaries until after you have successfully completed
61the build steps above.
62
63 rm -rf /usr/include
64 mkdir /usr/include
65 make installkernel KERNCONF=<KERNELNAME>
66 make installworld
67
68Then you need to upgrade your /etc. DragonFly's 'make upgrade' target
69will unconditionally upgrade the /etc files that sysops do not usually
70mess around with, such as the files in /etc/rc.d. If you are unsure we
71recommend that you make a backup of your /etc before applying this step.
72Note that DragonFly's RC system is basically RCNG from FreeBSD-5, but
73there are some differences in the contents of the RC files.
74
75 make upgrade
76
77Finally we recommend that you do an 'ls -lta BLAH' for /bin, /sbin, /usr/bin,
78/usr/bin, and /usr/lib, and remove any stale files that you find.
79
80------------------------------------------------------------------------------
81
82> Upgrading DragonFly on an existing DragonFly system.
83---------------------
84
85The best way to upgrade DragonFly is to maintain a copy of the DragonFly
86CVS repository via cvsup and to checkout the source base and DragonFly
87ports via this repository. The repository is stored in /home/dcvs by
88default and requires about 500MB of disk space. The checked out source
89tree (/usr/src) requires about 500MB of disk space, and the build will
90eat around 500MB of space out of /usr/obj. To maintain the build you
91should reserve at least 2GB of disk space, and 3GB if you have the space.
92
93Note: most people run cvsup via a root cron job to keep the repository up to
94date. Please limit such automatic updates to once a day and try to randomize
95the hour and minute in the cron job a bit to avoid pileups.
96
97 # get the CVS pository (it is placed in /home/dcvs)
98 cvsup /usr/share/examples/cvsup/DragonFly-supfile
99 # install the source from the CVS hierarchy
100 cd /usr
101 cvs -R -d /home/dcvs checkout src
102 cvs -R -d /home/dcvs checkout dfports
103
104Once you have the repository and broken out sources you can decide whether to
105update your sources from the repository automatically or manually. Since
106you are tracking changes made to DragonFly, it is usually a good idea to
107update the sources manually:
108
109 cd /usr/src
110 cvs update
111
112To upgrade a DragonFly system from sources you run the following sequence:
113
114 cd /usr/src
115 make buildworld
116 make buildkernel KERNCONF=<KERNELNAME>
117 make installkernel KERNCONF=<KERNELNAME>
118 make installworld
119
120You will also want to run the 'upgrade' target to upgrade your /etc. The
121upgrade target is aware of stale files created by older DragonFly
122installations and should delete them automatically.
123
124 make upgrade
125
126If you are using 'config' manually from /usr/src/sys/i386/conf/BLAH, note
127that the build will use the current DragonFly environment rather then
128the post-build environment from the last buildworld. For this reason manual
129configs are discouraged. The proper way to build a kernel is to use the
130'buildkernel' or 'quickkernel' target in /usr/src.
131
132Once you've done a full build of the world and kernel you can do incremental
133upgrades of either by using the 'quickworld' and 'quickkernel' targets
134instead of 'buildworld' and 'buildkernel'. If you have any problems with
135the quick targets, try doing a cvsup, cvs update, and then a full buildworld
136and buildkernel as shown above, before asking for help.
137
138> Kerberos IV
139-------------
140
141Kerberos IV (eBones) was removed from the tree, please consider moving to
142Kerberos 5 (Heimdal).
143
144> FreeBSD and DragonFly ports
145-----------------------------
146
147DragonFly will eventually have its own package management system but at the
148moment we leverage off of the FreeBSD ports system. You should maintain
149/usr/ports from the FreeBSD cvs repository via cvsup just like you do now.
150
151DragonFly has its own 'port overrides' hierarchy in /usr/dfports. You can
152check this out of the DragonFly cvs repository using:
153
154cd /usr
155cvs -R -d /cvs checkout dfports
156
157You may wish to use a consolidated distfiles directory, in which case you
158should make /usr/dfports/distfiles a softlink to your existing distfiles
159directory (typically /usr/ports/distfiles).
160
161Be sure that you have installed 'relpath' from the DragonFly sources
162(/usr/src/usr.bin/relpath) as well as the updated /usr/share/mk files from
163/usr/src/share/mk. As a test you can cd into /usr/ports/sysutils/cpdup and
164build the port. Dragonfly should contain an override and you should see a
165warning message that the DragonFly override is being build instead when you
166build it from the FreeBSD ports.
167