Migrate Emails using imapcopy

To instal imapcopy on Ubuntu/Debian, run

To migrate mailbox, create a file

Create config file

In above file, replace SOURCE and DESTINATION server IP, user and passwords.

To start the email migration, run

You can test the config with command

PostgreSQL List all databases

To list all databases in PostgreSQL database, first connect to PostgreSQL database using psql command

Now run

This will list all available databases.

To change to a database, use command /connect

Once you connected to a database, you can list all tables in a database with command

Disable TLSv1 in Nginx

To disable TLSv1 in nginx, add

in your server config.

if you are using letsencrypt SSL, edit file

Find

Replace with

Restart Nginx

To verify, run

This will list all supported SSL protocols.

nmap

Nginx Rails Origin header didn’t match request.base_url

After installing SSL on Nginx server, rails application login page stopped working.

On log file (log/production.log), found following error

HTTP Origin header (https://domain.com) didn't match request.base_url (http://domain.com)

The Nginx config used was

The problem is solved by adding following to nginx config.

The new config is

See Nginx

CloudLinux EasyApache 4 Profile Missing

On CloudLinux server, EasyApache profile was missing.

WHM shows following error message

Re installing ea-profiles-cpanel did not help.

The issue is resolved by running

See Cpanel

Sending Email with telnet

To sent email with telent, run

On the promt, type following

See Telnet

Install Squid Proxy Server

Proxy server allow to hide your IP address. To install squid proxy server, run

If you have multiple IP address configured on server, you can configure IP address by running

Now you will be able to use all IP available in server as proxy server.

To create a user in squid proxy, run

To change password of a user, run

See proxy