Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Restoring a legacy backup for one user?

Discussion in 'E-mail Discussion' started by peter-wetink, Dec 16, 2013.

  1. peter-wetink

    peter-wetink Member

    Joined:
    Dec 16, 2013
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi all, I am a little new to this so please be gentle :)

    I have recently had a user accidentally delete all of her mail apart from around 30 unread messages from her inbox.

    I didn't set our WHM server up but have discovered that it is using the legacy backup system, I pulled all of the emails out of her monthly personal folder (/home/backup/cpbackup/monthly/account name/homedir/mail/domain/email account) and FTP'd them to my local machine.

    I know that all of the mails are stored in the /cur folder but these files are named in a VERY different way to those that are in her live inbox; for instance:

    Live server file name
    102EGN~O

    Backup file name
    1314785483.H165746P19453.servername.co.uk,S=23635/2,Sb

    Am I OK just to merge the folders (only adding new or files with different file names) or do I have do something to else to put the old emails into her inbox?

    Thanks in advance
     
  2. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,802
    Likes Received:
    1,895
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello :)

    The format used in the file names from the backup archive look like the standard format used with maildir. Assuming you are not using a custom mail server, you can restore those files to the appropriate directory. You may also want to run the following command after moving the files:

    Code:
    /scripts/mailperm $username
    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. peter-wetink

    peter-wetink Member

    Joined:
    Dec 16, 2013
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Thanks Michael,

    For my total clarification when you say "restore" do you mean I can just FTP these files into her personal folder? I don't have to use any functionality of WHM to do so? I won't end up with duplicate mail or anything if I do so?
     
  4. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,802
    Likes Received:
    1,895
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Yes, you can upload the individual emails to the appropriate directory. Any files that already exist should prompt you with an overwrite notice.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. peter-wetink

    peter-wetink Member

    Joined:
    Dec 16, 2013
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Thanks Michael.

    I have copied the backup onto the server but have discovered a bit of a problem, I know have too many levels on inbox!

    Rather than just going:
    - Inbox
    - Sent
    - Folders

    I now have
    - Inbox
    - INBOX​
    - INBOX​
    - Deleted​
    - Deleted​
    - Junk​
    - Trash​
    - Sent

    Without folders, is there anyway that I can get the folder structure back to how it used to be?

    I ran the mailperm script as you said but it didn't flag anything up or make any sign this was an issue.
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice