Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Plasma troubleshooting with elogind
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Belliash
Advocate
Advocate


Joined: 24 Nov 2004
Posts: 2456
Location: Wroclaw, Poland

PostPosted: Sun Jul 28, 2019 10:08 am    Post subject: Plasma troubleshooting with elogind Reply with quote

Hello,

I have bought a new computer and installed a fresh Gentoo Linux system on it. I have heard that consolekit seems to be deprecated and is no longer under active development. It has been recommended to me to use elogind. Actually I come across several problems:

1. I cannot reboot nor shutdown computer from plasma. Doing such action results in getting back to SDDM, when I need to click 'Reboot' once again.
2. Any action in nm-plasma result in 'Insufficient privileges' .

Below I put some additional information from my system. If you need more data, please let me know.

/var/log/messages wrote:
Jul 28 10:33:28 BelliashPC NetworkManager[3045]: <info> [1564302808.5589] audit: op="connection-add" pid=4429 uid=1000 result="fail" reason="Insufficient privileges."


dmesg | grep elogind wrote:
[ 4.474939] elogind-daemon[2844]: New seat seat0.
[ 4.475345] elogind-daemon[2844]: Watching system buttons on /dev/input/event1 (Power Button)
[ 4.475399] elogind-daemon[2844]: Watching system buttons on /dev/input/event0 (Power Button)
[ 4.475481] elogind-daemon[2844]: Watching system buttons on /dev/input/event4 (Logitech G500s Laser Gaming Mouse Keyboard)
[ 4.475559] elogind-daemon[2844]: Watching system buttons on /dev/input/event5 (Logitech G500s Laser Gaming Mouse Consumer Control)
[ 4.475607] elogind-daemon[2844]: Watching system buttons on /dev/input/event2 (AT Translated Set 2 keyboard)
[ 7.552460] elogind-daemon[2844]: New session c1 of user sddm.
[ 124.576511] elogind-daemon[2844]: New session 2 of user belliash.
[ 124.637126] elogind-daemon[2844]: Removed session c1.


cat /var/log/messages | grep -e 'elogind' -e 'polkit' wrote:
Jul 28 11:06:36 BelliashPC polkitd[4124]: Reloading rules
Jul 28 11:06:36 BelliashPC polkitd[4124]: Collecting garbage unconditionally...
Jul 28 11:06:36 BelliashPC polkitd[4124]: Loading rules from directory /etc/polkit-1/rules.d
Jul 28 11:06:36 BelliashPC polkitd[4124]: Loading rules from directory /usr/share/polkit-1/rules.d
Jul 28 11:06:36 BelliashPC polkitd[4124]: Finished loading, compiling and executing 4 rules
Jul 28 11:06:36 BelliashPC polkitd[4124]: Reloading rules
Jul 28 11:06:36 BelliashPC polkitd[4124]: Collecting garbage unconditionally...
Jul 28 11:06:36 BelliashPC polkitd[4124]: Loading rules from directory /etc/polkit-1/rules.d
Jul 28 11:06:36 BelliashPC polkitd[4124]: Loading rules from directory /usr/share/polkit-1/rules.d
Jul 28 11:06:36 BelliashPC polkitd[4124]: Finished loading, compiling and executing 4 rules
Jul 28 11:07:37 BelliashPC polkitd[4124]: Reloading rules
Jul 28 11:07:37 BelliashPC polkitd[4124]: Collecting garbage unconditionally...
Jul 28 11:07:37 BelliashPC polkitd[4124]: Loading rules from directory /etc/polkit-1/rules.d
Jul 28 11:07:37 BelliashPC polkitd[4124]: Loading rules from directory /usr/share/polkit-1/rules.d
Jul 28 11:07:37 BelliashPC polkitd[4124]: Finished loading, compiling and executing 4 rules
Jul 28 11:07:37 BelliashPC polkitd[4124]: Reloading rules
Jul 28 11:07:37 BelliashPC polkitd[4124]: Collecting garbage unconditionally...
Jul 28 11:07:37 BelliashPC polkitd[4124]: Loading rules from directory /etc/polkit-1/rules.d
Jul 28 11:07:37 BelliashPC polkitd[4124]: Loading rules from directory /usr/share/polkit-1/rules.d
Jul 28 11:07:37 BelliashPC polkitd[4124]: Finished loading, compiling and executing 4 rules
Jul 28 11:35:10 BelliashPC kernel: elogind-daemon[2843]: Removed session 3.
Jul 28 11:35:11 BelliashPC kernel: elogind-daemon[2843]: New session c3 of user sddm.
Jul 28 11:35:13 BelliashPC kernel: elogind-daemon[2843]: System is rebooting..
Jul 28 11:35:13 BelliashPC kernel: elogind-daemon[2843]: Received signal 15 [TERM]
Jul 28 11:35:13 BelliashPC polkitd[4124]: Lost the name org.freedesktop.PolicyKit1 - exiting
Jul 28 11:35:13 BelliashPC sddm-helper[23184]: pam_elogind(sddm-greeter:session): Failed to release session: Connection reset by peer
Jul 28 11:35:50 BelliashPC polkitd[3236]: Started polkitd version 0.116
Jul 28 11:35:50 BelliashPC polkitd[3236]: Loading rules from directory /etc/polkit-1/rules.d
Jul 28 11:35:50 BelliashPC polkitd[3236]: Loading rules from directory /usr/share/polkit-1/rules.d
Jul 28 11:35:50 BelliashPC polkitd[3236]: Finished loading, compiling and executing 4 rules
Jul 28 11:35:50 BelliashPC polkitd[3236]: Acquired the name org.freedesktop.PolicyKit1 on the system bus
Jul 28 11:35:53 BelliashPC kernel: elogind-daemon[2844]: New session c1 of user sddm.
Jul 28 11:37:50 BelliashPC kernel: elogind-daemon[2844]: New session 2 of user belliash.
Jul 28 11:37:50 BelliashPC kernel: elogind-daemon[2844]: Removed session c1.


cat /etc/portage/make.conf wrote:
CHOST="x86_64-pc-linux-gnu"
CFLAGS="-march=znver2 -mtune=znver2 -O2 -s -pipe -fomit-frame-pointer"
CXXFLAGS="${CFLAGS}"
LDFLAGS="-Wl,-O1,--enable-new-dtags,--sort-common,--hash-style=both,--as-needed"
CPU_FLAGS_X86="aes apng avx avx2 f16c fma3 mmx mmxext pclmul popcnt sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3"
USEFLAGS="a52 aac acpi alsa apng autotype bash bash-completion bluray browser cacert cairo caps cgroups chm corefonts cups cxx dbus default-gold dvd efi egl elogind exif experimental ffmpeg flac gif gnome-keyring gold graphite gtk http2 icu introspection ipv6 jit jpeg kde leaps_timezone librtmp lm_sensors lto lzma matroska minizip mng mp3 mpeg netifrc networkmanager nls nptl nsplugin nss ogg opengl openssl pcre16 pcre32 phonon plasma png policykit pulseaudio qt5 scanner sha3 sqlite ssl svg symlink tahoma text tiff truetype udev unicode usb utils vaapi vdpau vim-syntax vnc vorbis vpx wayland X x264 x265 xcomposite xkb xvid zsh-completion -consolekit -filecaps -llvm -wext -wifi"

# Locales
L10N="en"
LINGUAS="en"
LANG="en_US"
LC_ALL="en_US"

# Mirrors
GENTOO_MIRRORS="http://gentoo.mirror.web4u.cz/"

# Portage Settings
ABI_X86="32 64"
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
AUTOCLEAN="yes"
CLEAN_DELAY="0"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/env.d"
DISTDIR="/usr/distfiles"
EMERGE_DEFAULT_OPTS="--ask --verbose --with-bdeps y"
EMERGE_WARNING_DELAY="5"
FEATURES="candy clean-logs nodoc parallel-fetch parallel-install sfperms sandbox splitdebug strict userfetch userpriv usersandbox"
GRUB_PLATFORMS="pc"
INPUT_DEVICES="evdev keyboard mouse"
MAKEOPTS="-j24 -s"
PORT_LOGDIR="/var/log/portage"
PORT_LOGDIR_CLEAN="find \"\${PORT_LOGDIR}\" -type f ! -name \"summary.log*\" -mtime +5 -delete"
PORTDIR="/usr/repos/gentoo-portage"
PORTAGE_COMPRESS="bzip2"
PORTAGE_COMPRESS_FLAGS="--best"
PORTAGE_ECLASS_WARNING_ENABLE="0"
PORTAGE_TMPDIR="/var/tmp"
PYTHON_SINGLE_TARGET="python3_7"
PYTHON_TARGETS="python2_7 python3_7"
QEMU_SOFTMMU_TARGETS="i386 x86_64"
SANE_BACKENDS="net"
USE="${USEFLAGS}"
VIDEO_CARDS="nouveau"


cat /etc/polkit-1/rules.d/50-org.freedesktop.NetworkManager.rules wrote:
polkit.addRule(function(action, subject) {
if (action.id.indexOf("org.freedesktop.NetworkManager.") == 0 && subject.isInGroup("plugdev")) {
return polkit.Result.YES;
}
});


