Bug 127546

Summary: syslog-ng update fails
Product: [openSUSE] SUSE LINUX 10.0 Reporter: Bjoern Jacke <bjacke>
Component: ConsoleAppsAssignee: Marius Tomaschewski <mt>
Status: RESOLVED WONTFIX QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None    
Version: RC 4   
Target Milestone: ---   
Hardware: Other   
OS: All   
Whiteboard:
Found By: Other Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: requested output
My (working) upgrade output

Description Bjoern Jacke 2005-10-11 13:22:18 UTC
during update of syslog-ng I got this:

syslog-ng              warning: /etc/syslog-ng/syslog-ng.conf created as
/etc/syslog-ng/syslog-ng.conf.rpmnew

and later:


/etc/syslog-ng/syslog-ng.conf does not exist


# ls /etc/syslog-ng/
.  ..  syslog-ng.conf.in  syslog-ng.conf.rpmnew

syslog-ng.conf is not available and syslog-gn is in an unusable state.
Comment 1 Marius Tomaschewski 2005-10-20 16:11:09 UTC
I've updated a 9.3 to 10.0 multiple times with modified/unmodified
syslog-ng.conf and/or syslog-ng.conf.in combinations and was unable
to reproduce it.

Do you have disabled SuSEconfig(.syslog-ng) on your system?
Can you describe how exactly you have done the update, please?

Can you attach the /var/log/YaST2/y2logRPM file to the Bug, please?
Comment 2 Bjoern Jacke 2005-10-21 18:45:10 UTC
you probably did not test it with a *modified* syslog-ng.conf, did you?
I have no y2logs as I updated it using rpm directly ;-) (suseconfig is enabled though).

I just tried a forced downgrade with the same error:

--snip--
pell:/home/bjacke # cp -a /etc/syslog-ng/syslog-ng.conf /etc/syslog-ng/syslog-ng.conf.bj
pell:/home/bjacke # rpm -U --force /install/suse/9.3-FTP/suse/i586/syslog-ng-
syslog-ng-1.6.5-10.i586.rpm            syslog-ng-debuginfo-1.6.5-10.i586.rpm
pell:/home/bjacke # rpm -U --force /install/suse/9.3-FTP/suse/i586/syslog-ng-1.6.5-10.i586.rpm
Updating etc/sysconfig/syslog...
Updating etc/sysconfig/syslog...
Updating etc/sysconfig/syslog...
Starting SuSEconfig, the SuSE Configuration Tool...
Running module syslog-ng only
Reading /etc/sysconfig and updating the system...
Executing /sbin/conf.d/SuSEconfig.syslog-ng...

ATTENTION: You have modified //etc/syslog-ng/syslog-ng.conf.  Leaving it untouched...
You can find my version in //etc/syslog-ng/syslog-ng.conf.SuSEconfig...

Finished.
/etc/syslog-ng/syslog-ng.conf does not exist
--snap--


then copy my own syslog-ng.conf to the place again and update once more from 9.3 package to 10.0 package, same error:

