Results 1 to 7 of 7
  1. #1
    Join Date
    Aug 2002
    Location
    dublin
    Posts
    238

    Moving a site to a new server but want to keep old database

    I have moved a site i made from my server to my companies server and there is a problem with the MySQL database,

    here is the page where the info is been pulled to on my server
    http://www.davidstokes.com/avi/3/outlets.php
    and this is where the new one will is
    http://217.114.173.147/~admin1/outlets.php

    if you click on the links on my site you get the info, but if you click them on the new server they dont work

    what i have done already is change the "localhost" setting on the new server to the IP address of my server but that didnt work.

    I only changed it in 1 place and i dont know if there is any other places where it is, would it be in any other area? is there anything else i have to change ?

    I didnt make the script and the guy that did wont help me, so i'm stuck.

    any help would be great

    thanks

    {edit}

    also
    i tired to login to the admin area of the script where i add and remove new dealers. and i got this error

    Code:
    Warning: mysql_pconnect(): Can't connect to MySQL server on '207.44.232.119' (4) in /home/admin1/domains/avi.ie/public_html/adodb/drivers/adodb-mysql.inc.php on line 354
    Can't connect to MySQL server on '207.44.232.119' (4)


    I checked this line and it's
    Code:
    $this->_connectionID = mysql_pconnect($argHostname,$argUsername,$argPassword,$this->clientFlags);

  2. #2
    Most likely your "old" server that serves as MySQL server doesn't allow connections except from loopback (localhost).
    You should add new IP to allowed hosts list and that will sort it out.
    If you have cPanel, the problem is really easily solvable since you only need to input a new IP under "MySQL databases".

  3. #3
    Join Date
    Aug 2002
    Location
    dublin
    Posts
    238
    how do i add a new IP , my sit eis hosted with www.ehostpros.com

  4. #4
    Join Date
    Mar 2002
    Location
    In My Own World
    Posts
    972
    AdminWHF,

    What kind of control panel do they use. It might be possible that there is a setting in the CP that allows remote connections. DirectAdmin for example allows you to setup IP's that connect from a remote location, other than localhost anyway.

    Tracy Phillips

  5. #5
    AdminWHF, please answer Mr. Weberize's post since it's important which CP you use.
    I can tell you how to add new host from shell but..do you have SSH access?

  6. #6
    Join Date
    Oct 2004
    Location
    UK
    Posts
    487
    Just by looking at the URLs he had provided, I am assuming that he is using Ensim or Ensim Pro. But I may be wrong

  7. #7
    Join Date
    Jul 2003
    Location
    Kuwait
    Posts
    5,099
    Why don't you just create a dump of your database and then repopulate it at your new server? This would solve many of your problems.

    You would then only need to change the IP address back to localhost for things to work.

    Also, if your local MySQL server is behing a proxy/firewall, you might not be able to connect to it from your live server.

    Your best option is to migrate the databases. If you use phpmyadmin or another administration tool, create a dump from your old database then import it into your new one (your live one).
    In order to understand recursion, one must first understand recursion.
    If you feel like it, you can read my blog
    Signal > Noise

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •