Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Debian User (http://www.linux-archive.org/debian-user/)
-   -   loader: always call klogctl to disable kernel logging in the console. (http://www.linux-archive.org/debian-user/516014-loader-always-call-klogctl-disable-kernel-logging-console.html)

Chris Lumens 04-19-2011 02:04 PM

loader: always call klogctl to disable kernel logging in the console.
 
> diff --git a/loader/loader.c b/loader/loader.c
> index 2ef02d0..1726dc0 100644
> --- a/loader/loader.c
> +++ b/loader/loader.c
> @@ -1301,8 +1301,6 @@ static void restartSyslog(void) {
> close(conf_fd);
> }
>
> - /* rsyslog is going to take care of things, so disable console logging */
> - klogctl(8, NULL, 1);
> /* now we really start the daemon. */
> int status = system("/bin/systemctl --quiet restart rsyslog.service");
> if (status < 0 ||
> @@ -1967,6 +1965,8 @@ int main(int argc, char ** argv) {
> cmdline = readvars_parse_file("/proc/cmdline");
>
> restartSyslog();
> + /* disable console logging so we don't clog the ttys */
> + klogctl(8, NULL, 1);
>
> /* check for development mode early */
> if (cmdline && g_hash_table_lookup_extended(cmdline, "devel", NULL, NULL)) {

Good find.

- Chris

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


All times are GMT. The time now is 06:45 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.