Professional Documents
Culture Documents
Catatan CENTOS 6.7 Server
Catatan CENTOS 6.7 Server
7 minimal
## Configure eth0
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
NM_CONTROLLED="yes"
ONBOOT=yes
HWADDR=A4:BA:DB:37:F1:04
TYPE=Ethernet
BOOTPROTO=static
NAME="System eth0"
UUID=5fb06bd0-0bb0-7ffb-45f1-d6edd65f3e03
IPADDR=192.168.1.44
NETMASK=255.255.255.0
# vi /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=centos6
GATEWAY=192.168.1.1
# vi /etc/resolv.conf
First update your server packages to latest version and install wget package which is used download the files
from web.
[Install wget]
# yum -y install wget
2) Install CWP
First update your server packages to latest version and install wget package which is used download the files from web.
If you face any error while downloading the above link, then use below one.
# wget http://dl1.centos-webpanel.com/files/cwp-latest
Initiate the CWP installation and wait, it will take hardly 30 mins, so sit back and have a cub of coffee.CWP successfully
installed, just not the MysQL password and reboot the server.
First thing first, install CWP and login to CWP dashboard as root or a user with root privilege via http://your-
ip:2030
1. Setup Nameservers
Name servers (NS) are often called DSN servers, every web site has two name servers to which it is pointed.
Setting up NS must be done at both domain registrar and hosting account (server-end). In CWP you can define
your default NS by going to DNS Functions >> Edit Nameservers IPs. Enter your desired Nameservers and
put your server’s IP next to each followed by clicking Save Changes button. See illustration below:
Now do not forget to register those two NameServers (NS) to your domain registrar. Consult directly to your
domain registrar if you confused on how to set it up.
2. Setup Shared IP
This is very needed. However if you forgot this step then you’ll not be able to host your websites on your
server. Yet, even you typed your VPS IP on browser, it will load nothing / inaccessible. This step is also
necessary if you have two or more free IPs on your sever so you can define any specific IP of your server to use
with ant other users (think as Shared hosting).
After clicking the Save Changes button, you’ll see a message similar to this:
That’s it. Now each time you want to add new website as new domain or addon domain, you can choose
whether to create new account or simply use your newly created account.
5. Install Softaculous
This is optional but I believe you and your users may need it. Softaculous, a one-clik script installer. You can
install this popular script installer software in CWP with only one click-away. Just go to Script Installer >
Script Manager > then click the Install Softaculous button.
If you refresh your browser and the installation is done, you may notice new menu added in the bottom left
corner:
That’s all what I think few basic configs for newly installed CWP. Any suggestion? Do not hesitate to tip me.
Type in the following to confirm that you have CentOS 6.7 default of MySQL 5.1 installed:
mysql-server-5.1.73-5.el6_6.x86_64
mysql-libs-5.1.73-5.el6_6.x86_64
mysql-5.1.73-5.el6_6.x86_64
If you have not done so already, install and activate the REMI and EPEL repositories;
nano /etc/yum.repos.d/remi.repo
Under the section that looks like [remi] make the following changes:
[remi]
name=Remi's RPM repository for Enterprise Linux 6 - $basearch
#baseurl=http://rpms.remirepo.net/enterprise/6/remi/$basearch/
mirrorlist=http://rpms.remirepo.net/enterprise/6/remi/mirror
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi
mysql-5.5.45-1.el6.remi.x86_64
compat-mysql51-5.1.54-1.el6.remi.x86_64
mysql-libs-5.5.45-1.el6.remi.x86_64
mysql-server-5.5.45-1.el6.remi.x86_64
Install Samba on CentOS 6.0/6.1/6.2/6.3/6.4/6.5
To install the samba package,enter the following command:
# smbd --version
Configure the samba service, so that, it will start automatically at boot time:
# chkconfig smb on
# chkconfig nmb on
# iptables -I INPUT 4 -m state --state NEW -m udp -p udp --dport 137 -j ACCEPT
# iptables -I INPUT 5 -m state --state NEW -m udp -p udp --dport 138 -j ACCEPT
# iptables -I INPUT 6 -m state --state NEW -m tcp -p tcp --dport 139 -j ACCEPT
# service iptables save
Backup the smb.conf file, then delete it and create the new one:
# cp /etc/samba/smb.conf /etc/samba/smb.conf.bak
# rm /etc/samba/smb.conf
# touch /etc/samba/smb.conf
# nano /etc/samba/smb.conf
Add these lines, in your smb.conf file (or change it according to your requirement):
# smbpasswd –a namausernyadisini