{"id":20,"date":"2011-05-30T13:04:00","date_gmt":"2011-05-30T11:04:00","guid":{"rendered":"http:\/\/gabrielezappi.net\/?p=20"},"modified":"2014-06-26T10:32:01","modified_gmt":"2014-06-26T08:32:01","slug":"varlogmessages-log-file-missing-in-linux-ubuntu-natty-narwhal-english-post","status":"publish","type":"post","link":"https:\/\/gabrielezappi.net\/en\/varlogmessages-log-file-missing-in-linux-ubuntu-natty-narwhal-english-post\/","title":{"rendered":"&#8220;\/var\/log\/messages&#8221; log file missing in Linux Ubuntu Natty Narwhal (english post)"},"content":{"rendered":"<div style=\"text-align: center;\">[clicca <a href=\"http:\/\/gabrielezappi.net\/?p=19\">qui<\/a> per il post in lingua italiana]<\/div>\n<p>Hi there,<br \/>After a clean install of Linux Ubuntu 11.04 (Natty Narwhal) I realized that the log file <i>\/var\/log\/messages<\/i> was missing. I realized that it was a deliberate choice as well!<br \/>Ubuntu community&#8217;s (or Canonical&#8217;s) kernel guys took that decision (modifing rsyslog configuration file provided as default after install) saying that this change avoids logs to be duplicated in two log files (\/var\/log\/syslog and \/var\/log\/messages).<br \/>Just to be frank, polite and clear&#8230; I totally disagree this choice: as a matter of fact, you can have duplicated rows in both log files &#8220;syslog&#8221; and &#8220;messages&#8221;, but the purpose of these files is quite different, and I don&#8217;t find it correct to mix them up, for two reasons:<\/p>\n<ol>\n<li><b>\/var\/log\/message<\/b>s is not only a convention. It <u>became a standard for all *nix\/linux systems<\/u> (no matter if you run a server or a desktop class distribution).<br \/><b>\/var\/log\/syslog<\/b> purpose is to be the audit log, and <u>it will be log everythings<\/u> (such as cron\/at jobs, &#8220;info&#8221; msg, and so on &#8230;)<br \/><b>\/var\/log\/messages<\/b> is the usual place for <u>system applications warning messages<\/u>, even if non-kernel related, boot messages (non-kernel) similar to info you may report with command &#8216;dmesg&#8217;. This is THE place to look at, if you feel that something is going wrong!<\/li>\n<li><b>All standard applications and programs<\/b> (including applications out-of-the-box, third part&#8217;s, etc..), monitoring programs, Network monitors &amp; SNMP frameworks (such as Hobbit\/XyMon, Nagios, Zabbix, and so on) <u>usually go to look for it in order to catch statuses and error conditions<\/u>. It&#8217;s not a solution to symbolic link syslog to messages, because that mentioned programs\/daemons would parse milions of unuseful lines of logs in vain, degrading the overall system performances consequently.<\/li>\n<\/ol>\n<p>Since I feel that neather Canonical nor Ubuntu community can decide to change this importand standard overnight (at least without discuss a change in a worldwide commission of IT standards or something like that &#8211; see ISO, ANSI, etc.), here is how to take rsyslog back to write \/var\/log\/messages like in the past:<\/p>\n<p><\/p>\n<ul>\n<li>edit file \/etc\/rsyslog.d\/50-default.conf (with &#8220;<i>sudo vi \/etc\/rsyslog.d\/50-default.conf<\/i>&#8221; if you are logged as normal user)<\/li>\n<li>Change the following paragraph:<\/li>\n<\/ul>\n<blockquote>\n<blockquote><p><span style=\"font-family: 'Courier New', Courier, monospace; font-size: x-small;\">&#8230;<br \/>#<br \/># Some &#8220;catch-all&#8221; log files.<br \/>#<br \/>#*.=debug;<br \/># &nbsp; &nbsp; &nbsp; auth,authpriv.none;<br \/># &nbsp; &nbsp; &nbsp; news.none;mail.none &nbsp; &nbsp; -\/var\/log\/debug<br \/>#*.=info;*.=notice;*.=warn;<br \/># &nbsp; &nbsp; &nbsp; auth,authpriv.none;<br \/># &nbsp; &nbsp; &nbsp; cron,daemon.none;<br \/># &nbsp; &nbsp; &nbsp; mail,news.none &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;-\/var\/log\/messages<br \/>&#8230;.<\/span>&nbsp;<\/p><\/blockquote>\n<\/blockquote>\n<ul><\/ul>\n<ul><\/ul>\n<ul><\/ul>\n<ul><\/ul>\n<ul><\/ul>\n<ul><\/ul>\n<ul><\/ul>\n<ul><\/ul>\n<ul><\/ul>\n<ul><\/ul>\n<ul>\n<li>to read the following:<\/li>\n<\/ul>\n<blockquote>\n<blockquote><p><span style=\"font-family: 'Courier New', Courier, monospace; font-size: x-small;\">&#8230;<br \/>#<br \/># Some &#8220;catch-all&#8221; log files.<br \/>#<br \/>*.=debug;<br \/>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;auth,authpriv.none;<br \/>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;news.none;mail.none &nbsp; &nbsp; -\/var\/log\/debug<br \/>*.=info;*.=notice;*.=warn;<br \/>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;auth,authpriv.none;<br \/>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;cron,daemon.none;<br \/>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;mail,news.none &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;-\/var\/log\/messages<br \/>&#8230;<\/span><\/p><\/blockquote>\n<\/blockquote>\n<ul>(in other words, uncomment the lines under the text &#8216;Some &#8220;catch-all&#8221; log files.&#8217;) <\/p>\n<li>restat rsyslog with the following command:<br \/>&nbsp;&nbsp; &nbsp;<b>sudo restart rsyslog<\/b><\/li>\n<li>Done! Now <i><u>\/var\/log\/messages<\/u><\/i> will be written again.<\/li>\n<\/ul>\n<p>Anyway, I hope that this annoying problem will be fixed in Oneiric (and this should nicely be a valid patch for natty-backports)<\/p>\n<p>Yours faithfully,<br \/>Gabriele<br \/>http:\/\/www.gabrielezappi.net<br \/>GNU\/Linux user #380098<\/p>\n<div><\/div>\n","protected":false},"excerpt":{"rendered":"<p>[clicca qui per il post in lingua italiana] Hi there,After a clean install of Linux Ubuntu 11.04 (Natty Narwhal) I realized that the log file \/var\/log\/messages was missing. I realized that it was a deliberate choice as well!Ubuntu community&#8217;s (or Canonical&#8217;s) kernel guys took that decision (modifing rsyslog configuration file provided as default after install) &hellip; <a href=\"https:\/\/gabrielezappi.net\/en\/varlogmessages-log-file-missing-in-linux-ubuntu-natty-narwhal-english-post\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">&#8220;\/var\/log\/messages&#8221; log file missing in Linux Ubuntu Natty Narwhal (english post)<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0,"footnotes":""},"categories":[50,63],"tags":[],"class_list":["post-20","post","type-post","status-publish","format-standard","hentry","category-linux","category-ubuntu"],"_links":{"self":[{"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/posts\/20","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/comments?post=20"}],"version-history":[{"count":1,"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/posts\/20\/revisions"}],"predecessor-version":[{"id":43,"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/posts\/20\/revisions\/43"}],"wp:attachment":[{"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/media?parent=20"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/categories?post=20"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gabrielezappi.net\/en\/wp-json\/wp\/v2\/tags?post=20"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}