linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* 2.6-test1 startup messages?
@ 2003-07-20 14:00 Robert L. Harris
  2003-07-20 17:34 ` Ivan Gyurdiev
  0 siblings, 1 reply; 7+ messages in thread
From: Robert L. Harris @ 2003-07-20 14:00 UTC (permalink / raw)
  To: Linux-Kernel

[-- Attachment #1: Type: text/plain, Size: 1180 bytes --]



  I just converted a box to 2.6-test1.  I've installed the module-init-tools
per another thread on the list.  Spread throughout the startup messages
of the system (Debian Unstable) are messages that read:

FATAL: Module /dev/tts not found
FATAL: Module /dev/tts not found
FATAL: Module /dev/ttsS?? not found
FATAL: Module /dev/ttsS?? not found

looking at /dev/tty* I have /dev/tty, /dev/tty0-tty63.  There is no
/dev/ttyS0 (serial console) or tts*.

Have they been renamed or did I miss something in my config?  Can anyone
point me to a thread?  Digging through the archives gave some great
reading material yet nothing that seemed to answer my problem.

Thanks for any pointers,
  I'd still gladly recomend Linux to my friends.
    Robert

:wq!
---------------------------------------------------------------------------
Robert L. Harris                     | GPG Key ID: E344DA3B
                                         @ x-hkp://pgp.mit.edu 
DISCLAIMER:
      These are MY OPINIONS ALONE.  I speak for no-one else.

Diagnosis: witzelsucht  	

IPv6 = robert@ipv6.rdlg.net	http://ipv6.rdlg.net
IPv4 = robert@mail.rdlg.net	http://www.rdlg.net

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.6-test1 startup messages?
  2003-07-20 14:00 2.6-test1 startup messages? Robert L. Harris
@ 2003-07-20 17:34 ` Ivan Gyurdiev
  2003-07-20 20:01   ` Robert L. Harris
                     ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Ivan Gyurdiev @ 2003-07-20 17:34 UTC (permalink / raw)
  To: Robert L. Harris; +Cc: Linux-Kernel

Robert L. Harris wrote:
> 
>   I just converted a box to 2.6-test1.  I've installed the module-init-tools
> per another thread on the list.  Spread throughout the startup messages
> of the system (Debian Unstable) are messages that read:
> 
> FATAL: Module /dev/tts not found
> FATAL: Module /dev/tts not found
> FATAL: Module /dev/ttsS?? not found
> FATAL: Module /dev/ttsS?? not found
> 
> looking at /dev/tty* I have /dev/tty, /dev/tty0-tty63.  There is no
> /dev/ttyS0 (serial console) or tts*.
>

Are you using devfs?
I get the same messages with devfs.
Looking up a /dev file that does not presently exist
or have a corresponding module results in the above warnings.
At boot time, on a redhat distro pam_console_apply tries to lookup
the devices specified in /etc/security/console.perms, which causes a 
zillion warnings for me. The question is - are those warnings to correct 
way to handle a devfs lookup of a nonexisting device. I don't remember 
getting warnings under 2.4. Maybe I did, and just didn't notice (but I 
doubt it). They're certainly annoying and I don't like them.

P.S. Not a kernel developer - just a tester :)




^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.6-test1 startup messages?
  2003-07-20 17:34 ` Ivan Gyurdiev
