Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
03-24-2009, 04:20 AM
|
#1
|
LQ Newbie
Registered: Mar 2009
Posts: 2
Rep:
|
Fedora 10 com1 port will not connect to router console port using minicom
Hello everyone, I'm posting for the first time.
The problem I'm having is getting my serial port to connect to a Cisco router console port. All of the postings I've seen suggested changing the inittab file. But Fedora 10 no longer uses the inittab for serial configs. From what I understand I should use the /etc/event.d/tty1 if I'm using ttyS0 and I should use mgetty and not mingetty. What do I put into the tty1 file? I'm using minicom without success...
Fedora 10 is installed on an IBM Thinkpad 600X. Prior to installing Fedora the laptop had Windows XP and the com1 port worked with hyperterm without any problem.
cat /proc/tty/driver/serial:
0: uart:16550A port:000003F8 irq:4 tx:0 rx:0 CTS|DSR|CD|RI
Does anyone know how to get rid of the control signals CTS|DSR|CD|RI on the above port? Could they be causing the problem?
setserial -a /dev/ttyS0:
/dev/ttyS0, Line 0, UART: 16550A, Port: 0x03f8, IRQ: 4
Buad_Base: 115200, close delay: 50, divisor: 0
closing_wait: 300
Flags: spd_normal skip_test
Should I use setserial to change the baud_mode of ttyS0 to 9600. In WinXP I used 9600 81N to connect the router to the Thinkpad using hyperterm prior to installing Fedora 10.
Thanks in advance for any help ...
|
|
|
03-24-2009, 11:26 AM
|
#2
|
LQ Guru
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 27,336
|
Quote:
Originally Posted by rgjr979
Hello everyone, I'm posting for the first time.
The problem I'm having is getting my serial port to connect to a Cisco router console port. All of the postings I've seen suggested changing the inittab file. But Fedora 10 no longer uses the inittab for serial configs. From what I understand I should use the /etc/event.d/tty1 if I'm using ttyS0 and I should use mgetty and not mingetty. What do I put into the tty1 file? I'm using minicom without success...
Fedora 10 is installed on an IBM Thinkpad 600X. Prior to installing Fedora the laptop had Windows XP and the com1 port worked with hyperterm without any problem.
cat /proc/tty/driver/serial:
0: uart:16550A port:000003F8 irq:4 tx:0 rx:0 CTS|DSR|CD|RI
Does anyone know how to get rid of the control signals CTS|DSR|CD|RI on the above port? Could they be causing the problem?
setserial -a /dev/ttyS0:
/dev/ttyS0, Line 0, UART: 16550A, Port: 0x03f8, IRQ: 4
Buad_Base: 115200, close delay: 50, divisor: 0
closing_wait: 300
Flags: spd_normal skip_test
Should I use setserial to change the baud_mode of ttyS0 to 9600. In WinXP I used 9600 81N to connect the router to the Thinkpad using hyperterm prior to installing Fedora 10.
Thanks in advance for any help ...
|
The inittab settings are for getty's, which are INCOMING terminal sessions to your Linux box.
If you're trying to go from Minicom out to a Cisco router, you should just have to fire up Minicom, set your device to be /dev/ttyS0 (or whatever it's called on your system, for the first serial port), and set the baud/parity/etc/ in there, and have at it. We do it at the office all the time. You shouldn't have to do anything with setserial, and you don't want to get rid of the CTS/DSR/CD/RI either...you need them all for successful serial connections.
Be aware that Linux is case-sensitive. So ttyS0 is different from ttys0. Check which one you have, and if you're using a USB to serial dongle, your serial port will actually be /dev/ttyUSB0....
|
|
|
03-24-2009, 03:21 PM
|
#3
|
LQ Newbie
Registered: Mar 2009
Posts: 2
Original Poster
Rep:
|
Hello thanks for the quick response ..
I am using the motherboard serial port on ttyS0.
- serial port setup in minicom: /dev/ttyS0 /var/lock 9600 9N1 No No
- modem dialing: nothing in init string and reset string
- auto bps detect=Yes Modem has DCD line=No - When I change Modem has DCD line=Yes the status line shows online 00:00
- I'm using the Cisco (LL97744) cable from the Cisco to Linux box.
The only line enabled in my inittab is id:5:initdefault:
Here is my /etc/event.d/tty1:
start on stopped rc2
start on stopped rc3
start on stopped rc4
stop on runlevel 0
stop on runlevel 1
stop on runlevel 6
respawn
exec /sbin/mgetty tty1
I did a cat /proc/tty/driver/serial after attempting to run minicom:
0: uart:16550A port:000003F8 irq:4 tx:43 rx:0 CTS|DSR|CD|RI
There are always tx: increments but rx: always remains 0
Any ideas ???
|
|
|
03-24-2009, 06:31 PM
|
#4
|
LQ Guru
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 27,336
|
Quote:
Originally Posted by rgjr979
Hello thanks for the quick response ..
I am using the motherboard serial port on ttyS0.
- serial port setup in minicom: /dev/ttyS0 /var/lock 9600 9N1 No No
- modem dialing: nothing in init string and reset string
- auto bps detect=Yes Modem has DCD line=No - When I change Modem has DCD line=Yes the status line shows online 00:00
- I'm using the Cisco (LL97744) cable from the Cisco to Linux box.
The only line enabled in my inittab is id:5:initdefault:
Here is my /etc/event.d/tty1:
start on stopped rc2
start on stopped rc3
start on stopped rc4
stop on runlevel 0
stop on runlevel 1
stop on runlevel 6
respawn
exec /sbin/mgetty tty1
I did a cat /proc/tty/driver/serial after attempting to run minicom:
0: uart:16550A port:000003F8 irq:4 tx:43 rx:0 CTS|DSR|CD|RI
There are always tx: increments but rx: always remains 0
Any ideas ???
|
As I said in my first post, the getty's are used for INCOMING connections. If the getty's have the ports locked to them, minicom won't get a lock...hardware contention is taking place. Stop the gettys, all of them. Comment them all out in inittab. Remove don't do anything with the tty's at all....whatever you're doing with the tty1, etc., devices, turn it off. Reboot, and minicom should work.
|
|
|
12-28-2009, 06:35 PM
|
#5
|
LQ Newbie
Registered: Dec 2009
Posts: 1
Rep:
|
Quote:
Originally Posted by TB0ne
As I said in my first post, the getty's are used for INCOMING connections. If the getty's have the ports locked to them, minicom won't get a lock...hardware contention is taking place. Stop the gettys, all of them. Comment them all out in inittab. Remove don't do anything with the tty's at all....whatever you're doing with the tty1, etc., devices, turn it off. Reboot, and minicom should work.
|
Was using FedoraCore 6, upgraded to FedoraCore 12.
Minicom stopped working.
Looks like console-kit-daemon is holding ttya:
[root@localhost ~]# lsof /dev/tty0
lsof: WARNING: can't stat() fuse.gvfs-fuse-daemon file system /home/jackb/.gvfs
Output information may be incomplete.
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
console-k 892 root 11r CHR 4,0 0t0 2175 /dev/tty0
[root@localhost ~]# ps -aef|grep 892
root 892 1 0 15:11 ? 00:00:00 /usr/sbin/console-kit-daemon
root 1986 1760 0 15:29 pts/1 00:00:00 grep 892
[root@localhost ~]#
If I kill console-kit-daemon, I then get garbage on minicom,
however typing on any pty generates garbage on minicom.
Connection works fine under Windows, so the hw and speed are
correct.
Is there a way to tell console-kit-daemon to leave ttya alone?
thx,
jack
|
|
|
All times are GMT -5. The time now is 03:31 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|