Cara Upgrade FreeBSD
Upgrade FreeBSD dilakukan untuk memperbarui FreeBSD ke versi rilis terbaru, misalnya pada tutorial ini dari versi 11.0 ke 11.1. Upgrade dilakukan karena versi rilis yang digunakan saat ini akan memasuki masa end-of-life atau tidak akan mendapatkan update lagi. Memakai sistem opearsi/aplikasi server yang tidak terupdate bisa berisiko pada keamanan. Informasi rilis FreeBSD yang masih didukung baca di FreeBSD.org.
Sebelum melakukan upgrade, FreeBSD di-update terlebih dahulu. Secara detail tentang update bisa dibaca di Cara Update FreeBSD.
1 2 | root@server:~ # freebsd-update fetch root@server:~ # freebsd-update install |
Selanjutnya perintah upgrade
1 | root@server:~ # freebsd-update upgrade -r 11.1-RELEASE |
Hasilnya seperti di bawah ini
Jawab y, download file upgrade
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | src component not installed, skipped Looking up update.FreeBSD.org mirrors... 4 mirrors found. Fetching metadata signature for 11.0-RELEASE from update3.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/lib32 The following components of FreeBSD do not seem to be installed: kernel/generic-dbg world/base-dbg world/doc world/lib32-dbg Does this look reasonable (y/n)? y |
Proses download file upgrade, 10697 file.
1 2 3 4 5 6 7 8 9 10 11 12 13 | Fetching metadata signature for 11.1-RELEASE from update3.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 11.0-RELEASE for merging... done. Preparing to download files... Fetching 10697 patches.....10....20....30....40....50....10670....10680....10690...done. Applying patches... done. Fetching 236 files... done. Attempting to automatically merge changes in files... done. To install the downloaded upgrades, run "/usr/sbin/freebsd-update install". |
Setelah download file selesai, jalankan perintah install
1 | root@server:~ # freebsd-update install |
Proses install kernel
1 2 3 4 | src component not installed, skipped Installing updates... Kernel updates have been installed. Please reboot and run "/usr/sbin/freebsd-update install" again to finish installing updates. |
Restart
1 | root@server:~ # reboot |
Setelah restart jalankan kembali perintah install
1 | root@server:~ # freebsd-update install |
Proses install
1 2 3 4 5 6 | src component not installed, skipped Installing updates... Completing this upgrade requires removing old shared object files. Please rebuild all installed 3rd party software (e.g., programs installed from the ports tree) and then run "/usr/sbin/freebsd-update install" again to finish installing updates. |
Jika sebelumnya sudah pernah install aplikasi via ports collection, jalankan perintah untuk rebuild 3rd party software. Jika tidak lanjutkan ke tahap selanjutnya.
1 | root@server:~ # portmaster -af |
Jika belum ada portmaster, install terlebih dahulu.
1 | root@server:~ # pkg install portmaster |
Jalankan kembali perintah update install yang terkahir.
1 | root@server:~ # freebsd-update install |
Cek versi setelah uprade
1 | root@server:~ # freebsd-version |
Hasilnya
1 | 11.1-RELEASE-p1 |
selamat mencoba 🙂
sumber:
gimana cara merubah mirror dari update resmi ke mirrorlist lokal (indonesia), karena di daftar mirrorlist resmi ga ada server dari indonesia. Paling dekat di Malaysia tapi kadang lemotnya minta ampun.
coba cek di file
/etc/pkg/FreeBSD.conf