Ensure that System Requirements have been met prior to proceeding with the CentOS Configuration Guide.
yum update |
All installations of ProVision require at least PHP 5.5 (and related extensions). CentOS 6 comes with PHP 5.3 by default. You can either add a repository which provides PHP 5.5 or install PHP manually.
The Webtatic and Remi repos both have versions of PHP which are newer than those in the official repos. For this example, we'll be using Webtatic
Add the repository:
rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm |
Update:
yum update |
Install:
PHP5 / Apache2 / extensions
Development tools for pecl / additional system packages:
|
yum install httpd php55w php55w-opcache php55w-mysqlnd php55w-pdo php55w-ldap php55w-pecl-memcache php55w-bcmath php55w-devel php55w-pear php55w-cli curl openssl memcached mod_ssl |
MySQL is included with most CentOS installs, check for it with:
yum list installed | grep mysql |
The default MySqL version included with most CentOS installs will need to be upgraded to the latest version:
rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm |
If you have an existing installation, you can replace it with:
yum install mysql.`uname -i` yum-plugin-replace yum replace mysql --replace-with mysql55w |
For a fresh install:
yum install mysql55w mysql55w-server |
Then, re-start and configure.
service mysqld start chkconfig mysqld on |
/usr/bin/mysqladmin -u root password 'new-password' |
For an existing install / upgrade, you will need to upgrade the existing tables after the restart.
mysql_upgrade -u root -p |
This will issue a password prompt for the user. If you don't have a root user password, remove the "-p".
|
yum install curl openssl nmap bind-utils bind expect |
yum groupinstall 'Development Tools' yum install openssl-devel perl-devel perl-CPAN cd /usr/src wget https://www.dnssec-tools.org/download/dnssec-tools-2.1.tar.gz tar -xzf dnssec-tools-2.1.tar.gz ./configure make make install |
Self signed certificates in CentOS 6 by default have been already installed.
If you want to change it, follow the steps below:
Note: For production install, it is HIGHLY RECOMMENDED to use organization signed certs |
Generate private key, CSR, and temporary key if one hasn't been provided.
openssl genrsa -out ca.key 1024 openssl req -new -key ca.key -out ca.csr openssl x509 -req -days 365 -in ca.csr -signkey ca.key -out ca.crt |
cp ca.crt /etc/pki/tls/certs cp ca.key /etc/pki/tls/private/ca.key cp ca.csr /etc/pki/tls/private/ca.csr |
Make sure that you copy the files and do not move them if SELinux is enabled (which it is by default) |
vi /etc/httpd/conf.d/ssl.conf |
SSLCertificateFile /etc/pki/tls/certs/ca.crt SSLCertificateKeyFile /etc/pki/tls/private/ca.key |
/etc/init.d/httpd restart |
sed -i 's/AllowOverride None/AllowOverride All/g' /etc/httpd/conf/httpd.conf |
chkconfig httpd on service httpd start |
Please note that mod_rewrite is required! If it is not enabled in Apache, key elements will not work as expected. |
Set the MySQL Configuration:
mysql -p -e "SET GLOBAL sql_mode='NO_ENGINE_SUBSTITUTION';SET SESSION sql_mode='NO_ENGINE_SUBSTITUTION';" |
then enter the MySQL root password when prompted.
Please remember - if you change the IP address of the your server, then you will need to update SELinux functions accordingly |
/usr/sbin/getsebool -a | grep httpd |
/usr/sbin/setsebool -P httpd_can_network_connect 1 |
IPTables is enabled by default on CentOS. Add a new rule to allow 443 from anywhere. Make sure that this rule is in the chain BEFORE any blanket reject rule:
To list all current IPTable rules:
To add a rule for 443:
To save the new config:
OR (some versions of centOS have different iptables names, so the above won't work)
With the file open for editing, add:
Once complete - restart the iptables service:
|
This section only needs to be followed if the customer will be using Radius for authentication.
Install radius module:
|
yum install libssh2-devel pecl install -f ssh2 echo extension=ssh2.so > /etc/php.d/ssh2.ini |
Source Guardian is only required for ProVision versions 5.1.2 and earlier. If installing ProVision 5.1.3 or later, skip this step. |
Install the Source Guardian php extension.
Download the loader and put it in the appropriate place. Place the file in your php extension directory as specified in your php.ini Note: The PHP cli binary path must be set in the ProVision software Admin section if is different from default. By default it is /usr/bin/php. Add extension=ixed.x.x.y.y to your php.ini
Reload the web server
|
1. Remove the current contents in the ProVision web folder (currently the www root) and after extract the archive contents:
tar -xf productionBuild-5.1.2-php5.5.tar -C /var/www/html |
2. Change the permissions to be the web user permissions
chown -R apache.apache /var/www/html
3. Go to http://﹤web root﹥/configTest.php. If there are any configuration errors listed in red, other than in the Database and Configuration Files section, they must be corrected.
4. Run configDir.sh ﹤web user﹥ from the command line as root in the web root. This will setup the directories apache user needs read/write access to.
cd /var/www/html /var/www/html/configDir.sh apache |
5. Create the default database and initial user in MySQL
6. Go to http://﹤web root﹥/configBootstrap.php. Fill in the requested information, noting any login credentials.
7. Create a secure directory and run configSecureKeys.sh ﹤web user﹥ ﹤path to secure directory﹥ from the command line as root. This sets up the secure directory where your key file for password management will be stored. The secure directory should be a location outside of the web root that is only accessible by appropriate users.
mkdir /secure ./configSecureKeys.sh apache /secure |
8. Log in using the credentials that were generated in Step 6 and change your password!