Master server got deleted

Discussion in 'Installation/Configuration' started by arkangelll, Sep 4, 2014.

  1. arkangelll

    arkangelll New Member

    Greetings everyone,

    You could say I'm fairly new around here, I was only lurking around so far for reading purposes, but now I'm facing a problem I just haven't a clue how to even start working on... so I'm completly at your mercy right now.

    I have set up a (debian based) multi-server environment (virtual servers) using a howtoforge guide, I must admit, I'm not exactly sure which one now. (Probably this)
    Due to some problems with our host system, not only did our backup(s) vanish from the server, we have lost the web-host master server as well. It's completly gone we couldn't get it back. :(
    Right now, I'm left with a mail, database, nameserver who do not really know about each other...
    I have tried looking through the forums and the web for a solution, but couldn't find anything even resembling an answer I need...

    The only idea I've had so far was running an update on one of the (mail) servers hoping it would connect to the master server as it was asking for the SQL details... but nope. :(

    If there is already a thread about this, then I'd be grateful if anyone could point me in the right direction and sorry for making a useless thread.
    If there isn't... I'm open for suggestions :(
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Please run this on the master:

    ls -la /var/backup/isp*

    to see if we have any of the automated backups from ispconfig updates left.

    The problem is that slave servers contains only a partial database, the master is the only one that has all data. But we might be able to create a masterdatabase based on all slaves, but before we try that, lets first see if there is really no backup left that we can use as a starting point.

    did you loose only the ispconfig database or did you loose also data in the mysql "mysql" database (mysql users and permissions)?
  3. arkangelll

    arkangelll New Member

    Dear till,

    Thank you very much for your time, looking into my problem.
    Unfortunately I do not have any backups left as I have lost the whole system, not just the database itself (I'm sorry if I was not clear about this) and now I have a brand new ISPConfig server set up (using the same guide) hoping to reclaim some data I had...
    This means I've lost not only the database of the master server, but also files for websites and so on...

    Recreating the master database from partial data is exactly what I'm hoping for!
    I already accepted my fate of lost websites, but I still have a completley functional email server and I'd love to keep it that way!
    My main concern though is integrating the slave systems to the master server again, I have not found any information about this... (well, except for running the install.php..)

    About mysql users and permissions - is it only the root password we require or the random generated "ispconfig" user password for each slave as well?..
  4. arkangelll

    arkangelll New Member

    I can feel this topic is going to die and perish... but I'll give it one more last try :)
    As I've failed to examine the database structure of the master server when I had it, I do not actually know if all the data from the slave servers exist there as well.. or only on the slaves?
    I guess I'm just left with migrating the e-mails manually after rebuilding the whole system...
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    The slaves contain only data thet is used on them. The sum of the data of all salves is the master server (as long as you did not host any websites or mail accounts n the amster itself). So if you copy all slave databases together, then you get the data of the master, except of the data that was stored on the master only like websites or mail accounts that were hosted on the master.

    the slaves connect to the amster with a user "ispcsrv*" where * is the ID of the slave. This user has limited permissions for security reasons. But you can recreate it manually with full access to the dbispconfig database on the master and then later run a ispconfig update on the slave and let it reconfigure permissions in the master database. The root user is only used by the slaves to run ispconfig updates, it is not used for "daily work".
  6. arkangelll

    arkangelll New Member

    Thanks for response, till!
    Didn't know about that user, great!
    I've restored the client-user settings already, I'll get started on connecting the servers to the master server again... thank you very much!
  7. arkangelll

    arkangelll New Member

    I've managed to copy the "server", "sys_group" and the "mail_" tables from the slave (mail) server to the master server and now I can see all that on the web interface as well, I also granted full access to the "ispcsrv?" user using the same password I found in the
    Then I ran the update script and reconfigured the permissions. (well, or atleast i said "yes")

    So I figured let's give it a try, and created an alias on the web interface... aaand it did not get replicated to the slave... any idea what have I done wrong there? =(
  8. till

    till Super Moderator Staff Member ISPConfig Developer

    Try to set the value of the "updated" column in the server table on the master and slave to 0 for the record of the slave server.
  9. till

    till Super Moderator Staff Member ISPConfig Developer

  10. arkangelll

    arkangelll New Member

    That was it! (It was over 800)
    Now it's working like a charm again, thank you SO MUCH till for helping me out.
    I'll take a look at the debugging you shown me as well.

    Once again: thanks a lot.

Share This Page