Discussion:
How to change back to the console when stucked by the desktop environment
(too old to reply)
Yubin Ruan
2016-07-16 12:56:01 UTC
Permalink
Hi,
I just tried FreeBSD-10.3 stable and get stuck when trying to use the
Mate desktop environment. I use Slim as the login manager. But when I
try to login, with correct username and passwd, Slim tell me that
"Failed to execute login command"
(Any idea why would that happen?)
So I try to switch back to the console use "Alt-F1...Alt-F8", which is
suggested by the doc. But that doesn't work. Why ?

How can I switch back to the console to tune the system?

Regards,
Ruan
Charles W. Ross
2016-07-16 13:38:53 UTC
Permalink
Post by Yubin Ruan
Hi,
I just tried FreeBSD-10.3 stable and get stuck when trying to use the
Mate desktop environment. I use Slim as the login manager. But when I
try to login, with correct username and passwd, Slim tell me that
"Failed to execute login command"
(Any idea why would that happen?)
This error message means that whatever you have in your .xinitrc file is
wrong. For example, to start the the OpenBox window manager, you would
include 'exec openbox-session' in your .xinitrc. This varies based on
the window manager you want to use.
Post by Yubin Ruan
So I try to switch back to the console use "Alt-F1...Alt-F8", which is
suggested by the doc. But that doesn't work. Why ?
The correct key combination to get back to a console is "CTRL + ALT +
F1" (through F8), not just ALT by itself.
Post by Yubin Ruan
How can I switch back to the console to tune the system?
Regards,
Ruan
Hope this helps,

Charlie
Julian H. Stacey
2016-07-16 13:58:29 UTC
Permalink
Date: Sat, 16 Jul 2016 20:56:01 +0800
Hi,
I just tried FreeBSD-10.3 stable and get stuck when trying to use the
Mate desktop environment. I use Slim as the login manager. But when I
try to login, with correct username and passwd, Slim tell me that
"Failed to execute login command"
(Any idea why would that happen?)
So I try to switch back to the console use "Alt-F1...Alt-F8", which is
suggested by the doc. But that doesn't work. Why ?
How can I switch back to the console to tune the system?
(Ive never heard of Slim, but) general procedure:
From another net connected host:
rlogin / telnet / ssh yourhost
cd /var/log ; ls -ltr
ls -l xdm.log messages Xorg.0.log
+ whatever logfile might be appropriate for your Slim
ps -laxww
kill some processes, watch if they restart
vi /etc/ttys
change eg
ttyv1 "/usr/local/bin/xdm -nodaemon" xterm on secure
to
ttyv1 "/usr/local/bin/xdm -nodaemon" xterm off secure
maybe you are using ttyv0 for xdm
(I use ttyv1 to leave 0 for errors)
kill -HUP 1
sometimes screen still wont come back,
if desperate then reboot

PS I dropped cc: freebsd-***@freebsd.org
as this has nothing to do with that CPU, & freebsd.org list rules
say dont cross post more than 2 lists.

Cheers,
Julian
--
Julian Stacey, BSD Linux Unix Sys Eng Consultant Munich http://berklix.eu/jhs/
Mail plain text, No quoted-printable, HTML, base64, MS.doc.
Prefix old lines '> ' Reply below old, like play script. Break lines by 80.
http://berklix.eu/brexit/#stolen_votes
mokhi
2016-07-16 14:11:06 UTC
Permalink
I am using FreeBSD10.3 + Slim + MATE on my laptop without such problems.
Maybe you forgot about creating .xinitrc ?
BTW, you can reboot to single user mode and delete slim from startups
(rc.conf) and start solving problem then (creating .xinitrc if not
created it and so on)

Best regards, Mokhi.
Freddie Cash
2016-07-16 20:59:58 UTC
Permalink
Post by Yubin Ruan
Hi,
I just tried FreeBSD-10.3 stable and get stuck when trying to use the
Mate desktop environment. I use Slim as the login manager. But when I try
to login, with correct username and passwd, Slim tell me that
Post by Yubin Ruan
"Failed to execute login command"
(Any idea why would that happen?)
So I try to switch back to the console use "Alt-F1...Alt-F8", which is
suggested by the doc. But that doesn't work. Why ?

Try CTRL+ALT+F1 through F8.