loginctl wrote:
SESSION UID USER SEAT TTY
2 1000 belliash seat0

1 sessions listed.


loginctl user-status wrote:
Could not get properties: Caller does not belong to any logged in user or lingering user


loginctl unlock-session wrote:
Error registering authentication agent: GDBus.Error:org.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject (polkit-error-quark, 0)


id wrote:
uid=1000(belliash) gid=1000(belliash) groups=1000(belliash),10(wheel),16(cron),18(audio),19(cdrom),27(video),78(kvm),80(cdrw),85(usb),97(input),100(users),102(wireshark),103(scanner),105(polkitd),247(crontab),999(plugdev)


rc-status wrote:
Runlevel: default
hdparm [ started ]
dbus [ started ]
net.eno1 [ started ]
net.tap1 [ started ]
net.br1 [ started ]
NetworkManager [ started ]
netmount [ started ]
syslog-ng [ started ]
ntp-client [ started ]
consolefont [ started ]
xdm [ started ]
cronie [ started ]
sshd [ started ]
local [ started ]
Dynamic Runlevel: hotplugged
Dynamic Runlevel: needed/wanted
xdm-setup [ started ]
Dynamic Runlevel: manual


rc-update wrote:
NetworkManager | default
binfmt | boot
bootmisc | boot
cgroups | sysinit
consolefont | default
cronie | default
dbus | default
devfs | sysinit
dmesg | sysinit
elogind | boot
fsck | boot
hdparm | default
hostname | boot
hwclock | boot
keymaps | boot
killprocs | shutdown
kmod-static-nodes | sysinit
local | default nonetwork
localmount | boot
loopback | boot
modules | boot
mount-ro | shutdown
mtab | boot
net.br1 | default
net.eno1 | default
net.tap1 | default
netmount | default
ntp-client | default
opentmpfiles-dev | sysinit
opentmpfiles-setup | boot
procfs | boot
root | boot
save-keymaps | boot
save-termencoding | boot
savecache | shutdown
sshd | default
swap | boot
sysctl | boot
sysfs | sysinit
syslog-ng | default
termencoding | boot
udev | sysinit
udev-trigger | sysinit
urandom | boot
xdm | default

_________________
Asio Software Technologies
Belliash IT Weblog
Back to top
View user's profile Send private message
asturm
Developer
Developer


Joined: 05 Apr 2007
Posts: 7480
Location: Austria

PostPosted: Sun Jul 28, 2019 10:44 am    Post subject: Reply with quote

Code:
$ eselect profile list
$ emerge -vp plasma-meta

_________________
backend.cpp:92:2: warning: #warning TODO - this error message is about as useful as a cooling unit in the arctic
Back to top
View user's profile Send private message
Belliash
Advocate
Advocate


Joined: 24 Nov 2004
Posts: 2456
Location: Wroclaw, Poland

PostPosted: Sun Jul 28, 2019 11:06 am    Post subject: Reply with quote

eselect profile list:
Available profile symlink targets:
  [1]   default/linux/amd64/17.0 (stable)
  [2]   default/linux/amd64/17.0/selinux (stable)
  [3]   default/linux/amd64/17.0/hardened (stable)
  [4]   default/linux/amd64/17.0/hardened/selinux (stable)
  [5]   default/linux/amd64/17.0/desktop (stable)
  [6]   default/linux/amd64/17.0/desktop/gnome (stable)
  [7]   default/linux/amd64/17.0/desktop/gnome/systemd (stable)
  [8]   default/linux/amd64/17.0/desktop/plasma (stable)
  [9]   default/linux/amd64/17.0/desktop/plasma/systemd (stable)
  [10]  default/linux/amd64/17.0/developer (stable)
  [11]  default/linux/amd64/17.0/no-multilib (stable)
  [12]  default/linux/amd64/17.0/no-multilib/hardened (stable)
  [13]  default/linux/amd64/17.0/no-multilib/hardened/selinux (stable)
  [14]  default/linux/amd64/17.0/systemd (stable)
  [15]  default/linux/amd64/17.0/x32 (dev)
  [16]  default/linux/amd64/17.1 (stable) *
  [17]  default/linux/amd64/17.1/selinux (stable)
  [18]  default/linux/amd64/17.1/hardened (stable)
  [19]  default/linux/amd64/17.1/hardened/selinux (stable)
  [20]  default/linux/amd64/17.1/desktop (stable)
  [21]  default/linux/amd64/17.1/desktop/gnome (stable)
  [22]  default/linux/amd64/17.1/desktop/gnome/systemd (stable)
  [23]  default/linux/amd64/17.1/desktop/plasma (stable)
  [24]  default/linux/amd64/17.1/desktop/plasma/systemd (stable)
  [25]  default/linux/amd64/17.1/developer (stable)
  [26]  default/linux/amd64/17.1/no-multilib (stable)
  [27]  default/linux/amd64/17.1/no-multilib/hardened (stable)
  [28]  default/linux/amd64/17.1/no-multilib/hardened/selinux (stable)
  [29]  default/linux/amd64/17.1/systemd (stable)
  [30]  default/linux/amd64/17.0/musl (exp)
  [31]  default/linux/amd64/17.0/musl/hardened (exp)
  [32]  default/linux/amd64/17.0/musl/hardened/selinux (exp)
  [33]  default/linux/amd64/17.0/uclibc (exp)
  [34]  default/linux/amd64/17.0/uclibc/hardened (exp)


