Results 1 to 8 of 8

Thread: Exporting email accounts

  1. #1
    Registered User
    Join Date
    Sep 2008
    Posts
    2

    Default Exporting email accounts

    Hi there, I would like to find out how to export the whole mail account from a specific domain. Meaning

    abc.com > MAIL accounts > x@abc.com, r@abc.com, s@abc.com a@abc.com g@abc.com

    Exporting the full account info including the passwords.

    I want to migrate to another better cpanel based hosting but do not want users to go through the trouble of changing their mail passwords and settings of their mail clients. The mentioned account is an add on domain in cpanel.

    Anyone care to advice please?

  2. #2
    Technical Product Specialist cPanelDavidG's Avatar
    Join Date
    Nov 2006
    Location
    Houston, TX
    Posts
    11,289
    cPanel Access Level

    Root Administrator

    Default

    Quote Originally Posted by bronwerkz View Post
    Hi there, I would like to find out how to export the whole mail account from a specific domain. Meaning

    abc.com > MAIL accounts > x@abc.com, r@abc.com, s@abc.com a@abc.com g@abc.com

    Exporting the full account info including the passwords.

    I want to migrate to another better cpanel based hosting but do not want users to go through the trouble of changing their mail passwords and settings of their mail clients. The mentioned account is an add on domain in cpanel.

    Anyone care to advice please?
    If this is part of a migration process of moving an entire cPanel account from one server to another, just make a full site backup and have your new hosting provider restore this backup. This will back up all data (including email, email accounts, passwords etc.) and will make the migration to the new server very easy.

  3. #3
    Registered User
    Join Date
    Sep 2008
    Posts
    2

    Default

    Hey david thank you for your reply but sadly no, this is not a full cpanel account migration. I just need to move one of the add on domain name under the main account to another shared hosting provider.

    Anyway i can do the mail account migration on the add on domain?

  4. #4
    Registered User
    Join Date
    Apr 2011
    Posts
    1

    Default Re: Exporting email accounts

    Has anyone figured out how to do this? My cPanel host cannot help me and has told me to write a PHPscript... Nice one! I need to move email addresses, plus passwords etc. to a new server. Thanks!

  5. #5
    Technical Product Specialist cPanelDavidG's Avatar
    Join Date
    Nov 2006
    Location
    Houston, TX
    Posts
    11,289
    cPanel Access Level

    Root Administrator

    Default Re: Exporting email accounts

    Quote Originally Posted by cliffvt View Post
    Has anyone figured out how to do this? My cPanel host cannot help me and has told me to write a PHPscript... Nice one! I need to move email addresses, plus passwords etc. to a new server. Thanks!
    You are just moving email accounts, not an entire cPanel account? Are you moving to another server running cPanel&WHM?

  6. #6
    cPanel Staff cPanelJared's Avatar
    Join Date
    Feb 2010
    Location
    Houston, TX
    Posts
    1,815
    cPanel Access Level

    Root Administrator

    Default Re: Exporting email accounts

    E-mail account usernames and passwords are stored in files named passwd and shadow in the following directory structure:

    /$HOME/$USER/etc/$DOMAIN/

    where:

    • $HOME is the actual account home directory;
    • $USER is the cPanel account user, and;
    • $DOMAIN is the actual domain in question.

    Passwords are stored in shadow in this directory in salted MD5 format. There is no way to make them human-readable, but the file can be copied and the passwords will still work.

    The actual mailboxes are stored in the following format:

    /$HOME/$USER/mail/$DOMAIN/$MAILBOX

    where $MAILBOX is the name of the mailbox user as defined in cPanel. $MAILBOX is a directory containing all of the files related to the actual mail account data.

    You can copy the files and directories from the etc and mail directories from one cPanel account to another, or from one server to another. Make sure to apply the ownerships of the destination account to the files and directories. Also, make sure to move the following files out of the way before logging into cPanel on the destination account:

    /$HOME/$USER/.cpanel/email_accounts.cache
    /$HOME/$USER/.cpanel/email_accounts.yaml


    These files will automatically be created when you log into cPanel.
    For hands-on assistance, please reference our new support information page: Where should I go for support?
    cPResources: Support Options - Submit a ticket here - Additional Support Options - Forums Search - Mailing Lists(Alt) - Documentation - Find cPanel hosting


    -- Jared Ryan, Technical Analyst, cPanel Technical Support

  7. #7
    Registered Member
    Join Date
    Mar 2011
    Posts
    5

    Default Re: Exporting email accounts

    can you explain more details about this part?
    Quote Originally Posted by cPanelJared View Post
    Make sure to apply the ownerships of the destination account to the files and directories.

  8. #8
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel Access Level

    Root Administrator

    Default Re: Exporting email accounts

    The files should be owned by username:mail for /$HOME/$USER/mail/$DOMAIN/$MAILBOX path, so something like:

    Code:
    cd /$HOME/$USER/mail/$DOMAIN/
    chown -R username:mail $MAILBOX
    Where /$HOME is where you have your /home directory (normally, this is just /home itself), $USER is the cPanel username, $DOMAIN is the domain name, and $MAILBOX is the email account username.
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

Similar Threads

  1. Exporting list of CPanel email accounts
    By albatroz in forum E-mail Discussions
    Replies: 1
    Last Post: 06-23-2014, 11:49 AM
  2. Exporting email addresses from the Newslist
    By Jeger in forum E-mail Discussions
    Replies: 0
    Last Post: 03-11-2007, 11:17 AM
  3. exporting report
    By jhcs in forum General Discussion
    Replies: 1
    Last Post: 09-10-2005, 02:46 PM
  4. Exporting Packages
    By russellhosting in forum General Discussion
    Replies: 2
    Last Post: 04-10-2005, 07:47 AM
  5. Replies: 3
    Last Post: 01-05-2005, 12:39 AM
bargain