Bug 145933 - logrotate fails when root shell != bash
Summary: logrotate fails when root shell != bash
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Fedora
Classification: Fedora
Component: logrotate
Version: 3
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Peter Vrabec
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-01-24 07:44 UTC by Ben Herrick
Modified: 2007-11-30 22:10 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-02-16 08:51:18 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Ben Herrick 2005-01-24 07:44:14 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5)
Gecko/20041111 Firefox/1.0

Description of problem:
Weekly log rotation script fails since I changed my root shell to
tcsh. I get the following message in my email every week:

/etc/cron.daily/logrotate:

error: error running shared postrotate script for /var/log/messages
/var/log/secure /var/log/maillog /var/log/spooler /var/log/boot.log
/var/log/cron

When I run the command in postrotate command in
/etc/logrotate.d/syslog using a bash -c it operates fine. Example:

bash -c '/bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2>
/dev/null'

No error is generated and the new file starts to get written to.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Change root shell 'chsh -s /bin/tcsh'
2. Wait for weekly log rotation to happen.
3. Get error in email.
    

Actual Results:  Received error in email and logs were not properly
rotated.

Expected Results:  Logs should have been properly rotated.

Additional info:

Comment 1 Peter Vrabec 2005-02-01 13:10:46 UTC
I can't reproduce it.
It looks like bug #146597.


Note You need to log in before you can comment on or make changes to this bug.