Explore information related to centos 7

cPanel error networkmanager is installed and running


This article covers how to resolve the error, NetworkManager is installed and running. Basically, this error happens if cPanel does not support NetworkManager-enabled systems.


To fix this error, simply run the commands below and then restart the installation of cPANEL:

$ systemctl stop NetworkManager.service
$ systemctl disable NetworkManager.service

Read More


Install Wazuh Server on CentOS 7 - Step by Step Process ?


This article covers the installation procedure of Wazuh Server on CentOS Linux System. Basically, Wazuh is a free, open-source and enterprise-ready security monitoring solution for threat detection, integrity monitoring, incident response and compliance. 


You can use Wazuh for the following applications:

  • Security analysis
  • Log analysis
  • Vulnerability detection
  • Container security
  • Cloud security


To Install Java on CentOS 8.

1. Run the command below to install JDK:

$ sudo dnf install java-11-openjdk-devel

2. Confirm that you have it installed

$ java -version

Read More


Install PHP 8 on CentOS 7 / CentOS 8 - Step by Step Process ?


This article covers how to install PHP 8.0 on CentOS 8/7 and RHEL 8/7.

PHP is the most used scripting language for web development, both websites and web applications.

This guide will show you how to install PHP 8.0 on CentOS 8 | CentOS 7. 

Please note the GA release is fit for running in Production if the application already supports it.


To install any additional PHP package use command syntax:

$ sudo yum install php-xxx

To Check PHP version:

$ php --version

Read More


Enable EPEL repository on AlmaLinux 8 - Step by Step Process ?


This article covers how to enable EPEL repository on AlmaLinux 8.

Extra Packages for Enterprise Linux (EPEL) is repository with a high quality set of additional packages for Enterprise Linux operating systems such as Red Hat Enterprise Linux (RHEL), CentOS and Scientific Linux (SL), Oracle Linux (OL), AlmaLinux and any other Linux distribution from the RHEL family.


Run the command below to install EPEL Repository on AlmaLinux OS 8:

# sudo yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm

Accept installation using the y key.

Read More


Welcome to Emergency mode in Linux - Fix this boot error now


This article covers how to fix boot error, Welcome to Emergency mode in Linux. This issue happens after an emergency power outage on a server, a system crash, or similar situations.


The Emergency Mode sometime means that your file system may be corrupted.

In such cases, you will be left out with a prompt to go nowhere.

All you have to do is perform a file system check using,

fsck.ext4 /dev/sda3

where sda3 can be your partition and if you are using ext3 file system, change the command as follows:

fsck.ext3 /dev/sda3

About the partition number, Linux shows you the partition before arriving at the prompt.

This should solve the problem.


To fix  Emergency Mode On Ubuntu:

1. use Ubuntu Live USB to boot, and open terminal:

$ sudo fsck.ext4 /dev/sda3

2. Adding sudo because it needs root permission.

(Replace ext4 with ext3 if applicable to you)

3. Cycle through the SDAs by changing the last number in the sda to see which file system has problems.

Ex: sda1, sda2, sda3, sda4, and so on

4. As I encountered, the problem might be with the 'home' directory.

5. Once you run the above command, you'll be prompted to fix the issue right inside the terminal itself.

6. Keep hitting y (for yes) until the end of the fix.

(or you can use -fy for automatically response yes to all.)

7. Navigate to the home folder of your sda using your files explorer.

(This will be mounted from the HDD since you are working with a Live USB)

8. Check inside 'home' if you can see all your files. If yes, then you're ready to reboot to your system (remove the Live USB).

Read More


Files and Processes in SELinux on CentOS 7 - More information


This article covers Files and Processes in SELinux. Basically, managing file and process context are at the heart of a successful SELinux implementation.

With SELinux, a process or application will have only the rights it needs to function and NOTHING more. The SELinux policy for the application will determine what types of files it needs access to and what processes it can transition to. 

SELinux policies are written by app developers and shipped with the Linux distribution that supports it. A policy is basically a set of rules that maps processes and users to their rights.


SELinux enforces something we can term as “context inheritance”. What this means is that unless specified by the policy, processes and files are created with the contexts of their parents.

So if we have a process called “proc_a” spawning another process called “proc_b”, the spawned process will run in the same domain as “proc_a” unless specified otherwise by the SELinux policy.


SELinux in Action: Testing a File Context Error

1. First, let's create a directory named www under the root. We will also create a folder called html under www:

mkdir -p /www/html

 

2. If we run the ls -Z command, we will see these directories have been created with the default_t context:

ls -Z /www/

drwxr-xr-x. root root unconfined_u:object_r:default_t:s0 html


3. Next we copy the contents of the /var/www/html directory to /www/html:

cp /var/www/html/index.html /www/html/

 

The copied file will have a context of default_t. That's the context of the parent directory.


We now edit the httpd.conf file to point to this new directory as the web site's root folder. 

i. We will also have to relax the access rights for this directory.

vi /etc/httpd/conf/httpd.conf

ii. First we comment out the existing location for document root and add a new DocumentRoot directive to /www/html:

# DocumentRoot "/var/www/html"

DocumentRoot "/www/html"

iii. We also comment out the access rights section for the existing document root and add a new section:

#<Directory "/var/www">

#    AllowOverride None

    # Allow open access:

#    Require all granted

#</Directory>


<Directory "/www">

    AllowOverride None

    # Allow open access:

    Require all granted

</Directory>


