Skip to content

Troubleshooting

Troubleshooting SSH ​

The command was refused for its characters ​

ssh_exec runs no shell, so ;, |, &, >, <, $, `, *, ? and ~ are refused unquoted, and a backslash always. Ask for the command as sh -c '…' when it needs a pipeline or a glob. You then approve the whole line.

"it carries something that must not leave this machine" ​

The command contains a stored secret's value. Name the key with as, and keep values out of the command line.

A changed host key is refused ​

text
… Refused: this may be someone in between. The owner must remove the trusted key of <host> …

The server presents another key than the one you trusted. If you know why (a reinstall), remove the old key under Extensions › SSH or with nocturn ssh forget <host>, then run the command again and compare the new fingerprint (Host keys).

The key is refused ​

  • It has a passphrase. Store a copy without one: ssh-keygen -p -N '' -f <copy>. The vault encrypts it already.
  • The host is not one of its hosts. A key is used only for the hosts it names. Add the host to the key, or use another key.
  • Adding it from the app is refused. Adding a key needs a private connection (Secrets troubleshooting).

The command timed out ​

A command runs one minute unless the call names a timeout, and ten minutes at most. Raise NOCTURN_SSH_TIMEOUT or NOCTURN_SSH_MAX_TIMEOUT, or run long jobs in the background on the server.

The output is cut off ​

stdout and stderr are each cut at 64 KiB. Ask for a narrower command (| tail -n 50 inside sh -c '…'), or raise NOCTURN_SSH_MAX_OUTPUT.

An IPv6 address does not work ​

host takes a name or an IPv4 address. Give the server a DNS name.

An agent cannot run commands ​

An agent has ssh_exec off until you allow it. Accept its request, or allow specific commands (Allow commands on a host).

nocturn is open source. Example hosts and people on these pages are made up.