Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 50322 - python-updater causes logger to hang indefinitely
Summary: python-updater causes logger to hang indefinitely
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-05-07 00:44 UTC by Erik van Mourik
Modified: 2004-06-26 13:18 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Erik van Mourik 2004-05-07 00:44:23 UTC
I upgraded to Python 2.3, and was instructed to run python-updater. This script  updated 6 packages but failed on one of them. At the end of the script, it started generating a result summary, using the ewarn macro from functions.sh. This macro in turn calls the logger application to write to the system log.

One of the strings to be logged is a " ". According to 'ps -ax', the logger receives arguments "-p daemon.warning -t rc-scripts --" and starts waiting for input on stdin. Result: logger halts, python-updater halts, user is confused.


Reproducible: Always
Steps to Reproduce:
1. Upgrade to python 2.3
2. Run python-updater
3. Make certain it fails upgrading at least one package (no idea how one could achieve this, but it happened to me :-)
4. Wait, and wait, and wait...

Actual Results:  
I returned the next morning and found a frozen script. Some script inspection 
combined with the 'ps -ax' output told me exactly what had gone wrong: the 
logger application was halted.

Expected Results:  
It should have logged the results of the python-updater script.

Simple workaround: Ctrl-Z, ps -ax, kill <logger process ID>, fg (multiple times, 
because the script contains several attempts to log empty strings :-)

A more elegant solution: Please don't try to log blank strings in 
python-updater.sh!!!

The ultimate solution: trap this situation in functions.sh. I verified that you 
can log a blank string with command 'logger -- " "'. The esyslog() function 
could test for a blank/empty string and then use the above construct to log a 
single space char...
Comment 1 Rob Cakebread (RETIRED) gentoo-dev 2004-06-14 10:30:42 UTC
Are you using an old version of baselayout? 

Is this bug related?
http://bugs.gentoo.org/show_bug.cgi?id=16466
Comment 2 Alastair Tse (RETIRED) gentoo-dev 2004-06-26 13:18:41 UTC
needinfo