You are not logged in.
Pages: 1
I installed Plasma and it came by default with Wayland (or at least that is what it was logging into). I started using Plasma with Xorg later. But then I noticed that x applications were not working, like xclip. I installed xeyes and xclock to test it but every time I ran any of those applications I got
Authorization required, but no authorization protocol specified
Error: Can't open display: :0
I confirmed that the $DISPLAY variable has the value of :0:
$ echo $DISPLAY
:0Some posts suggested to run xhost but it got the same issue with xeyes, xclock, xclip and all other x applications: "Autorization required...". Then I noticed that .Xauthority is missing in my home directory
This answer even suggested a way to create the .Xauthority, whcih does create the magic cookie, but I started getting the error:
Invalid MIT-MAGIC-COOKIE-1 key
Error: Can't open display: :0Others suggested to just restart Plasma that the .Xauthority is re-created automatically but I already restarted many times and it hasn't been created.
Can anyone help?
Last edited by Adriano Epifas (2025-01-20 11:00:45)
Offline
You're starting plasma how? This could also be up to your hostname changing because you didn't configure one, make sure to properly configure a hostname: https://wiki.archlinux.org/title/Networ … e_hostname
If that doesn't help, post a xorg log https://wiki.archlinux.org/title/Xorg#General as well as the link you get from
sudo journalctl -b | curl -F 'file=@-' 0x0.stOffline
This answer even suggested a way to create the .Xauthority, whcih does create the magic cookie, but I started getting the error:
Don't.
Next to the information in #2, also check "echo $XAUTHORITY", SDDM uses a custom location for it.
Ftr, if $DISPLAY wasn't set the error would not include ":0"
Offline
Don't.
Next to the information in #2, also check "echo $XAUTHORITY", SDDM uses a custom location for it.
Ftr, if $DISPLAY wasn't set the error would not include ":0"
$XAUTHORITY is pointing to where the standard file should be
$ echo $XAUTHORITY
/home/myuser/.XauthorityOffline
You're starting plasma how? This could also be up to your hostname changing because you didn't configure one, make sure to properly configure a hostname: https://wiki.archlinux.org/title/Networ … e_hostname
If that doesn't help, post a xorg log https://wiki.archlinux.org/title/Xorg#General as well as the link you get from
sudo journalctl -b | curl -F 'file=@-' 0x0.st
I'm using sddm for starting plasma, and yes, the hostname was already set.
The log for Xorg.0.log is below (as suggested in the arch wiki), but the journalctl part is just too long. Can I grep something out of it?
$ grep -e tty -e Log /var/log/Xorg.0.log
[ 9.806] (--) Log file renamed from "/var/log/Xorg.pid-999.log" to "/var/log/Xorg.0.log"
[ 9.808] (==) Log file: "/var/log/Xorg.0.log", Time: Sun Jan 19 15:05:59 2025
[ 9.812] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
Offline
$ echo $XAUTHORITY
/home/myuser/.Xauthority
is most likely the problem when
I'm using sddm for starting plasma
because as mentioned that's not where SDDM puts them (it uses randomized tmpfiles)
=> Figure what sets that (probably some shell rc?) and remove it.
There's no point in setting that path explicitly, since it's the default fallback when $XAUTHORITY isn't set.
In general grepping logs isn't helpful unless you know precisely what you're looking for.
You can upload things to 0x0.st, eg
sudo journalctl -b | curl -F 'file=@-' 0x0.stbut I'm pretty sure your problem is the bogus XAUTHORITY environment.
Offline
$ echo $XAUTHORITY
/home/myuser/.Xauthorityis most likely the problem when
I'm using sddm for starting plasma
because as mentioned that's not where SDDM puts them (it uses randomized tmpfiles)
=> Figure what sets that (probably some shell rc?) and remove it.
There's no point in setting that path explicitly, since it's the default fallback when $XAUTHORITY isn't set.
You were totally right, I had copied my .bashrc from another one and had not realized that I had the $XAUTHORITY variable set there. Thanks!
Offline
Pages: 1