yum list available

yum list all available packages in a repo

To list all packages available on a specific repo, run

Example:

yum list available

This command list all packages available in repo “litespeed”

Install PHP 7 on CentOS VestaCP

To install PHP 7. you need to first enable epel and remi repo.

Remove existing PHP

Install PHP 7.3

start php-fpm

Set php 7.3 as default PHP for cli

Restart apache

rpmdb DB_RUNRECOVERY: Fatal error, run database recovery

When running yum update on a CentOS server, i get following error.

To fix it, run

rpm verify packages

To verify a package installed on system, you can use

Example

Here bind package have /etc/named.conf file modified.

To verify all packages on system, run

CentOS 7 resolv.conf make changes permanent

On rebooting CentOS 7 server, changes made to resolv.conf is lost. This is becaise one of the network interface is configured to use DNS server.

To fix, edit

Remove the line

Now NetworkManager will not modify /etc/resolv.conf file on boot.

Or you can set valid DNS servers in network config file like

If your network configuration use DHCP, set set PEERDNS=no.

Another solution is to make file immutable with

Related Posts

Domain Resolver

Install Pure-FTPd on CentOS with Virtual Users

To install Pure-FTPd on CentOS, run

Edit configuration file

To disable anonymous FTP, find

Replace with

To enable Virtual Users, find

Uncomment the line.

To Allow Apache user to login via FTP, find

Replace with

I set MinUID value to 47, as apache user have UID/GID of 48. By setting MinUID below that apache user should be able to login.

Set pureftpd to start on Boot

Restart pure-ftpd

Create a Virual User

To create a virtual user, run

It will ask you to enter password two times.

Now run

Change Password of an existing Virual User

It will ask you to enter new password.

Rebuild password database and restart pure-ftpd with

Related Posts

Install pureftpd on Ubuntu

pureftpd

Install vim from source on CentOS

To install vim from source on CentOS server, run

This will install latest version of vim. You can start it with command

To get it work with “vi” command, i removed preinstalled vim editor with command

Now create a symlink with

OpenLiteSpeed Benchmark

Install OpenLiteSpeed on CentOS

To install OpenLiteSpeed web server on CentOS, install repository for your CentOS version

For CentOS 6

For CentOS 7

For CentOS 8

To install OpenLiteSpeed, run

Before you can install PHP, you need epel repository enabled with

Install PHP with

Set symlink

Start OpenLiteSpeed with

To stop OpenLiteSpeed, run

By default, OpenLiteSpeed will run on port 8088

You can login to Admin Interface at

By default, you see an example application. The configuration file for this is at

Default DocumentRoot is /usr/local/lsws/Example/html. To change, edit file

Find

Replace $VH_ROOT/html/ with whatever path you need. You need to restart OpenLiteSpeed to make the change go live

Set hostname in CentOS 7

Hostname is a sub domain. To set hosting, edit file

Add

Example

Now run

Example

Run

Edit file

Edit or add HOSTNAME entry

Reboot the server with

You can verify hostname with command

Related Posts

Change Server Hostname in VestaCP
Set Permanant hostname on AWS EC2 CentOS 7 server
Install SSL for Cpanel Server Hostname