How can I change the port for telnetd to something other than 23?

I have a Digi connect me 9210 Linux development kit and I have written a basic telnet server application that takes commands from a telnet client to operate a peice of equipment. It all works fine on the port I have specified (26), but my customer would like to connect to it via the standard telnet port (23).

That port (23) is currently used by the OS for a shell connection. And I can’t really disable the built in telnet daemon because I need it to change the devices IP address (Because I cannot seem to make ADDP work but that’s another issue).

I have edited the /etc/services file and changed the telnet port there, but it seems to have no affect on the telnet daemon, it still sits on port 23. I also don’t see an inet or xinet configuration file so I think Digi is doing something different, but I can’t figure out what.

Any suggestions would be greatly appreciated.


telnet daemon is started in /etc/inittab

In telnetd daemon init line add “-p portnumber”

build and install onto module. It will work

1 Like

That answer sounds like the port has to be a hard-coded value prior to building the application.

Can the port number be changed during run time by a user-entered preference?