Getting Started with Command Line Utilities

Command line utilities for Plesk for Linux are located in the /usr/local/psa/bin directory on the Plesk server. They are run using the plesk utility.

To run a command line utility:

  1. Log in to the server via SSH.
  2. Execute the following command:

    # plesk bin <utility name> [parameters] [options]

You can also run each utility in the same way as you run other executable files on Linux:

  • From any directory:

    # /usr/local/psa/bin/<utility name> [parameters] [options]

  • From the directory /usr/local/psa/bin/:

    plesk bin <utility name> [parameters] [options]

Upon successful execution, utilities return the 0 code. If an error occurs, utilities return code 1 and display the description of the encountered problem on stderr.

For exact command syntax for each utility, consult the corresponding sections in the Using Command Line Utilities chapter.

Note: All input parameters for the utilities must be passed in the UTF-8 encoding. It is the required condition for Plesk stable work.

Warning: Passing passwords through CLI as parameters of the -passwd option may potentially compromise the system's security as command line can be observed by other users of the system. It is more secure to pass passwords through the environment variables. You can transfer non-encrypted passwords by using environment variable PSA_PASSWORD while using single quotes to specify the empty values in the command line for the argument of the -passwd option. Similarly, you can transfer encrypted passwords through the environment variable PSA_CRYPTED_PASSWORD while using single quotes to specify the empty values in the command line for the argument of the -passwd option.

 

Leave your feedback on this topic here

If you have questions or need support, please visit the Plesk forum or contact your hosting provider.
The comments below are for feedback on the documentation only. No timely answers or help will be provided.