The domain utility is used to manage domains through CLI. By using this utility, you can perform the following tasks:
Usage
domain <command> <domain name> [
<option_1> [<param>]
[<option_2> [<param>]]
… [<option_N> [<param>]]
Example
The following command creates and enables domain example.com, assigns the ownership of the domain to an existing Plesk client with the login name JDoe, assigns IP address 192.0.2.78 to the domain, enables physical hosting and DNS zone on the domain, sets login name John and password ftppass for the FTP user, and enables CGI and PHP support on the domain.
# ./domain --create example.com -clogin JDoe -ip 192.0.2.78 -status enabled -hosting true -hst_type phys -dns true -login John -passwd ftppass -cgi true -php true
Commands
Command |
Parameter |
Description |
Example |
|---|---|---|---|
|
|
Creates a new domain. Requires |
To create the domain example.com for the client with the login name JDoe: # ./domain --create example.com -clogin JDoe or # ./domain -c example.com -clogin JDoe |
|
|
Updates configuration of an existing domain. |
To enable the domain example.com: # ./domain -u example.com -status enabled |
|
|
Deletes an existing domain. |
To delete the domain example.com: # ./domain --remove example.com or # ./domain -r example.com |
|
|
Displays information about configuration of a domain. |
To view configuration information on the domain example.com: # ./domain --info example.com or # ./domain --i example.com |
|
|
Enables a domain. |
To enable the domain example.com: # ./domain --on example.com |
|
|
Disables a domain. |
To disable the domain example.com: # ./domain --off example.com |
|
|
Changes the owner of a domain. Requires the |
To make the client with the login name JDoe the owner of domain example.com: # ./domain --change-owner example.com -clogin JDoe |
|
|
Displays the list of available shells on a domain. |
To view the list of shells available on the Plesk server: # ./domain --shells |
|
|
Displays help on the use of the utility. |
To view help on the use of the domain utility: # ./domain --help or # ./domain -h |
Options
Option |
Parameter |
Description |
Example |
|---|---|---|---|
|
|
Enables/Disables a domain (the |
To enable the 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 with the |
To rename the domain example.com to sample.net: # ./domain -u example.com -new_name sample.net |
|
|
Enables/Disables DNS zone for a domain. |
To enable DNS zone for the domain example.com: # ./domain -u example.com -dns true To disable a DNS zone for the domain example.com: # ./domain -u example.com -dns false |
|
|
Enables/Disables the www prefix for a domain. Is |
To disable the www prefix for the domain example.com: # ./domain -u example.com -www false |
|
|
Enables/Disables hosting for a domain. Is Requires |
To enable hosting for the domain example.com with the IP address 192.0.2.87: # ./domain -u example.com -hosting true -ip 192.0.2.87 |
|
|
Sets the type of hosting on a domain. The following types are available: physical hosting ( Is Requires Requires the |
To set up the standard forwarding hosting (with forwarding to sample.org) for the existing domain example.com: # ./domain -u example.com -hst_type std -target_url sample.org |
|
|
Sets a target URL for the Standard forwarding and Frame forwarding types of hosting. Required with |
To set up a target URL for the domain example.com with the standard forwarding hosting (forwarding to sample.org): # ./domain -u example.com -target_url sample.org -hst_type std |
|
|
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. Requires with |
To specify an IP address for domain example.com when creating it to 192.0.2.87: # ./domain -c example.com -clogin JDoe -ip 192.0.2.87 To indicate IP address of the domain example.com, where physical hosting configured: #./domain -u example.com -hst_type phys -login jdoe -passwd sample -hosting true -ip 192.0.2.1 |
|
|
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 the login name john and password sample when creating domain example.com with physical hosting for the client JDoe: # ./domain -c example.com -hosting true -hst_type phys -clogin JDoe -login john -passwd sample To change the FTP user login name to jane on domain example.com with physical hosting: # ./domain -u example.com -login jane |
|
|
Specifies the FTP user password on a domain with physical hosting. Required with No password is set by default. |
To change the FTP user password on the domain example.com to sample: # ./domain --update example.com -passwd sample |
|
|
Specifies the type of the FTP user password. Requires Is |
To set the FTP user on example.com password to qweqwe and password type to encrypted: # ./domain -u example.com -passwd "as9C3ml08ncCE" -passwd_type encrypted |
|
|
Enables/Disables shell access for FTP user, and sets the OS system shell for FTP user access. |
To enable shell access for FTP user on the domain example.com, and to set the shell to # ./domain -u example.com -shell /bin/sh |
|
< |
Limits the FTP user hard disk quota. Unlimited if set to A number without a letter is interpreted as the number of bytes. |
To set a 100 MB hard disk quota for the domain example.com: # ./domain -u example.com -hard_quota 100M |
|
|
Enables/Disables FrontPage support on a domain. Is Deprecated since Plesk v.8.1 due to the stop of FrontPage support in Plesk for Linux/Unix. |
To enable Microsoft FrontPage support for the domain example.com: # ./domain -u example.com -fp true |
|
|
Enables/Disables FrontPage Over SSL support on a domain. Is 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 the domain example.com: # ./domain -u example.com -fp_ssl true |
|
|
Enables/Disables FrontPage authoring on a domain. Is 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 |
|
|
Sets the login name for the FrontPage user. 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 on the domain example.com to john: # ./domain -u example.com -fplogin john |
|
|
Sets the password for the FrontPage user. Deprecated since Plesk v.8.1 due to the stop of FrontPage support in Plesk for Linux/Unix. |
To set the FrontPage user password on the domain example.com to sample: # ./domain -u example.com -fppasswd sample |
|
|
Sets the domain creation date. Used with the |
To set the creation date for domain example.com to 2008-12-30: # ./domain -c example.com -clogin JDoe -creation-date 2008-12-30 |
|
|
Enables/Disables SSI support. Is |
To enable SSI support on the domain example.com: # ./domain -u example.com -ssi true |
|
|
Enables/Disables PHP support. Is |
To enable PHP support on the domain example.com: # ./domain -u example.com -php true |
|
|
Enables/Disables safe mode for PHP support. Is |
To disable safe mode for PHP support on the domain example.com: # ./domain -u example.com -php true -php_safe_mode false |
|
|
Enables/Disables CGI support. Is |
To enable CGI support on the domain example.com: # ./domain -u example.com -cgi true |
|
|
Enables/Disables Perl support. Is |
To enable Perl support on the domain example.com: # ./domain -u example.com -perl true |
|
|
Enables/Disables Apache ASP support. Is |
To enable Apache ASP support on the domain example.com: # ./domain -u example.com -asp true |
|
|
Enables/Disables Python support. Is |
To enable Python support on the domain example.com: # ./domain -u example.com -python true |
|
|
Enables/Disables FastCGI support. Is |
To enable FastCGI support on the domain example.com: # ./domain -u example.com -fastcgi true |
|
|
Enables/Disables ColdFusion support. Is |
To enable ColdFusion support on the domain example.com: # ./domain -u example.com -coldfusion true |
|
|
Enables/Disables Miva support. Is |
To enable Miva support on the domain example.com: # ./domain -u example.com -miva true |
|
|
Enables/Disables SSL support. Is |
To enable SSL support on the domain example.com: # ./domain -u example.com -ssl true |
|
|
Enables/Disables using a single directory for storing content accessible through SSL and non-SSL connection. Is |
To enable using a single directory for storing content accessible through SSL and non-SSL connection on the domain example.com: # ./domain -u example.com -same_ssl true |
|
|
Enables/Disables Web statistic support; selects Web statistics application (Awstats or Webalizer). Is |
To enable Webalizer support on the domain example.com: # ./domain -u example.com -webstat webalizer |
|
|
Enables/Disables access to web statistics data through password- protected directory Is |
To enable access to web statistics data through password- protected directory # ./domain -u example.com -webstat-protdir-access true |
|
|
Enables/Disables custom server error messages. Is |
To enable custom error messages support on the domain example.com: # ./domain -u example.com -err_docs true |
|
|
Enables/Disables log rotation. Is |
To enable log rotation on the domain example.com: # ./domain -u example.com -log_rotate true |
|
|
Enables/Disables log rotation based on the current log file size. |
To enable log rotation on the domain example.com once the current log file reaches the 200 KB size: # ./domain -u example.com -log_bysize 200 |
|
|
Enables/Disables log rotation by time. Is |
To enable weekly log rotation on the domain example.com: # ./domain -u example.com -log_bytime weekly |
|
|
Limits the number of log files parameter. Is |
To restrict the maximum number of log files (current and rotated) on the domain example.com to 10: # ./domain -u example.com -log_max_num 10 |
|
|
Enables/Disables log file compression. Is |
To disable log file compression on the domain example.com: # ./domain -u example.com -log_compress false |
|
|
Enables/Disables automatic sending of rotated log files to the specified email address. |
To enable automatic sending of rotated log files on the domain example.com to email 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 with the |
To create the domain example.com and assign ownership of the domain to a Plesk client with the login name JDoe: # ./domain -c example.com -clogin JDoe |
|
|
Enables/Disables mail service. Is |
To disable mail service on the domain example.com: # ./domain -u example.com -mail_service false |
|
|
Enables/Disables the mailing list service. Is |
To enable mailing list service on the domain example.com: # ./domain -u example.com -maillist_service true |
|
|
Sets a new IP address for a domain. Used with Required with |
To set the IP address 192.0.2.87 for the domain example.com when changing the owner of the domain to Plesk client with the login name JaneDoe: # ./domain --change-owner example.com -clogin JaneDoe -map_ip 192.0.2.87 |
|
|
Allows/Prohibits publishing site with Sitebuilder. Is Available since Plesk 8.3. |
To allow publishing site with Sitebuilder on the domain example.com: # ./domain -u example.com -publish-sb-site true |
|
|
Limits the number of available connections. Unlimited is set to Available since Plesk 8.3. |
To limit the maximum number of connections available for the domain example.com to 10: # ./domain -u example.com -max-connections 10 |
|
|
Limits the network use. Unlimited is set to Available since Plesk 8.3. |
To limit the maximum network use on the domain example.com to 500 KB/S: # ./domain -u example.com -traffic-bandwidth 500 |
|
|
Enables/Disables the anonymous ftp service. Is Deprecated since Plesk 8.1. Use the |
To enable the anonymous FTP service on the domain example.com: # ./domain -u example.com -aftp true or ./anonftp -u example.com -status true |
|
|
Enables/Disables uploading to the incoming directory. Is Deprecated since Plesk 8.1. Use the |
To allow uploading files to the incoming directory: # ./domain -u example.com -aftp_inc true or ./anonftp -u example.com -incoming true |
|
|
Limits the amount of disk space for the incoming directory. A number without a letter is interpreted as the number of bytes. Unlimited if set to Deprecated since Plesk 8.1. Use the |
To restrict the amount of disk space available for the incoming directory to 10 MB: ./anonftp -u example.com -aftp_inc_disk_limit 10M |
|
|
Enables/Disables a domain administrator account. Is Deprecated since Plesk version 8.1. Use the |
To enable the domain administrator account on the domain example.com, set the domain administrator's password to adminpass, make the password encrypted, set the personal name as John Doe, set the email address to admin@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 adminpass -du_pname "John Doe" -du_email admin@example.com -du_language it-IT -du-multiple-sessions true |
|
|
Sets the type of the user password for domain administrator. Is Deprecated since Plesk 8.1. Use the |
|
|
|
Sets the user password for domain administrator. Deprecated since Plesk 8.1. Use the |
|
|
|
Sets the domain administrator personal name. Deprecated since Plesk 8.1. Use the |
|
|
|
Sets the Email address for domain administrator. Deprecated since Plesk 8.1. Use the |
|
|
|
Sets the default interface language for domain administrator. The argument of the command must be a valid two letter language code and two-letter country code as described in ISO-3166 (for example, "it-IT" stands for Italian). Deprecated since Plesk 8.1. Use the |
|
|
|
Enables/Disables multiple network simultaneous sessions for a domain administrator. Deprecated since Plesk 8.1. Use the |
|
|
|
Allows/Prohibits standard email notifications on a domain creation (Plesk domain administrators and clients). Used with |
To prevent email notifications about domain creation: # ./domain --create example.com -clogin JDoe -notify false |