/run/user/1000目录归属异常引发Snap及系统相关问题求助
/run/user/1000目录归属异常引发Snap及系统相关问题求助
大家好,我最近碰到了一堆和Snap相关的故障,查了半天发现根源似乎是系统里的/run/user/1000目录权限归属出了问题,想请各位大佬帮忙支招。
首先,我执行了这个命令查看显示管理器状态:
systemctl status display-manager
得到的输出里有这些关键错误信息:
gkr-pam: unable to locate daemon control file gkr-pam: stashed password to try later in open session pam_unix(gdm-password:session): session opened for user jhon(uid=1000) by (uid=0) pam_systemd(gdm-password:session): Runtime directory '/run/user/1000' is not owned by UID 1000, as it should pam_systemd(gdm-password:session): Not setting $XDG_RUNTIME_DIR, as the directory is not in order. gkr-pam: gnome-keyring-daemon started properly and unlocked keyring Gdm: process -888 was already dead.r
其中pam_systemd提示的/run/user/1000不属于UID 1000,导致$XDG_RUNTIME_DIR没设置,我怀疑这就是Snap问题的源头。
现在的Snap问题具体表现为打不开Firefox,启动时会弹出这些错误:
cmd_run.go:1055: WARNING: cannot start document portal: Expected portal at "run/user/1000/doc", got "/home/pablo/.cache/doc" /user.slice/user-1000.slice/session-2.scope is not a snap cgroup
我试过用chmod修改目录权限,但完全没用,实在不知道该怎么办了,求大家帮忙!
备注:内容来源于stack exchange,提问作者P2000Gua
相关产品推荐
相关产品推荐

