Page 1 of 2 12 LastLast
Results 1 to 10 of 18

Thread: Old server crashed, trying to restore, need help.

  1. #1
    Isbeorn is offline Junior Member
    Join Date
    Mar 2007
    Posts
    9
    Rep Power
    8

    Default Old server crashed, trying to restore, need help.

    So my old zimbra server crapped out. Watchdog rebooted the server and we had kernel panics trying to get back up and running (none of that is related to zimbra, just bad memory we think)

    Anyway, we reinstalled RHEL4 on a new drive and mounted our old drive so we could restore zimbra from it. I've been browsing the forums and wiki to find the best way to do this but all attempts seem to fail.

    Before I go about posting logs from failed attempts, I just want to know the best process for this. I've tried installing a fresh zimbra so that the scripts are all back in place, then moving /opt/zimbra out of the way and putting /mnt/oldserver/opt/zimbra in place, doing all the necessary zmcontrol stop starts and stuff. Also tried just putting the old /opt/zimbra in place and doing an install on top of it, install.sh recognized the folder and asked if I wanted to upgrade.

    But after going through those the final results weren't working right. So I'm back at a clean slate and just want to know the best way to do this.

    Since the old server crashed with zimbra running, there are pid files and such in place. IE, it was not cleanly shutdown. Perhaps I could chroot to the old environment and fix that... not sure.

    Thanks

    Oh and the old version was zcs-4.5.0_GA_612.RHEL4.tgz, I'm actually using the same tarball I did oringally, so I know I'm not getting version mismatches.

  2. #2
    jholder's Avatar
    jholder is offline Former Zimbran
    Join Date
    Oct 2005
    Location
    Thatcher, AZ
    Posts
    5,606
    Rep Power
    20

    Default

    What kind of errors are you seeing?
    When you start, it should tell you that there are stale PIDs in certain locations like /opt/zimbra/db, etc
    You can find this in /var/log/zimbra.log

    Also, don't forget to disable senmail/postfix, ldap, mysql, and httpd on your server so that they don't conflict.

    In any case, post your /var/log/zimbra.log so we can help you with the errors.
    Welcome to the forums!
    john

  3. #3
    Isbeorn is offline Junior Member
    Join Date
    Mar 2007
    Posts
    9
    Rep Power
    8

    Default

    Well, at the moment I don't have any errors to post, because I'm sitting at what I believe to be a 'clean slate'. I've done an ./install.sh -u. Removed everything zimbra related in /tmp, and removed /opt/zimbra. I have my old zimbra install at /mnt/oldserver/opt/zimbra, it remains as it was when our server crashed.

    I have a new RHEL4 install going, I've shutdown sendmail and httpd, and disabled the firewall and SELinux for the time being.

    So um, where do I start?

    Never was really clear on the 'proper' procedure for this.

  4. #4
    jholder's Avatar
    jholder is offline Former Zimbran
    Join Date
    Oct 2005
    Location
    Thatcher, AZ
    Posts
    5,606
    Rep Power
    20

    Default

    To start with, install your CURRENT version on your server. If you're running 4.5.0, install 4.5.0.

    Then stop zimbra, and rm-rf /opt/zimbra
    then
    rsync -avr /old/backup/location /opt

    Install your CURRENT version again as an upgrage.
    Let's go to that point

  5. #5
    Isbeorn is offline Junior Member
    Join Date
    Mar 2007
    Posts
    9
    Rep Power
    8

    Default

    Okay here goes,
    install.log
    Code:
    [root@neo tmp]# cat install.log.19485
    COMMAND: zmlocalconfig -s | sed -e "s/ = \(.*\)/=\'\1\'/" > /opt/zimbra/.saveconfig/config.save
    -bash: zmlocalconfig: command not found
    COMMAND: zmcontrol shutdown
    -bash: zmcontrol: command not found
    Preparing packages for installation...
    zimbra-core-4.5.0_GA_612.RHEL4-20070115195939
    mkdir: cannot create directory `/opt/zimbra/ssl': File exists
    Loading classes to share ... done.
    Rewriting and unlinking classes ... done.
    Calculating hash values for String objects .. done.
    Calculating fingerprints ... done.
    Removing unshareable information ... done.
    Moving most read-only objects to shared space at 0x90be0000 ... done.
    Moving common symbols to shared space at 0x90f5c4f0 ... done.
    Moving remaining symbols to shared space at 0x91088280 ... done.
    Moving string char arrays to shared space at 0x91088d10 ... done.
    Moving additional symbols to shared space at 0x9110a7b8 ... done.
    Read-only space ends at 0x9115eaf8, 5761784 bytes.
    Moving read-write objects to shared space at 0x913e0000 ... done.
    Moving String objects to shared space at 0x91969c50 ... done.
    Read-write space ends at 0x919a9d78, 6069624 bytes.
    Updating references to shared objects ... done.
    
    Preparing packages for installation...
    zimbra-ldap-4.5.0_GA_612.RHEL4-20070115195939
    Preparing packages for installation...
    zimbra-logger-4.5.0_GA_612.RHEL4-20070115195939
    Preparing packages for installation...
    zimbra-mta-4.5.0_GA_612.RHEL4-20070115195939
    umount2: Invalid argument
    umount: /opt/zimbra/amavisd/tmp: not mounted
    mv: cannot stat `/opt/zimbra/amavisd': No such file or directory
    chown: changing ownership of `/opt/zimbra/mysql': No such file or directory
    chown: changing ownership of `/opt/zimbra/snmp': No such file or directory
    chown: cannot access `/opt/zimbra/perdition-1.17': No such file or directory
    Preparing packages for installation...
    zimbra-snmp-4.5.0_GA_612.RHEL4-20070115195939
    Preparing packages for installation...
    zimbra-store-4.5.0_GA_612.RHEL4-20070115195939
    Preparing packages for installation...
    zimbra-apache-4.5.0_GA_612.RHEL4-20070115195939
    Preparing packages for installation...
    zimbra-spell-4.5.0_GA_612.RHEL4-20070115195939
    These are the errors I saw while watching the upgrade process
    Code:
    Backup LDAP
    bdb_db_open: unclean shutdown detected; attempting recovery.
    bdb_db_open: Recovery skipped in read-only mode. Run manual recovery if errors are encountered.
    
    ....skipped
    
    Restoring existing configuration file from /opt/zimbra/.saveconfig/config.save...done
    chown: cannot access `/opt/zimbra/conf/smtpd.key': No such file or directory
    chown: cannot access `/opt/zimbra/conf/smtpd.crt': No such file or directory
    
    ....skipped
    
    Starting LDAP
    ERROR: service.FAILURE (system failure: getDirectContext) (cause: javax.naming.CommunicationException localhost:389)
    ....Bunches of these
    ERROR: service.FAILURE (system failure: getDirectContext) (cause: javax.naming.CommunicationException localhost:389)
    Done
    Lastly, I haven't finished the zmsetup.pl of the upgrade yet because I have a ton of UNSET, items that I'm not even sure what they should be set to.
    Showing on the the UNSET...
    Code:
    ******* +Spam training user:                   UNSET
    ******* +Non-spam(Ham) training user:          UNSET
    ******* +Web server HTTP port:                 UNSET
    ******* +Web server HTTPS port:                UNSET
    ******* +IMAP server port:                     UNSET
    ******* +IMAP server SSL port:                 UNSET
    ******* +POP server port:                      UNSET
    ******* +POP server SSL port:                  UNSET

  6. #6
    jholder's Avatar
    jholder is offline Former Zimbran
    Join Date
    Oct 2005
    Location
    Thatcher, AZ
    Posts
    5,606
    Rep Power
    20

    Default

    Yeah, don't finish it. CTRL C
    and
    cat /etc/hosts
    looks like your hosts file is not set up.

  7. #7
    Isbeorn is offline Junior Member
    Join Date
    Mar 2007
    Posts
    9
    Rep Power
    8

    Default

    [root@neo zcs]# cat /etc/hosts
    # Do not remove the following line, or various programs
    # that require network functionality will fail.
    127.0.0.1 localhost.usethesource.org localhost
    67.18.241.171 neo.usethesource.org neo
    67.18.241.173 mail.usethesource.org mail

  8. #8
    jholder's Avatar
    jholder is offline Former Zimbran
    Join Date
    Oct 2005
    Location
    Thatcher, AZ
    Posts
    5,606
    Rep Power
    20

    Default

    Go ahead and take a trip over to the wiki, and fix the hosts file.

    Then try ldap start, and tell me what you get.

  9. #9
    Isbeorn is offline Junior Member
    Join Date
    Mar 2007
    Posts
    9
    Rep Power
    8

    Default

    Yeah, I just noticed the localhost.usethesource.org part myself. In one of my previous attempts (before posting on the forums) I had fixed that. But in my random attempts to get everything as it was I cp'd my old /etc/hosts from my old zimbra server over the correct one. With the thought that it was all working with this file before.

    Ok, so right now my /etc/hosts looks like this
    127.0.0.1 localhost.localdomain localhost

    and thats it.

    I su'd to the zimbra user and ran 'ldap start' I get this

    ldap_url and ldap_master_url cannot be the same on an ldap replica

  10. #10
    jholder's Avatar
    jholder is offline Former Zimbran
    Join Date
    Oct 2005
    Location
    Thatcher, AZ
    Posts
    5,606
    Rep Power
    20

    Default

    so it looks like the localconfig got wiped and we're gonna need to restore it.
    If this doesn't work, then we're gonna have to build the config, and reset all of your mysql and ldap passwords:

    Do all as root:
    rm-rf /opt/zimbra/.saveconfig
    rsync -avr /old/opt/zimbra/.saveconfig /opt/zimbra
    rm -rf /opt/zimbra/conf/localconfig.xml
    rsync -av /old/opt/zimbra/conf/localconfig.xml /opt/zimbra/conf
    chown -R zimbra:zimbra /opt/zimbra
    cd /opt/zimbra/libexec
    ./zmfixperms
    ./zmsetup.pl

Page 1 of 2 12 LastLast

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. initializing ldap...FAILED(256)ERROR
    By manjunath in forum Installation
    Replies: 39
    Last Post: 06-07-2013, 10:27 AM
  2. Zimbra fails after working for 2 weeks
    By Linsys in forum Administrators
    Replies: 10
    Last Post: 10-07-2008, 12:42 AM
  3. need advice on configuring zimbra to work with fax server
    By pheonix1t in forum Administrators
    Replies: 0
    Last Post: 07-11-2007, 07:46 PM
  4. 3 testing: LDAP: 389 Failed when restore zimbra
    By victorLeong in forum Administrators
    Replies: 15
    Last Post: 05-24-2007, 06:45 AM
  5. Error 256 on Installation
    By RuinExplorer in forum Installation
    Replies: 5
    Last Post: 10-19-2006, 09:19 AM

Posting Permissions

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