cancel
Showing results for 
Search instead for 
Did you mean: 

access new Magento install using the same domain as a live production store on a different hosting

access new Magento install using the same domain as a live production store on a different hosting

Hi,

I have 2 hosting accounts - an old VPS account and a new CLOUD account. I have an old version of Magento (1,3,1) running on the old VPS hosting account (this needs to be the active one because I have all my products there and it is the current production store). I want to upgrade by just doing a fresh install of the Magento 1,9,1 version so I created a new MYDOMAIN.com account on the cloud server and then I installed the new Magento shopping cart there (1,9,1). I planned to access that by using the IP address (numerical IP address and then the account user name) but now - when I click on the IP address in the list of hosting accounts in the WHM (basically just try to access the new shopping cart by it's actuall IP address and a user name on the server) - it automatically loads the actual MYDOMAIN.com website (on the old server). I mean - the old website suppose to be the one active (loading from the VPS hosting account) but at the same time - I need to work on the new version of the shopping cart before it's all ready to go live (change design, add hundreds of products etc.)

How can I work with this new version of the Magento shopping cart without it reverting to the (old) production site?

Thanks,


Allysin

PS: Is this something in the htaccess file or something like that?

PS2: The hosting company replied this but I don't really understand it...

The easiest way to work on your new Magento site is to create a subdomain within your account MYDOMAIN.com .
You will have to create new folder within public_html or wherever you like and call it, for example test.

Then, within your cPanel account merge that subdomain with created folder and you can start testing.
Of course, you will have to copy content to newly created folder.

I cannot have a special directory where Magento resides I think because of the SEO links would not be the same as in the old store...

 

Thanks again for any suggestions. ;-)

2 REPLIES 2

Re: access new Magento install using the same domain as a live production store on a different hosti

There are three ways where you can go about this:-

 

1. The first way is to set a host entry in your computer to point the domain to the IP address of the new server when you want to access it and remove the host entry when you want to access the old server. This is not ideal and not really recommended if you want to switch back and forth or see the two stores side by side. 

 

2. The second way is to change your Magento Base URL to the IP address of the new server (for example: http://1.1.1.1/) while you are developing the store. You can change the Base URL to your correct domain when you are ready to go live. 

 

3. The third way is to create a subdomain like "dev.yourdomain.com" and add it as a Parked Domain in your cPanel where it will share the same document root as the main domain (so you will not need to move files, paths, etc). You can then change the Magento base URL to this subdomain while you are developing the store and change it to your correct domain when you are ready to go live. 

Re: access new Magento install using the same domain as a live production store on a different hosti

I have never had any luck moving magento to a new server with the same domain.  Seems simple enough.  Zip it, unzip it and change the local.xml file to reflect any changes.  But that never works. This is the error I always get.

 


Warning: file_exists(): open_basedir restriction in effect. File(/tmp/magento/var) is not within the allowed path(s): (/var/www/vhosts/username/mydomain.com:/usr/share/php:/usr/share/pear) in /var/www/vhosts/username/mydomain.com/httpdocs/app/code/core/Mage/Core/Model/Config/Options.php on line 216

Fatal error: Call to a member function getOptions() on a non-object in /var/www/vhosts/username/mydomain.com/httpdocs/app/Mage.php on line 329

 

I thought I read once that it is not possible to move a magento install.  A new install would be required.

 

I appreciate any help.