# telnet delay couple of seconds



## tomindo (Aug 13, 2014)

Hi guys 

I'm new to FreeBSD and forum. My issue is when I do telnet server IP port, it sometimes delays a couple of seconds. When I trace system calls, look like it is hanging at 

```
0.026349986 setuid(0x0,0x1,0x6,0x18,0x803031ae7,0x802352a60) = 0 (0x0)
0.026413782 setsockopt(0x3,0x0,0x3,0x61e790,0x4,0x802352a60) = 0 (0x0)
```
I was thinking of socket limit issue but not since the open sockets are way less than the limit. Any idea what going ? 

Thanks


----------



## SirDice (Aug 14, 2014)

Please stop using telnet(1). It is an incredibly insecure protocol. Use ssh(1) and sshd(8) instead.


----------



## AzaShog (Aug 14, 2014)

SirDice said:
			
		

> Please stop using telnet(1).



I felt a great disturbance on the Internet, as if hundreds of MUDs/MUSHes/MUCKs suddenly cried out in terror, and were suddenly silenced.

But otherwise yeah, if you're not connecting to those, or testing your MTA (heh heh), use ssh.


----------



## tomindo (Aug 14, 2014)

sorry guys for misunderstanding. I actually use ssh for console but what I'm doing is to test connecting to the specific port like 11211, 80 which is hanging once in a while.


----------



## youngunix (Aug 19, 2014)

Actually, you can use any port you please with ssh() as long as you do the following:

Edit the /etc/ssh/sshd_config to include the port you want to use. 
The non-standard port must be available and below 65537.
Specify the port number when connecting: `ssh -p 11211 user@server`


----------



## SirDice (Aug 19, 2014)

tomindo said:
			
		

> sorry guys for misunderstanding. I actually use ssh for console but what I'm doing is to test connecting to the specific port like 11211, 80 which is hanging once in a while.


What exactly is "hanging"? Specific ports run specific services, each with their own specific issues. Without knowing what exactly you're testing we'll be guessing until the cows come home.


----------

