This topic created in 1768 days ago, the information mentioned may be changed or developed.
系统用的 ubuntu20.04 ,界面管理用的 lightdm,开机自启了一个界面管理程序 deskmanger 。~/.profile 管理。现在在操作过程中 有一个摘显卡操作,但是 deskmange,会被 session 会话给 kill 掉,各位有什么好方法。让程序不被 session kill ?
下边是一些系统日志:
Jun 23 17:26:29 user systemd[1]: session-c10.scope: Stopping timed out. Killing.
Jun 23 17:26:29 user systemd[1]: session-c10.scope: Killing process pid with signal SIGKILL.
Jun 23 17:26:29 user systemd[1]: session-c10.scope: Failed with result 'timeout'.
5 replies 2021-06-24 16:03:23 +08:00  | | 1 myd Jun 23, 2021 摘显卡,好奇,这是啥需求 |
 | | 2 dzdh Jun 23, 2021 摘??显卡?? |
 | | 5 SiYuetian Jun 24, 2021 已解决; 利用了 systemd-run --scope --user xxxxx 将需要的执行的进程 利用 systemd-run 制作一个临时态 scope,相当于将执行权限交给了 systemd,系统层不由 user-session 管理,所以将 user-session stop,之后进程仍然存在。注意 /etc/systemd/logind.conf 中 KillUserProcess=no,设置 user session 退出时,不会关闭进程。 |