Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I wanted to get X windows to start, but I am stuck. I have installed PuTTY and Xming on my PC, and I have enabled X11 forwarding to display localhost:0.0. On the Archlinux remote, I have installed Xorg.
But nothing works! Doing "startx" on the remote seems to start and immediately stop the server with the following message:
Code:
error setting MTRR (base = 0xf8000000, size = 0x00400000, type = 1) Invalid argument (22)
/etc/X11/xinit/xinitrc: line 55: exec: xterm: not found
/etc/X11/xinit/xinitrc: line 54: xterm: command not found
xinit: connection to X server lost
waiting for X server to shut down error setting MTRR (base = 0xf8000000, size = 0x00400000, type = 1) Invalid argument (22)
(EE) Server terminated successfully (0). Closing log file.
Couldn't get a file descriptor referring to the console
And the PuTTY session just gives me a normal SSH command line but no graphics. What is it that I am doing wrongly?
Startx is intended to start an X server. You don't do that as you don't have control over the console display.
Using X forwarding you just start the X application. The sshd server will forward (if it is configured to do so) the X connections (as defined by the DISPLAY environment variable that sshd sets for you) and your X server (Xming on on your PC) will then display the window.
sshd is running at runlevel 3. You need to set Arch up so that sshd runs at runlevel 5. Using google I could find examples of how to do this in Red Hat and Debian but I could not find any Arch examples. Here is a link for Red Hat and Debian:
"On Debian boxes, save this script to your /etc/init.d directory. Then, use update-rc.d to create the symlinks to the appropriate runlevel directories.
update-rc.d -f ssh defaults 20
This will set sshd to start in multiuser runlevels."
If you look in the /etc/ssh/sshd_config there is a line (usually commented out) for XForwarding, and the default value. If the value is no, you can uncomment and change the value to yes. Personally, I prefer to copy the line, then comment it out and change the value. This way there is still some documentation about what the default value really is.
sshd is running at runlevel 3. You need to set Arch up so that sshd runs at runlevel 5. Using google I could find examples of how to do this in Red Hat and Debian but I could not find any Arch examples. Here is a link for Red Hat and Debian:
normally sshd runs at 3 AND at 5. There should be no need for any changes.
"On Debian boxes, save this script to your /etc/init.d directory. Then, use update-rc.d to create the symlinks to the appropriate runlevel directories.
update-rc.d -f ssh defaults 20
This will set sshd to start in multiuser runlevels."
Startx doesn't work over ssh, and cannot. The default X server requires a video access - and an ssh connection doesn't have one, nor can it get one.
Now running a nested X server would work - and also wouldn't get the same errors as nested X servers use the X protocol for the display and not a video connection.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.