You are on page 1of 7

install centos minimal

chmod +x /etc/rc.d/rc.local

vi /etc/rc.d/rc.local

loadkeys fr
ip route add 192.168.10.0/24 via 192.168.10.254
ip route add 192.168.20.0/24 via 192.168.10.254
ip route add 192.168.30.0/24 via 192.168.10.254
ip route add 192.168.40.0/24 via 192.168.10.254
ip route add 192.168.50.0/24 via 192.168.10.254
ip route add 192.168.60.0/24 via 192.168.10.254

export http_proxy=http://192.168.20.245
export https_proxy=$http_proxy
export ftp_proxy=$http_proxy
export dns_proxy=$http_proxy
export rsync_proxy=$http_proxy
export no_proxy="localhost,127.0.0.1,localaddress,.sgtg.tg"

vi /etc/environment
http_proxy="http://192.168.20.245:8080/"
https_proxy="https://192.168.20.245:8080/"
ftp_proxy="ftp://192.168.20.245:8080/"
no_proxy="localhost, 127.0.0.1/8, .sgtg.tg"

vi /etc/yum.conf
proxy=http://192.168.20.245:8080
proxy=https://192.168.20.245:8080

disable fastestmirror
vi /etc/yum/pluginconf.d/fastestmirror.conf

systemctl disable firewalld


systemctl stop firewalld

disable selinux

vi /etc/selinux/config

hostname
should return shortname
hostname -f
should return fqdn
hostnamectl set-hostname intrawebsrv.sgtg.tg

vi /etc/hosts
add

192.168.1.100 server1.example.com server1


192.168.10.17 intrawebsrv.sgtg.tg intrawebsrv

shutdown -r now

yum install wget telnet net-tools -y

yum install epel-release -y


wget https://centos7.iuscommunity.org/ius-release.rpm
wget http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
rpm -ivh ius-release.rpm remi-release-7.rpm

php-bcmath php-cli php-common php-gd php-intl php-mbstring php-mysqlnd php-pdo


php-pear php-soap php-xml php-xmlrpc php-fpm php-ldap php-pear-Net-LDAP2 php-*

install apache
yum install httpd httpd-devel httpd-tools mod_ssl -y

yum install httpd24* -y


yum install httpd24u mod24u_ssl mod24u_session mod_fcgid
mod_xsendfile

systemctl start httpd


systemctl enable httpd

yum install mariadb mariadb-server -y


systemctl start mariadb
systemctl enable mariadb
mysql_secure_installation

to use last version you need to run this


yum install yum-plugin-replace -y
yum replace mariadb-libs --replace-with=mariadb101u-libs -y
yum install mariadb101u mariadb101u-server -y

yum remove yum-plugin-replace -y

install PHP 5.4 (CentOS repos)


yum install php
yum install php php-bcmath php-cli php-common php-gd php-intl php-mbstring php-
mysqlnd php-pdo php-pear php-soap php-xml php-xmlrpc php-fpm php-ldap php-pear-Net-
LDAP2 php-symfony-ldap -y

php-*

systemctl restart httpd


systemctl start php-fpm
systemctl enable php-fpm

your php.ini for PHP5.4 is located at /etc/php.ini

PHP 5.6 (Remi-safe repos)

yum install php56-php-bcmath php56-php-cli php56-php-common php56-php-fpm php56-


php-gd php56-php-intl php56-php-mbstring php56-php-mcrypt php56-php-mysqlnd php56-
php-opcache php56-php-pdo php56-php-pear php56-php-pecl-uploadprogress php56-php-
soap php56-php-xml php56-php-xmlrpc php56-php-ldap -y

php56-php-*

feel free to add more php56-php-* packages to enhance your PHP5.6 functionality.

command line editor, and edit


vi /opt/remi/php56/root/etc/php-fpm.d/www.conf
so that
listen = 127.0.0.1:9000
is changed to
listen = 127.0.0.1:9006

systemctl start php56-php-fpm


systemctl enable php56-php-fpm

Your php.ini for all PHP56 settings is located at /opt/remi/php56/root/etc/php.ini

PHP 7.0 (Remi-safe repos)

yum install php70-php-bcmath php70-php-cli php70-php-common php70-php-fpm php70-


php-gd php70-php-intl php70-php-json php70-php-mbstring php70-php-mcrypt php70-php-
mysqlnd php70-php-opcache php70-php-pdo php70-php-pear php70-php-pecl-
uploadprogress php70-php-pecl-zip php70-php-soap php70-php-xml php70-php-xmlrpc
php70-php-ldap -y

php70-php-*

feel free to install more php70-php-* packages to enhance your PHP70 installation.
edit
vi /etc/opt/remi/php70/php-fpm.d/www.conf
change
listen = 127.0.0.1:9000
to
listen = 127.0.0.1:9007

systemctl start php70-php-fpm


systemctl enable php70-php-fpm

Your php.ini for all PHP70 settings is located at /etc/opt/remi/php70/php.ini

-----

PHP7.1

yum install php71 php71-php-bcmath php71-php-cli php71-php-common php71-php-fpm