--snip--
pell:/home/bjacke # cp -a /etc/syslog-ng/syslog-ng.conf.bj /etc/syslog-ng/syslog-ng.conf
pell:/home/bjacke # rpm -U  /install/suse/10.0/DVD/suse/i586/syslog-ng-1.6.8-3.i586.rpm
warning: /etc/syslog-ng/syslog-ng.conf created as /etc/syslog-ng/syslog-ng.conf.rpmnew
Updating etc/sysconfig/syslog...
Updating etc/sysconfig/syslog...
Updating etc/sysconfig/syslog...
Starting SuSEconfig, the SuSE Configuration Tool...
Running module syslog-ng only
Reading /etc/sysconfig and updating the system...
Executing /sbin/conf.d/SuSEconfig.syslog-ng...
Installing new //etc/syslog-ng/syslog-ng.conf
Finished.
/etc/syslog-ng/syslog-ng.conf does not exist
--snap--
Comment 3 Marius Tomaschewski 2005-10-27 09:26:44 UTC
(In reply to comment #2)
> you probably did not test it with a *modified* syslog-ng.conf, did you?

Yes, of course.

As I wrote, I've tryed all combinations of modified conf and conf.in files
using rpm directly as well as an update using YaST (in a vmware session).

> I just tried a forced downgrade with the same error:

Yes, a downgrade to 9.3 package does not work without a further SuSEconfig
run - this is the case, because the spec files works differently (the conf
file is renamed to rpmsave and it will be switched to generated config) and
9.3 package does not provide any default syslog-ng.conf.


*** Downgrage 10.0 -> 9.3 (modified config):

Xanthos:/etc/syslog-ng # l
-rw-r--r--   1 root root 4658 2005-10-27 11:08 syslog-ng.conf
-rw-r--r--   1 root root 4715 2005-09-09 18:27 syslog-ng.conf.in
-rw-r--r--   1 root root 4658 2005-10-27 11:08 syslog-ng.conf.SuSEconfig
Xanthos:/etc/syslog-ng # rpm -U /net/mirror/SuSE/dist/9.3-i386/suse/i586/syslog-ng-1.6.5-10.i586.rpm --force
[...]
Xanthos:/etc/syslog-ng # l
-rw-r--r--   1 root root 4510 2005-03-19 21:23 syslog-ng.conf.in
-rw-r--r--   1 root root 4658 2005-10-27 11:08 syslog-ng.conf.rpmsave
-rw-r--r--   1 root root 4634 2005-10-27 11:09 syslog-ng.conf.SuSEconfig
Xanthos:/etc/syslog-ng # SuSEconfig --module syslog-ng
Xanthos:/etc/syslog-ng # l
-rw-r--r--   1 root root 4634 2005-10-27 11:09 syslog-ng.conf
-rw-r--r--   1 root root 4510 2005-03-19 21:23 syslog-ng.conf.in
-rw-r--r--   1 root root 4658 2005-10-27 11:08 syslog-ng.conf.rpmsave


But the update from 9.3 (modified config) to 10.0 always works for me.


*** Upgrage 9.3 -> 10.0 (modified config):

Xanthos:/etc/syslog-ng # mv syslog-ng.conf.rpmsave syslog-ng.conf
Xanthos:/etc/syslog-ng # rpm -U /net/mirror/SuSE/dist/10.0-i386/suse/i586/syslog-ng-1.6.8-3.i586.rpm --force
warning: /etc/syslog-ng/syslog-ng.conf created as /etc/syslog-ng/syslog-ng.conf.rpmnew
Updating etc/sysconfig/syslog...
Updating etc/sysconfig/syslog...
Updating etc/sysconfig/syslog...
Starting SuSEconfig, the SuSE Configuration Tool...
Running module syslog-ng only
Reading /etc/sysconfig and updating the system...
Executing /sbin/conf.d/SuSEconfig.syslog-ng...

ATTENTION: You have modified //etc/syslog-ng/syslog-ng.conf.  Leaving it untouched...
You can find my version in //etc/syslog-ng/syslog-ng.conf.SuSEconfig...

Finished.
Xanthos:/etc/syslog-ng # l
-rw-r--r--   1 root root 4658 2005-10-27 11:08 syslog-ng.conf
-rw-r--r--   1 root root 4715 2005-09-09 18:27 syslog-ng.conf.in
-rw-r--r--   1 root root 4952 2005-09-09 18:27 syslog-ng.conf.rpmnew


Can you attach the output from yor 9.3 -> 10.0 update call using:
    rpm -Uvvv syslog-ng-1.6.8-3.i586.rpm --force &>/tmp/out

Perhaps we can see there why it does not work for you.
Comment 4 Bjoern Jacke 2005-10-27 11:31:17 UTC
Created attachment 55698 [details]
requested output
Comment 5 Bjoern Jacke 2005-10-27 11:31:34 UTC
I wonder how it can work for you, looks impossible to me. The 9.3 RPM does not provide syslog-ng.conf, it contains just the .in file, while the new RPM contains the syslog.ng file and overwrites it. The only non standard hook for config file handling I can find in the RPM is the preun in the 9.3 package, removing an unmodified syslog-ng.conf, which is not the case here. Now comes the new RPM, containing the %config(noreplace) .conf file but the noreplace is just valid for the new RPM, e.g. updates from 10.0 to newer syslog-ng RPMs will work. It's hard to fix RPMs in a way to work around bugs of already installed RPMs. I hope you find a way ;-)
Comment 6 Marius Tomaschewski 2005-10-27 12:26:15 UTC
Hmm.. there is a difference between my "rpm -Uvvv" output and yours.

First in both cases RPM installs its config as syslog-ng.conf.rpmnew
and shows a warning, because a modified config exists in both cases.

But then, in your output of %post happens something I currently can't
understand:

+ /sbin/SuSEconfig --module syslog-ng
Starting SuSEconfig, the SuSE Configuration Tool...
Running module syslog-ng only
Reading /etc/sysconfig and updating the system...
Executing /sbin/conf.d/SuSEconfig.syslog-ng...
Installing new //etc/syslog-ng/syslog-ng.conf
Finished.

In my output no new config will be _NOT_ created:

+ /sbin/SuSEconfig --module syslog-ng
Starting SuSEconfig, the SuSE Configuration Tool...
Running module syslog-ng only
Reading /etc/sysconfig and updating the system...
Executing /sbin/conf.d/SuSEconfig.syslog-ng...

ATTENTION: You have modified //etc/syslog-ng/syslog-ng.conf.  Leaving it untouched...
You can find my version in //etc/syslog-ng/syslog-ng.conf.SuSEconfig...

Finished.

The only way to get this result I was able to find, was to remove the
/var/adm/SuSEconfig/md5/etc/syslog-ng/syslog-ng.conf containing the MD5
sum of the last generated config (or write the MD5 sum of your config
into it) and then to update the package.
Comment 7 Marius Tomaschewski 2005-10-27 12:29:19 UTC
Created attachment 55701 [details]
My (working) upgrade output
Comment 8 Marius Tomaschewski 2005-10-27 13:04:24 UTC
(In reply to comment #5)
> It's hard to fix RPMs in a way to work around bugs of already installed
> RPMs. I hope you find a way ;-)

I can't imagine one. For this reason and because I can't reproduce it
(without to remove the MD5 file) --> wontfix.