Hey Guys! I've got a server with a serial console cable plugged directly into a Cisco router.
I can full working access to the CLI of the Cisco router by doing:
What I really want is to be able to access this server remotely in order to administer this Cisco router via console cable and so if I SSH into the box and then run the cu command, all is well.
However, I want users to be able to connect with minimal fuss so I'd love to use reverse telnet so that we can just telnet to a special port (ie 2301) and be connected immediately to the console connection.
I've tried using inetd and xinetd and setting up a configuration like this:
I've added the console0 service to /etc/services:
This works, except the output is pretty garbled and unusable. For instance:
- the Router's command prompt is always printed twice (on separate lines)
- password entry is not masked (ie it shows what you are typing)
- although normal entry isn't repeated (ie a typed command does not get doubled)
- streaming output often breaks (ie listing the configuration stops prematurely)
- ctrl-a, ctrl-e etc to move the cursor does not work
Any ideas on this one? I'd appreciate any! Maybe a better way of doing this? Thanks!
I can full working access to the CLI of the Cisco router by doing:
Code:
cu -l /dev/ttyUSB0 -s 9600
What I really want is to be able to access this server remotely in order to administer this Cisco router via console cable and so if I SSH into the box and then run the cu command, all is well.
However, I want users to be able to connect with minimal fuss so I'd love to use reverse telnet so that we can just telnet to a special port (ie 2301) and be connected immediately to the console connection.
I've tried using inetd and xinetd and setting up a configuration like this:
Code:
service console0
{
flags = REUSE
socket_type = stream
wait = no
user = root
server = /usr/bin/cu
server_args = -l /dev/ttyUSB0 -s 9600
disable = no
}
I've added the console0 service to /etc/services:
Code:
console0 2301/tcp
This works, except the output is pretty garbled and unusable. For instance:
- the Router's command prompt is always printed twice (on separate lines)
- password entry is not masked (ie it shows what you are typing)
- although normal entry isn't repeated (ie a typed command does not get doubled)
- streaming output often breaks (ie listing the configuration stops prematurely)
- ctrl-a, ctrl-e etc to move the cursor does not work
Any ideas on this one? I'd appreciate any! Maybe a better way of doing this? Thanks!