LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 10-21-2009, 08:16 PM   #1
jsjohns2
LQ Newbie
 
Registered: Oct 2009
Posts: 2

Rep: Reputation: 0
/dev/console buffering behavior


Posted this in the newbie forum, didn't get a response there:

I've got a couple questions related to the /dev/console special file.

From what I've read, it seems that /dev/console used to be a simple symlink to ttyS0, or whatever was passed to the kernel with the "console=" parameter. In recent kernels, /dev/console is managed directly by the kernel. Does anyone know the relevant files in the kernel source that deal with setting up/configuring /dev/console?

On the current systems I am working with, the kernel command line parameters in grub.conf look something like this:
kernel /vmlinuz ro root=/dev/md2 console=tty0 console=ttyS0,115200n8r

I have noticed that echoing text to /dev/console and /dev/ttyS0 does not always have the same effect. For one, it seems that writes to /dev/console ignore the "clocal" stty flag, but honor the "crtscts" flag. Second, if I have "co:2345:respawn:/sbin/agetty -h ttyS0 115200 vt100" in my inittab such that agetty is running with flow control on, writes to /dev/console behave differently in this way:

* writes are buffered (looks like a ~4096 character buffer)
* once the buffer becomes full, writes block until CTS is asserted

Can anyone explain this behavior, or give me a good starting point to research?

Thanks!

BTW, this is on CentOS 5.3 x64.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
/dev/console buffering behavior jsjohns2 Linux - Newbie 0 10-20-2009 09:16 AM
logs sent to /dev/console appear on /dev/tty1 lfur Linux - General 3 01-08-2008 01:19 PM
s0:0:wait:/sbin/rc0 >/dev/msglog 2<>/dev/msglog </dev/console ikinnu Solaris / OpenSolaris 1 08-09-2007 08:25 AM
Weird Console Behavior georgejc Slackware 9 07-09-2006 11:10 AM
Strange console behavior after exiting X rcrules Linux - Laptop and Netbook 7 05-20-2006 09:39 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 12:51 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration