Koozali.org: home of the SME Server

Move AFFA usb hard drive to new sme server and restore from the usb drive

Offline tstokovaz

  • *
  • 23
  • +0/-0
I have complete backups using affa stored on a usb hard drive connected to our affa backup server. I need to restore an earlier monthly backup of our job "mailbackup" to a test server rather than back to the original system.  If I did it from the backup server I see the instructions of how to rise that server to the current backup on that server but I want to restore a point about a month ago before some strange things happened. And I want to do it on a machine that is not our backup server or our production server. I tried to figure out how but am lost in the options. My goal is to do some testing.

So far I created the new SME server and applied all updates. I also installed AFFA. Is there a way for affa to search the usb drive and find the jobs stored on it? I don't want to accidentally write over the backups I have.

The drives are set to automount at /media/usbdisk and the backup on the server is called mailbackup (our mail server).

Part of the problem is that when I do a list-archives with the usb drive on the backup server it lists the correct backups but when I go to the usbdisk and list the contents it shows something different. One of the backups shown in the list-archives doesn't show up at all on the actual usbdisk. It looks like the original backups are the very earliest I made.  I'm guessing because along the way I set the backup to automount? Or somehow the list-archives is not reporting what is actually there.


Offline m

  • ****
  • 276
  • +0/-0
  • Peet
I have complete backups using affa stored on a usb hard drive connected to our affa backup server. I need to restore an earlier monthly backup of our job "mailbackup" to a test server rather than back to the original system.  If I did it from the backup server I see the instructions of how to rise that server to the current backup on that server but I want to restore a point about a month ago before some strange things happened. And I want to do it on a machine that is not our backup server or our production server. I tried to figure out how but am lost in the options. My goal is to do some testing.

On your testserver setup a job mailbackup idendtical to that on your backup server but set property RootDir to /var/affa and property status to disabled. Connect the USB drive and copy the archive of  the job mailbackup to /var/affa. Then run affa --rise mailbackup ARCHIVE

Offline m

  • ****
  • 276
  • +0/-0
  • Peet
Forgot  to mention that Affa places job setup scripts into the archive directories. In your case it is mailbackup-setup.pl. Copy it to your testserver, change the RootDir and status properties and execute it.

Offline tstokovaz

  • *
  • 23
  • +0/-0
Re: Move AFFA usb hard drive to new sme server and restore from the usb drive
« Reply #3 on: November 19, 2008, 06:32:18 PM »
I've finally gotten time to work on this but when I move the usb drive to the test system, the drive isn't found. I've tried vgscan and it is  not found. Any suggestions?  It seems like I understood that AFFA uses a different approach. I'm searching and googling all I can but haven't found the solution yet.

Offline David Harper

  • *
  • 653
  • +0/-0
  • Watch this space
    • Workgroup Technology Solutions
Re: Move AFFA usb hard drive to new sme server and restore from the usb drive
« Reply #4 on: November 20, 2008, 06:04:32 AM »
Have you mounted the USB drive successfully?

e.g. mount /dev/sda1

Offline tstokovaz

  • *
  • 23
  • +0/-0
Restore from USB drive per Affa documentation not working - need help
« Reply #5 on: January 06, 2009, 05:11:31 PM »
Since this is a tip listed in Affa documentation, it may be helpful to explore the problem I have encountered. I did exactly as suggested and set up the new server identically to the old one, copied over my setup.pl fie to root from the archives and the archives to /var/affa. After the rise command was finished I could get to the webpage but NOT login to any of the users.  All the appropriate files seemed to be restored to their proper locations.

1. I CAN login to the root via putty.
2. I CAN login to the server-manager (even tried changing a password)
3. I CANNOT log into webmail as admin or any other user though they show in server-manager.
4. Quota page shows all mail amount as zero even though you can see the messages are there and contain information using the command line to go to /home/e-smith/files/users....

Is there a password file, SSL issue or such that is preventing me from validating a password? Somehow the server-manager doesn't seem to record the restored file sizes in the quota section.
« Last Edit: January 07, 2009, 04:01:42 PM by tstokovaz »