Softether on VPS Using Local Bridge

Problem on SecureNAT

SecureNAT is a fairly simple way to setup Softether. You don’t need a lot of sysadmin skill and network understanding in order to get Softether up and running.

The problem is SecureNAT is a bit SLOW. I will show a comparison at the end of this article.

We can boost the performance using a local bridge.

Softether using local bridge

To start with you need Softether installed and setup. You can follow the guide on Softether on VPS

Just skip the last step “Enable the Virtual NAT”

Local bridge Setup

Network setup

  • VPN Server IP: 192.168.7.1
  • VPN Client IP Range: 192.168.7.50-192.168.7.60
  • Tap Device name: tap_soft

From here we go to the “Local Bridge Setting”

Continue reading “Softether on VPS Using Local Bridge” »

Share

Installing Manageengine Opmanager 12 standar/pro edition on Linux Centos 7

Lately for a project needed to install opmanager for a specific client. The installation is quite straight forward on a fresh installation of Centos 7 Box. Assuming you already have a linux installaiton file (ended with .bin) file. So here it goes-

Installing OpManager on Linux using Console mode / Silent mode
This is a quick walk-through of the console mode installation of OpManager on a Linux box – an easy thing to do if you are working on a Windows box and want to install on a remote Linux system.

Prerequisites

To begin with, make sure you have downloaded the binary for Linux. (https://www.manageengine.com/network-monitoring/download.html)

Steps to install

Step 1: Execute the binary with administrator privileges (sudo) and -i console option.

Continue reading “Installing Manageengine Opmanager 12 standar/pro edition on Linux Centos 7” »

Share

Let’s Encrypt for cPanel Installation

Option-1

Let’s Encrypt for cPanel Installation using Installing the cPanel Plugin

Log into your SSH client at root level, then add the Let’s Encrypt repository with the following command:

cd /etc/yum.repos.d/ && wget https://letsencrypt-for-cpanel.com/static/letsencrypt.repo

Next, install the plugin for cPanel with line below and yum:

yum -y install letsencrypt-cpanel

The installation process usually takes about a minute. If all goes well and the installation was successful, a test should run automatically. If it renders similar messages as the example below, you’re good to go:

le-cp self-test
[SELF-TEST] Can read config ............ SUCCESS.
[SELF-TEST] Can connect to daemon and check licence ............ SUCCESS.
[SELF-TEST] Can connect to Lets Encrypt ............ SUCCESS.
[SELF-TEST] Can talk to WHM API ............ SUCCESS.
[SELF-TEST] Can talk to plugin RPC ............ SUCCESS.

You can log in to your cPanel account and install your first SSL certificate.

Installing a Certificate
Once you’re logged into cPanel, you should see a Let’s Encrypt for cPanel button under Security. Click on it to access your active domains list to install a certificate.

Continue reading “Let’s Encrypt for cPanel Installation” »

Share

Clone KVM-based Virtual Machines on Redhat / CentOS Linux

Prerequisite: Operating System and Software Versions

  • Operating System: – Redhat 7.3
  • Software: – libvirtd (libvirt) 2.0.0

Obtain Source Virtual Machine’s information

Before we begin cloning any virtual machine we first need to obtain some basic information about it. The absolute minimum information required about the source virtual machine we are about to clone would be its name and number of disk in use. To get virtual machines name run:

# virsh list
Id Name State
----------------------------------------------------
1 server1.local running

Next, we may would like to know the number of disk our source virtual machines is using as well as its location. The information about disks location is optional as it only provides us with a hint on where to store new clone disk files for the sake of consistency: # virsh dumpxml server1.local | grep "source file"
<source file='/var/lib/libvirt/images/server1.local.qcow2'/>
<source file='/var/lib/libvirt/images/server1.local-1.qcow2'/>
<source file='/var/lib/libvirt/images/server1.local-2.qcow2'/>

From the above output we can see that our original virtual machine has three disks stored in location /var/lib/libvirt/images/. Continue reading “Clone KVM-based Virtual Machines on Redhat / CentOS Linux” »

Share

Install Mariadb on CentOS 7

MariaDB is an open-source relational database management system, backward compatible, binary drop-in replacement of MySQL. It is developed by some of the original developers of the MySQL and by many people in the community. With the release of CentOS 7, MySQL was replaced with MariaDB as the default database system.

If you, for any reason need to install MySQL, check the How to Install MySQL on CentOS 7 tutorial. If your application does not have any specific requirements, you should stick with MariaDB, the default database system in CentOS 7.

In this tutorial we will show you how to install the latest version of MariaDB on CentOS 7 using the official MariaDB repositories.

Prerequisites

Make sure you are logged in as a user with sudo privileges before proceeding with the tutorial.

Install MariaDB 5.5 on CentOS 7: The version of the MariaDB server provided in default CentOS repositories is version 5.5. This is not the latest version though, but it is quite stable.

Follow the steps below to install and secure MariaDB 5.5 on CentOS 7:

Install the MariaDB package using the yum package manager:

sudo yum install mariadb-server

Press y when prompted to proceed with the installation. Once the installation is complete, start the MariaDB service and enable it to start on boot using the following commands:

sudo systemctl start mariadbsudo systemctl enable mariadb

To verify that the installation was successful, check the MariaDB service status by typing:

sudo systemctl status mariadb

The output should show that the service is active and running: Continue reading “Install Mariadb on CentOS 7” »

Share

Set Time Zone on CentOS 7

Checking the Current Timezone

In CentOS and other modern Linux distros, you can use the timedatectl command to display and set the current system’s time and timezone.

timedatectl

The output below shows that the system’s timezone is set to UTC:

Local time: Wed 2019-02-06 22:43:42 UTC
Universal time: Wed 2019-02-06 22:43:42 UTC
RTC time: Wed 2019-02-06 22:43:42
Time zone: Etc/UTC (UTC, +0000)
NTP enabled: no
NTP synchronized: yes
RTC in local TZ: no
DST active: n/a

The system timezone is configured by symlinking /etc/localtime to a binary timezone identifier in the /usr/share/zoneinfo directory. So, another option to check the timezone is to show the path the symlink points to using the ls command:

ls -l /etc/localtime
lrwxrwxrwx. 1 root root 29 Dec 11 09:25 /etc/localtime -> ../usr/share/zoneinfo/Etc/UTC

Changing Timezone in CentOS

Before changing the timezone, you’ll need to find out the long name for the timezone you want to use. The timezone naming convention usually uses a “Region/City” format.

To list all available time zones, you can either list the files in the /usr/share/zoneinfo directory or use the timedatectl command.

timedatectl list-timezones
...
America/Tijuana
America/Toronto
America/Tortola
America/Vancouver
America/Whitehorse
America/Winnipeg
...

Once you identify which time zone is accurate to your location, run the following command as sudo user: Continue reading “Set Time Zone on CentOS 7” »

Share

Install ZFS on CentOS 7

Installing ZFS File System

ZFS File System support is not enabled by default on CentOS 7. That is not the only problem. ZFS is not available in the official package repository of CentOS 7. You have to install it from the official package repository of ZFS. I am installing this on a server running Centos 7.6. You may take a look at https://github.com/zfsonlinux/zfs/wiki/RHEL-and-CentOS for more details.

First check what version of CentOS 7 you’re using with the following command:

$ cat /etc/redhat-release

As you can see, I am using Centos 7.6

[root@localhost ~]# cat /etc/redhat-release
CentOS Linux release 7.6.1810 (Core)

Now you have to add the official repository of ZFS on CentOS 7 with the following command:

yum install http://download.zfsonlinux.org/epel/zfs-release.el7_6.noarch.rpm

ZFS repository should be added.

There are two ways ZFS module can be loaded to the kernel, DKMS and kABI. The difference between these is that if you install DKMS based ZFS module, and then for some reason you update the kernel of your operating system, the ZFS kernel module must be recompiled again. Otherwise it won’t work. But the kABI based ZFS module has the upper hand in that it doesn’t require recompilation if the kernel of the operating system is updated. Continue reading “Install ZFS on CentOS 7” »

Share

Disable FirewallD and Enable Iptables on CentOS 7

Download and Install the Iptables Service

To begin your server’s transition, you need to download and install the iptables-service package from the CentOS repositories. Download and install the service files by typing:

sudo yum install iptables-services

This will download and install the systemd scripts used to manage the iptables service. It will also write some default iptables and ip6tables configuration files to the /etc/sysconfig directory.

Construct your Iptables Firewall Rules

Next, you need to construct your iptables firewall rules by modifying the /etc/sysconfig/iptables and /etc/sysconfig/ip6tables files. These files hold the rules that will be read and applied when we start the iptables service.

How you construct your firewall rules depends on whether the system-config-firewall process is installed and being used to manage these files. Check the top of the /etc/sysconfig/iptables file to see whether it recommends against manual editing or not:

sudo head -2 /etc/sysconfig/iptables

If the output looks like this, feel free to manually edit the /etc/sysconfig/iptables and /etc/sysconfig/ip6tables files to implement the policies for your iptables firewall:

output
# sample configuration for iptables service
# you can edit this manually or use system-config-firewall

Open and edit the files with sudo privileges to add your rules:

sudo nano /etc/sysconfig/iptables
sudo nano /etc/sysconfig/ip6tables

After you’ve made your rules, you can test your IPv4 and IPv6 rules using these commands:

sudo sh -c 'iptables-restore -t < /etc/sysconfig/iptables'
sudo sh -c 'ip6tables-restore -t < /etc/sysconfig/ip6tables'

If, on the other hand, the output from examining the /etc/sysconfig/iptables file looks like this, you should not manually edit the file: Continue reading “Disable FirewallD and Enable Iptables on CentOS 7” »

Share

Zimbra 8.8 on CentOS 7

Before we proceed with Zimbra Collaboration Suite installation process, first login to your server console with root privileges and install the following packages:

# yum -y install unzip net-tools sysstat openssh-clients perl-core libaio nmap-ncat libstdc++.so.6 perl perl-core ntpl nmap sudo libidn gmp libaio libstdc++ unzip sqlite dnsmasq

Next, issue getenforce command to check if Selinux in enabled on your machine. In case the policy is set to Enforced disable it by issuing the below commands:

# getenforce
# setenforce 0
# getenforce

To completely disable Selinux on CentOS, open /etc/selinux/config file with a text editor and set the line SELINUX to disabled.

Assure that wget system utility is also installed on your system by issuing the following command:

# yum install wget

In order for Zimbra to function correctly you must set the local machine hostname and FQDN to point to your server IP Address by running the below commands from root account:

# hostnamectl set-hostname mail
# echo "192.168.0.14 mail.centos7.lan mail " >> /etc/hosts
# cat /etc/hosts

Replace the system hostname and FQDN values accordingly in order to match your own domain settings. Test the hostname and FQDN values by issuing the ping command against both records. Continue reading “Zimbra 8.8 on CentOS 7” »

Share

Add a New Disk Larger Than 2TB to An Existing Linux

I am using fdisk and parted utilities to do this configuration.

First list the current partition details using fdisk command as shown.

# fdisk -l
List Linux Partition Table
List Linux Partition Table

For the purpose of this article, I am attaching a hard disk of 20GB capacity, which can be followed for disk larger than 2TB as well. Once you added a disk, verify the partition table using same fdisk command as shown. Continue reading “Add a New Disk Larger Than 2TB to An Existing Linux” »

Share