We leave the location of the cgi-bin directory as it is. We are not getting into detailed Apache configuration here; we just want our site to work for SELinux purposes.


iv. Finally, restart the httpd daemon:

service httpd restart

 

Once the server has been restarted, accessing the web page will give us the same “403 Forbidden” error (or default “Testing 123” page) we saw before.

The error is happening because the index.html file's context changed during the copy operation. It needs to be changed back to its original context (httpd_sys_content_t).

Read More


dhclient to persistently look for an IP address lease - Configure it Now


This article covers how to use dhclient command. Basically, Linux dhclient command can provide an IP lease until DHCP Server/Router grants one.

With this guide, you can easily configure Linux dhclient command to continuously requests an IP lease until one is granted by DHCP Server / Router.

Read More


Create CentOS Fedora RHEL VM Template on KVM - How to do it


This article covers how to create CentOS/Fedora/RHEL VM Templates on KVM. VM Templates are more useful when deploying high numbers of similar VMs that require consistency across deployments. If something goes wrong in an instance created from the Template, you can clone a fresh VM from the template with minimal effort.


To install KVM in your Linux system:

The KVM service (libvirtd) should be running and enabled to start at boot.

$ sudo systemctl start libvirtd

$ sudo systemctl enable libvirtd

Enable vhost-net kernel module on Ubuntu/Debian.

$ sudo modprobe vhost_net

# echo vhost_net | sudo tee -a /etc/modules


How to Prepare CentOS / Fedora / RHEL VM template ?

1. Update system

After you finish VM installation, login to the instance and update all system packages to the latest versions.

$ sudo yum -y update

2. Install standard basic packages missing:

$ sudo yum install -y epel-release vim bash-completion wget curl telnet net-tools unzip lvm2 

3. Install acpid and cloud-init packages.

$ sudo yum -y install acpid cloud-init cloud-utils-growpart

$ sudo sudo systemctl enable --now acpid

4. Disable the zeroconf route

$ echo "NOZEROCONF=yes" | sudo tee -a /etc/sysconfig/network

5. Configure GRUB_CMDLINE_LINUX – For Openstack usage.

If you plan on exporting template to Openstack Glance image service, edit the /etc/default/grub file and configure the GRUB_CMDLINE_LINUX option. Your line should look like below – remove rhgb quiet and add console=tty0 console=ttyS0,115200n8.

GRUB_CMDLINE_LINUX="crashkernel=auto rd.lvm.lv=cl/root rd.lvm.lv=cl/swap console=tty0 console=ttyS0,115200n8"

Generate grub configuration.

$ sudo grub2-mkconfig -o /boot/grub2/grub.cfg

6. Install other packages you need on your baseline template.

7. When done, power off the virtual machine.


How to Clean VM template ?

You need virt-sysprep tool for cleaning the instance.

$ sudo virt-sysprep -d centos7

Read More


Add Compute Host to oVirt Virtualization - How to do it


This article covers oVirt Virtualization and how to add Compute Host to oVirt Virtualization. oVirt is a free and open-source distributed virtualization solution that can be used to manage your entire infrastructure.

oVirt allows you to manage virtual machines, compute, storage and networking resources from the web-based interface. It uses KVM hypervisor and built upon several other community projects, including libvirt, Gluster, PatternFly, and Ansible.


To Add Compute Host to oVirt:

1. Validate oVirt Engine installation by logging into the console.

2. Navigate to Compute > Hosts > New and fill all required information.

3. Modify other settings in the left panel as you see fit and click "OK" button to provision the node.

4. The Status should change to Installing and will finish in few minutes.


To Configure Host Networking:

1. If you want to add additional networks – extra bridges with VLANs e.t.c, this can be done once the host is added.

2. First create a Logical Network on Network > New. Give Virtual Network correct details. For VLAN ID check "Enable VLAN tagging".

3. With the Host added and active you can configure its networking under Network Interfaces > Setup Host Networks.

4. Assign the Logical network to an interface.

5. Drag Virtual Network for mapping to host interface.

6. Configure IP addressing if required.

7. Once saved and successful it should turn green.

8. You can then proceed to create virtual machines using oVirt Management interface.

Read More


SELinux users on CentOS 7 – Actions and Deciphering error messages


This article covers more information about SELinux users on CentOS 7.


Deciphering SELinux Error Messages

We looked at one SELinux error message. We were then using the grep command to sift through /var/log/messages file. Fortunately SELinux comes with a few tools to make life a bit easier than that. These tools are not installed by default and require installing a few packages, which you should have installed in the first part of this tutorial.

The first command is ausearch. We can make use of this command if the auditd daemon is running. In the following code snippet we are trying to look at all the error messages related to the httpd daemon. Make sure you are in your root account:

ausearch -m avc -c httpd

In our system a number of entries were listed, but we will concentrate on the last one:

----
time->Thu Aug 21 16:42:17 2014
...
type=AVC msg=audit(1408603337.115:914): avc:  denied  { getattr } for  pid=10204 comm="httpd" path="/www/html/index.html" dev="dm-0" ino=8445484 scontext=system_u:system_r:httpd_t:s0 tcontext=unconfined_u:object_r:default_t:s0 tclass=file

Even experienced system administrators can get confused by messages like this unless they know what they are looking for. To understand it, let’s take apart each of the fields:

type=AVC and avc: AVC stands for Access Vector Cache. SELinux caches access control decisions for resource and processes. This cache is known as the Access Vector Cache (AVC). That's why SELinux access denial messages are also known as “AVC denials”. These two fields of information are saying the entry is coming from an AVC log and it’s an AVC event.


