LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-07-2009, 12:15 AM   #1
kbarani
Member
 
Registered: Dec 2008
Posts: 41

Rep: Reputation: 15
How to read the Linux logs


Hi all,
I am going to read the logs (system log, security log) through my "C" application, operating system is Linux fedora core8. i am only interest in the present logs. How to read this logs through my application ,where to read, what is the logic behind this.

Thanks,
Barani
 
Old 04-07-2009, 12:44 AM   #2
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
The log files are usually found in /var/log and you need to be root or use sudo to read them. They are text files so any editor (emacs, vim, kate, etc.) will be able to read them.
cheers,
jdk
 
Old 04-07-2009, 01:41 AM   #3
sieira
Member
 
Registered: Dec 2007
Location: Alcalá de Henares (Madrid)
Distribution: Debian
Posts: 40

Rep: Reputation: 16
$dmesg will show you the lastest lines in /var/log/system.log (it's more or less "tail -30 /var/log/system.log"), even as a user.

I suggest you to read "man syslogd".

Last edited by sieira; 04-07-2009 at 02:15 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] How to read iptables logs procfs Linux - Newbie 2 07-23-2008 04:25 AM
unable to read logs gsr_kashyap Other *NIX 6 03-03-2006 03:34 PM
how do i read logs from Freebsd?? human *BSD 2 03-01-2005 06:19 PM
how to read mail logs? djfranknitti Linux - Newbie 2 09-21-2004 08:41 AM
how to read fwlogwatch logs rosscopeeko Mandriva 1 04-20-2004 01:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:17 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration