LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-13-2022, 10:43 AM   #1
ck_chik
LQ Newbie
 
Registered: Mar 2020
Posts: 29

Rep: Reputation: Disabled
How to setup DNS after moving webpage


I have two web server ( server A & server B ) , running Linux , apache , they are located in two different data center , that means they are hosted by different provider

server A 's IP is 111.111.111.111 , two website are running on it , the url to access these Two website are
http://serverA.com/website1
http://serverA.com/website2


server B 's IP is 222.222.222.222 , one website are running on it , he url to access this website is
http://serverB.com/website3

As these two servers are hosted by two different data center , that means they have different DNS

Now we want relocate ( move / migrate ) server B 's website to server A , but want the url to access these three website are unchanged , as below
http://serverA.com/website1
http://serverA.com/website2
http://serverB.com/website3

Just would like to ask after relocate server B 's website to server A , what conf file need to be change ? how to change the DNS record to make the above three url are unchanged ?

Thanks a lot

Last edited by ck_chik; 05-13-2022 at 10:44 AM.
 
Old 05-13-2022, 07:31 PM   #2
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,324
Blog Entries: 28

Rep: Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142
If you have a registered domain, your domain registrar should take care of this.
 
Old 05-16-2022, 02:58 AM   #3
ck_chik
LQ Newbie
 
Registered: Mar 2020
Posts: 29

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by frankbell View Post
If you have a registered domain, your domain registrar should take care of this.
In server A , the hosts file as below

#vi /etc/hosts
111.111.111.111 serverA


What I need to do is add the below entry to the DNS server of the domain registrar ?

#vi /etc/hosts
111.111.111.111 serverB
 
Old 05-16-2022, 08:59 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
You don't make it clear if these are publicly available servers with registered domain names or if they are internal servers only.

If they are public available with a registered domain name then you need to find out where the A records for the domain are hosted.

It could be that the domain registrar is providing DNS services, in which case you will need to locate the appropriate A record within the domain and change it. As you look like you're serving with the bare domain then the A record may have a designation of @

If the registrar has delegated DNS services back to you (you'd be able to tell by the NS records for the domain) then you'll need to work out where and how DNS is actually being served and adjust the zone files accordingly.
 
  


Reply



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
Blocking Specific webpage not the whole domain For all DNS client.. sjangra Linux - Newbie 2 01-04-2011 07:23 AM
Before setup DNS and after DNS question sportivo888 Linux - Enterprise 7 12-13-2009 09:47 PM
webpage in webpage? kalleanka Programming 6 06-07-2009 04:13 PM
Webpage Browsing DNS lookup SLOW (ongoing Suse prob) dohanc SUSE / openSUSE 21 08-16-2005 11:11 PM
how to setup linux as a webpage Bashkir Linux - General 8 05-17-2001 10:19 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:15 AM.

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