BSD Stuff
Updating FreeBSD
14 September 2006, 01:01
- 1
- 2
This is how I update my FreeBSD systems. Updating the kernel and ports tree I’ll use cvsup, for updating the ports that are installed I’ll use portupgrade.
First we will have to install cvsup-without-gui. Because the ports tree is still out dated we will use pkg_add to install it and then we make the necessary changes so it reflects to the current version we’ll be running and to choose a cvsup server. To find a cvsup server near you go and have a look here
# pkg_add -vr cvsup-without-gui# cp /usr/share/examples/cvsup/standard-supfile ~/# vim ~/standard-supfile
| # | Code |
|---|---|
| 0001 | *default host=cvsup.de.freebsd.org |
| 0002 | *default base=/var/db |
| 0003 | *default prefix=/usr |
| 0004 | *default release=cvs tag=RELENG_6 |
| 0005 | *default delete use-rel-suffix |
| 0006 | |
| 0007 | *default compress |
| 0008 | |
| 0009 | src-all |
| 0010 |
Now we are ready to run cvsup to update the /usr/src/ tree and update the kernel and userland.
# cd /usr/src# make cleanworld# cvsup -g -L 2 /path-to-supfile# make buildworld# make buildkernel# make installkernel# mergemaster -p# make installworld# mergemaster# reboot
If you want to make or have made any changes to the kernel file a simple make buildkernel and make installkernel will not work because it will compile the GENERIC kernel, to do that there are a few more steps.
# cd /usr/src/sys/i386/conf# cp GENERIC MYKERNEL# vim MYKERNEL# make buildkernel KERNCONF=MYKERNEL# make installkernel KERNCONF=MYKERNEL
Run the following to see if the changes were made
uname -a
Next we look into how to update the ports tree and the installed ports.
Page 1 of 2