You are not logged in.

#1 2012-02-17 07:07:57

OakRaider4Life
Member
Registered: 2012-02-08
Posts: 98

X Server being uncooperative?

I've recently installed Arch Linux and installed a KDE desktop as my graphical environment, but starting the graphical environment has presented some confusing abnormalities. When I attempt the command

startkde

, I'm met with an error saying "$Display is not set or can't connect to X server". However, when I run

kdm

, it starts up the kde environment with no problems. This is confusing and annoying, for one, because I can't use ALT-CTRL F7 to switch back into kde after I switch into a tty session with ALT-CTRL F1, and I'm not sure what other problems may derive from this apparent lack of connection which I haven't even encountered yet. Any help on this topic would be greatly appreciated! I'm running an intel video chipset, and followed the instructions for configuring an intel video chip on the Arch wiki. Happy to provide any other needed information!

Offline

#2 2012-02-17 07:13:16

Gcool
Member
Registered: 2011-08-16
Posts: 1,456

Re: X Server being uncooperative?

Have a look here. I'm guessing you would want the .xinitrc approach.

Last edited by Gcool (2012-02-17 07:14:24)


Burninate!

Offline

#3 2012-02-17 07:21:59

OakRaider4Life
Member
Registered: 2012-02-08
Posts: 98

Re: X Server being uncooperative?

I've checked out the xinitrc wiki page as well, but the problem is the xinitirc file simply tells the system to execute

startkde

on boot... a command which returns the aforementioned error in my case.

Offline

#4 2012-02-17 07:30:24

Gcool
Member
Registered: 2011-08-16
Posts: 1,456

Re: X Server being uncooperative?

So when you add

exec ck-launch-session startkde

to .xinitrc in your home directory and then run "startx", you get the exact same issue?

Does the .xsession-errors file in your home directory contain any related entries?


Burninate!

Offline

#5 2012-02-17 08:38:12

Cdh
Member
Registered: 2009-02-03
Posts: 1,098

Re: X Server being uncooperative?

First, you can enable the SysRq keys:
https://wiki.archlinux.org/index.php/Ke … uts#Kernel
That way you can press alt+print+r which releases your nonresponding controls stuck in X and do ctrl+alt+f1.

Then, you should check if you really have xf86-input-evdev installed xf86-input-keyboard and xf86-input-mouse wouldn't be bad either I think.

If it still doesn't work have a look at /var/log/Xorg.0.log. Maybe "grep -i" for "input" in that file. Maybe it says something meaningful.


฿ 18PRsqbZCrwPUrVnJe1BZvza7bwSDbpxZz

Offline

#6 2012-02-17 09:50:38

n0stradamus
Member
Registered: 2010-11-08
Posts: 94
Website

Re: X Server being uncooperative?

Simply entering you WMs or DEs command in the console shouldn't start the wm, because an X server  hasn't yet been provided.
That's what the xinit/startx scripts are for.

kdm will looks after the X server, which is why simply typing 'kdm' in the console works.

Have you tried using the most basic ~/.xinitrc?

exec startkde

And if I may ask out of curiosity? Why aren't you starting up kdm at boot?
If my WM provided a nice login manager for me, I'd use it smile

Last edited by n0stradamus (2012-02-17 09:51:11)

Offline

#7 2012-02-17 19:15:08

OakRaider4Life
Member
Registered: 2012-02-08
Posts: 98

Re: X Server being uncooperative?

Go figure... I displayed my newbie skills in not even attempting to finish the edit of the .xinitrc file. I gave it a shot and when logging in as the user, 'startx' started kde just as it was supposed to. No surprise that the only issue was my lack of understanding about how the X server works. Also, on the issue of not being able to change between my tty and graphical environments w/ ALT-CTRL F1-F7, I enabled sysreq, which didn't appear to make a difference, but then tried using the left side ALT-CTRL on my keyboard instead of the right side one... so not sure if it was enabling sysreq that made the difference or if my error was that simple the whole time... :-! Anyhow, my only remaining question at this point is whether there's a way I can setup 'startx' to launch kde by default when logged in as root. I understand that when running as root, X looks straight to the /etc/X11/xinit/xinitrc file, so I suppose my question is whether it's safe to replace that file with the same skeleton .xinitrc file I copied to ~.

To answer the question about why not kdm at boot, I've actually started finding the command line growing on me lately. If I ever need to do a quick piece of system administration that I wouldn't even need a graphical environment to accomplish, it seems like booting straight into a CLI could be a nifty time saver

Offline

#8 2012-02-17 19:16:18

OakRaider4Life
Member
Registered: 2012-02-08
Posts: 98

Re: X Server being uncooperative?

Which brings me to an interesting idea... Perhaps I could have two separate GRUB entries for the CLI and GUI...?

Offline

#9 2012-02-17 22:13:07

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 11,911
Website

Re: X Server being uncooperative?


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#10 2012-02-18 11:10:12

n0stradamus
Member
Registered: 2010-11-08
Posts: 94
Website

Re: X Server being uncooperative?

The page about Init and inittab may also be a good info source.
It basically boils down to:

  • Specify one runlevel for X (ideally #5) and one for console login (ideally #3)

  • Create another GRUB menu.lst entry and add the runlevel numbers at the end

To answer your question about root using X: You could do what you suggested.
I'd leave the .xinitrc in /root because that works too and leaves all the configuration in one single place.
But I'm curious, why do you need X for your root account?

Last edited by n0stradamus (2012-02-18 11:10:37)

Offline

Board footer

Powered by FluxBB