Project

General

Profile

Actions

Bug #46654

closed

Unsupported podman container configuration via systemd

Added by Juan Miguel Olmo Martínez almost 4 years ago. Updated over 3 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
cephadm (binary)
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
2 - major
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

Description of problem:
As per https://bugzilla.redhat.com/show_bug.cgi?id=1834974#c4 running podman containers via systemd without PIDfile and Type=forking attributes isn't a supported configuration.

If this is not fixed, this will have several collateral effects, one of the most important is that we are wasting disk space not cleaning properly deleted containers.

Version-Release number of selected component (if applicable):

# ceph --version
ceph version 15.2.4-9.el8cp (fd4d62d568194c0dbb787e1845e65ed5c1de1b1f) octopus (stable)
# rpm -qa cephadm
cephadm-15.2.4-9.el8cp.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Deploy ceph with cephadm

Actual results:

# systemctl show ceph-b2692c62-c535-11ea-a48b-fa163e07380d@mon.ofgnapinv-1.service|egrep '(Type|PIDFile)'
Type=simple

# systemctl cat ceph-b2692c62-c535-11ea-a48b-fa163e07380d@mon.ofgnapinv-1.service
# /etc/systemd/system/ceph-b2692c62-c535-11ea-a48b-fa163e07380d@.service
# generated by cephadm
[Unit]
Description=Ceph %i for b2692c62-c535-11ea-a48b-fa163e07380d

# According to:
#   http://www.freedesktop.org/wiki/Software/systemd/NetworkTarget
# these can be removed once ceph-mon will dynamically change network
# configuration.
After=network-online.target local-fs.target time-sync.target
Wants=network-online.target local-fs.target time-sync.target

PartOf=ceph-b2692c62-c535-11ea-a48b-fa163e07380d.target
Before=ceph-b2692c62-c535-11ea-a48b-fa163e07380d.target

[Service]
LimitNOFILE=1048576
LimitNPROC=1048576
EnvironmentFile=-/etc/environment
ExecStartPre=-/bin/podman rm ceph-b2692c62-c535-11ea-a48b-fa163e07380d-%i
ExecStart=/bin/bash /var/lib/ceph/b2692c62-c535-11ea-a48b-fa163e07380d/%i/unit.run
ExecStop=-/bin/podman stop ceph-b2692c62-c535-11ea-a48b-fa163e07380d-%i
ExecStopPost=-/bin/bash /var/lib/ceph/b2692c62-c535-11ea-a48b-fa163e07380d/%i/unit.poststop
KillMode=none
Restart=on-failure
RestartSec=10s
TimeoutStartSec=120
TimeoutStopSec=120
StartLimitInterval=30min
StartLimitBurst=5

[Install]
WantedBy=ceph-b2692c62-c535-11ea-a48b-fa163e07380d.target

Expected results:

# systemctl show ceph-b2692c62-c535-11ea-a48b-fa163e07380d@mon.ofgnapinv-1.service|egrep '(Type|PIDFile)'
PIDFile=/path/to/container/pidfile.pid
Type=forking

Related issues 2 (0 open2 closed)

Related to Orchestrator - Bug #46036: cephadm: killmode=none: systemd units failed, but containers still runningResolved

Actions
Related to Orchestrator - Bug #49551: cephadm journald logs are mangledResolved

Actions
Actions #1

Updated by Sebastian Wagner almost 4 years ago

  • Description updated (diff)
Actions #2

Updated by Sebastian Wagner almost 4 years ago

  • Related to Bug #46036: cephadm: killmode=none: systemd units failed, but containers still running added
Actions #4

Updated by Sebastian Wagner almost 4 years ago

interestingly, Red Hat recommends killmode=none for this setup: https://www.redhat.com/sysadmin/podman-shareable-systemd-services

Actions #5

Updated by Sebastian Wagner almost 4 years ago

  • Assignee set to Adam King
Actions #7

Updated by Adam King over 3 years ago

  • Status changed from New to Fix Under Review
  • Pull request ID set to 36800
Actions #8

Updated by Adam King over 3 years ago

  • Status changed from Fix Under Review to Resolved
Actions #9

Updated by Sebastian Wagner about 3 years ago

  • Related to Bug #49551: cephadm journald logs are mangled added
Actions

Also available in: Atom PDF