Import Path Problems
Results 1 to 9 of 9
Like Tree2Likes
  • 1 Post By ken.munkholm
  • 1 Post By newmember

Thread: Import Path Problems

  1. #1
    Active Member
    Join Date
    Dec 2012
    Posts
    4

    Import Path Problems

    Hello,
    I am trying to migrate from zimbra 7.x to 8.0.6. OS = 8.04 to 12.04, both X64, on separate VM's
    Zextras version is 1.8.12
    Chrome browser 32.0.1700.107m is being used.

    I have a remote disk on a third VM that I attached with NFS to the source machine

    I managed to perform the export migration without much trouble. Something to note is that the target export directory must be *completely* empty. Delete the Lost+found directory if it exists.

    I have detached the remote disk from the source machine and attached to the target machine.
    On the target installation (8.0.6) the backup path is set to /opt/zimbra/backup/. The target machine has been backing up it's admin account to this directory for a couple of weeks.

    The remote disk is attached to:
    /opt/zimbra/backup/zextras/
    As user zimbra on the target machine, when in the directory of /opt/zimbra/backup/zextras/, I can touch a file, modify it's contents, and delete it. indicating to me that user zimbra has r/w access.

    On the target machine, from within the admin console, I navigate to the Zextras menu, select ZxBackup, click the Import Backup button.
    It asks for a Source Path.
    I enter:
    /opt/zimbra/backup/zextras/
    Click next and a dialog box pops up "Please select a valid import path."

    Very similar to this guy
    http://forums.zextras.com/zextras-mi...ems-stuck.html

    My zextras/ directory is noboby:nobody but has permissions of drwxrwxrwx

    I believe this is a permissions issue, but I can't figure it out.
    Must the source import directory be specifically owned by zimbra:zimbra?

    Ken.

  2. #2
    ZeXtras Community Manager ZeXtras Employee Cine's Avatar
    Join Date
    Apr 2011
    Posts
    2,342
    Hello Ken,
    welcome to the forums!

    Could you please post the output of the following commands?

    Code:
    zxsuite backup getBackupInfo backup_path /opt/zimbra/backup/zextras/
    and
    Code:
    zxsuite backup getBackupInfo backup_path /opt/zimbra/backup/
    Have a nice day,
    Cine
    IT Support Team Contact Form
    Sales Team Contact Form

    ZeXtras Website
    # ZeXtras Wiki # ZeXtras Store

    Have ZeXtras Suite or ZeXtras Migration Tool been helpful to you?
    Share your experience in the Zimbra Gallery!

    ZeXtras Suite on the Zimbra Gallery
    ZeXtras Migration Tool on the Zimbra Gallery

  3. #3
    Active Member
    Join Date
    Dec 2012
    Posts
    4
    Cine,
    Thanks for your reply.
    Results attached.
    Further investigation shows that the zimbra user has different UID and GID numbers between the systems.
    New VS Old
    999 VS 1001 UID
    999 VS 1004 GID

    I believe I can force a change of UID/GID through the NFS export if this is necessary.


    Code:
    zimbra@mail2:~$ zxsuite backup getbackupinfo backup_path /opt/zimbra/backup/zextras/                                                                                   
    
            exists                                              true
            readable                                            true
            valid                                               false
            empty                                               true
            lockok                                              true
            writable                                            true
            caseSensitive                                       true
            backupStat
                fullScan
                    firstZeXtrasBuild                                           d9c37ee146f9127226615a9272e1b60088cb8a35
                    firstZeXtrasVersion                                         1.8.12
                    firstZimbraVersion                                          8.0.6
                smartScan
                    firstZeXtrasBuild                                           d9c37ee146f9127226615a9272e1b60088cb8a35
                    firstZeXtrasVersion                                         1.8.12
                    firstZimbraVersion                                          8.0.6
            dataPath                                            /opt/zimbra/backup/zextras/
    Code:
    zimbra@mail2:~$ zxsuite backup getbackupinfo backup_path /opt/zimbra/backup/
    
    
            exists                                              true
            readable                                            true
            valid                                               true
            empty                                               false
            lockok                                              true
            writable                                            true
            caseSensitive                                       true
            backupStat
                fullScan
                    firstZeXtrasBuild                                           d9c37ee146f9127226615a9272e1b60088cb8a35
                    firstZeXtrasVersion                                         1.8.12
                    firstZimbraVersion                                          8.0.6
                    backupPath                                                  /opt/zimbra/backup/
                    lastSuccessful                                              Success
                    firstScan                                                   2014-02-10 15:21:30 PST
                    lastScan                                                    2014-02-10 15:21:30 PST
                    lastZeXtrasBuild                                            d9c37ee146f9127226615a9272e1b60088cb8a35
                    lastZeXtrasVersion                                          1.8.12
                    lastZimbraVersion                                           8.0.6
                    numTotalAccounts                                            8
                    numBackuppedAccounts                                        0
                    numActiveBackuppedAccounts                                  8
                    numDeletedAccounts                                          0
                    numDeletedItems                                             0
                    numPurgedFiles                                              0
                    numPurgedItems                                              0
                    numPurgedAccounts                                           0
                    numZimbraItems                                              456
                    numBackuppedItems                                           456
                    numItemsPerSecond                                           34.131935
                smartScan
                    firstZeXtrasBuild                                           d9c37ee146f9127226615a9272e1b60088cb8a35
                    firstZeXtrasVersion                                         1.8.12
                    firstZimbraVersion                                          8.0.6
                    backupPath                                                  /opt/zimbra/backup/
                    lastSuccessful                                              Success
                    firstScan                                                   2014-02-10 15:21:33 PST
                    lastScan                                                    2014-02-11 04:01:02 PST
                    lastZeXtrasBuild                                            d9c37ee146f9127226615a9272e1b60088cb8a35
                    lastZeXtrasVersion                                          1.8.12
                    lastZimbraVersion                                           8.0.6
                    numTotalAccounts                                            8
                    numBackuppedAccounts                                        8
                    numActiveBackuppedAccounts                                  8
                    numDeletedAccounts                                          0
                    numDeletedItems                                             0
                    numPurgedFiles                                              0
                    numPurgedItems                                              0
                    numPurgedAccounts                                           0
                    numBackuppedItems                                           8
            dataPath                                            /opt/zimbra/backup/
    Ken.

  4. #4
    ZeXtras Community Manager ZeXtras Employee Cine's Avatar
    Join Date
    Apr 2011
    Posts
    2,342
    Hello Ken!

    The output of the first command shows that the backup path is not considered as "valid". This check is done by trying to read the "backupstat" file within the export path, so the file is probably missing or unreadable.

    First thing, fix the UID/GID difference and retry.

    If this doesn't work please:
    - make sure that the /opt/zimbra/backup/zextras/backupstat file exists and is readable by the 'zimbra' user.
    - make sure that the export operation you ran on the source server has been completed successfully.
    - make sure that the "Operation Completed" notification about the export does not report any error.

    Have a nice day,
    Cine
    the ZeXtras Team
    IT Support Team Contact Form
    Sales Team Contact Form

    ZeXtras Website
    # ZeXtras Wiki # ZeXtras Store

    Have ZeXtras Suite or ZeXtras Migration Tool been helpful to you?
    Share your experience in the Zimbra Gallery!

    ZeXtras Suite on the Zimbra Gallery
    ZeXtras Migration Tool on the Zimbra Gallery

  5. #5
    Active Member
    Join Date
    Dec 2012
    Posts
    4
    Cine,
    Thank you for your help.
    My problem was a permissions issue. The zextras directory had 777 permissions, but the items in it did not.

    For the benefit of others...
    What is below worked for me. I do not have an in-depth knowledge of NFS, permissions, and so on. There are errors and assumptions. Correct as necessary.

    On my old zimbra server, user zimbra had a UID of 1001 and a GID of 1004
    On the new zimbra server, user zimbra had a UID of 999 and a GID of 999

    Files written with user:group of 1001:1004 couldn't be read by 999:999

    I changed the way NFS exported my ferry store.

    In my /etc/exports file, this line:
    /export 10.0.0.0/24(rw,fsid=0,insecure,no_subtree_check,async)
    preserves UID and GID values.

    Changing it to this:
    /export 10.0.0.0/24(rw,fsid=0,insecure,no_subtree_check,async,all_s quash,anonuid=1001,anongid=1004)
    forces all reads and writes to UID1001 and GID1004

    This info was gleaned from:
    linux - How to properly set permissions for NFS folder? Permission denied on mounting end. - Server Fault
    Thank you sciurus.

    Forcing the UID/GID seems to slow things down. I am waiting to see how long it will take to restore 54gb...

    Ken.
    Cine likes this.

  6. #6
    ZeXtras Community Manager ZeXtras Employee Cine's Avatar
    Join Date
    Apr 2011
    Posts
    2,342
    Hello Ken!

    I'm really glad you made it, thank you for sharing your knowledge!

    Have a nice day,
    Cine
    IT Support Team Contact Form
    Sales Team Contact Form

    ZeXtras Website
    # ZeXtras Wiki # ZeXtras Store

    Have ZeXtras Suite or ZeXtras Migration Tool been helpful to you?
    Share your experience in the Zimbra Gallery!

    ZeXtras Suite on the Zimbra Gallery
    ZeXtras Migration Tool on the Zimbra Gallery

  7. #7
    Active Member
    Join Date
    Dec 2012
    Posts
    4
    Cine,
    My zxbackup >>import backup process died at about 11 hours.
    The backup data was about 54gb in size. At 11 hours, the restore was at about 44/50 accounts complete.
    My /opt volume, 184gb is size was full.

    I initiated an HSM session to move data from /opt to /hsm1. As I check the volumes next day, the /hsm1 volume has 54gb on it and the /opt volume is back to 42gb used.

    Reviewing the Server>>Volumes setting, hsm1 is set to compress blobs, the primary message store is not.

    I think if I were doing this again from scratch, I would restore some accounts, initiate HSM, restore some more, HSM, etc.

  8. #8
    ZeXtras Community Manager ZeXtras Employee Cine's Avatar
    Join Date
    Apr 2011
    Posts
    2,342
    Quote Originally Posted by ken.munkholm View Post

    I think if I were doing this again from scratch, I would restore some accounts, initiate HSM, restore some more, HSM, etc.
    Hello Ken!
    This is not needed, as you can force ZeXtras Backup to automatically apply all HSM policies after each mailbox has been fully restored ("Apply HSM" checkbox in the last step of the Import Wizard)...

    Have a nice day,
    Cine
    the ZeXtras Team
    IT Support Team Contact Form
    Sales Team Contact Form

    ZeXtras Website
    # ZeXtras Wiki # ZeXtras Store

    Have ZeXtras Suite or ZeXtras Migration Tool been helpful to you?
    Share your experience in the Zimbra Gallery!

    ZeXtras Suite on the Zimbra Gallery
    ZeXtras Migration Tool on the Zimbra Gallery

  9. #9
    Active Member
    Join Date
    Jan 2014
    Posts
    5
    Just some notes on the steps to change the zimbra UserID.

    usermod -u <NEWUID> <LOGIN>
    groupmod -g <NEWGID> <GROUP>
    find / -user <OLDUID> -exec chown -h <NEWUID> {} \;
    find / -group <OLDGID> -exec chgrp -h <NEWGID> {} \;
    usermod -g <NEWGID> <LOGIN>

    Change from 999 to 1001 steps:

    usermod -u 1001 zimbra
    groupmod -g 1001 zimba
    groupmod -g 1001 zimbra
    find / -user 999 -exec chown -h 1001 {} \;
    find / -group 999 -exec chgrp -h 1001 {} \;
    usermod -g 1001 zimbra


    Hope this helps the next person.

    Cheers
    Cine likes this.

Bookmarks

Posting Permissions

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