denied { getattr }: The permission that was attempted and the result it got. In this case the get attribute operation was denied.

pid=10204. This is the process id of the process that attempted the access.

comm: The process id by itself doesn’t mean much. The comm attribute shows the process command. In this case it’s httpd. Immediately we know the error is coming from the web server.

path: The location of the resource that was accessed. In this case it’s a file under /www/html/index.html.

dev and ino: The device where the target resource resides and its inode address.

scontext: The security context of the process. We can see the source is running under the httpd_t domain.

tcontext: The security context of the target resource. In this case the file type is default_t.

tclass: The class of the target resource. In this case it’s a file.

Read More


Install ClickHouse on Ubuntu 20.04 - Step by step process to perform it


This article covers how to install ClickHouse on Ubuntu. Basically, ClickHouse is an open-source analytics database developed for big data use cases. 

Install of ClickHouse on Ubuntu involves a series of steps that includes adjusting the configuration file to enable listening over other IP address and remote access. 


Column-oriented databases store records in blocks grouped by columns instead of rows. 

By not loading data for columns absent in the query, column-oriented databases spend less time reading data while completing queries. 

As a result, these databases can compute and return results much faster than traditional row-based systems for certain workloads, such as OLAP.


Online Analytics Processing (OLAP) systems allow for organizing large amounts of data and performing complex queries. 

They are capable of managing petabytes of data and returning query results quickly. 

In this way, OLAP is useful for work in areas like data science and business analytics.


Aggregation queries are queries that operate on a set of values and return single output values. 

In analytics databases, these queries are run frequently and are well optimized by the database. 


Some aggregate functions supported by ClickHouse are:

1. count: returns the count of rows matching the conditions specified.

2. sum: returns the sum of selected column values.

3. avg: returns the average of selected column values.


Some ClickHouse-specific aggregate functions include:

1. uniq: returns an approximate number of distinct rows matched.

2. topK: returns an array of the most frequent values of a specific column using an approximation algorithm.


You can set up a ClickHouse database instance on your server and create a database and table, add data, perform queries, and delete the database.

You can start, stop, and check the ClickHouse service with a few commands.

To start the clickhouse-server, use:

$ sudo systemctl start clickhouse-server

The output does not return a confirmation.

To check the ClickHouse service status, enter:

$ sudo systemctl status clickhouse-server

To stop the ClickHouse server, run this command:

$ sudo systemctl stop clickhouse-server

To enable ClickHouse on boot:

$ sudo systemctl enable clickhouse-server

To start working with ClickHouse databases, launch the ClickHouse client. 

When you start a session, the procedure is similar to other SQL management systems.

To start the client, use the command:

$ clickhouse-client

Read More


Unable to allow access for disk path in libvirtd - Fix it Now


This article covers tips to fix the error Unable to allow access for disk path in libvirtd. By default, migration only transfers the in-memory state of a running guest (such as memory or CPU state). Although disk images are not transferred during migration, they need to remain accessible at the same path by both hosts.


To fix Unable to allow access for disk path in libvirtd error:

Set up and mount shared storage at the same location on both hosts. The simplest way to do this is to use NFS:

1. Set up an NFS server on a host serving as shared storage. The NFS server can be one of the hosts involved in the migration, as long as all hosts involved are accessing the shared storage through NFS.

# mkdir -p /exports/images
# cat >>/etc/exports <<EOF
/exports/images    192.168.122.0/24(rw,no_root_squash)
EOF


2. Mount the exported directory at a common location on all hosts running libvirt. For example, if the IP address of the NFS server is 192.168.122.1, mount the directory with the following commands:

# cat >>/etc/fstab <<EOF
192.168.122.1:/exports/images  /var/lib/libvirt/images  nfs  auto  0 0
EOF
# mount /var/lib/libvirt/images

Read More


Install PowerDNS and PowerAdmin on CentOS 7 - How to do it


This article covers the step by step procedure to install PowerDNS on CentOS 7. PowerDNS (pdns) is an open source DNS server written in C++ and released under GPL License. It has become a good alternative for the traditional DNS server Bind, designed with better performance and low memory requirements. 

PowerDNS provides two products, the Authoritative server, and the Recursor. 

The PowerDNS Authoritative server can be configured through the different backend, including the plain Bind zone files, RDBMS such as MySQL, PostgreSQL, SQLite3 or LDAP.


To Install PowerDNS on CentOS 7:

1. First let's start by ensuring your system is up-to-date:

$ yum clean all

$ yum -y update

2. Install PowerDNS and backend.

First, you need to enable EPEL repository and all required packages on your system:

$ yum install epel-release

$ yum install bind-utils pdns pdns-recursor pdns-backend-mysql mariadb mariadb-server

Enable PowerDNS on boot and start PowerDNS server:

$ systemctl enable mariadb

$ systemctl enable pdns

$ systemctl enable pdns-recursor

3. Configure MariaDB.

By default, MariaDB is not hardened. You can secure MariaDB using the mysql_secure_installation script. you should read and below each steps carefully which will set root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MariaDB:

mysql_secure_installation

4. Create PowerDNS Database and User in MariaDB.

Login as a MariaDB root and create a new database and tables:

### mysql -uroot -p

5. Configure PowerDNS.

Open the /etc/pdns/pdns.conf file.

Finally, restart the Power DNS service:

$ systemctl restart pdns.service

