Bug ID 916005
Summary puppet update corrupts /etc/sysconfig/puppet
Classification openSUSE
Product openSUSE 13.1
Version Final
Hardware x86-64
OS openSUSE 13.1
Status NEW
Severity Major
Priority P5 - None
Component Upgrade Problems
Assignee bnc-team-screening@forge.provo.novell.com
Reporter itsbo@fz-juelich.de
QA Contact jsrain@suse.com
Found By ---
Blocker ---

The recent update to puppet (3457) executes this in post:

%post
# Compatibility with old setups
if [ -f /etc/sysconfig/puppet ] && [ -z "`grep 'PUPPET_EXTRA_OPTS="'
/etc/sysconfig/puppet | grep ' --server=${PUPPET_SERVER}
--masterport=${PUPPET_PORT} --logdest=${PUPPET_LOG}"'`" ]; then
    echo 'PUPPET_EXTRA_OPTS=" --server=${PUPPET_SERVER}
--masterport=${PUPPET_PORT} --logdest=${PUPPET_LOG} ${PUPPET_EXTRA_OPTS}"' >> 
/etc/sysconfig/puppet
fi

On systems with an existing

PUPPET_EXTRA_OPTS=""

in /etc/sysconfig/puppet (also with other options in "" )

this adds a second PUPPET_EXTRA_OPTS line, like this:

# You may specify other parameters to the puppet client here
#
PUPPET_EXTRA_OPTS=""
PUPPET_EXTRA_OPTS=" --server=${PUPPET_SERVER} --masterport=${PUPPET_PORT}
--logdest=${PUPPET_LOG} ${PUPPET_EXTRA_OPTS}"

This disrupts operation on a system where PUPPET_EXTRA_OPTS is already set and
used.

It also leads to a service running like this:

/usr/bin/ruby2.0 /usr/bin/puppet agent  --server=${PUPPET_SERVER}
--masterport=${PUPPET_PORT} --logdest=${PUPPET_LOG} ${PUPPET_EXTRA_OPTS}
--no-daemonize

Please note that "man 5 systemd.exec" states for Environment variables:

"Variable expansion is not performed inside the strings, however, specifier
expansion is possible. The $ character has no special meaning."

Therefore the line is not usable in Systemd.

Reproducible: Always

Solution: remove the %post directive.


You are receiving this mail because: