Migrate to new server

Discussion in 'Installation/Configuration' started by skoena, Jul 26, 2012.

  1. till

    till Super Moderator Howtoforge Staff HowtoForge Supporter ISPConfig Developer

    1) If both servers are online, then you can copy them with scp. Example:

    scp www.tar.gz root@newserver.tld/tmp/

    You should not restore it on the new server. You just backup it in case that you need any of the config details and to have the /etc/passwd, shadow, group and gshadow files at hand for step 5).

    2) Backup only the client databases and dbispconfig database. The command you posted will backup all databases to one file so you get the problem that the mysql.mysql database is included but it should not be restored on the new server. You might be able to add a exclude statement if you dont o┬┤want to backup databases one by one.

    a mysql dump can be imported with:

    mysql -u root -p < backup.sql
     
  2. Appie Thrasher

    Appie Thrasher Member HowtoForge Supporter

    Been struggling with that one for my self the whole weekend, tried everything I could find about tar but always got the whole dir structure. So finally I used WinSCP to do the trick. Only hope the right are good after unpacking.

    Have the same question found different howtos some say do and others say don't :confused:

    I am doing it right now I am importing the database with phpMyAdmin. But the client database I first have to manually recreate to import them. I luckly have only 5 clients so not that much work.

    Hope it helped a bit...

    Appie
     
  3. till

    till Super Moderator Howtoforge Staff HowtoForge Supporter ISPConfig Developer

    If you switch steps 7 and 8 (do the resync before you import the client databases), then the database will exist.
     
  4. Appie Thrasher

    Appie Thrasher Member HowtoForge Supporter

    Followed these steps over and over on my new server (local) but again and again I get the "it works" when I try to connect to a site (after chancing the host file)
    And I can't login with phpMyAdMin as a user, root is working fine.
    Anybody can give me a hand, I really don't know it anymore :(
     
  5. skoena

    skoena Member

    I have dumps of all my databases but how to get them into ispconfig?

    When for example I import the old dbispconfig and import it into the new server I see al db's in ispconfig but not under phpmyadmin. How to do this?
     
  6. falko

    falko Super Moderator Howtoforge Staff Moderator HowtoForge Supporter ISPConfig Developer

    You need to import the SQL dumps of all the other databases as well.
     
  7. skoena

    skoena Member

    But how to import them?
    Of many DB's I don't have the users password, so I want to import them but passwords must be installed before?

    What to do with the mysql database? On my new server I have new passwords for ex. ispconfig so I can't simply import it back?
     
    Last edited: Apr 7, 2013
  8. skoena

    skoena Member

    Any tips on how to import the DB's I I don't know the DB's passwords.

    Please give me the steps and commands to use to get this done.
     
  9. skoena

    skoena Member

    Please can somebody help? ...
     
  10. skoena

    skoena Member

    Falko, Till, others? Any tips how to to import the db's?
     
  11. falko

    falko Super Moderator Howtoforge Staff Moderator HowtoForge Supporter ISPConfig Developer

    You just need the MySQL root password for importing DBs: http://www.howtoforge.com/faq/6_4_en.html
     
  12. skoena

    skoena Member

    But users have added their own DB passwords. How to import the DB'w into ispconfig (how to get them listed in ispconfig?) When I import them will it create the correct DB with the users PW automatically?
     
  13. beyerservice

    beyerservice Member HowtoForge Supporter

    @skoena: no. users and pass are in master-DB in MySQL.
    If you imported your dbispconfig-DB from old server you get them listed in ISPconfig (bot not in mysql...)

    Well thats the point: NO, Resync soes not create database nor users !!! (See on german forum: http://www.howtoforge.de/forum/35592-post1.html

    I will post solution here as well (if there is one...)
     
  14. beyerservice

    beyerservice Member HowtoForge Supporter

    no answer? what does this resync-thing do?
     
  15. skoena

    skoena Member

    Tried to migrate.
    I have an issue. My jobqueu stays very full, do I need to update a password of the dbispconfig or someting?

    Rudolf.
     
  16. skoena

    skoena Member

    Followed these steps:

    Did this to get a dump of all DB's:
    Copied the sql file via scp to the new server:
    Imported:

    I have an issue. My jobqueu stays very full, do I need to update a password of the dbispconfig or someting?

    Rudolf.
     
  17. beyerservice

    beyerservice Member HowtoForge Supporter

    i looked into my ispconfig files for dbispconfig pass and set it in phpmyadmin for ispconfig user and it worked!
    this pass is set by ispconfig setup, so it is different for new server!
     
  18. skoena

    skoena Member

    Tnx beyerservice

    Can you please tell exactly where to get this password and which file to update it in?
     
  19. skoena

    skoena Member

    Another thing.
    On all the sites I got the default Welcome to your website instead of the website it self.

    Any tips?
     
  20. beyerservice

    beyerservice Member HowtoForge Supporter

    you can find that pass on the new server for example in
    Code:
    /etc/postfix/mysql-virtual_domains.cf
    just look for the line with password.

    now you have to change the mysql password of this user (see in that file too) in mysql-server. how to do that, see for example http://blog.marceloaltmann.com/en-c...ysql-pt-trocando-a-senha-do-usuario-no-mysql/

    your second problem could caused by this db problem too, because ispconfig cant access that mysql-db and did not create proper apache vhost files.
    If you changed that password, you should resync your settings and wait, until your job-que is emty. Some reboot after that
    is a good idea too :)

    i hope you get it working soon :-D
     

Share This Page