From Fedora Project Wiki

No edit summary
 
(10 intermediate revisions by the same user not shown)
Line 1: Line 1:
= Configure for basic debug =
= Configure syslog to log kernel debug messages =
* Edit /etc/sysconfig/wpa_supplicant to log into /var/log/messages
In standard configuration system logger does not log kernel debug messages. Usually this is not a problem as debug messages
can be read by dmesg. However kernel internal dmesg buffer is limited (on Fedora limit is 512KB), only most recent messages
can be read from the buffer.  When lot of information is printed, it can be lost. Below configuration allow to log all kernel
messages to /var/log/kernel file.
* Add this line in /etc/rsyslog.conf
<pre>
<pre>
OTHER_ARGS="-u -f /var/log/messages -P /var/run/wpa_supplicant.pid"
kern.*                                                  /var/log/kernel
</pre>
* Restart services
<pre>
/etc/init.d/rsyslog restart
</pre>
 
= Configure syslog to debug kernel and wpa_supplicant =
Sometimes is needed to have kernel debug messages together with wpa_supplicant logged
in one place. Below changes allow to do this.
* Edit /etc/sysconfig/wpa_supplicant file to log into /var/log/messages
<pre>
OTHER_ARGS="-u -f /var/log/messages -dd -P /var/run/wpa_supplicant.pid"
</pre>
</pre>


* Edit /etc/rsyslog.conf to log all kernel messages into /var/log/messages
* Edit /etc/rsyslog.conf file to log all kernel messages into /var/log/messages
<pre>
<pre>
kern.*;*.info;mail.none;authpriv.none;cron.none                /var/log/messages
kern.*;*.info;mail.none;authpriv.none;cron.none                /var/log/messages
Line 16: Line 33:
</pre>
</pre>


= Configure for verbose debug =
= Configure syslog for debug kernel and wpa_supplicant together with NetworkManager=
Also requires settings from above.
 
* Edit /etc/sysconfig/wpa_supplicant to enable verbose debug
Requires settings from above and below changes.
<pre>
OTHER_ARGS="-u -f /var/log/messages -dd -P /var/run/wpa_supplicant.pid"
</pre>


* Edit /etc/init.d/NetworkManager to enable verbose debug
* Edit /etc/init.d/NetworkManager file to enable verbose debug
<pre>
<pre>
daemon --pidfile $pidfile --check $servicename $processname --pid-file=$pidfile --log-level=DEBUG
daemon --pidfile $pidfile --check $servicename $processname --pid-file=$pidfile --log-level=DEBUG
Line 31: Line 45:
<pre>
<pre>
/etc/init.d/NetworkManager restart
/etc/init.d/NetworkManager restart
/etc/init.d/wpa_supplicant restart
</pre>
</pre>

Latest revision as of 13:28, 24 January 2011

Configure syslog to log kernel debug messages

In standard configuration system logger does not log kernel debug messages. Usually this is not a problem as debug messages can be read by dmesg. However kernel internal dmesg buffer is limited (on Fedora limit is 512KB), only most recent messages can be read from the buffer. When lot of information is printed, it can be lost. Below configuration allow to log all kernel messages to /var/log/kernel file.

  • Add this line in /etc/rsyslog.conf
kern.*                                                  /var/log/kernel
  • Restart services
/etc/init.d/rsyslog restart

Configure syslog to debug kernel and wpa_supplicant

Sometimes is needed to have kernel debug messages together with wpa_supplicant logged in one place. Below changes allow to do this.

  • Edit /etc/sysconfig/wpa_supplicant file to log into /var/log/messages
OTHER_ARGS="-u -f /var/log/messages -dd -P /var/run/wpa_supplicant.pid"
  • Edit /etc/rsyslog.conf file to log all kernel messages into /var/log/messages
kern.*;*.info;mail.none;authpriv.none;cron.none                /var/log/messages
  • Restart services
/etc/init.d/wpa_supplicant restart
/etc/init.d/rsyslog restart

Configure syslog for debug kernel and wpa_supplicant together with NetworkManager

Requires settings from above and below changes.

  • Edit /etc/init.d/NetworkManager file to enable verbose debug
daemon --pidfile $pidfile --check $servicename $processname --pid-file=$pidfile --log-level=DEBUG
  • Restart services
/etc/init.d/NetworkManager restart