Difference between revisions of "Convert a FreeBSD System to PC-BSD®"

From PC-BSD Wiki
Jump to: navigation, search
 
(48 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{NavHome|custompagename=Turn FreeBSD into PC-BSD{{r}}|custompagecategory={{PAGENAME}}}}
+
<noinclude><translate>
  
Make sure you have these ports installed, using pkg_add or ports:
+
<!--T:1-->
{{txtbox|pre|width=48%|box=
+
{{NavHeader|back=Install a Server |forward=Using a Rolling Release}}</noinclude>
devel/subversion
+
devel/cmake
+
devel/cmake-gui
+
devel/gmake
+
devel/qt4-assistant
+
devel/qt4-assistant-adp
+
devel/qt4-designer
+
misc/qt4-doc
+
devel/qt4-libqtassistantclient
+
devel/qt4-linguist
+
devel/qt4-moc
+
devel/qmake4
+
devel/qt4-rcc
+
devel/qt4-qtsolutions-singleapplication}}
+
  
Then run:
+
<!--T:29-->
{{txtbox|pre|width=48%|box={{pound}} svn co <nowiki>svn://</nowiki>svn.pcbsd.org/pcbsd/current current
+
Beginning in February, 2013, the PC-BSD® utilities dealing with software installation and upgrades were converted to [https://wiki.freebsd.org/pkgng pkgng], FreeBSD's Next Generation package management tool. Part of this change included the creation of a custom PC-BSD® package repository which contains all of the packages that can be built using pkgng. Since the FreeBSD project does not yet have an official pkgng repository, FreeBSD users who wish to use pkgng are welcome to use the PC-BSD® package repository.
{{pound}} cd current/src-sh
+
{{pound}} make
+
{{pound}} make install
+
{{pound}} cd ../src-qt4/libpcbsd
+
{{pound}} qmake-qt4 *.pro>
+
{{pound}} make
+
{{pound}} make install
+
{{pound}} cd ..
+
{{pound}} qmake-qt4 *.pro
+
{{pound}} make
+
{{pound}} make install
+
|txt=The keyword 'current' means this would not be the release (9.1) version.<br>
+
<br> <!-- These empty lines help align the above sentence with the top -->
+
<br> <!-- If there were more text it could be added. -->
+
<br>
+
<br> <!-- Take a peek at txtbox template, results are as expected. -->
+
<br>
+
<br>
+
<br>
+
<br>
+
<br>
+
<br>
+
<br>
+
}}
+
  
[http://forums.pcbsd.org/showthread.php?p=96451#post96451 source]
+
<!--T:30-->
 +
This package repository contains a custom package, called ''pcbsd-base'', which can be used to easily convert an existing FreeBSD installation into a PC-BSD® desktop. It also contains a custom package called ''trueos-base'' which can be used to convert an existing FreeBSD installation into a TrueOS® server. The converted desktop will contain all of the graphical utilities that come with PC-BSD® and the converted server will contain all of their command line equivalents.
 +
 
 +
<!--T:31-->
 +
This section describes how to:
 +
 
 +
<!--T:32-->
 +
* Configure a FreeBSD or PC-BSD® system to use the pkgng repository.
 +
 
 +
<!--T:33-->
 +
* Convert a FreeBSD system to a PC-BSD® desktop.
 +
 
 +
<!--T:34-->
 +
* Convert a FreeBSD system to a TrueOS® server.
 +
 
 +
== Switching to the PC-BSD® pkgng Repository == <!--T:5-->
 +
 
 +
<!--T:6-->
 +
If you are running PC-BSD® 9.1-RELEASE or FreeBSD 9.1, you will need to first install the {{citelink|url=http://www.freshports.org/ports-mgmt/pkg/ ports-mgmt/pkg|txt=port or package}}.
 +
 
 +
<!--T:7-->
 +
After installing pkg, run the command '''pkg2ng''' to import your existing package database from the old format to the new pkgng format.
 +
 
 +
<!--T:8-->
 +
Next, configure access to the PC-BSD® repository. Start by creating the file ''/usr/local/etc/pkg.conf'' with the following contents:
 +
 
 +
<!--T:35-->
 +
{{txtbox|box=packagesite: {{ftp}}ftp.pcbsd.org/pub/mirror/packages/9.1-RELEASE/amd64
 +
PUBKEY: /usr/local/etc/pkg-pubkey.cert
 +
PKG_CACHEDIR: /usr/local/tmp}}
 +
 
 +
<!--T:10-->
 +
Note that the ''packagesite:'' variable should be changed to a PC-BSD® mirror close to your geographic location. Additionally, ''9.1-RELEASE'' and ''amd64'' can be changed to indicate the release version and architecture you want to use. Click [http://www.pcbsd.org/getmirrors.php?url=packages here] to get a list of the available mirrors and package sets.
 +
 
 +
<!--T:11-->
 +
Next, download the repository's [http://trac.pcbsd.org/export/780f3da562b72643c04b47a59d277102a09abbca/src-sh/pc-extractoverlay/desktop-overlay/usr/local/etc/pkg-pubkey.cert public key cert file], and copy it to ''/usr/local/etc/pkg-pubkey.cert''.
 +
 
 +
<!--T:12-->
 +
The system is now configured and you now update your packages to the latest versions from the pkgng repository using the following command:
 +
 
 +
<!--T:13-->
 +
{{txtbox|box= '''pkg upgrade -fy'''}}
 +
 
 +
<!--T:14-->
 +
Depending upon what is already installed, you may have to resolve some error messages in order to successfully upgrade all packages.
 +
 
 +
<!--T:15-->
 +
To install and delete packages use the '''pkg''' command. This command differs in usage from the original package format version. You can learn more about how to use this command in [http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/pkgng-intro.html Section 5.5.3 of the FreeBSD Handbook].
 +
 
 +
== Converting FreeBSD to a PC-BSD® Desktop == <!--T:16-->
 +
 
 +
<!--T:17-->
 +
Once the repository configuration is complete, it is now easy to convert a FreeBSD system into a PC-BSD® desktop using the following commands as the superuser:
 +
 
 +
<!--T:36-->
 +
{{txtbox|box= '''pkg install -fy pcbsd-base'''
 +
'''rehash'''
 +
'''pbreg set /PC-BSD/SysType PCBSD'''
 +
'''pc-extractoverlay desktop'''
 +
'''pc-extractoverlay ports'''}}
 +
 
 +
<!--T:37-->
 +
Next, reboot the system and the PC-BSD® login manager will start, allowing you to login to the desktop. If you want the [Post Installation Configuration and Installation Troubleshooting |PC-BSD® display wizard and first boot wizards] to run first, run these commands before rebooting:
 +
 
 +
<!--T:38-->
 +
{{txtbox|box= '''touch /var/.runxsetup'''
 +
'''touch /var/.pcbsd-firstboot'''
 +
'''touch /var/.pcbsd-firstgui'''}}
 +
 
 +
<!--T:39-->
 +
If you are running FreeBSD 10-CURRENT, specify the PBI version to pull from.  To do so, edit ''/usr/local/etc/pbi.conf'' and add this line:
 +
 +
{{txtbox|box=PBI_FBSDMAJOR: 9}}
 +
 
 +
<!--T:40-->
 +
{{note|icon64= If you are using NVIDIA video hardware, load the driver before rebooting into the display wizard by running the command '''pc-metapkgmanager add NVIDIA'''.}}
 +
 
 +
== Converting FreeBSD to a TrueOS® Server == <!--T:26-->
 +
 
 +
<!--T:27-->
 +
If you wish to convert a FreeBSD server to TrueOS®, use the following commands:
 +
 
 +
<!--T:41-->
 +
{{txtbox|box= '''pkg install -fy trueos-base'''
 +
'''rehash'''
 +
'''pbreg set /PC-BSD/SysType TRUEOS'''
 +
'''pc-extractoverlay server'''
 +
'''pc-extractoverlay ports'''}}
 +
 
 +
<!--T:42-->
 +
The installation of the ''trueos-base'' package will install the following: [[PBI Manager]], the command line version of '''[[Warden®#Using the Command Line Version of Warden® | warden]]''', and the command line versions of most of the [[Control Panel]] utilities. You will find those utilities in ''/usr/local/bin/pc-*''. It also installs this {{citelink|url=http://trac.pcbsd.org/browser/pcbsd/branches/9.1/build-files/metapkgsets/warden/pkgset/base-system/ports-list|txt=list}} of additional shells and utilities.
 +
</translate>
 +
<noinclude>
 +
{{refheading}}
 +
[[category:Convert a FreeBSD System to PC-BSD®]]
 +
[[category:Advanced Installation Topics]]
 +
[[category:handbook]]
 +
<languages/>
 +
</noinclude>

Latest revision as of 07:52, 17 May 2013


Previous: Install a Server Return to Table of Contents Next: Using a Rolling Release
Convert a FreeBSD System to PC-BSD®

Contents


Beginning in February, 2013, the PC-BSD® utilities dealing with software installation and upgrades were converted to pkgng, FreeBSD's Next Generation package management tool. Part of this change included the creation of a custom PC-BSD® package repository which contains all of the packages that can be built using pkgng. Since the FreeBSD project does not yet have an official pkgng repository, FreeBSD users who wish to use pkgng are welcome to use the PC-BSD® package repository.

This package repository contains a custom package, called pcbsd-base, which can be used to easily convert an existing FreeBSD installation into a PC-BSD® desktop. It also contains a custom package called trueos-base which can be used to convert an existing FreeBSD installation into a TrueOS® server. The converted desktop will contain all of the graphical utilities that come with PC-BSD® and the converted server will contain all of their command line equivalents.

This section describes how to:

  • Configure a FreeBSD or PC-BSD® system to use the pkgng repository.
  • Convert a FreeBSD system to a PC-BSD® desktop.
  • Convert a FreeBSD system to a TrueOS® server.

[edit] Switching to the PC-BSD® pkgng Repository

If you are running PC-BSD® 9.1-RELEASE or FreeBSD 9.1, you will need to first install the ports-mgmt/pkg port or package[1].

After installing pkg, run the command pkg2ng to import your existing package database from the old format to the new pkgng format.

Next, configure access to the PC-BSD® repository. Start by creating the file /usr/local/etc/pkg.conf with the following contents:

packagesite: ftp://ftp.pcbsd.org/pub/mirror/packages/9.1-RELEASE/amd64

PUBKEY: /usr/local/etc/pkg-pubkey.cert PKG_CACHEDIR: /usr/local/tmp

Note that the packagesite: variable should be changed to a PC-BSD® mirror close to your geographic location. Additionally, 9.1-RELEASE and amd64 can be changed to indicate the release version and architecture you want to use. Click here to get a list of the available mirrors and package sets.

Next, download the repository's public key cert file, and copy it to /usr/local/etc/pkg-pubkey.cert.

The system is now configured and you now update your packages to the latest versions from the pkgng repository using the following command:

pkg upgrade -fy

Depending upon what is already installed, you may have to resolve some error messages in order to successfully upgrade all packages.

To install and delete packages use the pkg command. This command differs in usage from the original package format version. You can learn more about how to use this command in Section 5.5.3 of the FreeBSD Handbook.

[edit] Converting FreeBSD to a PC-BSD® Desktop

Once the repository configuration is complete, it is now easy to convert a FreeBSD system into a PC-BSD® desktop using the following commands as the superuser:

pkg install -fy pcbsd-base

rehash pbreg set /PC-BSD/SysType PCBSD pc-extractoverlay desktop pc-extractoverlay ports

Next, reboot the system and the PC-BSD® login manager will start, allowing you to login to the desktop. If you want the [Post Installation Configuration and Installation Troubleshooting |PC-BSD® display wizard and first boot wizards] to run first, run these commands before rebooting:

touch /var/.runxsetup

touch /var/.pcbsd-firstboot touch /var/.pcbsd-firstgui

If you are running FreeBSD 10-CURRENT, specify the PBI version to pull from. To do so, edit /usr/local/etc/pbi.conf and add this line:

PBI_FBSDMAJOR: 9
NOTE:
If you are using NVIDIA video hardware, load the driver before rebooting into the display wizard by running the command pc-metapkgmanager add NVIDIA.

[edit] Converting FreeBSD to a TrueOS® Server

If you wish to convert a FreeBSD server to TrueOS®, use the following commands:

pkg install -fy trueos-base

rehash pbreg set /PC-BSD/SysType TRUEOS pc-extractoverlay server pc-extractoverlay ports

The installation of the trueos-base package will install the following: PBI Manager, the command line version of warden, and the command line versions of most of the Control Panel utilities. You will find those utilities in /usr/local/bin/pc-*. It also installs this list[2] of additional shells and utilities.


References


  1. http://www.freshports.org/ports-mgmt/pkg/ ports-mgmt/pkg
  2. http://trac.pcbsd.org/browser/pcbsd/branches/9.1/build-files/metapkgsets/warden/pkgset/base-system/ports-list
Other languages:English 100%