$systemctl enable pdns.service

6. Configure Recursor.

Open the /etc/pdns-recursor/recursor.conf file.

Read More


SELinux on CentOS 7 - Set it up now


This article covers how to set up SELinux on #CentOS 7. #SELinux is a security mechanism built into the Linux kernel. Linux distributions such as CentOS, RHEL, and Fedora are equipped with SELinux by default.

SELinux improves server security by restricting and defining how a server processes requests and users interact with sockets, network ports, and essential directories.


To check SELinux mode:

The easiest way on how to check SELinux ( Security Enhanced Linux ) operation mode is to use getenforce command. 

This command without any options or arguments will simply print a current status SELinux operational mode. 

Furthermore, the current status of SELinux operational mode can be set permanently or temporarily.


To check whether SELinux is enabled or not:

1. Use the getenforce command. [vagrant@vagrantdev ~]$ getenforce Permissive.

2. Use the sestatus command.

3. Use the SELinux Configuration File i.e. cat /etc/selinux/config to view the status.


To configure SELinux to enforcing mode:

1. Open the /etc/selinux/config file in a text editor of your choice, for example: # vi /etc/selinux/config.

2. Configure the SELINUX=enforcing option: # This file controls the state of SELinux on the system.

3. Save the change, and restart the system: # reboot.


To enable SELinux without rebooting:

1. Changing the SELinux mode at run time. If SELinux is disabled it cannot be enabled without rebooting.

2. To detemine the current Mode of SELinux.

3. Changing the SELinux mode Permanently. In the /boot/grub/grub.conf file add a line: selinux=0.

4. Or in /etc/sysconfig/selinux change.


To permanently change mode to permissive:

1. Edit the /etc/selinux/config file as follows: # This file controls the state of SELinux on the system. # SELINUX= can take one of these three values: # enforcing - SELinux security policy is enforced.

2. Restart the system: $ reboot.

Read More


Manage Networking with NetworkManager in RHEL CentOS 8


This article covers NetworkManager daemon for managing the networking service to dynamically configure and control network devices and keep connections up and active when they are available.
Netstat is a command line utility that can be used to list out all the network (socket) connections on a system.
It lists out all the tcp, udp socket connections and the unix socket connections.
To reboot Linux using the command line: To reboot the Linux system from a terminal session, sign in or “su”/”sudo” to the “root” account.
Then type “ sudo reboot ” to reboot the box. Wait for some time and the Linux server will reboot itself.

To troubleshoot network connectivity with Linux server:
i. Check your network configuration.
ii. Check the network configuration file.
iii. Check the servers DNS records.
iv. Test the connection both ways.
v. Find out where the connection fails.
vi. Firewall settings.
vii. Check Host status information.

To change the hostname in Linux Ubuntu:
i. Type the following command to edit /etc/hostname using nano or vi text editor: sudo nano /etc/hostname. Delete the old name and setup new name.
ii. Next Edit the /etc/hosts file: sudo nano /etc/hosts.
iii. Reboot the system to changes take effect: sudo reboot.

To reinstall #network service in #Linux (#Ubuntu / #Debian):
i. Use the following command to restart the server networking service. # sudo /etc/init.d/networking restart or
# sudo /etc/init.d/networking stop # sudo /etc/init.d/networking start else # sudo systemctl restart networking.
ii. Once this done, use the following command to check the server network status.

Read More


KVM live migration to resolve performance issues


This article covers how to use KVM live migration to achieve load balancing which is important in a server virtualization system to maintain server performance.
Migration enables an administrator to move a virtual machine instance from one compute host to another. A typical scenario is planned maintenance on the source host, but migration can also be useful to redistribute the load when many VM instances are running on a specific physical machine.

Kernel-based Virtual Machine (KVM) is an open source virtualization technology built into Linux.
Specifically, KVM lets you turn #Linux into a #hypervisor that allows a host machine to run multiple, isolated virtual environments called guests or virtual machines (VMs).

Live migration of virtual machines is necessary when you need to achieve high-availability setups and load distribution.
The #KVM hypervisor has been a powerful alternative to Xen and VMware in the Linux world for several years.
To make the virtualization solution suitable for enterprise use, the developers are continually integrating new and useful features.
An example of this is live migration of virtual machines (VMs).

Live #migration involves:
The instance keeps running throughout the migration.
This is useful when it is not possible or desirable to stop the application running on the instance.
Live migrations can be classified further by the way they treat instance storage:
1. Shared storage-based live migration. The instance has ephemeral disks that are located on storage shared between the source and destination hosts.
2. Block live migration, or simply block migration. The instance has ephemeral disks that are not shared between the source and destination hosts. Block migration is incompatible with read-only devices such as CD-ROMs and Configuration Drive (config_drive).
3. Volume-backed live migration. Instances use volumes rather than ephemeral disks.

Block live migration requires copying disks from the source to the destination host.
It takes more time and puts more load on the network. Shared-storage and volume-backed live migration does not copy disks.

Read More


OpenLDAP and phpLDAPadmin on Linux


This article will guide you on how to install #OpenLDAP and phpLDAPadmin on #Ubuntu. Also, we covered the prospective error affacting OpenLDAP and phpLDAPadmin and its solution as well.

#LDAP (Lightweight Directory Access Protocol) is an open and cross platform protocol used for directory services authentication. LDAP provides the communication language that applications use to communicate with other directory services servers.

