Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Results 1 to 7 of 7
  1. #1
    Member
    Join Date
    Jun 2007
    Posts
    5

    Default Add email address using linux command line

    I'm trying to learn how to add an email address to an account at the linux operating system command line. I have search through the cPanel and red hat user guides without success. Can anyone point me in the right direction.

    Thanks,
    John

  2. #2
    cPanel Development cpanelkenneth's Avatar
    Join Date
    Apr 2006
    Posts
    3,768
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Quote Originally Posted by classywear View Post
    I'm trying to learn how to add an email address to an account at the linux operating system command line. I have search through the cPanel and red hat user guides without success. Can anyone point me in the right direction.

    Thanks,
    John
    /scripts/addpop

  3. #3
    Member
    Join Date
    Jun 2007
    Posts
    5

    Smile Thanks!

    Thanks!

  4. #4
    Registered User
    Join Date
    May 2009
    Posts
    3

    Default Add email address using linux command line

    Hello classywear!

    Now that you know how to create a new email account via command line do you know how to set up an email quota via command line?

    I really need to do this.

    Thanks in advance.

    Cheers.

    http://forums.cpanel.net/f4/command-...ss-119665.html

  5. #5
    Technical Product Specialist cPanelDavidG's Avatar
    Join Date
    Nov 2006
    Location
    Houston, TX
    Posts
    10,718
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Quote Originally Posted by cteinternet View Post
    Hello classywear!

    Now that you know how to create a new email account via command line do you know how to set up an email quota via command line?

    I really need to do this.

    Thanks in advance.

    Cheers.

    http://forums.cpanel.net/f4/command-...ss-119665.html
    We are currently working on adding a parameter to the /scripts/addpop script to allow you to set a quota. I have no ETA on when this functionality will become available in the production-worthy builds of cPanel/WHM, but it is currently available in our EDGE build (internal case 28422). Use of EDGE on production web servers is discouraged since EDGE only receives minimal quality testing.

  6. #6
    Member
    Join Date
    Jun 2009
    Posts
    14

    Default non-root add email account?

    Is there a way to get a non-root account to be able to setup an email account via ssh or shell_exec via a php script?

    Basically I want to be able to add a form in a password protected directory that will allow me to fill out a form to create the email account. Mainly it is for a business setup where multiple managers can setup email accounts for their divisions without cPanel access.

  7. #7
    Technical Product Specialist cPanelDavidG's Avatar
    Join Date
    Nov 2006
    Location
    Houston, TX
    Posts
    10,718
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Quote Originally Posted by gearheadhost View Post
    Is there a way to get a non-root account to be able to setup an email account via ssh or shell_exec via a php script?

    Basically I want to be able to add a form in a password protected directory that will allow me to fill out a form to create the email account. Mainly it is for a business setup where multiple managers can setup email accounts for their divisions without cPanel access.
    You could just use our APIs for creating an email account. Information about our XML API including how to call the cPanel API1 and API2 APIs from the XML API is available at: XML and JSON APIs

    The actual function call for creating an email account is an API1 function:

    Code:
    <cpanel Email="addpop($FORM{'email'},$FORM{'password'},$FORM{'quota'},$FORM{'domain'})">
    So, to call this from the XML API, you would use the cPanel function. Here's the relevant information for calling the API:

    API version: 1
    Module: Email
    Function: addpop
    First arg: the part of the email address before @
    Second arg: password for the email account
    Third arg: a number, specifying the quota for this mail account in MB
    Forth arg: the part of the email address after @

    Matt has made a nifty PHP 5 class that makes calling our APIs much easier if you're using PHP 5. You can find his class at: http://forums.cpanel.net/f42/xmlapi-...ss-111897.html

Similar Threads & Tags
Similar threads

  1. command line commands - creating and setting up a quota to an email address
    By cteinternet in forum cPanel and WHM Discussions
    Replies: 5
    Last Post: 07-09-2009, 03:12 PM
  2. Change Site's IP Address using command line
    By inteltechs in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 04-27-2007, 02:47 AM
  3. how to find large files using command line linux?
    By spaceman in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 08-29-2006, 01:22 AM
  4. Add on Modules from command line ???
    By linuxmav in forum cPanel and WHM Discussions
    Replies: 5
    Last Post: 01-04-2005, 04:52 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube