Telnet to a serial port

 
Thread Tools Search this Thread
Special Forums Windows & DOS: Issues & Discussions Telnet to a serial port
# 8  
Old 05-12-2010
I think I understood.
I'm buying a RS232 Null Modem cable.
In ubuntu 9.10 there is not /etc/inittab. Init reads the command to execute by files in the /etc/init directory. However i think i will resolve.

Thank you again for your instructions!

Ps: If i'll have problems, i'll edit this post. Thanks again!
--------EDIT---------
I have a problem! In the DOS kermit client i don't see login prompt and no activity!
Here is my configuration. In both computers I have one serial port, db9 (9 pins). I connected the 2 pc with the null modem cable. I started kermit on the DOS pc. I setted no parity (set parity none). I setted 1 stop bit (set stop-bit 1). I setted 8 data bit (set term byte 8). port com1 (set port com1). baud 9600 (set baud 9600). set flow-control xonn/xoff. And finally i connected (connect).
In the shell of desktop ubuntu pc i typed: 'sudo /sbin/getty -8L 9600 /dev/ttyS0 vt320'
(vt320 is the model of emulated terminal). The command just hangs... And i dont see any login prompt on the dos pc. No garbage, nothing at all.

I tried a lot of times, but i'm not an expert... How can I do?

Thanks for any answer!

Last edited by mghis; 05-13-2010 at 03:04 PM..
# 9  
Old 05-14-2010
Did you set software flow control in kermit? If either end's on hardware flow control, they may refuse to talk to each other.

Try leaving off -8, I hadn't needed that when I used serial terminals.

Try -l /bin/bash in case the login program is messing up for some reason.

Try just giving it ttyS0 instead of /dev/ttyS0.

Try agetty instead of getty.

If you unplug the cable from the DOS PC, and just bridge pins 2-3 of the serial port with a piece of wire, do you see anything when you type? If your DOS terminal emulator's working at all you should see what you type.

And be sure to hit the enter key on your DOS machine to see the login prompt.

Last edited by Corona688; 05-14-2010 at 01:45 PM..
# 10  
Old 05-15-2010
Thank you! Smilie

Trying now.
Thanks again.

---------- Post updated at 07:05 PM ---------- Previous update was at 06:28 PM ----------

I setted the flow control to xon/xoff. (set flow-contron xon/xoff). I cutted -8 and added -l /bin/bash. And still no output.

When i maked a bridge between pin 2 and 3 i got the typed characters. So, the terminal emulator works well... But none login prompt

How can I do?
Thanks for any help!

---------- Post updated at 07:39 PM ---------- Previous update was at 07:05 PM ----------

I installed putty on the server and i connected to ttyS0. I maked a bridge between pin 2 and 3 (on the server) and i got the typed characters.
So: the serial port works fine in the desktop and in the dos pc. The problem may be: 1- the cable 2- the getty command!

Please help me !!
Thank you again for any answer!

If you need more infos, please ask me!

ps: I use ubuntu 9.10 karmic koala, and freebsd

Last edited by mghis; 05-15-2010 at 04:10 PM..
# 11  
Old 05-15-2010
Check you man pages for "init" and "inittab".
From my reading, the fact that you do not already have an /etc/inittab file, does not mean that if you have one, it will not be processed.
Create /etc/inittab with a line like the following:

Code:
SO:235:respawn:/sbin/agetty -L 9600 ttyS0 [ansi|vt100]

Choose one of ansi or vt100 and leave out the [], whichever you choose should match your settings in kermit.

Last edited by jgt; 05-15-2010 at 05:19 PM.. Reason: typo
# 12  
Old 05-17-2010
Init does not read the file /etc/inittab but the file in /etc/init.
This is the ubuntu man page of inittab.


Code:
inittab(5)                                                          inittab(5)

NAME
       inittab - init daemon configuration

SYNOPSIS
       /etc/inittab

DESCRIPTION
       The  /etc/inittab  file was the configuration file used by the original
       System V init(8) daemon.

       The Upstart init(8) daemon does not use this file,  and  instead  reads
       its  configuration  from  files  in  /etc/init.   See  init(5) for more
       details.

SEE ALSO
       init(8) init(5)

