Here's a first diagnostic:

When doing a squeeze => wheezy => jessie upgrade test, one gets:
================================================================

  Setting up ocsinventory-server (2.0.5-1.3) ...
  Preserving your changes in
/etc/apache2/conf-available/ocsinventory-server.conf
  Changing 'require "SOAP_USER"' by 'require user "SOAP_USER"'
  Backup is available in ocsinventory-server.conf.old
  apache2_invoke: Enable configuration ocsinventory-server

When doing a wheezy => jessie upgrade test, one gets:
=====================================================
  Setting up ocsinventory-server (2.0.5-1.3) ...
  apache2_invoke: Enable configuration ocsinventory-server


The "preserving your change" is wrong and is the root of the problem.


=============
= Diagnostic
=============

Squeeze
-------
1.02.2-1.1 postinst configure is quite complex. In unattended mode, it
will generate a /etc/ocsinventory/ocsinventory.conf when it doesn't
exists, using debconf, template
/usr/share/ocsinventory-server/files/ocsinventory.conf and a bunch of
sed commands.
(
https://anonscm.debian.org/cgit/collab-maint/ocsinventory-server.git/tree/debian/ocsinventory-server.postinst?h=debian/1.02.2-1.1
)
The resulting /etc/ocsinventory/ocsinventory.conf file with
024b0d2e135eb4810e3ff1316ce1e3db
(unfortunatly, I'm testing with xen and it looks like old squeeze is not
longer supported by xen-tools. So I could only test 1.02.2-1.1 in
wheezy. This hash should be double checked)


Wheezy
------
2.0.5-1.1 /usr/share/ocsinventory-server/files/ocsinventory.conf =>
024b0d2e135eb4810e3ff1316ce1e3db

2.0.5-1.1 postinst configure does:
  if [ ! -f /etc/ocsinventory/ocsinventory.conf ]; then
    cp /usr/share/ocsinventory-server/files/ocsinventory.conf
/etc/ocsinventory/ocsinventory.conf
  fi

Lenny
-----
2.0.5-1.3 postinst configure does:
  if [ $(md5sum /etc/ocsinventory/ocsinventory.conf | cut -d \  -f 1) =
'024b0d2e135eb4810e3ff1316ce1e3db' ]; then
    # file unchanged since wheezy
    rm /etc/ocsinventory/ocsinventory.conf
  else
    echo Preserving your changes in
/etc/apache2/conf-available/ocsinventory-server.conf
    mv /etc/ocsinventory/ocsinventory.conf
/etc/apache2/conf-available/ocsinventory-server.conf
    echo "Changing 'require \"SOAP_USER\"' by 'require user \"SOAP_USER\"'"
    sed -i.old 's/require "SOAP_USER"/require user "SOAP_USER"/'
/etc/apache2/conf-available/ocsinventory-server.conf
    echo Backup is available in ocsinventory-server.conf.old
  fi


=> Lenny postinst configure also discard postinst whose hash is
024b0d2e135eb4810e3ff1316ce1e3db .

Reply via email to