em/emx: Fix up detach path
[dragonfly.git] / UPDATING
CommitLineData
d2a0decc
MD
1# Updating Information for DragonFly users.
2#
3#
4# This file should warn you of any pitfalls which you might need to work around
5# when trying to update your DragonFly system. The information below is
6# in reverse-time order, with the latest information at the top.
7#
8# If you discover any problem, please contact the bugs@lists.dragonflybsd.org
9# mailing list with the details.
d2a0decc 10
c691bb43
SW
11+-----------------------------------------------------------------------+
12+ UPGRADING DRAGONFLY FROM 3.0 to later versions +
13+-----------------------------------------------------------------------+
14
15APIC_IO OPTION REMOVED
16----------------------
17
18The APIC_IO kernel option is no longer accepted after having been without
19effect for a while. The hw.ioapic_enable tunable now serves its purpose.
20If you have 'options APIC_IO' in your kernel config, you'll have to
21remove it.
22
6d488cc3
SW
23WATCHDOG_ENABLE & HW_WDOG OPTIONS REMOVED
24-----------------------------------------
cf03d6cd
SW
25
26The wdog framework is now compiled into our kernels by default, so the
6d488cc3 27options are no longer needed.
cf03d6cd 28
397ffc5c
SW
29DOSCMD(1) REMOVED
30-----------------
31
32doscmd(1) has been removed. It was i386 only. The doscmd(1) specific
33NO_X make.conf option was removed too.
34
96386d4b
SW
35+-----------------------------------------------------------------------+
36+ UPGRADING DRAGONFLY FROM 2.10 to later versions +
37+-----------------------------------------------------------------------+
38
39SEVERAL ISA DRIVERS REMOVED
40---------------------------
41
42The following ISA only drivers have been removed along with a couple of
43associated userland tools:
44
45aha(4)
46asc(4) & sasc(1)
47ctx
48dgb(4)
49el(4)
50gpib
51gsc(4) & sgsc(1)
52ie(4)
53labpc(4)
54le(4)
55mse(4)
56rc(4)
57rdp(4)
58spigot
59tw(4) & xten(1) & xtend(8)
60wl(4) & wlconfig(8)
61wt(4)
62
63Note that two of these drivers (aha(4) and ie(4)) are in our GENERIC
64config and one (aha(4)) is in our X86_64_GENERIC kernel configuration
65file.
66
67If buildkernel complains about any of these drivers, just remove them
68from your kernel configuration.
69
919eb219
JM
70BINUTILS 2.20
71-------------
37c5a0db 72Binutils 2.20 has been removed in favor of Binutils 2.22. The accepted
e685772e 73values of BINUTILSVERS are now binutils221 and binutils222 (default).
919eb219 74
83bc1e2a
SW
75BUILDWORLD/-KERNEL PARALLELIZATION WORK
76---------------------------------------
77Due to changes in the way we build with more than one make job, you
78will have to update install(1) and mkdir(1) prior to buildworld if you
79want to build with 'make -j':
80
81cd /usr/src/usr.bin/xinstall; make; make install; make clean
82cd /usr/src/bin/mkdir; make; make install; make clean
83
eca86bd9
SW
84DMA(8) UPGRADE
85--------------
86dma(8) has been upgraded to v0.7 which no longer supports the
87/etc/dma/virtusertable. Some of its functionality has been replaced
88with the MASQUERADE keyword and the EMAIL environment variable (see
89the dma(8) manual page).
90
a4a39c94 91+-----------------------------------------------------------------------+
2443e96e 92+ UPGRADING DRAGONFLY FROM 2.8 to later versions +
a4a39c94
JS
93+-----------------------------------------------------------------------+
94
b1242318
SW
95GCC 4.4 & BINUTILS 2.21
96-----------------------
30c91f0c 97
b1242318
SW
98GCC 4.4 has been made DragonFly's default compiler and Binutils 2.21 has
99been made DragonFly's default Binutils.
30c91f0c
SW
100
101That means that any settings that set CCVER to 'gcc44' are not needed
102anymore. Instead, CCVER can be set to 'gcc41' to go back to using
103GCC 4.1.
104
b1242318
SW
105It also means that 'binutils221' as a value for BINUTILSVER has no
106effect anymore. 2.17 has been removed and 'binutils220' is available
107as an option.
108
5738210d 109The NO_GCC44 option has been removed and will not affect the build
30c91f0c
SW
110anymore. There is now a NO_GCC41 option that will prevent GCC 4.1 from
111building in a similar fashion.
112
80abb3be 113Note that you must do a full buildworld/buildkernel for upgrading.
30c91f0c 114
a4a39c94 115pkg_radd settings
c983d16e 116-----------------
a4a39c94
JS
117
118The config file for pkg_radd has moved from /etc/settings.conf to
119/etc/pkg_radd.conf. Save the contents of settings.conf before upgrading
120if this is needed. This warning only applies if /etc/settings.conf
121exists. pkg_radd will continue to work with defaults.
122
b79f66dd 123+-----------------------------------------------------------------------+
72fe41d3 124+ 20100927 +
1bb1cc14 125+ UPGRADING DRAGONFLY FROM 2.6 to 2.8 or HEAD +
b79f66dd
JT
126+-----------------------------------------------------------------------+
127
72fe41d3 128OpenSSL
c983d16e 129--------
72fe41d3
PA
130
131OpenSSL has been upgraded, and SHLIB_MAJOR was bumped for libssh and libcrypto.
132This shouldn't break any 3rd-party software, but you'll need to recompile your
1333rd-party software if you want it to link against the new version of OpenSSL.
134
8eb0b612 135Loader
c983d16e 136-------
8eb0b612 137
b79f66dd
JT
138A new loader (dloader) has been added which better handles booting from
139multiple kernel/module versions.
140
141To upgrade (Only for this upgrade, for post 2.8 upgrades see GENERAL below)
142
143 cd /usr/src
144 make buildworld
145 make installworld
146 make upgrade
147 make buildkernel KERNCONF=<KERNELNAME>
148 make installkernel KERNCONF=<KERNELNAME>
149
150Note that you must installworld and run the 'upgrade' target before
151installing the new kernel.
152
8eb0b612 153BIND
c983d16e 154-----
8eb0b612
JS
155
156BIND has been removed from the base system. The ldns and drill tools have
157been added for basic functionality. Use 'drill' where you would normally
158use nslookup or dig, or install BIND from pkgsrc. It's available as
159net/bind95, net/bind96, or net/bind97 as of this writing.
160
161This only affects older systems upgrading to 2.8. New 2.8+ installs
162include BIND as a pkgsrc package.
163
d2a0decc
MD
164+-----------------------------------------------------------------------+
165+ UPGRADING DRAGONFLY ON AN EXISTING DRAGONFLY SYSTEM +
166+ GENERAL +
167+-----------------------------------------------------------------------+
984263bc 168
a700883c
SW
169Instructions on how to obtain and maintain DragonFly source code using git
170are in the development(7) manual page.
d2a0decc
MD
171
172To upgrade a DragonFly system from sources you run the following sequence:
173
174 cd /usr/src
175 make buildworld
176 make buildkernel KERNCONF=<KERNELNAME>
177 make installkernel KERNCONF=<KERNELNAME>
178 make installworld
179
180You will also want to run the 'upgrade' target to upgrade your /etc and the
181rest of your system. The upgrade target is aware of stale files created by
182older DragonFly installations and should delete them automatically.
183
184 make upgrade
185
a700883c
SW
186See the build(7) manual page for further information.
187
d2a0decc
MD
188Once you've done a full build of the world and kernel you can do incremental
189upgrades of either by using the 'quickworld' and 'quickkernel' targets
190instead of 'buildworld' and 'buildkernel'. If you have any problems with
a700883c 191the quick targets, try updating your repo first, and then a full buildworld
d2a0decc 192and buildkernel as shown above, before asking for help.
4523a2c0
TN
193
194+-----------------------------------------------------------------------+
195+ UPGRADING FROM DRAGONFLY <= 2.0 TO DRAGONFLY >= 2.1 +
196+-----------------------------------------------------------------------+
197
198In 2.1 kernel and modules has moved to boot directory. For most cases
199this is handled automatically by 'make upgrade'. A few cases needs manual
200intervention:
201
202 * When installing a kernel without first doing a make buildworld,
203 installworld and upgrade to the same DESTDIR as kernel:
204 make DESTDIR/boot directory and move kernel and modules into this boot
205 directory; also move kernel.old and modules.old.
206 Typical example is vkernel(7), use (no modules used):
207
208 cd /var/vkernel
209 mkdir boot
210 chflags noschg kernel
211 mv kernel kernel.old boot
212 chflags schg boot/kernel
213
214 * When using a boot-only partition, /boot/loader.rc needs to be edited:
215 delete occurrences of '/boot/'.
216 These occurences can normally be deleted in any case, see loader(8).
d2a0decc
MD
217
218+-----------------------------------------------------------------------+
219+ UPGRADING FROM DRAGONFLY <= 1.8 TO DRAGONFLY >= 1.9 +
220+-----------------------------------------------------------------------+
221
222In 1.9 major changes to the disk management infrastructure have taken
223place. make upgrade may not catch all of your disk devices in /dev,
224so after upgrading be sure to cd /dev; ./MAKEDEV <blah> where <blah>
45e80934
MD
225are all of your disk devices. HOWEVER, from late 2.3 on we run devfs
226and MAKEDEV no longer exists.
d2a0decc
MD
227
228The biggest changes in 1.9 are:
229
230(1) That whole-slice devices such as da0s1 no longer share the same device
231 id as partition c devices such as da0s1c.
232
233(2) The whole-disk device (e.g. da0) is full raw access to the disk,
234 with no snooping or reserved sectors. Consequently you cannot run
235 disklabel on this device. Instead you must run disklabel on a
236 whole-slice device.
237
238(3) The 'compatibility' partitions now use slice 0 in the device name,
239 so instead of da0a you must specify da0s0a. Also, as per (1) above,
240 accessing the disklabel for the compatibility partitions must be
241 done via slice 0 (da0s0).
242
243(4) Many device drivers that used to fake up labels, such as CD, ACD, VN,
244 and CCD now run through the disk management layer and are assigned
245 real disk management devices. VN and CCD in particular do not usually
246 use a MBR and disklabels must be accessed through the compatibility
247 slice 0. Your /etc/ccd.conf file still specifies 'ccd0', though, you
248 don't name it 'ccd0s0' in the config file.
249
250Generally speaking, you have to get used to running fdisk and disklabel on
251the correctly specified device names. A lot of the wiggle, such as running
252disklabel on a partition, has been removed.
253
254+-----------------------------------------------------------------------+
255+ UPGRADING FROM OLDER VERSIONS OF DRAGONFLY OR FREEBSD +
256+-----------------------------------------------------------------------+
257
258> Kerberos IV
259-------------
260
261Kerberos IV (eBones) was removed from the tree, please consider moving to
262Kerberos 5 (Heimdal).
263
264> Package Management System
265---------------------------
266
267Starting with the 1.4 release, DragonFly uses NetBSD's pkgsrc package
268management system. The necessary tools to build and maintain packages
269are provided in /usr/pkg/bin and /usr/pkg/sbin. Make sure that these
270directories are in your PATH variable.
271
272In order to obtain a reasonably current snapshot of the pkgsrc tree, use
273the tarball from NetBSD:
274
275 fetch -o /tmp/pkgsrc.tar.gz ftp://ftp.NetBSD.org/pub/NetBSD/packages/pkgsrc.tar.gz
276 cd /usr; tar -xzf /tmp/pkgsrc.tar.gz; chown -R root:wheel pkgsrc
277
278This tree can then be kept up to date with cvs update:
279
280 cd /usr/pkgsrc; cvs up
281
282NOTE! If you upgraded from a pre-1.4 system to 1.4 or later, you need to
283build and install the pkgsrc bootstrap manually:
284
285 cd /usr/pkgsrc/bootstrap
286 ./bootstrap --pkgdbdir /var/db/pkg --prefix /usr/pkg
287
288+-----------------------------------------------------------------------+
289+ UPGRADING DRAGONFLY ON AN EXISTING DRAGONFLY SYSTEM +
290+ UPDATING FROM PRE-1.2 SYSTEMS OR FreeBSD 4.x TO +
291+ DRAGONFLY 1.3+ (EITHER PREVIEW or HEAD) +
292+-----------------------------------------------------------------------+
58116288 293
114580ac 294The compatibility shims for the build environment have been removed, you
58116288
JS
295have to update to DragonFly 1.2 release branch first.
296
1fcc7462
JS
297The default PAM configuration has moved from /etc/pam.conf to /etc/pam.d/.
298The existing configuration can be converted using /etc/pam.d/convert.sh.
299Entries in /etc/pam.d/ override entries in /etc/pam.conf. In addition
300the pam_skey.so module was retired, you have to remove it manually from
301your configuration, when you convert it.
58116288 302
a3107071
MD
303> Required user and group IDs when upgrading from either FreeBSD or DragonFly
304---------------------
305
306The following users may be missing from your password file. Use vipw and
307add any that are missing:
308
309smmsp:*:25:25::0:0:Sendmail Submission User:/var/spool/clientmqueue:/sbin/nologin
dcf85892 310_pflogd:*:64:64::0:0:pflogd privsep user:/var/empty:/sbin/nologin
a3107071
MD
311
312The following groups may be missing from your group file. Use vi /etc/group
313and add any that are missing:
314
315smmsp:*:25:
316authpf:*:63:
dcf85892 317_pflogd:*:64:
a3107071
MD
318
319
f419daca 320> Upgrading to DragonFly from FreeBSD
5e0ae0d4 321---------------------
984263bc 322
f419daca
MD
323You can build the DragonFly world and DragonFly kernels on a FreeBSD-4.x or
324FreeBSD-5.x machine and then install DragonFly over FreeBSD, replacing
325FreeBSD. Note that the DragonFly buildworld target does not try to reuse
326make depend information, it starts from scratch, so no pre-cleaning of the
327object hierarchy is necessary.
328
466bbc10 329 # get the CVS repository (it is placed in /home/dcvs, 500MB).
f419daca
MD
330 # Please use the -h option and a mirror site to pull the
331 # initial repository, but feel free to use the main repository
332 # machine to pull updates.
5010eeb3 333 cvsup /usr/share/examples/cvsup/DragonFly-cvs-supfile
f419daca
MD
334 # install the source from the CVS hierarchy (remove preexisting
335 # FreeBSD src first) (500MB)
336 cd /usr
337 rm -rf src
50172b1c 338 cvs -R -d /home/dcvs checkout -P src
f419daca
MD
339
340 # build it (500MB used in /usr/obj)
341 #
342 cd /usr/src
343 make buildworld
344 make buildkernel KERNCONF=<KERNELNAME>
984263bc 345
f419daca
MD
346Once you have built DragonFly you have to install it over FreeBSD. Since
347DragonFly does not track changes made by FreeBSD to its include file
348hierarchy and include file pollution can cause all sorts of unexpected
349compilation issues to come up, it is best to wipe your include hierarchy
350prior to installing DragonFly. Note that you should not wipe any installed
351FreeBSD header files or binaries until after you have successfully completed
352the build steps above.
fb12f484 353
f419daca
MD
354 rm -rf /usr/include
355 mkdir /usr/include
356 make installkernel KERNCONF=<KERNELNAME>
357 make installworld
fb12f484 358
b8cbf045 359Then you need to upgrade your system. DragonFly's 'make upgrade' target
f419daca 360will unconditionally upgrade the /etc files that sysops do not usually
b8cbf045
SW
361mess around with, such as the files in /etc/rc.d. It will also remove any
362obsolete files such as utilities and manpages that have been removed from
363the system since the version you're coming from. If you are unsure we
364recommend that you make a backup of at least your /etc before applying
365this step. Note that DragonFly's RC system is basically RCNG from
366FreeBSD-5, but there are some differences in the contents of the RC files.
f419daca
MD
367
368 make upgrade
369
b8cbf045
SW
370NOTE! Never do a 'make upgrade' before 'make installworld' has been run.
371Doing so might leave your system in an unusable state.
372
f419daca 373Finally we recommend that you do an 'ls -lta BLAH' for /bin, /sbin, /usr/bin,
b8cbf045
SW
374/usr/bin, and /usr/lib, and remove any stale files that you find. Please
375report these files to the DragonFly developers so that they can be added to
376the 'upgrade' target.
f419daca 377