The domain utility is used to manage domains through CLI. By using this utility, you can perform the following tasks:
Syntax
domain <command> <domain name> [
<option_1> [<param>]
[<option_2> [<param>]]
…[<option_N> [<param>]]
Example
The following command line creates and enables domain example.com, assigns the ownership of the domain to an existing Plesk client with login clientlogin, assigns IP address 192.168.67.78 to the domain, enables physical hosting and DNS zone on the domain, sets login name ftpuserlogin and password ftpuserpass for the FTP user, and enables CGI and PHP support on the domain.
# ./domain --create example.com -clogin clientlogin -ip 192.168.67.78 -status enabled -hosting true -hst_type phys -dns true -login ftpuserlogin -passwd ftpuserpass -cgi true -php true
Commands
Ñommand |
Parameter |
Description |
Example |
|---|---|---|---|
|
|
Creates a new domain. Requires concomitant use of the |
To create new domain example.com for a client with login name clientlogin: # ./domain --create example.com -clogin clientlogin - ip 192.168.67.78 or # ./domain -c example.com -clogin clientlogin |
|
|
Updates configuration of an existing domain. |
To enable domain example.com: # ./domain -u example.com -status enabled |
|
|
Deletes an existing domain. |
To delete domain example.com: # ./domain --remove example.com or # ./domain -r example.com |
|
|
Displays information about configuration of a domain. |
To display configuration information about domain example.com: # ./domain --info example.com or # ./domain --i example.com |
|
|
Enables a domain. |
To enable domain example.com: # ./domain --on example.com |
|
|
Disables a domain. |
To disable domain example.com: # ./domain --off example.com |
|
|
Changes the owner of a domain. Requires concomitant use of the |
To make the client with login name clientlogin the owner of domain example.com: # ./domain --change-owner example.com -clogin clienlogin |
|
|
Displays the list of available shells on a domain. |
To display the list of shells available on the Plesk server: # ./domain --shells |
|
|
Displays help on the use of the utility. |
To display help on the use of the domain utility: # ./domain --help or # ./domain -h |
Options
Option |
Parameter |
Description |
Example |
|---|---|---|---|
|
|
Enables or disables a domain (the |
To enable domain example.com: # ./domain -u example.com -status enabled To assign the status of domain example.com to the status of the client account that owns it: # ./domain -u example.com -status parent |
|
|
Renames a domain. Used only with the |
To change the name of the domain example.com to newname.org: # ./domain -u example.com -new_name newname.org |
|
|
Enables or disables DNS zone for a domain. |
To enable DNS zone for domain example.com: # ./domain -u example.com -dns true To disable a DNS zone for domain example.com: # ./domain -u example.com -dns false |
|
|
Enables the www prefix option for Domain name. Set to |
To disable the www prefix option for domain name example.com: # ./domain -u example.com -www false |
|
|
Enables or disables hosting for a domain. Set to Requires concomitant use of the |
To enable hosting for domain example.com: # ./domain -u example.com -hosting true -ip 192.168.76.87 |
|
|
Sets the type of hosting on a domain: Set to Requires concomitant use of the When the |
To set up the standard forwarding type of hosting (with forwarding to newname.org) for existing domain example.com: # ./domain -u example.com -hst_type std -target_url newname.org -ip 192.168.76.87 |
|
|
Sets a target URL for the Standard forwarding and Frame forwarding types of hosting. Must be used concomitantly with the |
To set up a target URL for domain example.com with the standard forwarding type of hosting (forwarding to newname.org): # ./domain -u example.com -target_url newname.org -hst_type std -ip 192.168.76.87 |
|
|
Specifies the IP address of a domain that is created or updated. For domains with physical hosting, the option also specifies the IP address at which domain content is hosted. Must be used concomitantly with options creating a domain or specifying hosting type for a domain ( |
To specify an IP address for domain example.com when creating it: # ./domain -c example.com -clogin clientlogin -ip 192.168.76.87 To indicate IP address of the domain, where physical hosting configured: # ./domain -c example.com -hosting -hst_type -phys true -ip 192.168.76.87 |
|
|
Specifies FTP user login name, for example, while creating a new domain with physical hosting or changing hosting type for an existing domain. Updates current FTP user login name. |
To create FTP user with login name ftplogin and password ftppass when creating domain example.com with physical hosting: # ./domain -c example.com -hosting true -hst_type phys -clogin clientlogin -login ftplogin -passwd ftppass To change the FTP user login name to newftplogin on domain example.com with physical hosting: # ./domain -u example.com -login ftplogin |
|
|
Specifies the FTP user password on a domain with physical hosting. No password is set by default. |
To change the FTP user password to newftppass: # ./domain -update example.com -passwd newftppass |
|
|
Specifies the type of the FTP user password - plain or cryptic. Set to |
To set the type of FTP user password to cryptic for existing domain example.com with physical hosting: # ./domain -u example.com -passwd_type crypt |
|
|
Enables or disables shell access for FTP user and sets the OS system shell for FTP user access. (You can use the |
To enable shell access and set the /bin/sh/ shell for FTP user on domain example.com: # ./domain -u example.com -shell /bin/sh |
|
< |
Sets the Hard disk quota parameter for domain. Type |
To set a 10 Mb hard disk quota for domain example.com: # ./domain -u example.com -hard_quota 10M or # ./domain -u example.com -hard_quota 10000K |
|
|
Enables or disables FrontPage support on a domain. Is set to Deprecated since Plesk v.8.1 due to the stop of FrontPage support in Plesk for Linux/Unix. |
To enable Microsoft FrontPage support for domain example.com: # ./domain -u example.com -fp true |
|
|
Enables or disables FrontPage Over SSL support on a domain. Is set to Deprecated since Plesk v.8.1 due to the stop of FrontPage support in Plesk for Linux/Unix. |
To enable Microsoft FrontPage Over SSL support on domain example.com: # ./domain -u example.com -fp_ssl true |
|
|
Enables or disables FrontPage authoring on a domain. Is set to Deprecated since Plesk v.8.1 due to the stop of FrontPage support in Plesk for Linux/Unix. |
To enable Microsoft FrontPage authoring on domain example.com: # ./domain -u example.com -fpauth true |
|
|
Deprecated since Plesk v.8.1 due to the stop of FrontPage support in Plesk for Linux/Unix. |
To set the FrontPage user login name to fploginname on domain example.com: # ./domain -u example.com -fplogin fploginname |
|
|
Deprecated since Plesk v.8.1 due to the stop of FrontPage support in Plesk for Linux/Unix. |
To set the FrontPage user password to fpuserpass on domain example.com: # ./domain -u example.com -fppasswd fpuserpass |
|
|
Sets the domain creation date. Used only with the |
To set the creation date for domain example.com to 2006-12-30: # ./domain -c example.com -clogin clientlogin -creation-date 2006-12-30 |
|
|
Enables or disables SSI support on a domain. Set to |
To enable SSI support on domain example.com: # ./domain -u example.com -ssi true |
|
|
Enables or disables PHP support on a domain. Set to |
To enable PHP support on domain example.com: # ./domain -u example.com -php true |
|
|
Enables or disables safe mode for PHP support on domain. Set to |
To disable safe mode for PHP support on domain example.com: # ./domain -u example.com -php true -php_safe_mode false |
|
|
Enables or disables CGI support on a domain. Set to |
To enable CGI support on domain example.com: # ./domain -u example.com -cgi true |
|
|
Enables or disables Perl support on a domain. Set to |
To enable Perl support on domain example.com: # ./domain -u example.com -perl true |
|
|
Enables or disables Apache ASP support on a domain. Set to |
To enable Apache ASP support on domain example.com: # ./domain -u example.com -asp true |
|
|
Enables or disables Python support on a domain. Set to |
To enable Python support on domain example.com: # ./domain -u example.com -python true |
|
|
Enables or disables FastCGI support on a domain. Set to |
To enable FastCGI support on domain example.com: # ./domain -u example.com -fastcgi true |
|
|
Enables or disables ColdFusion support on a domain. Set to |
To enable ColdFusion support on domain example.com: # ./domain -u example.com -coldfusion true |
|
|
Enables or disables Miva support on a domain. Set to |
To enable Miva support on domain example.com: # ./domain -u example.com -miva true |
|
|
Enables or disables SSL support on a domain. Set to |
To enable SSL support on domain example.com: # ./domain -u example.com -ssl true |
|
|
Enables or disables using a single directory for storing content accessible through SSL and non-SSL connection (the Set to |
To enable using a single directory for storing content accessible through SSL and non-SSL connection on domain example.com: # ./domain -u example.com -same_ssl true |
|
|
Enables or disables Web statistic support; selects Web statistics application (Awstats or Webalizer) on a domain. |
To enable Webalizer support on domain example.com: # ./domain -u example.com -webstat webalizer |
|
|
Enables or disables access to web statistics data through password- protected directory Set to |
To enable access to web statistics data through password- protected directory /plesk-stat on domain example.com: # ./domain -u example.com -webstat-protdir-access true |
|
|
Enables or disables custom server error messages on a domain ( the Custom Error Documents parameter). Set to |
To enable custom error messages support on domain example.com: # ./domain -u example.com -err_docs true |
|
|
Enables or disables log rotation on a domain. Set to |
To enable log rotation on domain example.com: # ./domain -u example.com -log_rotate true |
|
|
Enables or disables log rotation on a domain based on the current log file size (the Log rotation condition parameter). |
To enable log rotation for domain example.com once the current log file reaches the 20 Kb size: # ./domain -u example.com -log_bysize 20 |
|
|
Enables or disables log rotation on a domain based on the current log file size (the Log rotation condition parameter). Is set to |
To enable log rotation for domain example.com on a weekly basis: # ./domain -u example.com -log_bytime weekly |
|
|
Sets the Maximum number of log files parameter. Set to |
To set the maximum number of log files (current and rotated) to 5 for domain example.com: # ./domain -u example.com -log_max_num 5 |
|
|
Enables or disables log file compression (the Compress log files parameter). Set to |
To disable log file compression for domain example.com: # ./domain -u example.com -log_compress false |
|
|
Enables or disables automatic sending of rotated log files to the specified e-mail address (the Send processed log files to e-mail parameter). |
To enable automatic sending of rotated log files on domain example.com to e-mail address admin@example.com: # ./domain -u example.com -log_email admin@example.com |
|
|
Specifies the login name of an existing Plesk client who will own the domain. Used only with the |
To create domain example.com and assign ownership of the domain to a Plesk client with the login name clientlogin: # ./domain -c example.com -clogin clientlogin |
|
|
Enables or disables mail service for a domain. Set to |
To disable mail service for domain example.com: # ./domain -u example.com -mail_service false |
|
|
Enables or disables the mailing list service on a domain. Set to |
To enable mailing list service for domain example.com: # ./domain -u example.com -maillist_service true |
|
|
Sets a new IP address for a domain. Used only with the Required for the |
To set the IP address 192.168.76.87 for domain example.com when changing the owner of the domain to Plesk client with login name clientlogin: # ./domain --change-owner example.com -clogin clientlogin -map_ip 192.168.76.87 |
|
|
Enables or disables the anonymous ftp service on a domain. Set to Deprecated starting with Plesk 8.1. Use the anonftp utility instead. |
To enable the anonymous FTP service on domain example.com: # ./domain -u example.com -aftp true or ./anonftp -u example.com -status true |
|
|
Enables or disables uploading to the Set to Deprecated starting with Plesk 8.1. Use the anonftp utility instead. |
To allow uploading files to the incoming directory by users: # ./domain -u example.com -aftp_inc true or ./anonftp -u example.com -incoming true |
|
|
Sets disk space allocation for the A number without a letter is interpreted as the number of bytes. Type " Deprecated starting with Plesk 8.1. Use the anonftp utility instead. |
To limit disk space in the incoming directory to 900 Kb: ./anonftp -u example.com -aftp_inc_disk_limit 900K |
|
|
Enables or disables the domain administrator account. Set to Deprecated starting with Plesk version 8.1. Use the domadmin utility instead. |
To enable the domain administrator account on domain example.com, set the domain administrator's password to domadminpass, make the password encrypted, set the personal name as Michael Smith, set the e-mail address to domadmin@example.com, set the default Plesk interface language for domain administrator to Italian, and enable multiple simultaneous domain administrator sessions: # ./domain -u example.com -dom_user true -du_passwd_type encrypted -du_passwd domadminpass -du_pname "Michael Smith" -du_email domadmin@example.com -du_language it -du-multiple-sessions true |
|
|
Sets the type of the user password for domain administrator. Deprecated starting with Plesk 8.1. Use the domadmin utility instead. |
|
|
|
Sets the user password for domain administrator. Deprecated starting with Plesk version 8.1. Use the domadmin utility instead. |
|
|
|
Sets the Personal name parameter for domain administrator. Deprecated starting with Plesk version 8.1. Use the domadmin utility instead. |
|
|
|
Sets the Email address for domain administrator. Deprecated starting with Plesk version 8.1. Use the domadmin utility instead. |
|
|
|
Sets the default interface language for domain administrator (the Domain administrator's language parameter). The argument of the command must be a valid two-letter country code as described in ISO-3166 (for example, "it" stands for Italian). Deprecated starting with Plesk version 8.1. Use the domadmin utility instead. |
|
|
|
Enables multiple simultaneous sessions on a domain (the Allow multiple sessions parameter). Deprecated starting with Plesk version 8.1. Use the domadmin utility instead. |
|
|
|
Allows or prevents standard e-mail notifications about the domain creation (Plesk domain administrators and clients). Used only with the |
To prevent e-mail notifications about domain creation: # ./domain --create example.com -notify false |