Troubleshooting of installation
sshscript CLI related
Check the installation of sshscript CLI
SSHScript package has a CLI “sshscript”. To check if it is successfully installed. You can open a console and type:
$ sshscript
If your screen is something like below, than the installation is succeeded. (regardless version)
usage: sshscript [-h] [--run-order] [--script]...(etc)
SSHScript
positional arguments:
paths path of .spy files or folders
optional arguments:
-h, --help show this help message and exit
--run-order show the files to run in order...
--script show the converted python scri...
(...etc...)
What if installation was failed
Case I:command not found
You can check if the installation path is in the $PATH by “which” command.
$ which sshscript
If the “which” can not find the path for “sshscript”, you have to add the installation path into $PATH.
You might use this command to find crues of where it is:
$python3 -c "import sshscript;print(sshscript.__file__)"
Suppose its output is
/home/john/.local/lib/python3.9/site-packages/sshscript/__init__.py
the executable “sshscript” CLI might be
/home/john/.local/bin/sshscript
Then, /home/john/.local/bin is the path which has to be added into the $PATH.
Case II:Bad Interpreter
When you run sshscript and have result like this:
-bash: ... bad interpreter: No such file or directory
The reason is that the setuptools writes an incorrect path of the python executable when generating executables. The solution is simply to edit it.
For example, the 1st line of “sscript” might be:
#!/usr/local/bin/python
Because we got a “bad interpreter”, which means that “/usr/local/bin/python” is invalid path of the python executable.
You might change it to be:
#!/usr/bin/env python3
or you can find the absolute path of python3 by
$python3 -c "import sys;print(sys.executable)"
suppose its output is
/home/john/workspace/local/bin/python3
then, you can change the first line of “sshcript” to be
#!/home/john/workspace/local/bin/python3
Non of above cases:
You are welcome to issue a ticket on the Github’s issue system
Last Updated: 2026-07-25 16:59:40
Table of contents
- SSHScript v3.1 Documentation
- Accounts (legacy URL)
- Checking the syncing status of two MySQL servers
- Getting Started with SSHScript
- Q: What can it do that Netmiko doesn’t do? (origin)
- SSHScript Documents
- SSHScript v2.0 CLI(Draft)
- SSHScript v2.0 Commands Execution and Console
- SSHScript v2.0 Console of sudo and su
- SSHScript v2.0 Getting Started
- SSHScript v2.0 Interactive Commands and Foreground Commands
- SSHScript v2.0 Make Connections
- SSHScript v2.0 Recipes
- SSHScript v2.0 Reference Guide
- SSHScript v2.0 Stdout, Stderr and Exitcode
- SSHScript v2.0 Threading Support
- SSHScript v2.0 Upload and Download Files
- SSHScript v2.0.2 Release Notes
- SSHScript v3.0 Interactive and Foreground Commands
- SSHScript v3.0 Reference Guide
- SSHScript v3.0.0 Release Notes
- SSHScript v3.1
- SSHScript vs. Ansible
- 用 Python 作系統自動化