Project

General

Profile

Actions

Bug #22676

closed

Reinstalling deb package after uninstalling it doesn't re-enable rudder-cf-execd.service and rudder-cf-serverd.service systemd services

Added by Denis GERMAIN over 1 year ago. Updated over 1 year ago.

Status:
Rejected
Priority:
N/A
Assignee:
-
Category:
Packaging
Target version:
-
Severity:
Minor - inconvenience | misleading | easy workaround
UX impact:
User visibility:
Operational - other Techniques | Rudder settings | Plugins
Effort required:
Priority:
0
Name check:
To do
Fix check:
To do
Regression:
No

Description

I uninstalled rudder agent deb package, then reinstalled it. Everything seemed to be fine but nothing was ever scheduled on the node even though communication was OK

After some digging, I found out that the systemd services rudder-cf-execd.service and rudder-cf-serverd.service were disabled since the uninstall, and had not been re-enabled

Re-enabling them manually fixed the issue, but I think installation should re-enable them by default

Steps to reproduce :

Pop a new clean VM with Ubuntu 22.04, then install rudder agent

sudo wget --quiet -O /etc/apt/trusted.gpg.d/rudder_apt_key.gpg "https://repository.rudder.io/apt/rudder_apt_key.gpg" 
echo "deb http://repository.rudder.io/apt/7.2/ $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/rudder.list
sudo apt update && sudo apt install rudder-agent
sudo rudder agent policy-server rudder.server.ip.address

(Probably unnecessary step) Accept node in "Pending nodes" menu

Uninstall agent

sudo apt remove rudder-agent
[...]
Removed /etc/systemd/system/rudder-agent.service.requires/rudder-cf-execd.service.
Removed /etc/systemd/system/rudder-agent.service.wants/rudder-cf-serverd.service.
Removed /etc/systemd/system/multi-user.target.wants/rudder-cf-execd.service.
Removed /etc/systemd/system/multi-user.target.wants/rudder-cf-serverd.service.
Removed /etc/systemd/system/multi-user.target.wants/rudder-agent.service.
[...]

Re-install rudder-agent

sudo apt install rudder-agent
sudo rudder agent policy-server rudder.server.ip.address #not sure this is necessary here

From this point, rudder agent seems to be running but is not.

systemctl status rudder-agent
● rudder-agent.service - Rudder agent umbrella service
     Loaded: loaded (/lib/systemd/system/rudder-agent.service; disabled; vendor preset: enabled)
     Active: active (exited) since Fri 2023-04-21 12:36:44 UTC; 1min 34s ago
       Docs: man:rudder(8)
             https://docs.rudder.io
    Process: 4442 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
   Main PID: 4442 (code=exited, status=0/SUCCESS)
        CPU: 756us

Apr 21 12:36:44 instance-2023-04-21-14-21-29 systemd[1]: Starting Rudder agent umbrella service...
Apr 21 12:36:44 instance-2023-04-21-14-21-29 systemd[1]: Finished Rudder agent umbrella service.

Problem can be worked around by simply re-enabling services 

<pre><code>systemctl enable rudder-cf-serverd
Created symlink /etc/systemd/system/multi-user.target.wants/rudder-cf-serverd.service → /lib/systemd/system/rudder-cf-serverd.service.
Created symlink /etc/systemd/system/rudder-agent.service.wants/rudder-cf-serverd.service → /lib/systemd/system/rudder-cf-serverd.service.

systemctl start rudder-cf-serverd

systemctl enable rudder-cf-execd
Created symlink /etc/systemd/system/multi-user.target.wants/rudder-cf-execd.service → /lib/systemd/system/rudder-cf-execd.service.
Created symlink /etc/systemd/system/rudder-agent.service.requires/rudder-cf-execd.service → /lib/systemd/system/rudder-cf-execd.service.

systemctl start rudder-cf-serverd
</code></pre>

Related issues 1 (0 open1 closed)

Related to Rudder - Bug #22413: When we uninstall and reinstall an agent, the agent is not correctly activatedReleasedNicolas CHARLESActions
Actions #1

Updated by Alexis Mousset over 1 year ago

  • Category changed from Agent to Packaging
Actions #2

Updated by Alexis Mousset over 1 year ago

  • Related to Bug #22413: When we uninstall and reinstall an agent, the agent is not correctly activated added
Actions #3

Updated by Alexis Mousset over 1 year ago

  • Status changed from New to Rejected

#22413 duplicate

Actions

Also available in: Atom PDF