Archive for the tag 'server'

Setting up a remote MySQL server for cPanel/WHM server.

You can change the MySQL server from the local server (”localhost”) to point to a remote server.

This allows MySQL functions to be performed by another computer.

To set up a remote MySQL server:

1.Click on the Setup Remote MySQL server link.
2.Enter the name of the remote server in the Remote Mysql Host field and its password in the Remote Mysql Host’s Root Password field.
Note: Do not enter the root password for the remote MySQL server in the Remote Mysql Host’s Root Password field.
3.Click on the Setup button.

How to access psa database in Plesk Server

We can access plesk psa database, from the Linux command line (via ssh) and from the Plesk control panel.

The /etc/psa/.psa.shadow file contains the Plesk admin password.

So to access the database run the following command.

mysql -uadmin -p`cat /etc/psa/.psa.shadow`

Select the psa database.

mysql> use psa;

To view all the tables

mysql> show tables;

Localdomains and remotedomains in cPanel Server.

Problem : A user that pointed their MX records to another server but email from their website or users on the same server isn’t going out of the server.

This is because Exim on the server is configured to use files called localdomains and remotedomains, which tell Exim whether a domain’s email is hosted locally or remotely.

The files controlling these actions are:

/etc/localdomains: email hosted locally

/etc/remotedomains: email hosted remotely

* The remotedomains file takes precedence, so if a domain is located in both files, the mail server should use remotedomains.

Common Errors:

*Email from the user’s site is not being delivered to their outside mail server - add the domain to remotedomains
*lowest numbers MX record points to localhost - adding the domain to localdomains will resolve the issue.
*Email bouncing stating the user does not exist - add the domain to remotedomains

Apache Security: Hide Apache Web Server Version number

Apache Web Server Version number with ServerSignature and ServerTokens directives

Open your httpd.conf file using text editor such as vi:

vi httpd.conf

There are two config directives that controls Apache version. The ServerSignature directive adds a line containing the Apache HTTP Server server version and the ServerName to any server-generated documents, such as error messages sent back to clients. ServerSignature is set to on by default. The ServerTokens directive controls whether Server response header field which is sent back to clients includes a description of the generic OS-type of the server as well as information about compiled-in modules.

Append/modify config directive as follows:

ServerSignature Off
ServerTokens Prod

Save and close the file. Restart Apache web server:

/etc/init.d/httpd restart

TCP and UDP Ports for Cpanel Server Firewall

Incoming TCP ports

TCP_IN = “20,21,22,25,53,80,110,143,443,465,587,993,995,2077,2078,2082,2083,2086,2087,2095,2096,2242″

Outgoing TCP ports

TCP_OUT = “20,21,22,25,37,43,53,80,110,113,443,587,873,2087,2089,2703″

Incoming UDP ports

UDP_IN = “20,21,53″

Outgoing UDP ports

UDP_OUT = “20,21,53,113,123,873,6277″

« Prev - Next »