#Kerberos is used to manage credentials securely (authentication) while LDAP is used for holding authoritative information about the accounts, such as what they're allowed to access (authorization), the user's full name and uid.

To access #phpLDAPadmin:

Point your browser to http://IP_OF_SERVER/phpldapadmin (IP_OF_SERVER is the actual IP address of your LDAP server). 

From the main window, click the login button in the left pane. 

When prompted, you will log into your DN and enter the password for the admin user created during the slapd reconfiguration.

Read More


Install SQL Server 2019 on Linux


This article will guide you the process to install #MSSQL Server 2019 on #CentOS 7 and Ubuntu 16.04.

SQL Server 2019 #Developer is a full-featured free edition, licensed for use as a development and test database in a non-production environment.

SQL Server 2019 allows us to integrate data from structured and unstructured data sources. 

We can now process diverse big data and relational data sources using Transact-SQL from SQL Server using PolyBase. 

We can see below PolyBase support external databases.

SQL Server Express can be used in production (beware of the limitations, like the 10GB cap), but according to this link Express is available for Linux. SQL Server Express is available to use in Production.

Starting with SQL Server 2017, SQL Server runs on Linux. It's the same SQL Server database engine, with many similar features and services regardless of your operating system. It's the same SQL Server database engine, with many similar features and services regardless of your operating system.

To run a SQL script in #Linux terminal:

1. Open Terminal and type mysql -u to Open the MySQL command line.

2. Type the path of your #mysql bin directory and press Enter.

3. Paste your #SQL file inside the bin folder of mysql server.

4. Create a #database in MySQL.

5. Use that particular database where you want to import the SQL file.

Read More


Install WireShark CentOS


This article will guide you on how to install WireShark on #CentOS. WireShark is one of the leading #network analyzing tools. It helps in troubleshooting the traffic problems of a server and malicious activity. 

Wireshark is an open-source, free network packet analyzer, used to capture and analyze network traffic in real-time.

Basically, with Wireshark you can capture and view data traveling through your network.

You can install WireShark with yum install wireshark-gnome . 

After you install it, the Wireshark application will be at /usr/sbin/wireshark .

To install #wireshark on RHEL 8 / CentOS 8 Linux step by step instructions:

1. Install package called Whireshark using the dnf command. For a GUI Wireshark application execute: # dnf install wireshark To install Wireshark command line tool only execute: # dnf install wireshark-cli.

2. Launch Wireshark.

To install Wireshark from #terminal:

Open terminal and type the #commands:

i. sudo apt-get install wireshark.

ii. sudo dpkg-reconfigure wireshark-common.

iii. sudo adduser $USER wireshark.

iv. wireshark.

Read More


Monitor System Metrics with the TICK Stack on CentOS 7


This article will guide you on how the TICK stack can be a powerful tool for storing, analyzing, and visualizing time series data. To monitor InfluxDB _internal metrics in a production #cluster, use Telegraf and the influxdb input plugin to capture these metrics from the InfluxDB /debug/vars endpoint and store them in an external InfluxDB monitoring instance.

More about Kapacitor:

#Kapacitor is a native data processing engine for #InfluxDB 1. x and is an integrated component in the InfluxDB 2.0 platform. 

Kapacitor can process both stream and batch data from InfluxDB, acting on this data in real-time via its programming language TICKscript.

A retention policy (RP) is the part of InfluxDB data structure that describes for how long InfluxDB keeps data. 

InfluxDB compares your local server's timestamp to the timestamps on your data and deletes data that are older than the RP's DURATION . 

A single database can have several RPs and RPs are unique per database.

Read More


Install XRDP Server


This article will guide you on steps to install XRDP #Server on #Ubuntu. To provide remote access via RDP, a Windows native protocol, XRDP behind the scenes uses #VNC, a remote access protocol more common in Linux.

After #xrdp is installed you can start the server with the following command:

Service xrdp start.

Service xrdp-sesman start (Thanks to Greg for pointing that out) — UPDATE!!

If want it to auto start after reboot you need to run this command also: update-rc.d xrdp enable (It will not start xrdp-sesman automatic).


To use XRDP Linux:

1. With #Ubuntu 18.04 first install xrdp: sudo apt-get -y install xrdp.

2. Next, one may adjust the configuration file: sudo nano /etc/xrdp/xrdp.ini.

3. Set encryption level to high: encrypt_level=high.

4. Next, allow just RDP through the local firewall: sudo ufw allow 3389/tcp.

Read More


Install Vesta control panel in Ubuntu


This article will guide you on easy steps to install Vesta control panel in #Ubuntu. VestaCP is a control panel for Linux with many features that facilitate the administration of a #server. 

Vesta Development team provides an installer script that automates setting up of Vesta hosting control panel on Ubuntu / Debian and RHEL based Linux distributions. Login to your Ubuntu / #Debian system and ensure the system is updated. Download #Vesta installer. Run install with sudo if you're logged in as standard user.

To install vestaCP on Ubuntu:

1. # Connect to your server as root via #SSH

ssh root@your.server

2. # Download installation script

curl -O http://vestacp.com/pub/vst-install.sh

3. # Run it

bash vst-install.sh

To change my VestaCP port:

i. conf file and change the port that NGINX listens on from 8083 to 2083 (or the port you chose to use). listen 2083; 

ii. Once the port has been changed, press CTRL+X , followed by y , and then hit enter to save your changes. 

iii. The final step is removing the firewall entry for the previous port we were using.

Read More


GlusterFS install CentOS 7


