Skip navigation

Procedure needed to recover user data for mail, ical, files etc.

1112 Views 9 Replies Latest reply: Apr 18, 2013 4:43 PM by cavalieredona RSS
jheipmann Calculating status...
Currently Being Moderated
Jan 21, 2012 4:19 PM

Dear community

 

Due to bad luck combined with stupidity and laziness I lost my open directory master, and therefore also all network users (and yes, the back up of OD I did, but that file is corrupted), so that I end up recreating users in the OD.  That by itself is not that bad, but the potential loss of data is. To be more precise, currently I am not able to recover the Mailboxes, and specifically for about 10 iPad/iPhone only users, I have no chance to recover them from a time machine backup. So here goes my questions:

 

1.) Is there a way to copy / import from the old user id to the new one for Mail (Dovecot) ?

Simply copying the files from the old subdirectory to the new one does not work (seems to be secondary permissions), and I did not have any success by using doveadm tools.

 

2.) Same goes for iCal and Contacts server?

Any suggestions? Haven't tried those yet.

 

3.) For Home Directories including Mobile users homes I think copying the data and doing a chmod should be sufficient

Clearly the clients would have to delete their mobile homes first and then sync back, but in any case here I could use the TM backups in worst case.

 

 

 

So, can anyone point me in the right direction especially for the mail folders?

 

Thanks in advance

 

jheipmann

Mac OS X (10.7.2), Lion Server
  • Twistan Level 1 Level 1 (5 points)

    Hi,

    I noticed this typo

     

    # psql -U _postgres -d caldav -f /Library/Server/PostgreSQL/Backup/caldav.sql

     

    as well !

     

    Well spotted !

     

    Regards,

    Twistan

     

    P.S.

    One of my users can longer log in to his iCal account. I do not know how this happened but I remember that I deleted a jointly used iCal account (I mean an account that was used by all) and that that user, who can no longer log-in to his iCal account, had delegation status for that deleted account.

    I do not know of this is imprtant. I am by no means a postgrep or server expert. Just an experienced and seasoned physicist and mathematician.

     

    I think I shall delete the old server account and create a new one for that user. I don't know if that deletes any contributions to Wiki pages by that user.

     

    Apple have made trouble-shooting very difficult for Lion server that "everyone" can set-up but not administer properly.

  • delmod Level 1 Level 1 (0 points)

    I'm in a similar situation. I need to restore my wiki after a clean installation. Let me see if I have understood:

    1. First I need to restore the dumpall.psql.gz archive with Time Machine
    2. Second in Terminal: # psql -U _postgres -d collab -f /Library/Server/PostgreSQL/Backup/collab.sql

     

    Is it necesary do something with the folders "Collaboration" and "Wiki"?

     

    Thanks in advance for your help.

  • Twistan Level 1 Level 1 (5 points)

    Hi Joern,

    thanks for that. I took the gamble and I simply deleted and re-defined the user's account (same short name and password). User had iCal working again imediately.

    The user's Wiki read and write ACL's did not work but I found a group (very strange) with the user's name which I deleted as well and now all is fine again.

    By the way, the user's wiki entries were not deleted as I had feared.

     

    Regards/Gruss,

    Twistan

  • Twistan Level 1 Level 1 (5 points)

    Hi,

    please refer to

    http://hints.macworld.com/article.php?story=20120204035901957

     

    In my (lay) view you have to dump (back up) all individual databases first:

     

    $ sudo -s

    PGUSER=_postgres /usr/bin/pg_dump -U _postgres collab -Fc -f /Library/Server/PostgreSQL/Backup/collab.sql > /dev/null 2>&1

     

    Only if you done that can you restore using the second command


    # psql -U _postgres -d collab -f /Library/Server/PostgreSQL/Backup/collab.sql


    But I could be mistaken.

     

    Regards,

    Twistan

  • delmod Level 1 Level 1 (0 points)

    What about to restore the complete database?:

    • First restore the dumpall.psql.gz archive with Time Machine
    • Second in Terminal:¿¿¿???

     

    Thanks

  • Twistan Level 1 Level 1 (5 points)

    Hi,

    good question, but I do not know the answer.

    Maybe someone more knowledgable can answer this ?

     

    Regards,

    Twistan

  • cavalieredona Calculating status...

    Please Joern, I am now in your same trouble you were last year but a newbie and I need to know how to type chown -r _dovecot . I mean I guess by terminal. I open it and type only this?

     

    Besides, how can I copy the all contents? I go in data mail and I just make a copy and paste into the new folder?

     

    Thank you for your help.

     

    Best Regards

     

    Donatello

Actions

More Like This

  • Retrieving data ...

Bookmarked By (1)

Legend

  • This solved my question - 10 points
  • This helped me - 5 points
This site contains user submitted content, comments and opinions and is for informational purposes only. Apple disclaims any and all liability for the acts, omissions and conduct of any third parties in connection with or related to your use of the site. All postings and use of the content on this site are subject to the Apple Support Communities Terms of Use.