Migrate hosting sites from one VestaCP to another VestaCP

Lately, I was trying to migrate vesta hosted sites from one server to another. This trick might help to those who-

  • Either tried to update IP (after tried with so many vesta forum links!) and failed or
  • Have installed on a physical computer and need to move out sites on newer setups!

Make user backup on the old server. In this example we will use admin as the reference.

v-backup-user admin

Copy tarball to the new server and place it in the /home/backup directory Continue reading “Migrate hosting sites from one VestaCP to another VestaCP” »

Share

Enable root logins using ssh in Debian 8.0

By default you can no longer login using ssh as root with just a password since it is more secure to use a pre-shared key. However, you can you can still enable root logins using password authentication.

To do this you need to edit the ssh config file ‘/etc/ssh/sshd_config/sshd_config’ as root.

# vi /etc/ssh/sshd_config

Then find the entry in the Authentication section of the file that says ‘PermitRootLogin’ and change ‘without-password’ to ‘yes’. Continue reading “Enable root logins using ssh in Debian 8.0” »

Share

Add Linux machine on LibreNMS

Install SNMPD first

SNMPd is not installed by default. You must first install snmpd.

apt-get update
apt-get install snmpd lsb -y

Backup default snmp.conf file on the ‘/etc/snmp/’ directory and copy new one from the librenms directory.

mv /etc/snmp/snmpd.conf /etc/snmp/snmpd.conf.asli
cp /opt/librenms/snmpd.conf.example /etc/snmp/snmpd.conf

or instead copy-paste below snmpd text Continue reading “Add Linux machine on LibreNMS” »

Share

Phpvirtualbox fix on 5.1 using 5.0

I was able to get v5.0-5 working with vbox 5.1 by commenting out the version check line and replacing it with a static value in the endpoints/api.php file:

// $response['data']['responseData']['phpvboxver'] = @constant('PHPVBOX_VER');
 $response['data']['responseData']['phpvboxver'] = "5.1-0";

Src: https://sourceforge.net/p/phpvirtualbox/discussion/general/thread/565b7f31/

Share

Perfect Backup MX using Postfix

This is quite simple, and with a very simple setup, and does not require that much, since we do not need to send out e-mails from clients from this server, or use ASMTP. I find that MySQL is not needed here, but could be used. I will use normal flat files, since the number of domains to run a backup for is most likely a rather small number. 

This setup can be editet to run all times of different checks, antivirus etc.  Normally you would make sure that the setup is exactly the same on both the primary MTA, and the backup. It hardenens the systems, and should reduce spam, and unwanted traffic. Create public DNS entries. Remember to create an MX record with an lower priority than the primary mail server, or else this will not work! 

Example:example.com. 43200 IN MX 10 mail.example.com.
example.com. 43200 IN MX 20 backup.example.com.

After this these two records are created with A records pointing to different IPs (different servers).  Continue reading “Perfect Backup MX using Postfix” »

Share

PHP 7.0 on CentOS/RHEL 6.9 and 7.4 using Yum

Before beginning this, it is assumed that you already have installed LAMP on your server.

To install, first you must add the Webtatic EL yum repository information corresponding to your CentOS/RHEL version to yum:

CentOS/RHEL 7.x:

rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm

CentOS/RHEL 6.x:

rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm

Now you can install PHP 7.0’s mod_php SAPI (along with an opcode cache) by doing:

yum install php70w php70w-opcache

You can alternatively install PHP 7.0’s php-fpm SAPI (along with an opcode cache by doing:

yum install php70w-fpm php70w-opcache

See the package list below for additional SAPIs and PHP extensions. Continue reading “PHP 7.0 on CentOS/RHEL 6.9 and 7.4 using Yum” »

Share

Perfect Squid with Transparent proxy and SSL log

This will be a transparent SQUID proxy for your home or corporate network  ,  it  will transparently  intercept  all  traffic http and https  ,  for  https  you  will  need  to  push  to  clients  the CA certificate of the SQUID server, it  has  been tested to be working without problems with lastest Internet Explorer, Mozilla Firefox and Chrome browsers.

STEP 1 – Installing Base system , upgrading it and disabling IPtables , SeLINUX

We  start  by  downloading  the  CentOS  6.5  iso from CentOS website (x86 or x64) : CentOS 6.5 ISO’s , install Base system. Partitioning , software or hardware raid is up to the user. In this example hostname is : proxy.home.lan and ip address is : 192.168.201.250 . Continue reading “Perfect Squid with Transparent proxy and SSL log” »

Share

XEAMS mail Server Installation on CentOS 6

Installation Instructions

Follow the steps below to install Xeams on a Linux machine.Log in as root

  1. Download the installer
  2. Extract the tar file using the following command
     tar -xf XeamsLinux.tar
  3. Ensure the permissions for Install.sh is set as an executable. If not, use the chmod +x Install.sh command to change its permission
  4. Execute Install.sh script

Continue reading “XEAMS mail Server Installation on CentOS 6” »

Share

Install and configure ClamAV Antivirus on CentOS 6

Enable EPEL  repository

CentOS 6.x 32-bit:

# rpm –ivh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm

CentOS 6.x 64-bit:

# rpm –ivh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm

Check the repository list. Continue reading “Install and configure ClamAV Antivirus on CentOS 6” »

Share

Publishing long domain key SPF TXT records in bind9

If your bind is throwing error with long TXT data, you can do the following means to concatenate: You are using commas to separate your key/value pairs in your record instead of semi-colons. Change it to:

a9d04665528b593d263a6e5256648c99._domainkey IN 1800 TXT (
 "k=rsa;p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAz2/ZfhxSI/A"
 "bqgh0amM8ylrlosirWeKShUhq7fg12aYmRwOqq9hIzO0Fcz1BzfgHVu6HU++rC5"
 "QoUK0JQK/nk4jwkDgvG2di2ZYmAvEbY/VeiK1x/TG0p1Iczr2k6Bj0gEAb/YGD2"
 "YbwrwAi4bDXwoPsYuuNn9TB3jjyWKu/dvOsqhff1/4Wc+FkOi0ClvgrXiklN28X"
 "TLjyjSyU794ntIoegXxrfwcwkhfPMvuqcnhfIC0Z8L71M4WR4SoHyNHVfBtNlUv"
 "VNROiXlMxtxnNQvfViSwz6LC8bYIxeAba3hSXPTChKu3qZtfR0o3jFwEWAfLQdg"
 "Ixler0jMEoAyJmfQIDAQAB")

 

Share