Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Include Page
_Version
_Version

Table of Contents
stylenone

Overview 

cPanel & WHM version 58 introduced Dovecot's mdbox format for mail storage.

We added the following scripts to allow you convert mailbox formats:

  • /usr/local/cpanel/scripts/convert_mdbox_to_maildir — Converts mailboxes from mdbox format to maildir format.
  • /usr/local/cpanel/scripts/convert_maildir_to_mdbox — Converts mailboxes from maildir format to mdbox format.

Call the script

To run either of the scripts at the command line, run one of the following commands as the root user:

Code Block
languagebash
linenumberstrue
/usr/local/cpanel/scripts/convert_mdbox_to_maildir [options]
/usr/local/cpanel/scripts/convert_maildir_to_mdbox [options]

Options

When you run either script, you can specify the following options:

Note
titleNote:

You must include either the --user= or the --email= option.

OptionDescriptionExample
--help

Displays the script's help message.

Code Block
languagebash
/usr/local/cpanel/scripts/convert_mdbox_to_maildir --help
/usr/local/cpanel/scripts/convert_maildir_to_mdbox --help
--userConvert a cPanel user and all of their email accounts.
Code Block
languagebash
/usr/local/cpanel/scripts/convert_mdbox_to_maildir --user=username
/usr/local/cpanel/scripts/convert_maildir_to_mdbox --user=username
--email

Convert a single email account.

Note
titleNote:

Use one of the following email account formats:

  • username@example.com
  • username
  • _mainaccount@example.com
Code Block
languagebash
/usr/local/cpanel/scripts/convert_mdbox_to_maildir --email=username@example.com
/usr/local/cpanel/scripts/convert_maildir_to_mdbox --email=username@example.com
--delete-old-formatRemove the old files after successful conversion.
Code Block
languagebash
/usr/local/cpanel/scripts/convert_mdbox_to_maildir --user=username --delete-old-format
/usr/local/cpanel/scripts/convert_maildir_to_mdbox --user=username --delete-old-format

Additional documentation

Localtab Group
Localtab
activetrue
titleSuggested documentation

Content by Label
showLabelsfalse
max5
showSpacefalse
cqllabel in ("email","dovecot") and label = "whm" and space = currentSpace()

Localtab
titleFor cPanel users

Content by Label
showLabelsfalse
max5
showSpacefalse
cqllabel in ("email","dovecot") and label = "cpanel" and space = currentSpace()

Localtab
titleFor WHM users

Content by Label
showLabelsfalse
max5
showSpacefalse
cqllabel in ("email","dovecot") and label = "whm" and space = currentSpace()

Localtab
titleFor developers

Content by Label
showLabelsfalse
max5
showSpacefalse
cqllabel in ("dovecot","email") and space = "SDK"