Screenshot
I've got a fresh install of Ubuntu 22.04 Server.
I installed Slim and ubuntu-desktop afterwards to get a GUI.
When I login to the GUI and open the Software Updater it tells me "You are not allowed to perform this action" and doesn't ask me for my password. So I can't use it to install updates.
I had a similar issue on Linux Mint some time ago where I installed xdrp and from some guide put in some workarounds to make it work. That stopped PolicyKit from working properly. I'm also using xdrp again, but this time I didn't make the same mistake.
I only found quite some old topics here for old versions but none of them really had a solution from what I can see.
Is there any way to see what the issue really is and to fix it?
Someone asked for some output in another thread which might be helpful as well.
Authentication Error: Software can't be installed or removed | You are not allowed to perform this action
ubuntu@digioso:~$ groups
ubuntu adm dialout cdrom floppy sudo audio dip video plugdev netdev lxd admin
ubuntu@digioso:~$ sudo echo success
success
ubuntu@digioso:~$ pkexec echo success
==== AUTHENTICATING FOR org.freedesktop.policykit.exec ===
Authentication is needed to run `/usr/bin/echo' as the super user
Multiple identities can be used for authentication:
1. Ubuntu (ubuntu)
2. Ubuntu (ubuntu)
Choose identity to authenticate as (1-2): 1
Password:
polkit-agent-helper-1: error response to PolicyKit daemon: GDBus.Error:org.freedesktop.PolicyKit1.Error.Failed: No session for cookie
==== AUTHENTICATION FAILED ===
Error executing command as another user: Not authorized
This incident has been reported.
ubuntu@digioso:~$ pkexec echo success
==== AUTHENTICATING FOR org.freedesktop.policykit.exec ===
Authentication is needed to run `/usr/bin/echo' as the super user
Multiple identities can be used for authentication:
1. Ubuntu (ubuntu)
2. Ubuntu (ubuntu)
Choose identity to authenticate as (1-2): 2
Password:
polkit-agent-helper-1: error response to PolicyKit daemon: GDBus.Error:org.freedesktop.PolicyKit1.Error.Failed: No session for cookie
==== AUTHENTICATION FAILED ===
Error executing command as another user: Not authorized
This incident has been reported.
ubuntu@digioso:~$
ubuntu@digioso:~$ systemctl status polkit.service
● polkit.service - Authorization Manager
Loaded: loaded (/lib/systemd/system/polkit.service; static)
Active: active (running) since Wed 2023-01-04 20:28:28 CET; 1 day 13h ago
Docs: man:polkit(8)
Main PID: 936
Tasks: 3 (limit: 28694)
Memory: 5.3M
CPU: 911ms
CGroup: /system.slice/polkit.service
└─936 /usr/libexec/polkitd --no-debug
Jan 05 21:08:26 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Unregistered Authentication Agent for unix-process:306901:8860360 (system bus name>
Jan 05 21:08:35 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Registered Authentication Agent for unix-process:306901:8860360 (system bus name :>
Jan 05 21:08:44 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Operator of unix-process:306901:8860360 FAILED to authenticate to gain authorizati>
Jan 05 21:08:44 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Unregistered Authentication Agent for unix-process:306901:8860360 (system bus name>
Jan 05 21:10:48 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Registered Authentication Agent for unix-process:306901:8860360 (system bus name :>
Jan 05 21:10:53 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Operator of unix-process:306901:8860360 FAILED to authenticate to gain authorizati>
Jan 05 21:10:53 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Unregistered Authentication Agent for unix-process:306901:8860360 (system bus name>
Jan 05 21:10:54 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Registered Authentication Agent for unix-process:306901:8860360 (system bus name :>
Jan 05 21:10:59 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Operator of unix-process:306901:8860360 FAILED to authenticate to gain authorizati>
Jan 05 21:10:59 digioso.subnet12221621.vcn12221621.oraclevcn.com polkitd(authority=local)[936]: Unregistered Authentication Agent for unix-process:306901:8860360 (system bus name>
ubuntu@digioso:~$
Thanks @lucius, but I feat that I have a different problem.
root@digioso:/etc/polkit-1/localauthority.conf.d# ls -lart
total 16
-rw-r--r-- 1 root root 65 Feb 26 2022 51-ubuntu-admin.conf
-rw-r--r-- 1 root root 267 Feb 26 2022 50-localauthority.conf
drwxr-xr-x 4 root root 4096 Nov 6 03:31 ..
drwxr-xr-x 2 root root 4096 Nov 6 03:32 .
root@digioso:/etc/polkit-1/localauthority.conf.d# cat ^C
root@digioso:/etc/polkit-1/localauthority.conf.d# cat 51-ubuntu-admin.conf
[Configuration]
AdminIdentities=unix-group:sudo;unix-group:admin
root@digioso:/etc/polkit-1/localauthority.conf.d# cat 50-localauthority.conf
# Configuration file for the PolicyKit Local Authority.
#
# DO NOT EDIT THIS FILE, it will be overwritten on update.
#
# See the pklocalauthority(8) man page for more information
# about configuring the Local Authority.
#
[Configuration]
AdminIdentities=unix-user:0
root@digioso:/etc/polkit-1/localauthority.conf.d#