I use SSH to remote FreeBSD
$ssh tom@xxxxxxxxxxxx
password:
Then I SSh to suspend client in that remote machine:
$~
/home/tom: Permission denied
Permission denied? Why? How to do that?
I use SSH to remote FreeBSD
$ssh tom@xxxxxxxxxxxx
password:
Then I SSh to suspend client in that remote machine:
$~
/home/tom: Permission denied
Permission denied? Why? How to do that?
I don't think it's an escape code
problem here. Instead, it seems you're trying to execute your
home directory. :-)
The $ sign seems to imply you're using the Bourne Shell. The
same problem you described can be done using the C Shell:
% ~
/home/poly: Permission denied.
When I try this in BASH, I get this:
$ ~
bash: /home/poly: is a directory
Maybe
% cd ~
is what you indended to do?
SSH (as with most protocols) does not pass the hostname around like HTTP does, so you can't do name-based resolution.
To host two computers running SSH on a single public IP, you'll have to use a non-standard port for the 2nd machine (i.e. 2222) and forward that to Box2.
What happened here is that you were trying to type an escape code into ssh -- eg. ~^Z (suspend) or ~. (quit)
However, '~' is actually a fairly common character in normal usage, so ssh will pass it through to the remote login session unless you get the escape sequence exactly right. The ~ character must be the first thing on a new line, and it must be followed by one of the known key codes, which you can list by using the ~? escape during a ssh session.
It seems that you typed something wrong: perhaps you managed to type ~~ which means your shell on the remote machine would receive the ~ character. This it would duely expand to be the path to your home directory. It then tried to execute that path, but directories are not executable, resulting in the 'permission denied' message.
Cheers
Bookmarks