473,396 Members | 1,987 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Replacing python: in syslog log messages

Does anyone know a way to replace the python: in syslog messages?

As an example:

Currently I have:

Sep 5 16:57:03 typhoon python: jeeves_backup starting

I would like:

Sep 5 16:57:03 typhoon jeeves_backup: starting

Thanks

Brian

Jul 18 '05 #1
1 2391
On Fri, Sep 05, 2003 at 09:01:41PM +0000, Brian Donovan wrote:
Does anyone know a way to replace the python: in syslog messages?

As an example:

Currently I have:

Sep 5 16:57:03 typhoon python: jeeves_backup starting

I would like:

Sep 5 16:57:03 typhoon jeeves_backup: starting

Very roughly: at startup, if os.path.basename(sys.argv[0]) == "python",
os.execl() sys.executable with [sys.argv[1]] + sys.argv[1:] as the argument
list.

Thanks

Brian

--
http://mail.python.org/mailman/listinfo/python-list


--
"Minerals are inexhaustible and will never be depleted. A stream of
investment creates additions to proved reserves, a very large in-ground
inventory, constantly renewed as it is extracted... How much was in the
ground at the start and how much will be left at the end are unknown and
irrelevant." -- Morry Adelman, World Renowned Economist

Jul 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Micha³ Wo¼niak | last post by:
Hi again The Question of Logs, part II. :) What are the advantages/disadvantages of using syslog() to do the logging rather than writing the logs with fopen(), fwrite() and fclose()? What...
8
by: Guy Noir | last post by:
Hello. I am needing some advice. I need to build a syslog server that writes to a sql backend. I am concerned about the server not being able to handle multiple requests. For example on an...
1
by: J Rice | last post by:
I have a question: When should syslog.closelog() be called? I have a daemon that spends most of its time asleep and quiet, but writes messages to the mail log when active. Should I open the...
0
by: Kurt B. Kaiser | last post by:
Patch / Bug Summary ___________________ Patches : 385 open (+21) / 3790 closed (+21) / 4175 total (+42) Bugs : 1029 open (+43) / 6744 closed (+43) / 7773 total (+86) RFE : 262 open...
2
by: greg | last post by:
Hi All, Could anyone tell me how I could syslog to a specific log (e.g. /var/ log/daemon.log, /var/log/syslog.log...)? Thanks very much in advance! -Greg
2
by: peter | last post by:
I'm not sure if this query should be directed to comp.lang.python or comp.os.linux.misc so I intend to post it to both with apologies if it's inappropriate on either. I have a small python...
1
by: trytobreak | last post by:
Hey guys, I have a netscreen firewall which is configured to forward syslog messages to port 514 of my machine (specific ip on the network) and I am really puzzled as on how to capture these log...
1
by: trytobreak | last post by:
Hey guys, I have a netscreen firewall which is configured to forward syslog messages to port 514 of my machine (specific ip on the network) and I am really puzzled as on how to capture these log...
3
by: Troels Arvin | last post by:
Hello, On a server with DB2 v. 8.2, db2diag.log ran full, it seems (i.e. reached a size of 2GB). And it seems that in this case, DB2 started using syslog instead. I would actually like DB2 to...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.