Testing migrated sites, what's best?

schwim

Well-Known Member
Aug 2, 2006
213
0
166
Hi there guys,

I've migrated a site from one server to another and would like to test the newly moved site before pointing the domain to it.

I know that you can get to an account by serveraddress.com/~account but I don't have to tell anyone that it's not much good for testing a site that uses php. I need to test it with it's domain name.

Thinking I was smart, I entered my server's ns ips into my network connection properties, but it's not working.

Is there a way that I can test the site with the domain on my server? I've got Configserver's security service installed on it, so there may be something extra I need to do.

thanks,
json
 

MaestriaNick

Well-Known Member
Aug 6, 2008
159
3
68
if your local pc is linux , then there is an easy method put the entry as below in to your pc's /etc/hosts file:


IP Domainname


where, ip is the ip by which the domain is setup in the new server.

In windows also, i think there are similar files . http://www.enterprisenetworkingplanet.com/netsysm/article.php/991281 that link may help you
 
Last edited:

Cinquecento

Member
Mar 29, 2004
11
0
151
Loughborough UK
I've got the same issue!

Same situation - same Configserver setup!

I can't even navigate to the account on the server using ipAddress/~accountname - I get a 404 error everytime.

I've tried changing the basedir in httpd.conf from the testing subdomain where I have a preview running successfully to the new account but it's not working.
 

schwim

Well-Known Member
Aug 2, 2006
213
0
166
Man, I can't thank you enough for that. I can't tell you for how long I've been using the "fingers crossed" method. Adding the entry to my /etc/hosts file did the job!

Cinquecento, you can disable that feature in WHM, which is probably your case. With it enabled, users can access files via that URL and it won't get applied to their bandwidth use, so it's commonly disabled.

thanks,
json
 

MaestriaNick

Well-Known Member
Aug 6, 2008
159
3
68
Same situation - same Configserver setup!

I can't even navigate to the account on the server using ipAddress/~accountname - I get a 404 error everytime.

I've tried changing the basedir in httpd.conf from the testing subdomain where I have a preview running successfully to the new account but it's not working.
may be trailing slash problem. can you try

http://ip/~username/ ?
 

Cinquecento

Member
Mar 29, 2004
11
0
151
Loughborough UK
Cinquecento, you can disable that feature in WHM, which is probably your case. With it enabled, users can access files via that URL and it won't get applied to their bandwidth use, so it's commonly disabled.

thanks,
json
Where's the control for that then?

I've done the etc/hosts thing too - doesn't seem to make any difference but perhaps I've got the wrong end of the stick: we're talking about running a site from an account prior to redirecting the domain? Is the etc/hosts hack supposed to take me to the account on my server rather than route through normal DNS channels to the current live site?

regards

Ian