Activate mod_deflate on plesk server

On a Plesk server, the mod_deflate module is installed by default, however it may be disabled in the Apache configuration file. To enable the module edit the Apache configuration file

vi /etc/httpd/conf/httpd.conf

Search for the line

#LoadModule deflate_module modules/mod_deflate.so

and uncomment it i.e. remove the ‘#’ mark

LoadModule deflate_module modules/mod_deflate.so

Save the file and restart the httpd service

service httpd restart

Now, create a .conf file under the /etc/httpd/conf.d/ directory since Apache reads all the .conf files from that directory on a Plesk server

vi /etc/httpd/conf.d/deflate.conf

and place the following code in it

<Location />
SetOutputFilter DEFLATE
SetEnvIfNoCase Request_URI .(?:gif|jpe?g|png)$ no-gzip dont-vary
</Location>

Save the file and restart the httpd service. The compression code will compress all the files except the .gif, .jpe, .jpeg and .png files. To test the compression, use the tool

http://www.whatsmyip.org/mod_gzip_test/

To enable compression for a specific directory or domain, specify the directory path in the <Location> directive in deflate.conf and restart the Apache server.

WordPress migration with full Plesk integration

Step by step instructions for moving a WordPress site between servers using ‘duplicator’ plugin.

Source server
1. Install duplicator
Login to WP admin area. Click Plugins. Search for ‘Duplicator’ plugin and install.
2. Activate the plugin through the ‘Plugins’ menu in WordPress
3. Click on the Duplicator link from the main menu
4. Create your first package.
You will go through a verification check of the setup. Fix any issues that duplicator finds.
5. FTP installer.php and packageName_archive.zip to destination server (download to PC, upload to new server).

Destination server
1. Move installer.php and package.zip file into document root directory.
2. Install WP through Plesk. This step is only necessary if you want Plesk to recognize the WP installation.
3. Look in the wp-config.php file and make a note of mysql db, user, password and then rename file to be wp-config.php.back.
4. Run the installer.php script. Adjust domain name and mysql settings.
5. Verify successful migration.
6. Remove migration files: installer.php, installer-data.sql, installer-log.txt, packageName_archive.zip, wp-config.php.back