09-25-2014
You need to tell syslog there's a new log file by hupping (kill -hup PID) it...
This User Gave Thanks to RudiC For This Post:
9 More Discussions You Might Find Interesting
1. HP-UX
Hello,
I am New to Unix.
I am Using HP-UX 9000 Series for my Application.
I am Currently Facing an Issue that the error messages are being written in the syslog file instead of the Application Log File. The Codes for that Syslog.h is written in Pro*C.
I want to know how to Redirect these... (3 Replies)
Discussion started by: balasubramaniam
3 Replies
2. UNIX for Advanced & Expert Users
Hi,
we are trying to enable auditing for few oracle 9i database. and right now it writies into adump directory. As adump can be read/write by oracle user so could it be possible to write into syslog while oracle keeps writing to adump .
thanks in advance.
Pk (2 Replies)
Discussion started by: p4cldba
2 Replies
3. Shell Programming and Scripting
hello All,
I have the login name and pasword. I want to know how to use this info and open a file and write to it.
Ex: login: expr
pasword: xxxx
file: /expr/tmp.txt
I know how to use ftp (use Net::FTP) and upload files but I want to know how to write to a file.
Thanks, (4 Replies)
Discussion started by: rimser9
4 Replies
4. UNIX for Advanced & Expert Users
Hello Forumers!
Has anyone successfully implemented forwarding of syslog messages to a remote server which is listening on a port other than udp514?
Thanks! (3 Replies)
Discussion started by: bluescreen
3 Replies
5. Shell Programming and Scripting
I have several production servers and 1 offline server. Production server continuously generates new log files for my application. Depending on time of day new files may be generated every few seconds and at other times every few hours. I also have an offline server where I would like to pull log... (3 Replies)
Discussion started by: yoda9691
3 Replies
6. UNIX for Dummies Questions & Answers
Hi,
I created central syslog server, but it's not accepting the messages from remote. Not sure why I can't start the service with -r options? Please help.
# service syslog restart
Shutting down kernel logger:
Shutting down system logger: ... (1 Reply)
Discussion started by: samnyc
1 Replies
7. Linux
I found a script for automatically push tomcat logs to syslog server which is locate in same server. How do I change it to push logs to remote server?
log4j.rootLogger=INFO, WARN, console, file, SYSLOG
log4j.appender.file=org.apache.log4j.RollingFileAppender
log4j.appender.file.append=true... (2 Replies)
Discussion started by: heshandh
2 Replies
8. Shell Programming and Scripting
Hi guys,
So i am in server1 and i have to login to server 2, 3,4 and run some script there(logging script) and output its result. What i am doing is running the script in server2 and outputting it to a file in server 2 and then Scp'ing the file to server1. Similarly i am doing this for other... (5 Replies)
Discussion started by: srkmish
5 Replies
9. Shell Programming and Scripting
I have a script, which connecting to remote server and first checks, if the files are there by timestamp. If not I want the script exit without error. Below is a code
TARFILE=${NAME}.tar
TARGZFILE=${NAME}.tar.gz
ssh ${DESTSERVNAME} 'cd /export/home/iciprod/download/let/monthly;... (3 Replies)
Discussion started by: digioleg54
3 Replies
LEARN ABOUT DEBIAN
logger::syslog
Logger::Syslog(3pm) User Contributed Perl Documentation Logger::Syslog(3pm)
NAME
Logger::Syslog -- an intuitive wrapper over Syslog for Perl
DESCRIPTION
You want to deal with syslog, but you don't want to bother with Sys::Syslog, that module is for you.
Logger::Syslog takes care of everything regarding the Syslog communication, all you have to do is to use the function you need to send a
message to syslog.
Logger::Syslog provides one function per Syslog message level: debug, info, warning, error, notice, critic, alert.
NOTES
Logger::Syslog is compliant with mod_perl, all you have to do when using it in such an environement is to call logger_init() at the
beginning of your CGI, that will garantee that everything will run smoothly (otherwise, issues with the syslog socket can happen in
mod_perl env).
SYNOPSIS
use Logger::Syslog;
info("Starting at ".localtime());
...
if ($error) {
error("An error occured!");
exit 1;
}
...
notice("There something to notify");
FUNCTIONS
logger_init
Call this to explicitly open a Syslog socket. You can optionaly specify a Syslog facility.
That function is called when you use the module, if you're not in a mod_perl environement.
Examples:
# open a syslog socket with default facility (user)
logger_init();
# open a syslog socket on the 'local' facility
logger_init('local');
logger_close
Call this to close the Syslog socket.
That function is called automatically when the calling program exits.
logger_prefix
That function lets you set a string that will be prefixed to every messages sent to syslog.
Example:
logger_prefix("my program");
info("starting");
...
info("stopping");
logger_set_default_facility(facility)
You can choose which facility to use, the default one is "user". Use that function if you want to switch smoothly from a facility to
another.
That function will close the existing socket and will open a new one with the appropriate facility.
Example:
logger_set_default_facility("cron");
LOGGING
Logger::Syslog provides one function per Syslog level to let you send messages. If you want to send a debug message, just use debug(), for
a warning, use warning() and so on...
All those function have the same signature : thay take a string as their only argument, which is the message to send to syslog.
Examples:
debug("my program starts at ".localtime());
...
warning("some strange stuff occured");
...
error("should not go there !");
...
notice("Here is my notice");
LICENSE
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
COPYRIGHT
This program is copyright X 2004-2006 Alexis Sukrieh
AUTHOR
Alexis Sukrieh <sukria@sukria.net>
Very first versions were made at Cegetel (2004-2005) ; Thomas Parmelan gave a hand for the mod_perl support.
perl v5.12.4 2006-11-27 Logger::Syslog(3pm)