@ 2003-07-20 20:01   ` Robert L. Harris
  2003-07-20 20:22   ` Måns Rullgård
  2003-07-21 12:40   ` Martin Schlemmer
  2 siblings, 0 replies; 7+ messages in thread
From: Robert L. Harris @ 2003-07-20 20:01 UTC (permalink / raw)
  To: Ivan Gyurdiev; +Cc: Linux-Kernel

[-- Attachment #1: Type: text/plain, Size: 1794 bytes --]



Yes I am using devfs and it's working with the exact same config under
2.4.21 without the errors.


Thus spake Ivan Gyurdiev (ivg2@cornell.edu):

> Robert L. Harris wrote:
> >
> >  I just converted a box to 2.6-test1.  I've installed the 
> >  module-init-tools
> >per another thread on the list.  Spread throughout the startup messages
> >of the system (Debian Unstable) are messages that read:
> >
> >FATAL: Module /dev/tts not found
> >FATAL: Module /dev/tts not found
> >FATAL: Module /dev/ttsS?? not found
> >FATAL: Module /dev/ttsS?? not found
> >
> >looking at /dev/tty* I have /dev/tty, /dev/tty0-tty63.  There is no
> >/dev/ttyS0 (serial console) or tts*.
> >
> 
> Are you using devfs?
> I get the same messages with devfs.
> Looking up a /dev file that does not presently exist
> or have a corresponding module results in the above warnings.
> At boot time, on a redhat distro pam_console_apply tries to lookup
> the devices specified in /etc/security/console.perms, which causes a 
> zillion warnings for me. The question is - are those warnings to correct 
> way to handle a devfs lookup of a nonexisting device. I don't remember 
> getting warnings under 2.4. Maybe I did, and just didn't notice (but I 
> doubt it). They're certainly annoying and I don't like them.
> 
> P.S. Not a kernel developer - just a tester :)
> 
> 

:wq!
---------------------------------------------------------------------------
Robert L. Harris                     | GPG Key ID: E344DA3B
                                         @ x-hkp://pgp.mit.edu 
DISCLAIMER:
      These are MY OPINIONS ALONE.  I speak for no-one else.

Diagnosis: witzelsucht  	

IPv6 = robert@ipv6.rdlg.net	http://ipv6.rdlg.net
IPv4 = robert@mail.rdlg.net	http://www.rdlg.net

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.6-test1 startup messages?
  2003-07-20 17:34 ` Ivan Gyurdiev
  2003-07-20 20:01   ` Robert L. Harris
@ 2003-07-20 20:22   ` Måns Rullgård
  2003-07-21  2:42     ` Charles Lepple
  2003-07-21 12:40   ` Martin Schlemmer
  2 siblings, 1 reply; 7+ messages in thread
From: Måns Rullgård @ 2003-07-20 20:22 UTC (permalink / raw)
  To: linux-kernel

Ivan Gyurdiev <ivg2@cornell.edu> writes:

>>   I just converted a box to 2.6-test1.  I've installed the
>> module-init-tools
>> per another thread on the list.  Spread throughout the startup messages
>> of the system (Debian Unstable) are messages that read:
>> FATAL: Module /dev/tts not found
>> FATAL: Module /dev/tts not found
>> FATAL: Module /dev/ttsS?? not found
>> FATAL: Module /dev/ttsS?? not found
>> looking at /dev/tty* I have /dev/tty, /dev/tty0-tty63.  There is no
>> /dev/ttyS0 (serial console) or tts*.
>>
>
> Are you using devfs?
> I get the same messages with devfs.
> Looking up a /dev file that does not presently exist
> or have a corresponding module results in the above warnings.
> At boot time, on a redhat distro pam_console_apply tries to lookup
> the devices specified in /etc/security/console.perms, which causes a
> zillion warnings for me. The question is - are those warnings to
> correct way to handle a devfs lookup of a nonexisting device. I don't
> remember getting warnings under 2.4. Maybe I did, and just didn't
> notice (but I doubt it). They're certainly annoying and I don't like
> them.

It's the new modprobe that complains louder than the old one.  I guess
it's trivial to remove the printout from the source code.

-- 
Måns Rullgård
mru@users.sf.net


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.6-test1 startup messages?
  2003-07-21  2:42     ` Charles Lepple
@ 2003-07-21  1:49       ` Ivan Gyurdiev
  0 siblings, 0 replies; 7+ messages in thread
From: Ivan Gyurdiev @ 2003-07-21  1:49 UTC (permalink / raw)
  To: Charles Lepple; +Cc: linux-kernel


> couldn't you just set the 'install' action for "/dev/tts", etc. to
> '/bin/true'?

You'd have to do that for every single device program x.y.z might try to 
find in /dev. I, personally, get at least 25 warnings on boot.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.6-test1 startup messages?
  2003-07-20 20:22   ` Måns Rullgård
@ 2003-07-21  2:42     ` Charles Lepple
  2003-07-21  1:49       ` Ivan Gyurdiev
  0 siblings, 1 reply; 7+ messages in thread
From: Charles Lepple @ 2003-07-21  2:42 UTC (permalink / raw)
  To: linux-kernel

Måns Rullgård wrote:
> Ivan Gyurdiev <ivg2@cornell.edu> writes:
[...]
>>>  I just converted a box to 2.6-test1.  I've installed the
>>>module-init-tools
>>>per another thread on the list.  Spread throughout the startup messages
>>>of the system (Debian Unstable) are messages that read:
>>>FATAL: Module /dev/tts not found
>>>FATAL: Module /dev/tts not found
>>>FATAL: Module /dev/ttsS?? not found
>>>FATAL: Module /dev/ttsS?? not found
[...]
> It's the new modprobe that complains louder than the old one.  I guess
> it's trivial to remove the printout from the source code.

couldn't you just set the 'install' action for "/dev/tts", etc. to
'/bin/true'?

-- 
Charles Lepple <ghz.cc!clepple>





^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: 2.6-test1 startup messages?
  2003-07-20 17:34 ` Ivan Gyurdiev
  2003-07-20 20:01   ` Robert L. Harris
  2003-07-20 20:22   ` Måns Rullgård
@ 2003-07-21 12:40   ` Martin Schlemmer
  2 siblings, 0 replies; 7+ messages in thread
From: Martin Schlemmer @ 2003-07-21 12:40 UTC (permalink / raw)
  To: Ivan Gyurdiev; +Cc: Robert L. Harris, Linux-Kernel

[-- Attachment #1: Type: text/plain, Size: 1294 bytes --]

On Sun, 2003-07-20 at 19:34, Ivan Gyurdiev wrote:
> Robert L. Harris wrote:
> > 
> >   I just converted a box to 2.6-test1.  I've installed the module-init-tools
> > per another thread on the list.  Spread throughout the startup messages
> > of the system (Debian Unstable) are messages that read:
> > 
> > FATAL: Module /dev/tts not found
> > FATAL: Module /dev/tts not found
> > FATAL: Module /dev/ttsS?? not found
> > FATAL: Module /dev/ttsS?? not found
> > 
> > looking at /dev/tty* I have /dev/tty, /dev/tty0-tty63.  There is no
> > /dev/ttyS0 (serial console) or tts*.
> >
> 
> Are you using devfs?
> I get the same messages with devfs.
> Looking up a /dev file that does not presently exist
> or have a corresponding module results in the above warnings.
> At boot time, on a redhat distro pam_console_apply tries to lookup
> the devices specified in /etc/security/console.perms, which causes a 
> zillion warnings for me. The question is - are those warnings to correct 
> way to handle a devfs lookup of a nonexisting device. I don't remember 
> getting warnings under 2.4. Maybe I did, and just didn't notice (but I 
> doubt it). They're certainly annoying and I don't like them.
> 

You could try the attached patch.  Rusty do not like it though =)


Regards,

-- 
Martin Schlemmer


[-- Attachment #2: module-init-tools-0.9.11-be-quiet-for-devfsd.patch --]
[-- Type: text/plain, Size: 4208 bytes --]

--- module-init-tools-0.9.11-pre/modprobe.c.orig	2003-03-16 22:32:46.000000000 +0200
+++ module-init-tools-0.9.11-pre/modprobe.c	2003-03-18 03:43:52.000000000 +0200
@@ -52,6 +52,8 @@ struct module {
 
 /* Do we use syslog or stderr for messages? */
 static int log;
+/* Should we be totally quiet? */
+static int quiet = 0;
 
 static int getlen(const char *fmt, va_list ap)
 {
@@ -70,6 +72,9 @@ static void message(const char *prefix, 
 	va_list arglist;
 	int len;
 
+	if (quiet)
+		return;
+
 	va_start(arglist, fmt);
 	len = strlen(prefix) + getlen(fmt, arglist) + 1;
 	buf = malloc(len);
@@ -87,7 +92,7 @@ static void message(const char *prefix, 
 
 #define warn(fmt, ...) message("WARNING: ", fmt , ## __VA_ARGS__)
 #define fatal(fmt, ...) \
-	do { message("FATAL: ", fmt , ## __VA_ARGS__); exit(1); } while(0)
+	do { message("FATAL: ", fmt , ## __VA_ARGS__);  if (quiet) exit(0); else exit(1); } while(0)
 
 static void grammar(const char *cmd, const char *filename, unsigned int line)
 {
@@ -1093,6 +1098,7 @@ static struct option options[] = { { "ve
 				   { "showconfig", 0, NULL, 'c' },
 				   { "autoclean", 0, NULL, 'k' },
 				   { "quiet", 0, NULL, 'q' },
+				   { "really-quiet", 0, NULL, 'Q' },
 				   { "show", 0, NULL, 'n' },
 				   { "dry-run", 0, NULL, 'n' },
 				   { "syslog", 0, NULL, 's' },
@@ -1108,6 +1114,7 @@ static struct option options[] = { { "ve
 				   { NULL, 0, NULL, 0 } };
 
 #define DEFAULT_CONFIG "/etc/modprobe.conf"
+#define MODPROBE_DEVFSD_CONF "/etc/modprobe.devfs"
 
 int main(int argc, char *argv[])
 {
@@ -1146,7 +1153,7 @@ int main(int argc, char *argv[])
 		try_old_version("modprobe", argv);
 
 	uname(&buf);
-	while ((opt = getopt_long(argc, argv, "vVC:o:rknqsclt:aif", options, NULL)) != -1){
+	while ((opt = getopt_long(argc, argv, "vVC:o:rknqQsclt:aif", options, NULL)) != -1){
 		switch (opt) {
 		case 'v':
 			add_to_env_var("-v");
@@ -1193,6 +1200,10 @@ int main(int argc, char *argv[])
 			add_to_env_var("-q");
 			fail_if_already = 0;
 			break;
+		case 'Q':
+			add_to_env_var("-Q");
+			quiet = 1;
+			break;
 		case 's':
 			add_to_env_var("-s");
 			log = 1;
@@ -1215,8 +1226,51 @@ int main(int argc, char *argv[])
 		}
 	}
 
+	/* A hack to have absolutely no output if:
+	 *
+	 *   1) we have no logging enabled
+	 * 
+	 *   2) our config file is /etc/modprobe.devfs or /etc/modules.devfs
+	 *   
+	 *   3) with the module name starting with '/dev/'.
+	 *
+	 * Rasionale:  This is what modprobe from modutils-2.4.22 does:
+	 *
+	 *   gateway root # modprobe /dev/sd1   
+	 *   modprobe: Can't locate module /dev/sd1
+	 *   gateway root # modprobe -C /etc/modules.conf /dev/sd1
+	 *   modprobe: Can't locate module /dev/sd1
+	 *   gateway root # modprobe -C /etc/modules.devfs /dev/sd1
+	 *   gateway root #
+	 *   
+	 *   gateway root # modprobe foo     
+	 *   modprobe: Can't locate module foo
+	 *   gateway root # modprobe -C /etc/modules.conf foo     
+	 *   modprobe: Can't locate module foo
+	 *   gateway root # modprobe -C /etc/modules.devfs foo     
+	 *   modprobe: Can't locate module foo
+	 *   gateway root #
+	 *   
+	 *   gateway root # modprobe -C /etc/modules.devfs /dev/sd1 && echo yes
+	 *   yes
+	 *   gateway root # modprobe -C /etc/modules.devfs foo && echo yes
+	 *   modprobe: Can't locate module foo
+	 *   gateway root # 
+	 *   
+	 */
+	if (!log && !quiet && !dump_only && config) {
+		if (strncmp(argv[optind], "/dev/", 5) == 0
+				/* Handle recursive calls */
+			&& ((strcmp(MODPROBE_DEVFSD_CONF, config) == 0)
+				/* devfsd calls modprobe with '-C /etc/modules.devfs' */
+				|| (strcmp("/etc/modules.devfs", config) == 0))) {
+			add_to_env_var("-Q");
+			quiet = 1;
+		}
+	}
+
 	/* If stderr not open, go to syslog */
-	if (log || fstat(STDERR_FILENO, &statbuf) != 0) {
+	if (log || (!quiet && fstat(STDERR_FILENO, &statbuf) != 0)) {
 		openlog("modprobe", LOG_CONS, LOG_DAEMON);
 		log = 1;
 	}
@@ -1253,7 +1307,7 @@ int main(int argc, char *argv[])
 		if (strcmp("/etc/modules.conf", config) == 0)
 			config = NULL;
 		else if (strcmp("/etc/modules.devfs", config) == 0)
-			config = "/etc/modprobe.devfs";
+			config = MODPROBE_DEVFSD_CONF;
 	}
 
 	/* -r only allows certain restricted options */

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2003-07-21 12:28 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-20 14:00 2.6-test1 startup messages? Robert L. Harris
2003-07-20 17:34 ` Ivan Gyurdiev
2003-07-20 20:01   ` Robert L. Harris
2003-07-20 20:22   ` Måns Rullgård
2003-07-21  2:42     ` Charles Lepple
2003-07-21  1:49       ` Ivan Gyurdiev
2003-07-21 12:40   ` Martin Schlemmer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).