Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
06-18-2012, 11:55 AM
|
#1
|
LQ Newbie
Registered: Jun 2012
Posts: 2
Rep:
|
Regarding Syslog
hi,
I am new to syslog library. Kindly help in this query.
Is there any way to get syslog logs in dmesg command.
Achintya Singhal
|
|
|
06-18-2012, 01:04 PM
|
#2
|
LQ Guru
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
|
Not really and you don't really want to.
Most of what appears in dmesg is apt to show up in syslog (and can be configured to do so) because syslog allows for recording all sorts of things. demsg on the other hand is designed really only to display RECENT kernel messages. dmesg unlike syslog does not give date time of the entry so you never know on looking at dmesg whether what you are seeing occured just now, 5 minutes ago, 5 weeks ago or on a reboot you did last year. dmesg gets cleared during reboot so the only thing you're sure of is that what it has in it occurred during or after the last reboot. In fact some folks run scripts to dump dmesg into syslog periodically then clear dmesg so they can have some reasonable assurance what is in dmesg is after the last run of their script.
|
|
|
06-18-2012, 01:20 PM
|
#3
|
LQ Newbie
Registered: Jun 2012
Posts: 2
Original Poster
Rep:
|
Thanks MensaWater for your reply.
In syslog, I am using it using facility LOG_KERN. And then it should pass that log as kernel message. Still, demsg doesnot show these logs. Indeed logs are printing on console while application is running.
I need this logging because my device runs only one application and I need synchronization of logs between application and kernel.
Achintya Singhal
|
|
|
All times are GMT -5. The time now is 08:57 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|