I've last revised install instructions on January 22nd, 2006:
Since I couldn't find detailed information about setup of cPanel on FreeBSD, I thought to share my experience. This is a step-by-step for newbies, please feel free to add or comment onto it
Notice: I shall not be held responsible for any information provided here, and I recommend an experienced administrator to manage your server. These steps should not be processed on current production systems.
These instructions are based on FreeBSD 4.x/5.x & cPanel 9.x
All command line executions starts with ">>"
The following is needed to properly installed FreeBSD: perl 5.8.x (need to upgrade the perl that comes with FreeBSD 4.x before proceeding)
Partition FreeBSD steps:
=================
Partitioning is very important to be done properly. You need to take into account your current capabilities and your expectations in the future. So evaluate your needs carefully. As well, FreeBSD partition sizes different from Linux.
This is how much you'll be USING after the installation of FreeBSD, cPanel and source / ports:
SWAP (double your memory size)MB
/ 50MB
/tmp 256MB
/var 48MB
/usr 1,927MB
This is my recommended minimal parition size assuming you have 40GB+ hard drive:
SWAP (double your memory size)MB
/ 256MB - 512MB (root , boot)
/tmp 512MB-1024MB (store temp files sometimes large)
/var 5,000MB+ (location for your mySQL db, logs)
/usr 10,000MB+ (your local files, system files, cPanel files, fantastico..etc)
/home (rest of hard drive)
1)
To perform the following steps, you need to have installed the source code for your Kernel and the FreeBSD ports. If you've not done that during the installation, or if the source code still was not installed, you need to enter the setup console and install it as the following:
You can check if you have the source by going to:
>> cd /usr/src/sys/i386
If you are able to change to the above directory, then sources are installed
Logged in as root type:
>>/stand/sysinstall
choose "Configure"
choose "Distributions"
hit the space bar on "src"
this will take you to the src screen then hit the space bar on "all"
hit the space bar on "exit"
hit the space bar on "ports"
Press the tab key until you highlight "Ok" and hit Enter.
Exit out of the SysInstall
2)
You need to enable quotas on the system and re-compile the kernel (be very careful with these steps):
Your default kernel is located at (this is for 32-bit machines only):
/usr/src/sys/i386/conf
If you are using 64-bit OS and installed 5.4 amd64 version, your kernel is:
/usr/src/sys/amd64/conf
go to that path and run the following:
>>cp GENERIC MYKERNEL
>>edit MYKERNEL
add the following lines to your MYKERNEL file
# To enable quotas on the system
options QUOTA
Hit ESC then (a) to exit and save.
To compile the Kernel type the following:
>>/usr/sbin/config MYKERNEL
it will do some work then put you back to the prompt type:
>>cd ../compile/MYKERNEL
(This is on FreeBSD 5.x, for FreeBSD 4.x use "cd ../../compile/MYKERNEL")
>>make depend
Will take a minute or so
>>make
Will take another minute
>>make install
This should finish with no errors, if there are errors, go and check your MYKERNEL file for anything added or deleted improperly. It could also lead to a hardware conflict if kernel doesn't compile properly.
Now we need to edit /etc/rc.conf:
>>edit /etc/rc.conf
add the following line to the end of the file:
enable_quotas="YES"
To disable checking quotas at startup (recommended):
check_quotas="NO"
We need to set the quotas on the partition for /home (if you've created one or /usr if you didn't create a partition for it):
>>edit /etc/fstab
And add the following to your /usr or /home partition (which ever you're using), under the OPTIONS column add:
rw, userquota,groupquota
Press ESC to exit and (a) to save
Then reboot the system. If all works fine, you should be able to type:
>>quota -v
and it will display current quotas.
3)
Final step is to install the cPanel. If you've not created /home partition, then create a folder inside the /usr partition by:
>>cd /usr
>>mkdir /home
>>cd home
Installation of cPanel:
>>fetch http://layer1.cpanel.net/latest
It will take few minutes to download depending on your connection speed.
>>sh latest
The process of installing cPanel will take about 30 minutes or more depending on your processor and connection speed.
5)
Setup cPanel, after the installation is complete reboot the machine and try to access it from the web using the public IP address you've been provided
http://<your.IP.address.here>:2086/
Your login is: root
Your password is the same as the root password for your local system.
6)
After you setup the server and Apache is configured properly, you'll need to install FrontPage extensions (for some reason this wasn't installed for me with cPanel. I didn't submit a bug about it though....can anyone confirm?).
Go to the ports collection
>>cd /usr/ports/www
>>cd frontpage
>>make install
Reboot the system once installation is done.
7) It seems that BIND on some FreeBSD systems comes not configured properly. So this is what need to do to enable BIND:
>>edit /etc/namedb/named.conf
look for the line:
I hope these information are of good value, from my demo testing, this is what you need to setup FreeBSD properly with no need for additional configurations. If something else needed, please share it with the rest of us.
Since I couldn't find detailed information about setup of cPanel on FreeBSD, I thought to share my experience. This is a step-by-step for newbies, please feel free to add or comment onto it
Notice: I shall not be held responsible for any information provided here, and I recommend an experienced administrator to manage your server. These steps should not be processed on current production systems.
These instructions are based on FreeBSD 4.x/5.x & cPanel 9.x
All command line executions starts with ">>"
The following is needed to properly installed FreeBSD: perl 5.8.x (need to upgrade the perl that comes with FreeBSD 4.x before proceeding)
Partition FreeBSD steps:
=================
Partitioning is very important to be done properly. You need to take into account your current capabilities and your expectations in the future. So evaluate your needs carefully. As well, FreeBSD partition sizes different from Linux.
This is how much you'll be USING after the installation of FreeBSD, cPanel and source / ports:
SWAP (double your memory size)MB
/ 50MB
/tmp 256MB
/var 48MB
/usr 1,927MB
This is my recommended minimal parition size assuming you have 40GB+ hard drive:
SWAP (double your memory size)MB
/ 256MB - 512MB (root , boot)
/tmp 512MB-1024MB (store temp files sometimes large)
/var 5,000MB+ (location for your mySQL db, logs)
/usr 10,000MB+ (your local files, system files, cPanel files, fantastico..etc)
/home (rest of hard drive)
1)
To perform the following steps, you need to have installed the source code for your Kernel and the FreeBSD ports. If you've not done that during the installation, or if the source code still was not installed, you need to enter the setup console and install it as the following:
You can check if you have the source by going to:
>> cd /usr/src/sys/i386
If you are able to change to the above directory, then sources are installed
Logged in as root type:
>>/stand/sysinstall
choose "Configure"
choose "Distributions"
hit the space bar on "src"
this will take you to the src screen then hit the space bar on "all"
hit the space bar on "exit"
hit the space bar on "ports"
Press the tab key until you highlight "Ok" and hit Enter.
Exit out of the SysInstall
2)
You need to enable quotas on the system and re-compile the kernel (be very careful with these steps):
Your default kernel is located at (this is for 32-bit machines only):
/usr/src/sys/i386/conf
If you are using 64-bit OS and installed 5.4 amd64 version, your kernel is:
/usr/src/sys/amd64/conf
go to that path and run the following:
>>cp GENERIC MYKERNEL
>>edit MYKERNEL
add the following lines to your MYKERNEL file
# To enable quotas on the system
options QUOTA
Hit ESC then (a) to exit and save.
To compile the Kernel type the following:
>>/usr/sbin/config MYKERNEL
it will do some work then put you back to the prompt type:
>>cd ../compile/MYKERNEL
(This is on FreeBSD 5.x, for FreeBSD 4.x use "cd ../../compile/MYKERNEL")
>>make depend
Will take a minute or so
>>make
Will take another minute
>>make install
This should finish with no errors, if there are errors, go and check your MYKERNEL file for anything added or deleted improperly. It could also lead to a hardware conflict if kernel doesn't compile properly.
Now we need to edit /etc/rc.conf:
>>edit /etc/rc.conf
add the following line to the end of the file:
enable_quotas="YES"
To disable checking quotas at startup (recommended):
check_quotas="NO"
We need to set the quotas on the partition for /home (if you've created one or /usr if you didn't create a partition for it):
>>edit /etc/fstab
And add the following to your /usr or /home partition (which ever you're using), under the OPTIONS column add:
rw, userquota,groupquota
Press ESC to exit and (a) to save
Then reboot the system. If all works fine, you should be able to type:
>>quota -v
and it will display current quotas.
3)
Final step is to install the cPanel. If you've not created /home partition, then create a folder inside the /usr partition by:
>>cd /usr
>>mkdir /home
>>cd home
Installation of cPanel:
>>fetch http://layer1.cpanel.net/latest
It will take few minutes to download depending on your connection speed.
>>sh latest
The process of installing cPanel will take about 30 minutes or more depending on your processor and connection speed.
5)
Setup cPanel, after the installation is complete reboot the machine and try to access it from the web using the public IP address you've been provided
http://<your.IP.address.here>:2086/
Your login is: root
Your password is the same as the root password for your local system.
6)
After you setup the server and Apache is configured properly, you'll need to install FrontPage extensions (for some reason this wasn't installed for me with cPanel. I didn't submit a bug about it though....can anyone confirm?).
Go to the ports collection
>>cd /usr/ports/www
>>cd frontpage
>>make install
Reboot the system once installation is done.
7) It seems that BIND on some FreeBSD systems comes not configured properly. So this is what need to do to enable BIND:
>>edit /etc/namedb/named.conf
look for the line:
Change these to:// If named is being used only as a local resolver, this is a safe default.
// For named to be accessible to the network, comment this option, specify
// the proper IP address, or delete this option.
listen-on { 127.0.0.1; };
Exit and save the file, then restart BIND from within WHM.// If named is being used only as a local resolver, this is a safe default.
// For named to be accessible to the network, comment this option, specify
// the proper IP address, or delete this option.
// listen-on { 127.0.0.1; };
I hope these information are of good value, from my demo testing, this is what you need to setup FreeBSD properly with no need for additional configurations. If something else needed, please share it with the rest of us.
Last edited: