7 Replies Latest reply: Mar 2, 2013 1:17 AM by globalmark9129
Paul Spiller Level 1 Level 1 (5 points)

I am running Lion 10.7.2 and mail 5.1 (all software updates applied)

 

I know there is a fair bit referencing similar problems but I cannot find my solution.

I inadvertantly deleted a mail account and simply wish to restore the account from my time machine backups.

Time machine has been reliable in the past and my put my faith in it.  However this problem now introduces a fair bit of mistrust which should never happen with a backup system.

 

I navigate to ~/library/Mail/V2 and then open time machine and select a known good backup (I hope).

I highlight the time machine account folder I want to restore and select "restore".

Time machine starts the restore normally but very quickly comes up with this mesage -

 

"The operation can’t be completed because you don’t have permission to access “.mboxCache.plist”.

 

(I am logged on as admin)

 

I have repaired permission on my HD to no avail.

I assume that the message refers to the time machine file but any attempt at changing permisions on the time machine backups fails as "not permitted" (I would not be surprised at this anyway as I dont know how the time machine file system works).

 

I then copied my complete mail folder to another disk and deleted the original and tried to restore the complete mail folder from the time machine backup.

A similar permissions error message occurs but on a different file.

 

I am getting nowhere and am rapidly losing faith in time machine - I totally rely on it.

Can anyone help please.


imac Intel Core 2 Duo, Mac OS X (10.5.8)
  • Rob Gendreau Level 1 Level 1 (115 points)

    How did you repair permissions? Disk Utility? That won't do it on user files, which might include the stuff you're having problems with.

     

    You might try resetting to defaults if you haven't already.

     

    http://osxdaily.com/2011/11/15/repair-user-permissions-in-mac-os-x-lion/

     

    Rob

  • Pondini Level 8 Level 8 (38,720 points)

    If you deleted the account from Mail Preferences, restore the <home folder>/Library/Preferences/com.apple.Mail.plist file.

     

    Then try the special handling for Mail and Time Machine backups.  See the blue box in Time Machine - Frequently Asked Question #15.

  • Paul Spiller Level 1 Level 1 (5 points)

    Yes I did use disk utility - I was not aware of the process you mention.  Thanks for the reply, I need to do a bit of reading ref Lion.

    I followed the procedure but alas it did not resolve the issue - I still get the same error message.

    The problem seems to idicate that I cannot access the plist file on the time machine backups.

  • Paul Spiller Level 1 Level 1 (5 points)

    I deleted the account using mail preferences, so following your advise:

     

    I restored the pref file from the good known backup date.

     

    I also used disk utility to repair the time machine backup volume which showed no problems.

     

    First of all, restoring from time machine according to FAQ 15, the actual messages in the deleted account were indeed restored to the new mailbox that time machine created and could be viewed - that is fine and solves the problem of lost mail.

     

    Almost solved - but what I was trying to do was :

    I had two accounts which show under inbox and when you "get mail" the little whirling indicator shows activity which my wife (and I) liked.  After I deleted the second (now unused account) there is no more indicator when "getting mail" and it is not obvious that anything is actually happening.  Any mail received will show up under mail activity but if there is none we all just sit there with no feedback until it "beeps".

    There was also the other issue of maybe wanting to get back all mail for the deleted account (which you solved).

     

    I can of course recreate the account as a new one but I thought time machine would be able to restore the mail system back to where it was (as it should) - it seems it may not be able to which is not nice as in "what else will fail one day that I dont know about".  To restore "as was" is why I tried to restore just the "missing" folder in ~/library/mail/v2 but keep running into these permission problems. 

     

    Time machine was the best backup system I have seen in over 30 years in computing but if it now "doesnt" under all circumstances it becomes useless and we will have to go back to manual or other backup systems. Surely Apple will fix it - a backup and restore system has to completely reliable or not at all.

     

    I thank you for your help  and, as I say, there is no real urgency as mail items can actually be recovered - it would be nice to be able to restore "as it was" however.

  • Paul Spiller Level 1 Level 1 (5 points)

    An update to this post for anyone interested.

     

    After searching this "support" site for similar problems and after attempting to alter the time machine backup directory permissions with chmod to no avail with the following error message for just about everthing :

    "chmod: Unable to change file mode on <directory name>: Operation not permitted"  (I suspect that this is because of the time machine backup structure but dont know)

     

    I tried copying the "lost" directory using terminal with a simple "cp -R <directory path on time machine backup> to my desktop (for convenience only), then to the "mail" folder.  This worked with no problems.  (ack to some post I got this simple approach from - I lost the thread)

     

    I then used time machine facility to restore the "mail/V2/maildata/Accounts.plist" file which worked fine.

     

    Lo and behold mail is now as it was (I sincerly hope).

     

    Maybe all I needed to do was restore the accounts.plist file but not sure and I am not revisiting this to find out.

     

    It still raises the horrible thought that tme machine is a "bit" broken - one should be able to restore anything from a backup, otherwise its not a backup.  I hope Apple fix this.

     

    Regards

  • ADub128 Level 1 Level 1 (0 points)

    Thanks for the detailed summary. I agree, restoring from Time Machine is not straightfoward unless you are just grabbing a work file you accidentally deleted. For more complicated scenarios, it takes a lot of Googling unfortunately.

  • globalmark9129 Level 1 Level 1 (0 points)

    Hi Paul

     

    I have this Exact Same problem , want to restore my V2 folder but have the same permissions problem

    Can you let me know what you did step by step , with the cp -R etc as I dont really follw what you wrote above .

    I have used Terminal a couple times but really have no idea what I am doing so would be great if you can tell me step by step the Copying process and finally how you restored it .

     

    Thanks in Advance

    Mark