Upstart                           2009-07-09                        inittab(5)

Can I use getty directly form the shell? Must I use it in inittab?

Thanks again for any answer!

Last edited by mghis; 05-20-2010 at 12:00 PM.. Reason: typographical minstake!
# 13  
Old 05-22-2010
EUREKA!!!
Solved,
i could not create the /etc/inittab, but i added this file /etc/init/ttyS0.conf
i copied the contents from /etc/init/tty1.conf. I changed a bit of the getty command and i rebooted. Pressed enter at kermit connection in the dos pc and i got the login string!!

It worked!!

Thanks a lot for your usefuls posts!!. Smilie
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Solaris

Cabling and adapters to communicate to service processor serial port from Windows PC with USB port.

Hello, I have an unloaded T5140 machine and want to access the ILOM for the first time and subsequently the network port after that., and then load Solaris 10 the final January 2011 build. The first part is what confuses me -the cabling. I am coming from a Windows machine (w/appropriate... (5 Replies)
Discussion started by: joboy
5 Replies

2. IP Networking

telnet for port 5433 is not working while it works for port 22

Hi, I am trying to set up a dev environment and I have Ubuntu server (10.16.1.92) and a CentOS VM (10.16.3.235) on this. On the CentOS I have a program running on port 5433. Now my problem is that I am unable to telnet this port from another Windows server whereas I can telnet port 22 from... (5 Replies)
Discussion started by: rishav
5 Replies

3. Solaris

How to enable Serial port on ILOM, when Network Port is enabled in parallel

Hi Everyone, In my environment, I have few T5220. On the iLOM Management Card, I have both Network and Serial port are cabled, I don't have any issues while I try to connect using Network Management port, but when I try to connect the serial port for the same server which is actually connected... (3 Replies)
Discussion started by: bobby320
3 Replies

4. Shell Programming and Scripting

Need help with serial port

Hi, I have a external board connected to my serial port. I need to execute "shutdown -r now" command when system boot up. When system boots up it requires a username ans password. Then I need to run my command. I can use rc script but that is rebooting system before it asks for username and... (0 Replies)
Discussion started by: charlie.arya
0 Replies

5. Ubuntu

Ubuntu 9.04 Serial application to telnet to serial device

Hello! I am working on an application which reads environmental instruments which have serial ports. The application requires a serial port to be present to talk to the device (i.e. /dev/ttyS0 ). In some instances the environmental devices will be 100's of yards away from the computer, so a... (5 Replies)
Discussion started by: mvona
5 Replies

6. AIX

Serial port in AIX

Hi, How can i configure my modem in AIX thru serial port (sa0-->tty0) I have two port serial card configured as sa0 I created tty1 which port is tty0 and which port is tty1 how can i know?? (1 Reply)
Discussion started by: pchangba
1 Replies

7. UNIX for Dummies Questions & Answers

Serial port redirector

I need make serial data from virtual serial ports available on a TCP/IP network. For communications with hardware COM ports to send and receive serial data over a local network or the Internet. Example: POSIX machine (/dev/ttyS0) <--- TCP/IP ---> Windows machine COM1 Please help! I try use... (0 Replies)
Discussion started by: steel98
0 Replies

8. Solaris

Serial Port Datalogger

Hi, I'm using Solaris workstation with 5.4 OS. I was wondering if there's a way that I could log the data incoming and outgoing on a certain serial port. Thanks in Advance! (1 Reply)
Discussion started by: uryuu
1 Replies

9. Solaris

disabled telnet now need port 23 or port 22

we disabled telnet on solaris 9 via previous a thread. We use CMS (call management system) supervisor which used port 23 (telnet). We cannot use telnet via local directive and it was shut down as stated when we shut down telnet in the inetd file. I cannot now log into the CMS box since port 23 is... (3 Replies)
Discussion started by: panzerkw
3 Replies

10. UNIX for Dummies Questions & Answers

serial port configuration

I am having trouble with a device connected through a serial port on my sun workstation ( I am running solaris 7). The seriel device works on an identical workstation running the same o/s version but when I move it to the initial workstation it doesn't work. I am using an rs232 serial cable and... (1 Reply)
Discussion started by: Henrik
1 Replies
Login or Register to Ask a Question