php71-php-gd php71-php-intl php71-php-json php71-php-mbstring php71-php-mcrypt
php71-php-mysqlnd php71-php-opcache php71-php-pdo php71-php-pear php71-php-pecl-
uploadprogress php71-php-pecl-zip php71-php-soap php71-php-xml php71-php-xmlrpc
php71-php-ldap -y

php71-php-*

feel free to install more php71-php-* packages to enhance your PHP71 installation.

edit
vi /etc/opt/remi/php71/php-fpm.d/www.conf
change
listen = 127.0.0.1:9000
to
listen = 127.0.0.1:9008

systemctl start php71-php-fpm


systemctl enable php71-php-fpm

Your php.ini for all PHP71 settings is located at /etc/opt/remi/php71/php.ini

--------------------------
install postfix

yum install -y postfix cyrus-sasl-plain


systemctl start postfix
systemctl enable postfix

--------------------------------

yum install net-tools bind-utils telnet mailx vim traceroute nmap -y

Installing ISPConfig

wget https://downloads.sourceforge.net/project/ispconfig/ISPConfig%203/ISPConfig-
3.1.3/ISPConfig-3.1.3.tar.gz
tar zxf ISPC

php -q ispconfig3_install/install/install.php

--------------------------------------------------------------------------

[root@intrawebsrv ~]# php -q ispconfig3_install/install/install.php

--------------------------------------------------------------------------------
_____ ___________ _____ __ _ ____
|_ _/ ___| ___ \ / __ \ / _(_) /__ \
| | \ `--.| |_/ / | / \/ ___ _ __ | |_ _ __ _ _/ /
| | `--. \ __/ | | / _ \| '_ \| _| |/ _` | |_ |
_| |_/\__/ / | | \__/\ (_) | | | | | | | (_| | ___\ \
\___/\____/\_| \____/\___/|_| |_|_| |_|\__, | \____/
__/ |
|___/
--------------------------------------------------------------------------------

>> Initial configuration

Operating System: CentOS 7.3

Following will be a few questions for primary configuration so be careful.


Default values are in [brackets] and can be accepted with <ENTER>.
Tap in "quit" (without the quotes) to stop the installer.

Select language (en,de) [en]:

Installation mode (standard,expert) [standard]: expert

Full qualified hostname (FQDN) of the server, eg server1.domain.tld


[intrawebsrv.sgtg.tg]:

MySQL server hostname [localhost]:

MySQL server port [3306]:

MySQL root username [root]:

MySQL root password []: togo2017

MySQL database to create [dbispconfig]:

MySQL charset [utf8]:

The next two questions are about the internal ISPConfig database user and password.
It is recommended to accept the defaults which are 'ispconfig' as username and a
random password.
If you use a different password, use only numbers and chars for the password.

ISPConfig mysql database username [ispconfig]:


ISPConfig mysql database password [fd7c2e517e722b117889e94408d549b3]:

Shall this server join an existing ISPConfig multiserver setup (y,n) [n]:

Adding ISPConfig server record to database.

Configure Mail (y,n) [y]: n

[WARN] autodetect for Jailkit failed


Force configure Jailkit (y,n) [n]: n

Skipping Jailkit

[WARN] autodetect for pureftpd failed


Force configure pureftpd (y,n) [n]: y

Configuring Pureftpd
Configure DNS Server (y,n) [y]: n

Configure Web Server (y,n) [y]:

Configuring Apache
Configuring vlogger
[WARN] autodetect for OpenVZ failed
Force configure OpenVZ (y,n) [n]:

Skipping OpenVZ

Configure Firewall Server (y,n) [y]: n

[WARN] autodetect for Metronome XMPP Server failed


Force configure Metronome XMPP Server (y,n) [n]:

Skipping Metronome XMPP Server

[WARN] autodetect for Fail2ban failed


Force configure Fail2ban (y,n) [n]:

Skipping Fail2ban

Configuring Apps vhost


Install ISPConfig Web Interface (y,n) [y]:

Installing ISPConfig
ISPConfig Port [8080]:

Admin password [admin]: togo2017

Re-enter admin password []: togo2017

Do you want a secure (SSL) connection to the ISPConfig web interface (y,n) [y]:

Generating RSA private key, 4096 bit long modulus


...........................................................................++
...................................................................................
...............................................................................++
e is 65537 (0x10001)
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [XX]:TG
State or Province Name (full name) []:GOLFE
Locality Name (eg, city) [Default City]:Lome
Organization Name (eg, company) [Default Company Ltd]:SG Togo
Organizational Unit Name (eg, section) []:ITO
Common Name (eg, your name or your server's hostname) []:intrawebsrv
Email Address []:loic.kodzovi-defor@socgen.com

Please enter the following 'extra' attributes


to be sent with your certificate request
A challenge password []:
An optional company name []:SG Togo
writing RSA key

Configuring DBServer
Installing ISPConfig crontab
Installing ISPConfig crontab
no crontab for root
Detect IP addresses
Restarting services ...
PHP Warning: date(): It is not safe to rely on the system's timezone settings. You
are *required* to use the date.timezone setting or the date_default_timezone_set()
function. In case you used any of those methods and you are still getting this
warning, you most likely misspelled the timezone identifier. We selected the
timezone 'UTC' for now, but please set date.timezone to select your timezone. in
/root/ispconfig3_install/install/install.php on line 624
Installation completed.

You might also like