Recently, I switched from Ubuntu to Arch Linux. I've installed X11 as my Window System and KDE as my Desktop Environment. I've separate partition for /home, /var, / and /boot and they all mount at boot time. When I run startx, the following message gets displayed.

xauth:timeout in locking authority file /home/hello/.Xauthority

Accidently, I've deleted that file. So, I copied it from /root. I've changed it's authority using code below:

# chown hello:users ~/.Xauthority

Even after this, I'm unable to run startx unless I use root account.

  • Copying the file is a security risk. You changed its permissions (ownership), not its authority. – ctrl-alt-delor Nov 20 '13 at 13:37
  • (Re)move ~/.Xauthority and try startx again. Does it work? If not, what is the exact error message? – Adaephon Nov 20 '13 at 13:37

First a clarification, X is not a window manager, it is a windowing system.

Now, the ~/.Xauthority file is simply where the identification credentials for the current user's Xsession are stored, it is the file read when the system needs to determine if you have the right to use the current X session.

You should never copy an existing one from another account, the file should always belong to the user running X and is created automatically when you start a new X session. So, just delete the one you have, and then run startx again, everything should work as normal:

$ rm ~/.Xauthority; startx
  • Tredon, even after removing .Xauthority file. I am unable to starx. It keeps on displaying that same error. – Habi Nov 20 '13 at 13:51
  • @Habi you need to make sure there are no running X sessions, then remove the file, then run startx again. – terdon Nov 20 '13 at 13:57
  • Now, X runs but displays another message Call to Inusertemp failed(temporary directories full?). Check your installation. – Habi Nov 20 '13 at 13:57
  • @Habi ah, good, that's progress :). Please post another question for this since it is a completely different problem. In the new question, show us the output of df -h and also make sure this problem is still there after restarting. – terdon Nov 20 '13 at 14:01
  • Tredon, ya I will consider that progress. :). Btw,thanks. – Habi Nov 20 '13 at 14:04

I think an issue is that people login as root, then switch users using su -l username, which creates/spawns a subprocess under root owned by "username". X will use the .Xauthority of the top process (in this case root), which "username" does not have permission to use.

The error will be shown:

Cannot open virtual console 1 (Permission denied).

To solve this, just run login instead of su to start a new shell as a top process.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.