When are the console, you use Alt+F1 through F8, but need to add the CTRL
over X11 starts.
Yubin Ruan
2016-07-17 08:36:22 UTC
Permalink
Post by Julian H. Stacey
Date: Sat, 16 Jul 2016 20:56:01 +0800
Hi,
I just tried FreeBSD-10.3 stable and get stuck when trying to use the
Mate desktop environment. I use Slim as the login manager. But when I
try to login, with correct username and passwd, Slim tell me that
"Failed to execute login command"
(Any idea why would that happen?)
So I try to switch back to the console use "Alt-F1...Alt-F8", which is
suggested by the doc. But that doesn't work. Why ?
How can I switch back to the console to tune the system?
rlogin / telnet / ssh yourhost
cd /var/log ; ls -ltr
ls -l xdm.log messages Xorg.0.log
+ whatever logfile might be appropriate for your Slim
ps -laxww
kill some processes, watch if they restart
vi /etc/ttys
change eg
ttyv1 "/usr/local/bin/xdm -nodaemon" xterm on secure
to
ttyv1 "/usr/local/bin/xdm -nodaemon" xterm off secure
maybe you are using ttyv0 for xdm
(I use ttyv1 to leave 0 for errors)
kill -HUP 1
sometimes screen still wont come back,
if desperate then reboot
as this has nothing to do with that CPU, & freebsd.org list rules
say dont cross post more than 2 lists.
Cheers,
Julian
Thanks, I just manage to install a proper desktop environment(Xfce) to
use and it seems to work fine.
However, still, I cannot manage to do tty-switching using <Ctrl-Alt><F_>
(<Alt-F_> didn't work either). Strangely, whenever I press
<Ctrl-Alt><F_>, the whole desktop block. I don't know why, it just block
everytime I press <Ctrl-Alt><F_> ( the _ stand for number 1...8)

My /etc/ttys file looks like this:

console none unknown off secure
ttyv0 "/usr/libexec/getty Pc" xterm on secure
.
. (the same )
.
ttyv7 "/usr/libexec/getty Pc" xterm on secure
ttyv8 "/usr/local/bin/xdm-nodaemon" xterm off secure

#serial terminal
ttyu0 "/usr/libexec/getty 3wire" vt100 onifconsole secure
.
.
ttyu3 "/usr/libexec/getty 3wire" vt100 onifconsole secure

#Dumb console
dcons "/usr/libexec/getty std.9600" vt100 off secure

Any idea?

Thanks,
Ruan
Michael B. Eichorn
2016-07-17 10:34:37 UTC
Permalink
Post by Yubin Ruan
Thanks, I just manage to install a proper desktop environment(Xfce)
to 
use and it seems to work fine.
However, still, I cannot manage to do tty-switching using <Ctrl-
Alt><F_> 
(<Alt-F_> didn't work either). Strangely, whenever I press 
<Ctrl-Alt><F_>, the whole desktop block. I don't know why, it just
block 
everytime I press <Ctrl-Alt><F_> ( the _ stand for number 1...8)
     console     none                   unknown    off   secure
     ttyv0    "/usr/libexec/getty Pc"   xterm      on    secure
     .
     .          (the same )
     .
     ttyv7    "/usr/libexec/getty Pc"   xterm      on    secure
     ttyv8    "/usr/local/bin/xdm-nodaemon"  xterm  off  secure
     #serial terminal
     ttyu0    "/usr/libexec/getty 3wire"   vt100   onifconsole secure
     .
     .
     ttyu3    "/usr/libexec/getty 3wire"   vt100   onifconsole secure
     #Dumb console
     dcons    "/usr/libexec/getty std.9600"  vt100 off  secure
Any idea?
Thanks,
Ruan
Maybe it could be KMS related? Try swithing the console driver from
sc(4) to vt(4) by adding:

kern.vty=vt

to /boot/loader.conf and rebooting.

Vt(4), also known as newcons is the UTF-8 and KMS friendly console
driver. Vt(4) will be the console driver for 11.0 (r274085) but the
older sc(4) is the default on 10.x.
Anthony Jenkins via freebsd-questions
2016-07-18 15:22:20 UTC
Permalink
Post by Yubin Ruan
Post by Julian H. Stacey
Date: Sat, 16 Jul 2016 20:56:01 +0800
Hi,
I just tried FreeBSD-10.3 stable and get stuck when trying to use the
Mate desktop environment. I use Slim as the login manager. But when I
try to login, with correct username and passwd, Slim tell me that
"Failed to execute login command"
(Any idea why would that happen?)
So I try to switch back to the console use "Alt-F1...Alt-F8", which is
suggested by the doc. But that doesn't work. Why ?
How can I switch back to the console to tune the system?
rlogin / telnet / ssh yourhost
cd /var/log ; ls -ltr
ls -l xdm.log messages Xorg.0.log
+ whatever logfile might be appropriate for your Slim
ps -laxww
kill some processes, watch if they restart
vi /etc/ttys
change eg
ttyv1 "/usr/local/bin/xdm -nodaemon"
xterm on secure
to
ttyv1 "/usr/local/bin/xdm -nodaemon"
xterm off secure
maybe you are using ttyv0 for xdm
(I use ttyv1 to leave 0 for errors)
kill -HUP 1
sometimes screen still wont come back,
if desperate then reboot
as this has nothing to do with that CPU, & freebsd.org list rules
say dont cross post more than 2 lists.
Cheers,
Julian
Thanks, I just manage to install a proper desktop environment(Xfce) to
use and it seems to work fine.
However, still, I cannot manage to do tty-switching using
<Ctrl-Alt><F_> (<Alt-F_> didn't work either). Strangely, whenever I
press <Ctrl-Alt><F_>, the whole desktop block. I don't know why, it
just block everytime I press <Ctrl-Alt><F_> ( the _ stand for number
1...8)
console none unknown off secure
ttyv0 "/usr/libexec/getty Pc" xterm on secure
.
. (the same )
.
ttyv7 "/usr/libexec/getty Pc" xterm on secure
ttyv8 "/usr/local/bin/xdm-nodaemon" xterm off secure
#serial terminal
ttyu0 "/usr/libexec/getty 3wire" vt100 onifconsole secure
.
.
ttyu3 "/usr/libexec/getty 3wire" vt100 onifconsole secure
#Dumb console
dcons "/usr/libexec/getty std.9600" vt100 off secure
Any idea?
Thanks,
Ruan
If this is a laptop, remember some laptops require you to press an <Fn>
key to send the <F1> - <F12> keycodes (this is often configurable in the
BIOS). So to issue the <Ctrl>+<Alt>+<F1> key sequence, you actually have
to press <Ctrl>+<Alt>+<Fn>+<F1>.
--
Anthony Jenkins
Loading...