Operating System - HP-UX
1819870 Members
2544 Online
109607 Solutions
New Discussion юеВ

channel 3: open failed: administratively prohibited: open failed

 
juice vc
Occasional Advisor

channel 3: open failed: administratively prohibited: open failed

i used the command 'ssh -L2001:localhost:163 127.0.0.1' to test my local forwarding.
so i start a server process listening on 163 port

when i try to send something through the 2001 port,the system show me this error.

(i did open the AllowTcpForwarding yes option on sshd_config)

please help me on this,thanx
8 REPLIES 8
VK2COT
Honored Contributor

Re: channel 3: open failed: administratively prohibited: open failed

Hello,

Your syntax is wrong. Check the SSH manual:

-L [bind_address:]port:host:hostport]

bind_address is the locally-bound server
IP address or hostname (in your case
localhost or whatever)

port is locally bound port (in your case
2001)

host is "remote" host (in your case
you obviously want to test localhost, in
other words 127.0.0.1)

hostport is remote port (in your case 163)

Cheers,

VK2COT
VK2COT - Dusan Baljevic
juice vc
Occasional Advisor

Re: channel 3: open failed: administratively prohibited: open failed

it didnt work yet

i check my syntax,it could be right

so,thanx,but i still have that problem.
VK2COT
Honored Contributor

Re: channel 3: open failed: administratively prohibited: open failed

Hello,

Is port 163 open on your server:

# telnet localhost 163

Cheers,

VK2COT
VK2COT - Dusan Baljevic
juice vc
Occasional Advisor

Re: channel 3: open failed: administratively prohibited: open failed

Trying...
telnet: Unable to connect to remote host: Connection refused


the port is closed?
juice vc
Occasional Advisor

Re: channel 3: open failed: administratively prohibited: open failed

bstdev2[/]ssh -L2001:localhost:163 127.0.0.1
bstdev2[/]telnet localhost 2001
Trying...
channel 3: open failed: administratively prohibited: open failed
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.
VK2COT
Honored Contributor

Re: channel 3: open failed: administratively prohibited: open failed

Hello,

Since port 163 is closed on the localhost,
you cannot use SSH to forward port 2001 to it.

You need to use some other active port
that is responding on the local machine.

Cheers,

VK2COT
VK2COT - Dusan Baljevic
juice vc
Occasional Advisor

Re: channel 3: open failed: administratively prohibited: open failed

i test another two port,but the problem still there.

i guess the local-port 2001 maybe got something wrong with the purview problem when i try to open it(i used root purview)
juice vc
Occasional Advisor

Re: channel 3: open failed: administratively prohibited: open failed

use -R to bind Server port could solved this problem.....