This article will guide you on the steps to install and setup #GlusterFS. 

GlusterFS is a scalable #network filesystem suitable for data-intensive tasks such as cloud storage and media streaming. 

GlusterFS has a client and #server component. Servers are typically deployed as storage bricks, with each server running a glusterfsd daemon to export a local file system as a #volume.

To install GlusterFS:

1. Have at least two nodes. CentOS 7 on two servers named "server1" and "server2".

2. Format and mount the bricks.

3. Installing GlusterFS.

4. #Iptables configuration.

5. Configure the trusted pool.

6. Set up a GlusterFS volume.

7. Testing the GlusterFS volume.

Read More


Enable firewalld in Centos 7 How to do it


This article will guide you on steps to enable firewalld on #centos 7 servers for our customers. The firewall is one of the most important features of webservers. The #firewalld supports both IPv4 and IPv6 #firewall #settings.

Never run the iptables service and FirewallD service at the same time! The #iptables service is now provided by a separate package called iptables-services: Stop and disable the firewalld service first. # systemctl stop firewalld.

The firewalld daemon manages groups of #rules using entities called "zones". Zones are basically sets of rules dictating what traffic should be allowed depending on the level of trust you have in the networks your #computer is connected to.

To use FirewallD:

1. Installing and Managing FirewallD.

2. To start the service and enable FirewallD on boot: sudo systemctl start firewalld sudo systemctl enable firewalld.

3. Check the firewall status.

4. To view the status of the FirewallD daemon: sudo systemctl status firewalld.

5. To reload a FirewallD configuration: sudo firewall-cmd --reload.

Read More


Imagick php install


This article will guide you on how to install #Imagick #PHP #extension. Imagick is the most popular PHP extension which helps to create edit convert, and/or manipulates images. ImageMagick is a free and open source, feature-rich, text-based and cross-platform image manipulation tool used to create, edit, compose, or convert bitmap images. It runs on #Linux, #Windows, #Mac Os X, iOS, Android OS, and many other operating systems.

To use Imagick with PHP in your server, you can easily achieve it with the following #command:

sudo apt-get install php-imagick.

php -m | grep imagick.

sudo service apache2 restart.

Read More


Ansible Playbook to Install WordPress with LAMP


This article will guide you on the step to follow to use #Ansible Playbook to install #WordPress with #LAMP on #Ubuntu 18.04.

In Ansible, the role is the primary mechanism for breaking a #playbook into multiple files. This simplifies writing complex #playbooks, and it makes them easier to reuse. The breaking of playbook allows you to logically break the playbook into reusable components.

To start using Ansible:

1. Prerequisites.

2. Install Ansible.

3. Establish a manual connection to a managed node.

4. Run your first network Ansible command.

5. Create and run your first network Ansible Playbook.

6. Gathering facts from network devices.

Read More


Install imagemagick on CentOS


This article will guide you on steps to #install #ImageMagick and fix its errors. Basically, ImageMagick is used to manipulate the digital images.

ImageMagick helps to create, edit, compose, or convert #bitmap images. It can read and write images in a variety of formats (over 200) including #PNG, JPEG, GIF, HEIC, TIFF, DPX, EXR, WebP, Postscript, PDF, and #SVG.

To install ImageMagick from the source:

1. First #download the latest version of the program sources - ImageMagick.

2. Unzip the package to a folder of choice.

3. In the folder where you have unzipped ImageMagick run the configuration script.

4. If no errors were found, you can start the install process.

Read More


Install Froxlor on CentOS 7


This article will guide you on steps to #install Froxlor on #CentOS 7 and also resolve common Froxlor #errors.
#Froxlor is a simple but powerful server administration #software for managing #domains, emails and files.
To install Froxlor web hosting control panel:
1. Ensure that your webserver serves /var/www.
2. Extract froxlor into /var/www.
3. Point your browser to http://[ip-of-webserver]/froxlor.
4. Follow the #installer.
5. Login as #administrator.
6. Adjust "System > Settings" according to your needs.
7. Choose your distribution under "System > Configuration".
8. Follow the steps for your services.

Read More


List installed software Linux


