Solved

Event logs in UNIX

Posted on 2006-06-10
2
411 Views
Last Modified: 2010-04-21
Hi,

There are some scripts hwere the location fro the UNIX event log and the error log will be specified ... there is no problem with them

But there are some scripts that are just passing parameters to java programs or sth els .... for these type of scripts ... if the execuion got failed where to see the event logs  and the error logs.....

Will there be any location ... standard location where we can see the error logs of the entire process that run in that particular server ....if so ... what is the permission required for that...?

Please give me information on this and the links that can provide me more information in this area...

Thanks a lot in advance

Waiting for reply

Rajesh
0
Comment
Question by:m_razesh
2 Comments
 
LVL 38

Expert Comment

by:yuzh
ID: 16882612
>>There are some scripts hwere the location fro the UNIX event log and the error log will be specified ... there is no problem with them


It denpends how the script was written, you need to have a look at the script
yourself to find out if it logs any error to any file. there it no rules for script to
log their error, it is totally up to how the script was written !
0
 
LVL 6

Accepted Solution

by:
JJSmith earned 500 total points
ID: 16898992

In a UNIX environment all processes run in their own space and option could log anywhere they have been 'programmed' to; some processes, by design will direct their outputs to /dev/null.

For significant O/S processes it is usual to have a background logging daemon ( eg syslogd ), that write messages that it receives to logfiles ther are specified in it's configuration ( man syslogd ). Once the daemon is in place it becomes possible for all processes to pass messages to it, that can then be recorded in a central place.

The method of system logging varies between flavours of unix but in principley the same. Applications however tend to log somewhere in their installation area.

As a very very rough rule of thumb; if I suspect a process is logging but I don't know here the log is I sometime have success with:

$ touch /tmp/time_now      # this creates a file with a data time of now!

[ run the process I think is logging ]

$ find / -newer /tmp/time_now -print  

that will list all files that have changed since you 'touched' the /tmp/time_now file - this is very general and may list 100's of files in a very short time frame.

A more technical approach would probabley use something like the utility lsof (list open files), which lists the names of files and the names of processes that access those files, so imaginging a program called portlisten is running - you may find what file it is accessing with something like:

$ lsof  |  grep  portlisten

Note: lsof is not standard UNIX but an open source utility which is implimented on most variants of UNIX, see:

http://freshmeat.net/projects/lsof/

Cheers
JJ

0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

I have been running these systems for a few years now and I am just very happy with them.   I just wanted to share the manual that I have created for upgrades and other things.  Oooh yes! FreeBSD makes me happy (as a server), no maintenance and I al…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now