shell
Enable or disable regular (non-jailed) SSH shell access for a hosted account; enabling also removes the account's chroot jail
- Command:
/go/shell - Category: Accounts / SSH
- Required argument:
<domain> - Output: No confirmation. Only messages from the system tools it runs.
- Last updated: 2026-11-21
On this page: Overview · Quick start · Syntax · Arguments · Output · Examples · Troubleshooting · Details · Security · See also
Overview
/go/shell controls whether a hosting account can log in over SSH with a normal shell. It can:
- enable shell access: the account gets a regular shell, and is taken out of the jailed shell (chroot) if it had one
- disable shell access for the account
The command changes the account's Shell flag in GoAdmio's database, then runs ssh to rewrite the SSH server configuration so the change is applied.
[!WARNING] Running the command without an action enables shell access. Only
0or--disableturns it off. Any other value, or nothing, turns it on.
For a restricted shell that keeps the account inside its own folder, use jailedshell instead.
Quick start
# Enable shell access for a domain's account
/go/shell example.com
# Disable it
/go/shell example.com 0
Syntax
/go/shell <domain> [0 | --disable]
The command writes the call and a timestamp to /var/log/go/shell.log. Run it as root, because one step does not use sudo.
Arguments
| Position | Argument | Required | Notes |
|---|---|---|---|
| 1 | <domain> |
Yes | The hosted domain, written the same way as in GoAdmio. The account's username is looked up from it. |
| 2 | 0 or --disable |
No | Disables shell access. |
| You pass | Result |
|---|---|
example.com |
Enables shell access. |
example.com 1 |
Enables shell access. |
example.com anything-else |
Enables shell access. |
example.com 0 |
Disables shell access. |
example.com --disable |
Disables shell access. |
--disable example.com |
Does not work. The domain must be the first argument, so --disable is read as the domain and no account is changed. |
The command does not check that the domain exists. A misspelled domain changes nothing and prints no error.
Output
There is no success message. The only output comes from the tools the command runs:
- When enabling,
gpasswdprints a line such asRemoving user example.com from group Jailed, or an error if the user was not in that group. sshmay print its own messages.
Check the result by trying an SSH login, or by looking at the account's shell setting in GoAdmio.
Examples
# Give an account a regular SSH shell
/go/shell example.com
# Remove shell access
/go/shell example.com --disable
# Review recent calls
tail /var/log/go/shell.log
Troubleshooting
| Symptom | Likely cause | Fix |
|---|---|---|
| Nothing changes and no error is shown | The domain is misspelled or not hosted, so no account matched. | Use the domain exactly as GoAdmio shows it. |
gpasswd complains about a missing user or wrong arguments |
The domain has no account, so the username was empty. | Check the domain name. |
user '<name>' is not a member of 'Jailed' |
The account had no jailed shell. | Nothing to fix. The command continues. |
group 'Jailed' does not exist |
No jailed shell has been set up on this server. | Nothing to fix. The command continues. |
gpasswd: Permission denied |
The command was not run as root. | Run it as root. |
| The account's jailed shell was turned off | Enabling shell access removes the jail. | Use jailedshell to enable the jail again. |
| The account is still connected after disabling | Sessions that are already open are not ended. | End them, for example with pkill -u <username>. |
Details
What it does
- Records the call in the log.
- Looks up the account's username from the
Sitetable in/var/lib/sqlite/site.db. - If the second argument is
0, or--disableappears anywhere in the arguments, it disables:- sets
Shell=0for the domain
- sets
- Otherwise it enables:
- If the domain contains a dot, deletes
bin,lib, andlib64inside/home/<domain>. These are the folders of the chroot jail. - Removes the user from the
Jailedgroup withgpasswd -d. - Sets
Shell=1andJailedShell=0for the domain.
- If the domain contains a dot, deletes
- Runs
sshto rewrite/etc/ssh/sshd_config.
flowchart TD
A["shell domain [action]"] --> B["Log the call, look up username"]
B --> C{"Action is 0 or --disable?"}
C -- "Yes" --> D["Shell = 0"]
C -- "No" --> E["Delete jail folders bin, lib, lib64"]
E --> F["Remove user from Jailed group"]
F --> G["Shell = 1, JailedShell = 0"]
D --> H["Run ssh to rewrite SSH configuration"]
G --> H
Enable and disable compared
| Enable | Disable | |
|---|---|---|
Shell flag |
Set to 1 |
Set to 0 |
JailedShell flag |
Set to 0 |
Not changed |
Jail folders (bin, lib, lib64) |
Deleted | Not changed |
Jailed group |
User removed | Not changed |
| SSH configuration | Rewritten | Rewritten |
| Open SSH sessions | Not affected | Not ended |
The SSH configuration is rewritten on every run, even when nothing else changed.
Security
- Enabling shell access gives the account a regular SSH login. Only enable it for accounts you trust.
- Check the domain before you run the command. The domain is used in a file path that is deleted with
rm -rf. A value such as..contains a dot, so it would delete/bin,/lib, and/lib64on the server. Always type a real hosted domain. - Disabling does not end open sessions. A user who is already logged in stays logged in until they disconnect.
See also
| Command | Description |
|---|---|
jailedshell |
Enable or disable a chrooted SSH shell for a domain |
ssh |
Rewrite /etc/ssh/sshd_config with GoAdmio hardening |
sshtop |
Report the top SSH brute-force sources and optionally block them |
port |
Change the default SSH port (22) to another port |
password |
Change a GoAdmio account's FTP, SSH, and panel login password |
create |
Create a GoAdmio account (--shell and --jailedshell options) |