Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] xterm error Display not set
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Raoul
Tux's lil' helper
Tux's lil' helper


Joined: 30 Jul 2006
Posts: 108
Location: Adelaide, Aust.

PostPosted: Mon Feb 20, 2017 3:36 am    Post subject: [SOLVED] xterm error Display not set Reply with quote

Hi,
Just doing a fresh install. I have installed xorg-server also with nvidia-drivers (USE: tools, driver). I have used /opt/bin/nvidia-xconfig to generate /etc/X11/xorg-conf and also added Bus ID PCI:1:0:0 to the file as per wiki.

As user when I type 'xterm' I am told : Can't open display and DISPLAY is not set. And when I type 'startx' I get an error saying 'parse_vt_settings: Cannot open /dev/tty0 (Permission denied).

I have looked up various forums but in those instances it had to do with remote sessions. In other instances user had to be added to 'wheel' group - which I did during setup.

Hoping someone can please help.

Regards
Raoul
_________________
**************
Not all pain is gain.


Last edited by Raoul on Thu Feb 23, 2017 5:09 am; edited 1 time in total
Back to top
View user's profile Send private message
mjbjr
Apprentice
Apprentice


Joined: 02 Mar 2003
Posts: 233

PostPosted: Tue Feb 21, 2017 9:33 am    Post subject: Re: xterm error Display not set Reply with quote

Raoul wrote:
Hi,
Just doing a fresh install. I have installed xorg-server also with nvidia-drivers (USE: tools, driver). I have used /opt/bin/nvidia-xconfig to generate /etc/X11/xorg-conf and also added Bus ID PCI:1:0:0 to the file as per wiki.

As user when I type 'xterm' I am told : Can't open display and DISPLAY is not set. And when I type 'startx' I get an error saying 'parse_vt_settings: Cannot open /dev/tty0 (Permission denied).

I have looked up various forums but in those instances it had to do with remote sessions. In other instances user had to be added to 'wheel' group - which I did during setup.

Hoping someone can please help.

Regards
Raoul


What runlevel are you booting to? When grub gets done booting up are you presented with a full screen console (black screen) waiting for you to login or a graphical login?

If you're presented with a full screen console 'xterm' isn't going to work because the 'X' server hasn't been started yet.
And if you have been presented with a graphical login and you did so, what did you enter 'xterm' into? An 'xterm'?

Which desktop environment (DE) have you installed, if any? KDE, xfce, etc.?
Usually, the graphical desktop system consists of an X server, a window manager, and a dssktop.
When you install a DE for the first time it will install all three of the above.
And actually, you can install an X server and a window manager and not install a desktop, which is the way to go
in certain, usually technical, situations.
iIn the old days a default window manager (twm, ted's window manager) was installed with the X server, and
iirc under that situation startx would start twm.
'startx' looks for a .xinitrc file in the user directory to see what to start, if you don't have one I suspect it looks for a system .xinitrc file.

These days each DE has it's own startup command, kde has startkde, xfce has statxfce4, etc., etc., though you could have
one of those in your .xinitrc file, but generally they're now found in a specific sub-directory of the users .config directory.

'startx' would indicate that you're at a full screen console.

Under normal circumstances,
ctrl-alt-(F1..F6) (/dev/tty1..tty6) are full screen consoles,
ctrl-alt-(F6..F11) are where to find started X servers (yes, you can run more than one at a time, I have had as many as four running.)
ctrl-alt-F12 is usually used to show a live kernel message feed.

I'm not sure, but possibly /dev/tty0 is reserved for root or some other system thing.

I boot to runlevel 3, full screen console, which is automatically tty1, and login as root, (it could be a user)
I then do a ctrl-alt-F2 to get another full screen console (tty2) and login as my user,
from there I do 'startxfce4', which starts the X server and runs xfce4 window manager and desktop on it,
and my screen output is then switched to the xfce4 desktop, and I'm already logged in.

At any point I can do a ctrl-alt-F2 and my screen will switch back to my full console login (tty2) and
it will be a blank screen and there's no cursor for me to enter any commands because it's linked to
the startxfce4 command. I then do a ctrl-alt-F7 to go back to my xfce4 desktop, though sometimes
it gets a bit confused and it's on ctrl-alt-F8, but not usually.

A little more info is needed, at least for me, to sort your situation out.
.
Back to top
View user's profile Send private message
Raoul
Tux's lil' helper
Tux's lil' helper


Joined: 30 Jul 2006
Posts: 108
Location: Adelaide, Aust.

PostPosted: Tue Feb 21, 2017 10:09 pm    Post subject: Reply with quote

Hi mjbjr,
This is a fresh install, so I have not yet installed XFCE nor slim. I am simply following xorg-server wiki https://wiki.gentoo.org/wiki/Xorg/Guide. xterm is installed as part of these packages as is twm, so I am not installing anything extra. I am merely using xterm as a test to see if I can get X working prior to installing XFCE.

I am booting to runlevel 3 and the boot proceeds without any errors. I am simply presented with $hostname and $user as a CLI which is what I would expect not having installed any windows manager or login manager. As per original post I have also run nvidia-xconfig as per the NVIDIA wiki.

Not sure what else you need.

Regards
Raoul
_________________
**************
Not all pain is gain.
Back to top
View user's profile Send private message
mjbjr
Apprentice
Apprentice


Joined: 02 Mar 2003
Posts: 233

PostPosted: Wed Feb 22, 2017 5:19 am    Post subject: Reply with quote

Raoul wrote:
Hi mjbjr,
This is a fresh install, so I have not yet installed XFCE nor slim. I am simply following xorg-server wiki https://wiki.gentoo.org/wiki/Xorg/Guide. xterm is installed as part of these packages as is twm, so I am not installing anything extra. I am merely using xterm as a test to see if I can get X working prior to installing XFCE.

I am booting to runlevel 3 and the boot proceeds without any errors. I am simply presented with $hostname and $user as a CLI which is what I would expect not having installed any windows manager or login manager. As per original post I have also run nvidia-xconfig as per the NVIDIA wiki.

Not sure what else you need.

Regards
Raoul


oops, the 't' in 'twm' is Tom not Ted.

'xterm' stands for X terminal. For 'xterm' to work you must invoke it from within a running X environment, 'twm' in your current case.
So, you need to figure out how to get 'twm' started. Looking in /var/log/Xorg.0.log may help.

You might try this site: https://wiki.archlinux.org/index.php/Twm

When I install gentoo I go directly to installing 'xfce', which installs the X server and xfce's window manager and desktop, and other
stuff 'xfce' needs, but doesn't install 'twm' and a lot of what is mentioned in the gentoo xorg guide you mention above.

So, unfortunately, my environment is too different to offer you much further help on the 'twm' matter.

.
Back to top
View user's profile Send private message
Raoul
Tux's lil' helper
Tux's lil' helper


Joined: 30 Jul 2006
Posts: 108
Location: Adelaide, Aust.

PostPosted: Thu Feb 23, 2017 5:09 am    Post subject: Reply with quote

I have solved this by removing almost all my use-flags except those provided by my profile and a couple of extras I know that I need.
Code:
USE="X alsa  cups -gnome -gpm -ipv6 -kde -minimal -pulseaudio"


This seems to have worked and I am now proceeding with install.
_________________
**************
Not all pain is gain.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum