mtcAgent process stops when console times out

Bug #1999049 reported by Michel Thebeau [WIND]
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
Fix Released
Medium
Davi Frossard

Bug Description

Brief Description

After bootstrap the mtcAgent process does not persist of the console times out

Severity

Minor

Steps to Reproduce

Bootstrap a controller-0 using the console. After bootstrap watch the mtcAgent process in another shell, and set 'export TMOUT=10' on the console. When the console times out the mtcAgent will go away.

Expected Behavior

mtcAgent is not dependant on console

Actual Behavior

mtcAgent goes away when the console times out.

Reproducibility

Yes

System Configuration

Any, probably

Load info (eg: 2022-03-10_20-00-07)

Starlingx, November 17 and later

Last Pass

Uncertain. Maybe before: https://review.opendev.org/c/starlingx/config-files/+/861633)

Timestamp/Logs

Ten seconds after this bash log:
2022-11-17T23:22:09.000 localhost -sh: info HISTORY: PID=1871 UID=42425 export TMOUT=10

Alarms

fm alarm-list doesn't work

Test Activity

Generic, unrelated

Workaround

Do not let console time out after bootstrap and before unlock. Probably use "export TMOUT=99999999" before ansible bootstrap.

description: updated
Changed in starlingx:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to stx-puppet (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/starlingx/stx-puppet/+/867098

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to config-files (master)

Reviewed: https://review.opendev.org/c/starlingx/config-files/+/866211
Committed: https://opendev.org/starlingx/config-files/commit/50c4560b3f68fd8f3f58b8f48eec154fcc76f19f
Submitter: "Zuul (22348)"
Branch: master

commit 50c4560b3f68fd8f3f58b8f48eec154fcc76f19f
Author: Davi Frossard <email address hidden>
Date: Wed Nov 30 15:29:01 2022 -0500

    Workaround for console session timeout terminating user processes

    The change https://review.opendev.org/c/starlingx/config-files/+/861633
    causes an unexpected behavior of systemd, terminating user processes
    in case of session timeout after bootstrap and before unlock. As a
    workaround, this change disables session timeout.

    Test Plan:
    [PASS] Install, bootstrap and unlock.
    [PASS] Verify env variable TMOUT is set to 0.
    [PASS] Wait long time (more than 15min) and verify that seession still open.

    Partial-Bug: 1999049

    Signed-off-by: Davi Frossard <email address hidden>
    Change-Id: If72a29119917a91ded2d0d3bd2a12013794c1448

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to stx-puppet (master)

Reviewed: https://review.opendev.org/c/starlingx/stx-puppet/+/867098
Committed: https://opendev.org/starlingx/stx-puppet/commit/dd82356a9c4f3e07a4670b5f280ff8092995c0e4
Submitter: "Zuul (22348)"
Branch: master

commit dd82356a9c4f3e07a4670b5f280ff8092995c0e4
Author: Davi Frossard <email address hidden>
Date: Fri Dec 9 08:09:45 2022 -0500

    Workaround for console session timeout terminating user processes

    The change https://review.opendev.org/c/starlingx/config-files/+/861633
    causes an unexpected behavior of systemd, terminating user processes
    in case of session timeout after bootstrap and before unlock. As a
    workaround, the change
    https://review.opendev.org/c/starlingx/config-files/+/866211
    increases session timeout from 15min to 24h. In order to restore the
    default value, after unlock this change decreases back session timeout
    from 24h to 15min.

    Test Plan:
    [PASS] Install, bootstrap and unlock.
    [PASS] After unlock, verify TMOUT is set back to 900s (15min).

    Partial-Bug: 1999049
    Depends-on: https://review.opendev.org/c/starlingx/config-files/+/866211

    Signed-off-by: Davi Frossard <email address hidden>
    Change-Id: I2844df0fa52408b689aa179224b3530b33641bd9

Ghada Khalil (gkhalil)
Changed in starlingx:
assignee: nobody → Davi Frossard (dbarrosf)
importance: Undecided → Medium
tags: added: stx.8.0 stx.config stx.metal
Revision history for this message
Ghada Khalil (gkhalil) wrote :

Marking as Fix Released as the above two reviews have merged and there doesn't seem to be any further activity

Changed in starlingx:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.opendev.org/c/starlingx/stx-puppet/+/870667
Committed: https://opendev.org/starlingx/stx-puppet/commit/a09e31f934c28b245337278ae7c9828953d3b6a8
Submitter: "Zuul (22348)"
Branch: master

commit a09e31f934c28b245337278ae7c9828953d3b6a8
Author: Davi Frossard <email address hidden>
Date: Mon Jan 16 13:24:21 2023 -0500

    Workaround for console session timeout terminating user processes

    The change https://review.opendev.org/c/starlingx/config-files/+/861633
    causes an unexpected behavior of systemd, terminating user processes
    in case of session timeout, between the moment after bootstrap and before unlock. As a workaround, this change removes pam_systemd.so from PAM common-session file during bootstrap, avoiding the issue and also performance degradation.

    Following changes must be reverted:
    https://review.opendev.org/c/starlingx/config-files/+/866211
    https://review.opendev.org/c/starlingx/stx-puppet/+/867098
    https://review.opendev.org/c/starlingx/config-files/+/861633

    Test Plan (Debian AIO-SX):
    [PASS] Install, bootstrap and unlock.
    [PASS] Verify "pam_systemd.so" config is removed after bootstrap.
    [PASS] Verify there is no extra "systemd --user" processes running in
    background.
    [PASS] Verify no issues occur in standard upgrade scenario or during runtime manifest apply.

    Partial-Bug: 1999049
    Signed-off-by: Davi Frossard <email address hidden>
    Change-Id: I3c8964b1aa961fcea51f65205bfdbf8d39241569

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.opendev.org/c/starlingx/stx-puppet/+/875011
Committed: https://opendev.org/starlingx/stx-puppet/commit/585850afe1fbeea0059ee9809c001345ff88d62f
Submitter: "Zuul (22348)"
Branch: master

commit 585850afe1fbeea0059ee9809c001345ff88d62f
Author: Davi Frossard <email address hidden>
Date: Fri Feb 24 11:59:26 2023 +0000

    Revert "Workaround for console session timeout terminating user processes"

    This reverts commit dd82356a9c4f3e07a4670b5f280ff8092995c0e4.

    Reason for revert: see https://review.opendev.org/c/starlingx/stx-puppet/+/870667

    Partial-Bug: 1999049
    Change-Id: Ife29714e9ca6406f86ff8c411e6e21964af4a38b

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to config-files (master)

Reviewed: https://review.opendev.org/c/starlingx/config-files/+/875010
Committed: https://opendev.org/starlingx/config-files/commit/37796a511d2ba66fc918033e3c00a9b85f399545
Submitter: "Zuul (22348)"
Branch: master

commit 37796a511d2ba66fc918033e3c00a9b85f399545
Author: Davi Frossard <email address hidden>
Date: Fri Feb 24 11:58:47 2023 +0000

    Revert "Workaround for console session timeout terminating user processes"

    This reverts commit 50c4560b3f68fd8f3f58b8f48eec154fcc76f19f.

    Reason for revert: see https://review.opendev.org/c/starlingx/stx-puppet/+/870667

    Partial-Bug: 1999049
    Change-Id: Ib095bcca63662c2637871afb90833aa2a341481d

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.opendev.org/c/starlingx/config-files/+/874849
Committed: https://opendev.org/starlingx/config-files/commit/7a410eea860781428a3d0151011556fd91e2aaa4
Submitter: "Zuul (22348)"
Branch: master

commit 7a410eea860781428a3d0151011556fd91e2aaa4
Author: Davi Frossard <email address hidden>
Date: Fri Feb 24 11:57:03 2023 +0000

    Revert "debian: Remove pam_systemd.so from common-session"

    This reverts commit 8c1fb8d471af1c54f9a2e2e31a455227570e54d5.

    Reason for revert: see https://review.opendev.org/c/starlingx/stx-puppet/+/870667

    Partial-Bug: 1999049
    Change-Id: I33c2dda6c20b2547a66b8f3feaccd00f80d7ad8a

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.