Home | 簡體中文 | 繁體中文 | 雜文 | 打賞(Donations) | ITEYE 博客 | OSChina 博客 | Facebook | Linkedin | 知乎專欄 | Search | Email

2.2. Updating and Upgrading FreeBSD

2.2.1. update

安全補丁

# freebsd-update fetch
# freebsd-update install
			

如果出現錯誤回滾

# freebsd-update rollback
			
freebsd# rehash
freebsd# freebsd-update fetch
Looking up update.FreeBSD.org mirrors... 3 mirrors found.
Fetching public key from update5.FreeBSD.org... done.
Fetching metadata signature for 8.0-RELEASE from update5.FreeBSD.org... done.
Fetching metadata index... done.
Fetching 2 metadata files... done.
Inspecting system... done.
Preparing to download files... done.
Fetching 35 patches.....10....20....30.. done.
Applying patches... done.

The following files will be updated as part of updating to 8.0-RELEASE-p3:
/boot/kernel/ip_mroute.ko
/boot/kernel/ip_mroute.ko.symbols
/boot/kernel/kernel
/boot/kernel/kernel.symbols
/boot/kernel/krpc.ko
/boot/kernel/krpc.ko.symbols
/boot/kernel/nfsclient.ko
/boot/kernel/nfsclient.ko.symbols
/boot/kernel/zfs.ko
/boot/kernel/zfs.ko.symbols
/etc/mtree/BSD.var.dist
/lib/libzpool.so.2
/libexec/ld-elf.so.1
/usr/bin/dig
/usr/bin/host
/usr/bin/nslookup
/usr/bin/nsupdate
/usr/lib/libopie.a
/usr/lib/libopie.so.6
/usr/lib/libssl.a
/usr/lib/libssl.so.6
/usr/lib/libzpool.a
/usr/sbin/dnssec-dsfromkey
/usr/sbin/dnssec-keyfromlabel
/usr/sbin/dnssec-keygen
/usr/sbin/dnssec-signzone
/usr/sbin/freebsd-update
/usr/sbin/jail
/usr/sbin/lwresd
/usr/sbin/named
/usr/sbin/named-checkconf
/usr/sbin/named-checkzone
/usr/sbin/named-compilezone
/usr/sbin/ntpd
/usr/sbin/rndc-confgen
/usr/share/man/man2/mount.2.gz
/usr/share/man/man2/nmount.2.gz
/usr/share/man/man2/unmount.2.gz
/var/db/freebsd-update
/var/db/mergemaster.mtree

freebsd# freebsd-update install
Installing updates... done.
			

2.2.2. upgrade

尋找版本

http://update5.freebsd.org/

升級至9.1-RELEASE

freebsd# freebsd-update upgrade -r 9.1-RELEASE
			
Looking up update.FreeBSD.org mirrors... 3 mirrors found.
Fetching metadata signature for 9.1-RC3 from update5.freebsd.org... done.
Fetching metadata index... done.
Fetching 1 metadata files... done.
Inspecting system... done.

The following components of FreeBSD seem to be installed:
kernel/generic world/base world/games world/lib32

The following components of FreeBSD do not seem to be installed:
src/src world/doc

Does this look reasonable (y/n)? y

Fetching metadata signature for 9.1-RELEASE from update5.freebsd.org... done.
Fetching metadata index... done.
Fetching 1 metadata patches. done.
Applying metadata patches... done.
Fetching 1 metadata files... done.
Inspecting system... done.
Fetching files from 9.1-RC3 for merging... done.
Preparing to download files...

			
freebsd# freebsd-update install