emerge -vp plasma-meta:
These are the packages that would be merged, in order:

Calculating dependencies                                     ... done! 
[ebuild   R    ] kde-plasma/plasma-meta-5.16.3:5::gentoo  USE="crypt desktop-portal display-manager elogind gtk handbook legacy-systray networkmanager pam pm-utils pulseaudio sddm wallpapers -bluetooth -browser-integration -consolekit -discover -grub -plymouth -sdk -systemd" 0 KiB

Total: 1 package (1 reinstall), Size of downloads: 0 KiB


[Moderator edit: changed [quote] tags to [code] tags to preserve output layout. -Hu]
_________________
Asio Software Technologies
Belliash IT Weblog
Back to top
View user's profile Send private message
shazeal
Apprentice
Apprentice


Joined: 03 May 2006
Posts: 200
Location: New Zealand

PostPosted: Tue Jul 30, 2019 9:25 am    Post subject: Reply with quote

I just went through this myself, pretty sure you need to add dbus to fix this.

rc-update add dbus default

I couldn't get NetworkManager with plasma-nm to work correctly at all, I use WiFi and it would never remember the PSK. In the end I just removed network manager and am using dhcpcd + iwd which is working perfectly.
_________________
CFLAGS="-OmgWTFR1CE --fun-lol-loops --march=asmx86go"
Back to top
View user's profile Send private message
mirekm
Apprentice
Apprentice


Joined: 12 Feb 2004
Posts: 192
Location: Gliwice

PostPosted: Tue Jul 30, 2019 9:40 am    Post subject: Reply with quote

Belliash, I suppose, that you use option hidepid=2 for proc mount.
If so, you have to change it to:
mount -o remount,hidepid=2,gid=polkitd /proc

This should solve your problem.
Back to top
View user's profile Send private message
Fitzcarraldo
Veteran
Veteran


Joined: 30 Aug 2008
Posts: 1787
Location: United Kingdom

PostPosted: Tue Jul 30, 2019 11:14 am    Post subject: Reply with quote

shazeal wrote:
I couldn't get NetworkManager with plasma-nm to work correctly at all, I use WiFi and it would never remember the PSK. In the end I just removed network manager and am using dhcpcd + iwd which is working perfectly.

I wonder why you had trouble with plasma-nm and NetworkManager. I have two laptops with differing hardware -- one using ~amd64, the other amd64 -- both with elogind, plasma-nm and NetworkManager. Wi-Fi using WPA-PSK/WPA2-PSK works on both. You sound like you are satisfied with your current setup using dhcpcd with iwd, but if you ever want to investigate NetworkManager with plasma-nm let me know here if you want listings of any settings, config files, USE flags, etc.
_________________
Clevo W230SS: amd64 nvidia-drivers & xf86-video-intel.
Compal NBLB2: ~amd64 xf86-video-ati. Dual boot Win 7 Pro 64-bit.
OpenRC eudev elogind & KDE on both.

Fitzcarraldo's blog
Back to top
View user's profile Send private message
Belliash
Advocate
Advocate


Joined: 24 Nov 2004
Posts: 2456
Location: Wroclaw, Poland

PostPosted: Tue Jul 30, 2019 3:59 pm    Post subject: Reply with quote

mirekm wrote:
Belliash, I suppose, that you use option hidepid=2 for proc mount.
If so, you have to change it to:
mount -o remount,hidepid=2,gid=polkitd /proc

This should solve your problem.


Hah, Adding "gid=polkitd" mount option to /proc did the trick.
Everything is working as expected now. Thanks!
_________________
Asio Software Technologies
Belliash IT Weblog
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum