Skip to content
Nosce Te Ipsum
  • Home
  • About me
  • My COETAIL Blogs
    • Course 1
    • Course 2
    • Course 3
    • Course 4
  • Testimonials
    • Professional
    • Personal
Site Search

…after a long absence

  • December 14, 2015December 14, 2015
  • by Muhammad
Share on Facebook
Facebook
Tweet about this on Twitter
Twitter
Share on LinkedIn
Linkedin
Pin on Pinterest
Pinterest
Share on Reddit
Reddit
Email this to someone
email
Share on StumbleUpon
StumbleUpon
Digg this
Digg

i am glad to have successfully restored my blog from an aged laptop to Amazon EC2 🙂

would like to save some of the steps I had to follow in order to restore this old site from a Debian installed WordPress and old MySQL to an Ubuntu LAMP server. I managed to migrate the content and plugins from Debian install to now this standard WordPress install with latest MySQL

    • using Ubuntu 14.4 on AWS EC2 – Free Tier
    • installed apache2, php, mysql and phpmyadmin (apt-get)
    • created the .conf files in /etc/apache2/sites-available folder and then published them in /sites-enabled using a2ensite command
    • created the respective folders in /var/www/html/ for each site on this server
    • only needed apachae conf file for www.azeem.online and used the following code in standard index.html for redirections from all other domains pointed to this host

      Add the following lines to index.html

      <html>
      <head>
      <meta HTTP-EQUIV="REFRESH" content="0; url=http://www.azeem.online">
      </head>
      </html>

      Save the file and restart the web server.(Note: Replace DNS_NAME_SERVER with the actual website name.
    • download the latest WordPress in your home folder“sudo wget http://wordpress.org/latest.tar.gz”
      and unpack with
      “tar xzvf latest.tar.gz”
    • move this to the folder location at the “/var/www/html/” path
    • install the required extra packages“sudo apt-get install php5-gd libssh2-php”
    • using mysql command line do the following:

      mysql -u root -p
      CREATE DATABASE wordpress;
      CREATE USER wordpressuser@localhost IDENTIFIED BY 'password';
      GRANT ALL PRIVILEGES ON wordpress.* TO wordpressuser@localhost;
      FLUSH PRIVILEGES;
      exit

  • change folder to the wordpress folder in /var/www/html/ and run following commandscp wp-config-sample.php wp-config.php
  • edit this file and find + replace the following information which you have from creation of the database

    /** The name of the database for WordPress */
    define('DB_NAME', 'wordpress');/** MySQL database username */
    define('DB_USER', 'wordpressuser');/** MySQL database password */
    define('DB_PASSWORD', 'password');

  • visit the URL and finish the WordPress install in few steps. Once it’s done I got a fresh install of standard WordPress and it’s database
  • unpacked the old site folder in /tmp and replace the new WordPress wp-content folder with the one from old backup. That is the only folder I needed. It should bring back all site content and plugins etc.
  • change permissions on the wordpress folder to secure it

    sudo chown -R www-data:www-data *

  • load and login to ‘phpmyadmin’ in browser and click on the ‘wordpress’ database created earlier
  • import the previously backed up wordpress sql database into this database
  • click on “wp-options” table and change the URL to new ‘www.azeem.online’
  • load the site in browser and login to /wp-admin. It prompted me to update the database which worked smoothly
  • Using the ‘Settings’ -> ‘General’ menu check and update if needed the URLs to be the new ones
  • Updated all the plugins and WordPress components and

VOILA!!! 🙂

Share on Facebook
Facebook
Tweet about this on Twitter
Twitter
Share on LinkedIn
Linkedin
Pin on Pinterest
Pinterest
Share on Reddit
Reddit
Email this to someone
email
Share on StumbleUpon
StumbleUpon
Digg this
Digg
Unknown unknowns
Nearly ten years already!
Muhammad

Related articles

Raspberry PI as temperature and…
Dynamic DNS client setup for…
Install Nginx, MySQL and PHP…
Autostart a terminal app on…
Attaching an external storage with…
Setting up L2TP/IPSEC server using…
(c) Raspberry Pi
Starting with Raspberry Pi
Using GeoIP database to identify…
Designing Technology Infrastructure for Transformational…
The sad state of human…

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Follow Me!

Follow Me On TwitterFollow Me On LinkedInFollow Me On PinterestFollow Me On About.meFollow Me On Wordpress
May 2025
M T W T F S S
« Oct    
 1234
567891011
12131415161718
19202122232425
262728293031  

2009 2010 2011 Amelie apache beijing birthday clearos crèpes debian december 2009 dubai email february firewall guide holidays ill install internet kuala lumpur linux list mac maheen mobile october 2009 outlook Pakistan raspberry raspberry pi router search Sharepoint smtp snow spring ubuntu unix VLAN VPN windows 7 winter xian Zimbra

WP Cumulus Flash tag cloud by Roy Tanck requires Flash Player 9 or better.

Categories

Licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License.
Theme by Colorlib Powered by WordPress
  • Home
  • About me
  • My COETAIL Blogs
  • Testimonials