This article will guide you on different methods to #list all #software, the number of #packages available on the server along with the method to copy them and use them when we reinstall our operating system(#OS).
Yum automatically refreshes the list of packages, whilst with apt-get you must execute a command 'apt-get update' to get the fresh packages.
To list of installed programs in #Linux:
1. Aptitude-based distributions (#Ubuntu, #Debian, etc): dpkg -l.
2. RPM-based distributions (#Fedora, #RHEL, etc): rpm -qa.
3. pkg*-based distributions (#OpenBSD, #FreeBSD, etc): pkg_info.
4. Portage-based distributions (#Gentoo, etc): equery list or eix -I.
5. pacman-based distributions (Arch Linux, etc): pacman -Q.

Read More


Add Glance Cloud images to OpenStack


This article will guide you on steps to add #Glance #Cloud images to #OpenStack with different #Linux distributions which enables users to discover, register, and retrieve virtual machine images. 

After images are created they should be registered in Openstack Glance - #image operation service.

Upload Image Into Glance:

1. Replace <NAME> with the name that users will refer to the disk image by. 

2. Replace <IMAGE_FILE> with the local path to the image file to upload.

Read More


Cant locate LWP UserAgent pm in @INC


This article will guide you on how to get rid of error "Can't locate LWP/UserAgent.pm in @INC" which occurs in the process of installing #applications like CSF in the DirectAdmin server or any other #Linux #distros. 

libwww-perl (also known as LWP) is a collection of #Perl #modules that provide a simple and consistent programming interface (API) to the World-Wide Web.

In order to install and use this #package you will need Perl version

5.8.1 or better:

Some modules within this package depend on other packages that are distributed separately from Perl.  We recommend that you have the following #packages installed before you install

libwww-perl:

i. Digest-MD5

ii. Encode-Locale

iii. HTML-Form

iv. HTML-Parser

v. HTML-Tagset

vi. HTTP-Cookies

vii. HTTP-Date

viii. HTTP-Message

ix. HTTP-Negotiate

x. libnet

xi. LWP-MediaTypes

xii. MIME-Base64

xiii. Net-HTTP

xiv. URI

xv. WWW-RobotRules


If you want to access sites using the https protocol, then you need to

install the LWP::Protocol::https module from CPAN.

Read More


Install Graylog on CentOS 7 How to do it


This article will guide you on steps to #Graylog on #CentOS 7 and an effective method to make the logs more structured and searchable.

Graylog is a leading centralized log management solution built to open standards for capturing, storing, and enabling real-time analysis of terabytes of #machine data. 

Graylog is an open source log management platform which enables you to aggregate up to terabytes of log data, from multiple log sources, DCs, and geographies with the capability to scale horizontally in your data center, #cloud, or both.

To #Install Graylog 3 with Elasticsearch on CentOS 7:

1. Configure #SELinux. 

2. Add required #repositories 

3. Install #Java, #Elasticsearch, and #MongoDB. 

4. Configure Elasticsearch for Graylog. 

5. Install Graylog 3 on CentOS 7. 

6. Start Graylog service on CentOS 7.

Read More


Install InfluxDB on CentOS 7


This article will guide you on steps to Install #InfluxDB on #CentOS 7. You can Turn any InfluxData #instance into a production-ready cluster that can run anywhere. Easily create and share a comprehensive monitoring solution.

InfluxDB is similar to a #SQL #database, but different in many ways. Relational databases can handle time series data, but are not optimized for common time series workloads. InfluxDB is designed to #store large volumes of time series data and quickly perform real-time analysis on that data.

The local InfluxDB configuration file is located here: Linux: /etc/influxdb/influxdb. conf. macOS: /usr/local/etc/influxdb.

To Install InfluxDB:

Option 1 : Download the InfluxDB archive via the browser.

Option 2 : Adding the #repositories to your package manager.

i – Start your InfluxDB service.

ii – Configure your InfluxDB instance.

iii – Test your InfluxDB instance.

iv – #Download InfluxDB 2.0 archive from the website.

Read More


OpenLDAP on Ubuntu Steps to install it


This article will guide you on the steps to #install and configure #OpenLDAP on #Ubuntu.

OpenLDAP is a open source implementation of #LDAP in Linux.

If it's your #server, you will know just by looking at the running services. When you are there, run #netstat and probably you will see LDAP listening only on localhost . Remotely, if the server is listening on #localhost , you cannot know just by running nmap , the port will not answer for the public #interface.

To Install and Configure OpenLDAP on #CentOS / #RHEL #Linux:

1. Install OpenLDAP Packages. On CentOS and RedHat, use yum install as shown below, to install the openldap related packages. 

2. LDAP #Config Files. config. 

3. Create olcRootDN Account as Admin. 

4. Create olcRootPW Root Password. 

5. Create olcSuffix #Domain Name. 

6. Verify The #Configuration Files. 

7. Start the LDAP Server. 

8. Verify the LDAP Search.

Read More


How to Install OpenNMS on CentOS 8


This article will guide via a step-by-step procedure to #install OpenNMS in #CentOS. 

OpenNMS is a free, Open Source network monitoring system that can be used to #monitor tens of thousands of unlimited devices with a single #instance.

It will discover and monitor the services or nodes automatically in your #network, or you can assign a particular service to monitor by OpenNMS.

To configure #OpenNMS:

1. Install OpenNMS Horizon. Add yum repository and import GPG key. 

2. Initialize and set up #PostgreSQL. Initialization of the PostgreSQL database will start.

3. Initialize and start OpenNMS Horizon. 

4. First Login and change default password.

Read More


How To Install MariaDB on Ubuntu Focal Fossa


This article will guide you on steps to install #MariaDB from the #Ubuntu #repositories and from the official MariaDB repositories. You can install MariaDB in two different ways.

To install MariaDB on Ubuntu, follow these steps:

1. Update #packages index. sudo apt update.

2. Once the packages list is updated, install MariaDB by issuing the following command: sudo apt install mariadb-server.

3. The MariaDB service will start automatically.

The default data directory for the MariaDB database server is /var/lib/mysql. The configuration file of MariaDB database server is /etc/mysql/mariadb. conf. d/50-server.

Read More


SQL Server and create a database on Ubuntu How to install


This article will guide you on how to #install MS SQL on #Ubuntu Server 18.04. 

To Install #Microsoft SQL Server 2017:

1. Visit Microsoft's official SQL Server 2017 download page.

2. Select the edition you want to #download. 

3. Click Download now below your selected edition. 

4. The wizard will prompt you to select an installation type. 

5. On the next page, select a directory for the installation folder.

To connect to the SQL Server using #SSMS:

i. From the Connect menu under the Object Explorer, choose the #Database Engine.

ii. Then, enter the information for the Server name (localhost), Authentication (SQL Server Authentication), and password for the sa user.

iii. Click the Connect button to connect to the SQL Server.

Read More


NFS Server on RHEL CentOS 8 Steps to install and configure


This article will guide you on the steps to Install and Configure #NFS Server on #RHEL or #CentOS.

The terms client and server are used to describe the roles that a computer plays when sharing file systems. The NFS service enables any given computer to access any other computer's file systems and, at the same time, to provide access to its own file systems.

To install NFS server:

1. Install NFS #Kernel Server. 

2. Create the #Export #Directory. 

3. Assign server access to client(s) through NFS export file. 

4. Export the shared directory. 

5. Open #firewall for the client (s).

Read More


VirtualHost cannot occur within virtualhost section in WAMP


This article will guide on steps to fix #VirtualHost cannot occur within virtualhost section in #WAMP which occurs while we try to add VirtualHost #directive and reconfigure #vhost.

Directory directive works only for filesystem objects (e.g. /var/www/mypage, C:\www\mypage), while Location directive works only for URLs (the part after your site #domain name, e.g. www.mypage.com/mylocation).

To Configure name-based virtual #hosts:

1. Install Apache webserver. Make sure you have installed #Apache webserver. 

2. Create web directory for each host. 

3. Create demo web pages for each host. 

4. Create configuration file for each host. 

5. Enable virtual host configuration files. 

6. Test Virtual hosts.

Read More


How to install Metricbeat on CentOS 7 to Gather Infrastructure Metrics


This article will guide you on the steps to install #Metricbeat and configure the Elastic Stack to collect and analyze system metrics. Metricbeat is configured using a #YAML configuration file. On Linux, this file is located at: /etc/metricbeat/metricbeat. yml. On #Docker, you will find it at: /usr/share/metricbeat/metricbeat.
Both #Filebeat and #Logstash can be used to send #logs from a file-based data source to a supported output destination.

Read More


Steps To Harden OpenSSH Client on Ubuntu 18 04


This article will guide you on how to harden #OpenSSH Client by following some quick and easy steps.
#Hardening of the #OS is the act of configuring an OS securely, updating it, creating #rules and #policies to help govern the system in a secure manner, and removing unnecessary applications and services. This is done to minimize a computer OS's exposure to threats and to mitigate possible #risk.

Read More


HAProxy Logging with Rsyslog on CentOS 8


This article will guide you on how to set up #HAProxy Logging #Rsyslog with some quick and easy steps. HAProxy is installed with RightScale load #balancer ServerTemplates. Load-balancer servers are also known as front-end servers. Generally, their purpose is to direct users to available #application servers. HAProxy can be installed in front of them to provide load balancing and high availability.

Read More


Steps to create a Self-Signed SSL Certificate for Apache in CentOS 8


This article will guide you on how to configure #Apache to serve encrypted requests using a self-signed SSL certificate and to redirect unencrypted HTTP requests to #HTTPS. Self-signed #certificates or certificates issued by a private CAs are not appropriate for use with the general public. It can only properly verify the identity of the server when it is signed by a trusted third party because any attacker can create a self-signed certificate and launch a man-in-the-middle attack.

Read More


Install and configure Grafana on CentOS 7


This article will guide you on the steps to #install #Grafana on #CentOS 7 which is a #visualization and #analytics #monitoring software. Grafana is Free and Open Source which Runs on all major #OS operating systems.

Read More


Step by step process to Secure Apache with Lets Encrypt on CentOS 8


This article will guide you on the process to secure #Apache with Let’s Encrypt by installing Let's Encrypt #Certbot client, downloading #SSL #certificates for the #domain, and setting up automatic certificate renewal.

The objective of Let's Encrypt and the #ACME protocol is to make it possible to set up an #HTTPS server and have it automatically obtain a browser-trusted certificate, without any human intervention.

Read More


How To Troubleshoot Common HAProxy Errors


This article will guide you on the different methods to #troubleshooting and fix common #HAProxy errors which can range from diagnosing #errors with the service itself to locating misconfigured options for modules. 

Read More


ifconfig centos 7


This article will guide you on the steps to #install #ifconfig in #CentOS using the yum #package #manager.

The ifconfig command can tell you a lot about your Unix server's connection to your #network and the role it's playing in both generating and receiving network traffic.

Read More


Install Prometheus Network Monitoring Server on CentOS 7


#Prometheus collects metrics from targets by scraping 3metrics #HTTP endpoints. Since Prometheus exposes #data in the same manner about itself, it can also scrape and monitor its own health. 

This article will guide you on the steps to perform #installation of Prometheus on #CentOS 7 along with the method used for the #setup.

Read More


Sync Two CentOS 8 Servers Using File Replication


The #sync command forces an immediate write of all cached data to disk. Run sync if you anticipate the system to be unstable, or the storage device to become suddenly unavailable, and you want to ensure all data is written to disk. Individual files may be synced, or the entire filesystem containing the specified files.

This article will guide you on the right steps to sync two #CentOS 8 #servers using file replication.

Read More


Steps to Install Pure-FTPD on Ubuntu 18.04 LTS Server


#Pure-FTPd is a fast, production-quality, standard-conformant #FTP (SSL/TLS) server, based upon Troll-FTPd.

This article will guide you through the processes to install Pure-FTPd on your #Ubuntu server.

Read More


VirtualBox installation on CentOS 7


This article will help you to install VirtualBox on Centos. VirtualBox Software helps to create and run virtual machines on a single hardware machine.

Read More