Home / Разни / Upgrade FreeBSD 10 from RELEASE to STABLE

Upgrade FreeBSD 10 from RELEASE to STABLE

Upgrade FreeBSD 10 from RELEASE to STABLE

What is STABLE ?

The name „-STABLE“ is frequently misunderstood. It does not mean solid or steady. -STABLE means that while code can change, the ABI (Application Binary Interface) will remain stable and not change. Programs compiled to run on FreeBSD 9.0-RELEASE, or 9.1-RELEASE, or 9.2-RELEASE will continue to work on FreeBSD 9-STABLE. Effectively, -STABLE is the latest version of FreeBSD you can get without breaking installed software.

Move the current source code to a backup folder to be sure to get only -STABLE code:

mv /usr/src /usr/src-RELEASE

Do the same thing for the ports tree:

mv /usr/ports /usr/ports-RELEASE

When I did not moved the /usr/src folder and continued this article, everytime I would be back in 10.0-RELEASE…

Check out the STABLE source code:

svn checkout https://svn0.us-west.freebsd.org/base/stable/10 /usr/src

Also for the ports tree:

svn checkout https://svn0.us-west.freebsd.org/ports/head /usr/ports

Then cd in to the correct folder

cd /usr/src

Build the world:

make buildworld -j4

The -j 4 part means that it should run 4 jobs at once. I have a quad core CPU so all the cores will be used.

Build the kernel:

make buildkernel KERNCONF=MYKERNEL
make installkernel KERNCONF=MYKERNEL

Now reboot in to the new kernel:

shutdown -r now

Next, it was time to install the world. However, make installworld complained:

ERROR: Required unbound user is missing, see /usr/src/UPDATING.
*** Error code 1

make[1]: stopped in /usr/src
*** Error code 1

make: stopped in /usr/src

/usr/src/UPDATING to the rescue:

With the addition of unbound(8), a new unbound user is now
        required during installworld.  "mergemaster -p" can be used to
        add the user prior to installworld, as documented in the handbook.

However, mergemaster -p did not create the user:

mergemaster -p

*** Creating the temporary root environment in /var/tmp/temproot
 *** /var/tmp/temproot ready for use
 *** Creating and populating directory structure in /var/tmp/temproot

*** Beginning comparison

 *** Temp ./etc/group and installed have the same Id, deleting
 *** Temp ./etc/master.passwd and installed have the same Id, deleting

*** Comparison complete

*** /var/tmp/temproot is empty, deleting

I already am on FreeBSD 10, but this box is updated from 8 to 9 to 10, so maybe that didn’t work out quite well. Installing unbound via pkg did work:

pkg install unbound

It seemed that it was half done:

Proceed with installing packages [y/N]: y
Checking integrity... done
[1/2] Installing ldns-1.6.17... done
[2/2] Installing unbound-1.4.22...===> Creating users and/or groups.
Using existing group 'unbound'.
Creating user 'unbound' with uid '59'.

Oh wel… Now the make installworld continues;

make installworld

After that finished we can do another mergemaster:

mergemaster -Ui 

Time to reboot:

shutdown -r now

Remove old files and libraries:

cd /usr/src
make check-old
>>> Checking for old files
>>> Checking for old libraries
>>> Checking for old directories
To remove old files and directories run 'make delete-old'.
To remove old libraries run 'make delete-old-libs'.

make delete-old
>>> Removing old files (only deletes safe to delete libs)
remove /usr/include/clang/3.3/__wmmintrin_aes.h? y
remove /usr/include/clang/3.3/__wmmintrin_pclmul.h? y
remove /usr/include/clang/3.3/altivec.h? y
remove /usr/include/clang/3.3/ammintrin.h? y
>>> Old files removed
>>> Removing old directories
>>> Old directories removed
To remove old libraries run 'make delete-old-libs'.

make delete-old-libs
>>> Removing old libraries
Please be sure no application still uses those libraries, else you
can not start such an application. Consult UPDATING for more
information regarding how to cope with the removal/revision bump
of a specific library.
>>> Old libraries removed

Note that freebsd-update does not work with the STABLE branch. Therefore this process is required…

That’s it. Run freebsd-version to see that you are now on stable:


Обвързани статии :

How to upgrade FreeBSD 10 from RELEASE to STABLE

How To Tail Multiple Files on UNIX / Linux Console

How to install FreeBSD 10 Step by Step

About panev

Check Also

KVM and VirtManager on CentOS 7

KVM and VirtManager on CentOS 7 KVM is a kernel-based hypervisor which grows quickly in …

Вашият коментар

Вашият имейл адрес няма да бъде публикуван. Задължителните полета са отбелязани с *