Skip to content

who: recover missing SSH sessions - #16752

Closed
anastygnome wants to merge 1 commit into
uutils:mainfrom
anastygnome:fix/who-systemd-ssh-sessions
Closed

anastygnome wants to merge 1 commit into
uutils:mainfrom
anastygnome:fix/who-systemd-ssh-sessions

Conversation

@anastygnome

Copy link
Copy Markdown
Contributor

Fixes #16749

@anastygnome
anastygnome force-pushed the fix/who-systemd-ssh-sessions branch 6 times, most recently from 8582f85 to a72124d Compare November 21, 2026 14:28
@anastygnome

Copy link
Copy Markdown
Contributor Author

@cakebaker Any thoughts?

@anastygnome
anastygnome force-pushed the fix/who-systemd-ssh-sessions branch 6 times, most recently from 4cd1d58 to 0ec76bf Compare November 21, 2026 21:33
@anastygnome anastygnome changed the title who: recover SSH sessions without utmp who: recover missing SSH sessions Nov 21, 2026
@anastygnome
anastygnome force-pushed the fix/who-systemd-ssh-sessions branch from 0ec76bf to 9d0f616 Compare November 21, 2026 21:34
@codspeed

codspeed Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Merging this PR will improve performance by 52.87%

2 warnings, 1 note

⚠️ 125 benchmarks are dominated by system calls

System calls cannot be simulated consistently and are left out of the measure. The reported value understates the real cost. Switch to the Walltime instrument to measure them.

Learn more about system calls

See affected benchmarks

⚠️ 1 benchmark with a significant change ran on different hardware

Its base and head results were measured on machines with a different CPU, core count or memory, so the change might not come from the code. Run base and head on the same runner type.

Learn more about Macro Runners

See affected benchmarks

ℹ️ 1 benchmark has no flamegraph

The flamegraph wasn't generated: most of the time was spent in runtime internals, which would leave nothing useful to analyze.

See affected benchmarks

⚡ 1 improved benchmark
✅ 414 untouched benchmarks
⏩ 70 skipped benchmarks1

Performance Changes

Mode Benchmark BASE HEAD Efficiency
⚡ Memory timeout_enforced 151.8 KB 99.3 KB +52.87%

Tip

Curious why performance improved? Comment @codspeedbot explain why performance improved on this PR, or directly use the CodSpeed MCP with your agent.


Comparing anastygnome:fix/who-systemd-ssh-sessions (a54203d) with main (4ad8d9d)

Open in CodSpeed

Footnotes

  1. 70 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

@anastygnome
anastygnome force-pushed the fix/who-systemd-ssh-sessions branch 9 times, most recently from bbe70dc to 993ebd6 Compare November 22, 2026 08:51
@anastygnome

Copy link
Copy Markdown
Contributor Author

/rerun Android

@xtqqczze

This comment was marked as outdated.

@anastygnome
anastygnome force-pushed the fix/who-systemd-ssh-sessions branch from 993ebd6 to d5228ad Compare November 22, 2026 16:06
@sylvestre
sylvestre force-pushed the fix/who-systemd-ssh-sessions branch from d5228ad to 9c7641a Compare November 23, 2026 22:55
@anastygnome

Copy link
Copy Markdown
Contributor Author

/rerun

@sylvestre
sylvestre force-pushed the fix/who-systemd-ssh-sessions branch from 9c7641a to a54203d Compare November 26, 2026 07:26
@sylvestre

Copy link
Copy Markdown
Contributor

Sorry but it needs to be redone: the pty guessing (5s ctime window on /dev/pts, smallest ctime, the "web" branch) follows gnulib's readutmp.c too closely, and we can't accept GNU-derived code.

@sylvestre sylvestre closed this Nov 27, 2026
@anastygnome

Copy link
Copy Markdown
Contributor Author

@sylvestre I don't understand

how should we proceed,

We need to get the same output for web, and we need to get the Pty, gnu does a heuristic, so either we don't support web, or we have a different output

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

who: SSH sessions are not listed when utmp is missing (systemd-logind backend)

3 participants