Project

General

Profile

Actions

Bug #10810

closed

rudder agent start fails on sles12

Added by Janos Mattyasovszky over 7 years ago. Updated over 7 years ago.

Status:
Released
Priority:
N/A
Category:
Agent
Target version:
Severity:
Minor - inconvenience | misleading | easy workaround
UX impact:
User visibility:
Getting started - demo | first install | level 1 Techniques
Effort required:
Priority:
35
Name check:
Fix check:
Regression:

Description

On a SLES12 SP2 system after the initial installation of the agent 4.1.3:

vm00049:/home/cloud # rudder agent start
rudder-agent is neither service nor target!?
error: start service rudder-agent failed

This is because /sbin/service rudder-agent start is determined as default to be called by service_action:

if [ -x /usr/sbin/service ]; then
  CMD="service ${service} ${action}" 
elif [ -x /etc/init.d/${service} ]; then
  CMD="/etc/init.d/${service} ${action}" 
elif [ "${action}" = "start" ] && [ -x /usr/bin/startsrc ]; then
  CMD="startsrc -s ${service}" 
elif [ "${action}" = "stop" ] && [ -x /usr/bin/stopsrc ]; then
  CMD="stopsrc -s ${service}" 
fi

However, service does use systemd (at least in sles12 sp2):

vm00049:/home/cloud # bash -x /sbin/service rudder-agent status                      
...
+ is_service rudder-agent
++ systemctl --full --no-legend --no-pager --type=service --property=LoadState show rudder-agent.service
+ local state=LoadState=not-found
+ test LoadState=not-found = LoadState=loaded
+ is_target rudder-agent
++ systemctl --full --no-legend --no-pager --type=target --property=LoadState show rudder-agent.target
+ local state=LoadState=not-found
+ test LoadState=not-found = LoadState=loaded
+ echo 'rudder-agent is neither service nor target!?'
rudder-agent is neither service nor target!?
+ return 1


Related issues 1 (0 open1 closed)

Related to Rudder - Bug #10758: No report on Debian 8RejectedActions
Actions #1

Updated by François ARMAND over 7 years ago

  • Related to Bug #10758: No report on Debian 8 added
Actions #2

Updated by François ARMAND over 7 years ago

  • User visibility changed from First impressions of Rudder to Getting started - demo | first install | level 1 Techniques
  • Priority changed from 0 to 35

This is the same kind of bug than in #10758 because it is done in bash and not with the service (ncf) method, but the logic seems to be the same.

Actions #3

Updated by Janos Mattyasovszky over 7 years ago

The problem is on rudder CLI in /opt/rudder/share/commands/agent-start, not in the techniques.

Actions #4

Updated by Alexis Mousset over 7 years ago

  • Target version set to 4.0.7
Actions #5

Updated by Alexis Mousset over 7 years ago

  • Status changed from New to In progress
  • Assignee set to Alexis Mousset
Actions #6

Updated by Alexis Mousset over 7 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from Alexis Mousset to Benoît PECCATTE
  • Pull Request set to https://github.com/Normation/rudder-agent/pull/118
Actions #7

Updated by Alexis Mousset over 7 years ago

  • Status changed from Pending technical review to Pending release
Actions #8

Updated by Alexis Mousset over 7 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 4.0.7 which was released today.

Actions

Also available in: Atom PDF