Bug 194494 - postun code should again move to "post" code?
postun code should again move to "post" code?
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: sysklogd (Show other bugs)
rawhide
All Linux
medium Severity medium
: ---
: ---
Assigned To: Peter Vrabec
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-06-08 11:02 EDT by Florian La Roche
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version: 1.4.1-38
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-01-29 15:42:15 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Florian La Roche 2006-06-08 11:02:48 EDT
Description of problem: Seems like /var/log/* files are now only
created on postuninstall. Shouldn't this code stay in the post
section of sysklogd?

regards,

Florian La Roche



@@ -58,13 +65,9 @@
 rm -rf $RPM_BUILD_ROOT

 %post
-for n in /var/log/{messages,secure,maillog,spooler}
-do
-       [ -f $n ] && continue
-       touch $n
-       chmod 600 $n
-done
-/sbin/chkconfig --add syslog
+if [ "$1" -eq 1 ]; then
+   /sbin/chkconfig --add syslog
+fi

 %preun
 if [ $1 = 0 ]; then
@@ -74,8 +77,14 @@

 %postun
 if [ "$1" -ge "1" ]; then
-       service syslog condrestart > /dev/null 2>&1
-fi
+   for n in /var/log/{messages,secure,maillog,spooler}
+   do
+       [ -f $n ] && continue
+       touch $n
+       chmod 600 $n
+   done
+   service syslog condrestart > /dev/null 2>&1
+fi

 %triggerpostun -- sysklogd < 1.3.31-17
 /sbin/chkconfig --add syslog



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


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:
Comment 1 Jason Vas Dias 2006-06-14 17:04:10 EDT
Sorry about that - I thought this was only needed after upgrade - I guess not.
Now fixed with sysklogd-1.4.1-38 .

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