LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-26-2021, 02:57 AM   #1
awaismalik
Member
 
Registered: Mar 2021
Posts: 50

Rep: Reputation: Disabled
WordPress Instances with Multiple Databases


I am migrating the website from old server to new server for which i only have command line access to both servers. The website consists of two languages so i copied both wordpress files wordpressLanguage1 and wordpressLanguage2 files to the new server and also exported two mysql databases as exportLanguage1.sql and exportLanguage2.sql. On the new server i installed apache2, mysql,mariadb,php and configured them. In /etc/apache2/sites-available/mywebsite file at place of ServerName and ServerAlias i have placed IP of my new server to test the website. In database wp_options i also changed the siteurl and home to IP of my new server. When i search with IP of my new server it open the website of Language1 on the right side corner when i select the Language2 the IP redirects me to the old server URL. I am sure both databases are loaded and also both wordpress files are copied.Configuration at /etc/apache2/sites-available/mywebsite files are also same. For both languages website files(.conf) i have defined the same SeverName and ServerAlias 'IP' address of new server. Can any one tell me what i am missing or doing wrong? Thanks
 
Old 07-26-2021, 04:45 AM   #2
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,475

Rep: Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553
Quote:
Originally Posted by awaismalik View Post
In database wp_options i also changed the siteurl and home to IP of my new server.
Changing the domain name of a wordpress instance isn't as simple as that, as the domain name appears in a lot of places inside the database rather than just the options.

There are wordpress plugins for doing domain name changes, you'll probably need to use one of them.
 
Old 07-26-2021, 04:52 AM   #3
awaismalik
Member
 
Registered: Mar 2021
Posts: 50

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by TenTenths View Post
Changing the domain name of a wordpress instance isn't as simple as that, as the domain name appears in a lot of places inside the database rather than just the options.

There are wordpress plugins for doing domain name changes, you'll probably need to use one of them.
Unfortunately i dont have access to wp-admin so i can not use plugins. I am doing the backened migration of wordpress site.
 
Old 07-26-2021, 05:00 AM   #4
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,475

Rep: Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553
Quote:
Originally Posted by awaismalik View Post
Unfortunately i dont have access to wp-admin so i can not use plugins. I am doing the backened migration of wordpress site.
I'd strongly suggest you get whoever does have admin access to grant it to you for the purposes of this migration, you'll find it difficult otherwise.

Or maybe take a look at https://torquemag.io/2017/04/switch-...-names-wp-cli/ and https://wp-cli.org/ (which a 30 second search on Google for "wordpress migrate to new domain command line" turned up.)
 
1 members found this post helpful.
Old 07-26-2021, 08:04 AM   #5
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,636

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by awaismalik View Post
Unfortunately i dont have access to wp-admin so i can not use plugins. I am doing the backened migration of wordpress site.
Agreed with TenTenths, and will question why (as the administrator who is doing server-migrations), you are tasked with doing something you don't have rights to do??
 
  


Reply

Tags
migration, mysql, php, ubuntu 18.04, wordpress



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Batch adding multiple users to an instances for multiple pages Fred27377 Linux - Newbie 6 06-10-2020 02:48 PM
how to install pre existing wordpress directory on a existing wordpress to run a web ajbardhan Linux - Software 3 04-28-2012 07:01 PM
sendmail-2: Wrong number of instances of process sendmail:, expected instances equal maxymaxymaxymaxymaxy Linux - Newbie 1 06-15-2011 10:51 AM
kickstart; how-to info needed for multiple instances of RH OS's and multiple unique v Joe_Wulf Linux - Server 4 06-21-2007 11:18 PM
sendmail and NIS databases (aliases, mail.aliases) - what kind of databases? cotton213 Linux - Software 0 03-14-2006 05:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:47 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration