Gentoo Archives: gentoo-user

From: Neil Bothwick <neil@××××××××××.uk>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] xf86OpenConsole: Cannot open virtual console 1 (Permission denied)
Date: Sun, 07 Feb 2021 20:14:35
Message-Id: 20210207201423.61bc5a03@digimed.co.uk
In Reply to: Re: [gentoo-user] xf86OpenConsole: Cannot open virtual console 1 (Permission denied) by thelma@sys-concept.com
1 On Sun, 7 Feb 2021 12:38:25 -0700, thelma@×××××××××××.com wrote:
2
3 > >>>> I disable "slim" login manager and try not to use any display
4 > >>>> manger (for simplicity). I start X from:
5 > >>>>
6 > >>>> ~/.bash_profile
7 > >>>> exec startx -- vt1
8 > >>>>
9 > >>>> but now when I try to ssh as user, I get:
10 > >>>>
11 > >>>> (==) Using system config directory "/usr/share/X11/xorg.conf.d"
12 > >>>> (EE)
13 > >>>> Fatal server error:
14 > >>>> (EE) xf86OpenConsole: Cannot open virtual console 1 (Permission
15 > >>>> denied)
16 > >>>
17 > >>> Of course you are, because you are still trying to start X. If you
18 > >>> must start X from .bash_profile, you need something like
19 > >>>
20 > >>> [ -z "$SSH_TTY" ] && startx ...
21 > >>>
22 > >>> to only start it when not using SSH.
23 > >>
24 > >> What do you suggest?
25 > >> I was planning to get away from "slim" as I think it is getting more
26 > >> unstable; I just need a simple system to start X, log-in over ssh and
27 > >> use x2go session.
28 > >
29 > > Why do you need to start X, doesn't x2go run its own X session? You
30 > > are trying to start X in an SSH session, which is what gives your
31 > > error. The line I suggested runs startx only if you are not logging
32 > > in via SSH. No display manager is involved.
33 >
34 > Maybe I wasn't clear. No, I don't start any X over ssh.
35
36 But you do, because you run it from .bash_profile whenever you login.
37 That's why I suggested an alternative command that wouldn't do that.
38
39
40 --
41 Neil Bothwick
42
43 Hospitality: making your guests feel like they're at home, even if you
44 wish they were.

Replies