AIGLX: Suspending AIGLX clients for VT switch

263 views
Skip to first unread message

Victor Sudakov

unread,
Apr 20, 2019, 9:03:39 AM4/20/19
to freebsd-...@freebsd.org
Dear Colleagues,

I use two Xservers on my desktop box (FreeBSD 11.2):

[vas@vas ~] ps axww | grep xin
70999 v1- I 0:00,00 xinit /home/vas/.xinitrc -- /usr/local/bin/X :1 -auth /home/vas/.serverauth.70986
69720 v2 I+ 0:00,00 xinit /home/nk/.xinitrc -- /usr/local/bin/X :0 -auth /home/nk/.serverauth.69707
36786 8 R+ 0:00,00 grep xin
[vas@vas ~]

One is my Mate session and the other my wife's one.

We switch between them with Ctrl+Alt+Fn. Sometimes I also need to switch
to the vt text console with Ctrl+Alt+F1.

The problem is that sometimes Ctrl+Alt+Fn just freezes the GUI for good,
and I have to ssh to the box from my son's computer and issue "sudo killall xinit"
and then start "startx" again.

Sometimes after I kill the xinit processes I see the following message:

(II) AIGLX: Suspending AIGLX clients for VT switch

I presume that something is preventing the vt switching from happening.

Can I configure startx/xinit/xorg whatever so that if I press
Ctrl+Alt+Fn, the virtual consoles should be switched unconditionally
without "Suspending AIGLX clients" or whatever the xservers are trying
to do. I'm the boss after all. If vt switching crashes some X client, I'm
fine with it.

It is also remarkable that now I cannot kill the Xserver with
Control+Alt+Backspace any more. How can I regain this possibility?

--
Victor Sudakov, VAS4-RIPE, VAS47-RIPN
2:5005/49@fidonet http://vas.tomsk.ru/
signature.asc

Polytropon

unread,
Apr 20, 2019, 10:48:11 PM4/20/19
to Victor Sudakov, freebsd-...@freebsd.org
On Sat, 20 Apr 2019 20:02:28 +0700, Victor Sudakov wrote:
> Sometimes after I kill the xinit processes I see the following message:
>
> (II) AIGLX: Suspending AIGLX clients for VT switch
>
> I presume that something is preventing the vt switching from happening.

THat's probably the same thing that makes vt an inappropriate
replacement for sc. ;-)

Have you tried disabling AIGLX? In a partial configuration file
in X's configuration directory, /usr/local/etc/X11/xorg.conf.d/,
you could try this:

Section "ServerFlags"
Option "DontVTSwitch" "false"
Option "AIGLX" "false"
EndSection

Check for any missing functionality within X.



> If vt switching crashes some X client, I'm
> fine with it.

Well, I don't think some of the most fundamental things (at
least problem-less standard behaviour for decades with sc)
should randomly crash X clients, but that's probably the
price to pay if you want to run X today...



> It is also remarkable that now I cannot kill the Xserver with
> Control+Alt+Backspace any more. How can I regain this possibility?

There seem to be several ways, and you need to experiment
to find out which one works for you. A partial configuration
file for your input device, for example:

Section "InputDevice"
Option "XkbOptions" "terminate:ctrl_alt_bksp"
EndSection

Another one for the server layout:

Section "ServerLayout"
Option "DontZap" "false"
EndSection

And if you're using MATE, you're probably also using the dreaded
combination of HAL and Dbus, things long forgotten in Linux land,
but still required and present on many FreeBSD X desktop solutions.
So here's something for /usr/local/etc/hal/fdi/policy/x11-input.fdi:

<?xml version="1.0" encoding="iso-8859-1"?>
<deviceinfo version="0.2">
<device>
<match key="info.capabilities" contains="input.keyboard">
<merge key="input.x11_options.XkbOptions"
type="string">terminate:ctrl_alt_bksp</merge>
</match>
</device>
</deviceinfo>

This seems to require the "DontZap" option mentioned earlier.

Or a command for your X initialization file:

setxkbmap -option terminate:ctrl_alt_bksp

I have given up on using the console mode. Even if you can return
to it, the screen might appear in a font only suited for ants. ;-)



--
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
_______________________________________________
freebsd-...@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questi...@freebsd.org"

Robert Huff

unread,
Apr 20, 2019, 11:25:09 PM4/20/19
to Polytropon, Victor Sudakov, freebsd-...@freebsd.org

Polytropon writes:

> > It is also remarkable that now I cannot kill the Xserver with
> > Control+Alt+Backspace any more. How can I regain this possibility?
>
> There seem to be several ways, and you need to experiment
> to find out which one works for you. A partial configuration
> file for your input device, for example:
>
> Section "InputDevice"
> Option "XkbOptions" "terminate:ctrl_alt_bksp"
> EndSection

This has also worked for me.

> I have given up on using the console mode. Even if you can return
> to it, the screen might appear in a font only suited for ants. ;-)

Allow me to (hopefully) repay many years of useful advice, by
suggesting you try:

kern.vt.fb.default_mode="800x600"

in /boot/loader.conf. Values other than 800x600 are possible,
and you may need to adjust the font.



Respectfully,


Robert Huff

Victor Sudakov

unread,
Apr 21, 2019, 1:05:21 AM4/21/19
to freebsd-...@freebsd.org
Polytropon wrote:
> > Sometimes after I kill the xinit processes I see the following message:
> >
> > (II) AIGLX: Suspending AIGLX clients for VT switch
> >
> > I presume that something is preventing the vt switching from happening.
>
> THat's probably the same thing that makes vt an inappropriate
> replacement for sc. ;-)
>
> Have you tried disabling AIGLX? In a partial configuration file
> in X's configuration directory, /usr/local/etc/X11/xorg.conf.d/,
> you could try this:
>
> Section "ServerFlags"
> Option "DontVTSwitch" "false"
> Option "AIGLX" "false"
> EndSection
>
> Check for any missing functionality within X.

In better times, I used to have an XF86Config describing everything I
needed, even modelines. In fact, now I have zero X configs. Do you mean
I should create an incomplete config with only those tidbits you
provided?

>
> And if you're using MATE, you're probably also using the dreaded
> combination of HAL and Dbus, things long forgotten in Linux land,

By the way, if the alternative to the dreaded combination of hald and
dbus on Linux is the dreaded systemd, I don't really know which is worse.

But, once it comes to that, if I wanted to run an X desktop on a FreeBSD
system, like a modern fashionable guy, what alternatives do I have that
would not require the dreaded HAL and Dbus?


> I have given up on using the console mode. Even if you can return
> to it, the screen might appear in a font only suited for ants. ;-)

In my case, it is not the console mode that is important, but switching
between two X servers each running a different user's GUI session (my
wife's and mine).

If I could find a way to run two independent sessions within one X
server, I would do that.
signature.asc

Polytropon

unread,
Apr 21, 2019, 3:00:46 PM4/21/19
to Robert Huff, Victor Sudakov, freebsd-...@freebsd.org
On Sat, 20 Apr 2019 23:23:23 -0400, Robert Huff wrote:
>
> Polytropon writes:
>
> > > It is also remarkable that now I cannot kill the Xserver with
> > > Control+Alt+Backspace any more. How can I regain this possibility?
> >
> > There seem to be several ways, and you need to experiment
> > to find out which one works for you. A partial configuration
> > file for your input device, for example:
> >
> > Section "InputDevice"
> > Option "XkbOptions" "terminate:ctrl_alt_bksp"
> > EndSection
>
> This has also worked for me.

A partial configuration file should be sufficient. However,
I don't know if HAL / DBus interferes here, but because this
is an X setting, it should still work even if the PolicyKit
setting is not in place.



> > I have given up on using the console mode. Even if you can return
> > to it, the screen might appear in a font only suited for ants. ;-)
>
> Allow me to (hopefully) repay many years of useful advice, by
> suggesting you try:
>
> kern.vt.fb.default_mode="800x600"
>
> in /boot/loader.conf. Values other than 800x600 are possible,
> and you may need to adjust the font.

I have done so, but never got it working, The fonts are blurred,
the colors are way off, the mouse pointer causes color garbage,
and a functional (!) text mode is no more. :-(



--
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...

Polytropon

unread,
Apr 21, 2019, 3:18:33 PM4/21/19
to Victor Sudakov, freebsd-...@freebsd.org
On Sun, 21 Apr 2019 12:04:07 +0700, Victor Sudakov wrote:
> Polytropon wrote:
> > > Sometimes after I kill the xinit processes I see the following message:
> > >
> > > (II) AIGLX: Suspending AIGLX clients for VT switch
> > >
> > > I presume that something is preventing the vt switching from happening.
> >
> > THat's probably the same thing that makes vt an inappropriate
> > replacement for sc. ;-)
> >
> > Have you tried disabling AIGLX? In a partial configuration file
> > in X's configuration directory, /usr/local/etc/X11/xorg.conf.d/,
> > you could try this:
> >
> > Section "ServerFlags"
> > Option "DontVTSwitch" "false"
> > Option "AIGLX" "false"
> > EndSection
> >
> > Check for any missing functionality within X.
>
> In better times, I used to have an XF86Config describing everything I
> needed, even modelines. In fact, now I have zero X configs. Do you mean
> I should create an incomplete config with only those tidbits you
> provided?

With xorg.conf.d, you can use one partial configuration file
per item that you need to configure deviating from the auto-
detection magic. In /usr/local/etc/X11/xorg.conf.d/, you can
have multiple files with names of your choice. For example,
/usr/local/etc/X11/xorg.conf.d/no_aiglx.conf could be the
filename for the snippet shown above.

In the past, I preferred to have a /etc/X11/Xorg.conf with
all global settings in it, such as supported and switchable (!)
screen sizes, keyboard language, or non-standard fonts. Today,
you can still configure parts of X, and you don't need to have
a complete ("valid") xorg.conf file.

For example, I have /usr/local/etc/X11/xorg.conf.d/keyboard-de.conf
which just contains this:

Section "InputClass"
Identifier "KeyboardDefaults"
Driver "keyboard"
MatchIsKeyboard "on"
Option "XkbLayout" "de"
EndSectio

This makes sure I get a german keyboard independent from any
window manager or desktop I use (unless the desktop environment
thinks it's okay to override a priority setting, in which case
I'll get very angry).

In order to load a few additional modules, I also have a file
/usr/local/etc/X11/xorg.conf.d/modules.conf:

Section "Module"
Load "fb"
Load "vgahw"
EndSection

But the worst thing is /usr/local/etc/X11/xorg.conf.d/screen-resolution.conf
which I need to switch screen size depending on using the laptop's
LCD, a CRT, or a VGA->video converter:

Section "Screen"
Identifier "Screen0"
Device "Card0"
SubSection "Display"
# Modes "1280x800" # LCD R500
Modes "1024x768" # CRT R61i
# Modes "640x480" # CRT R61i + video link
EndSubSection
EndSection

Even though I could get a bigger screen size, I cannot get
more than 800px vertical, so I decided to stop worrying and
love the CRT. ;-)

Even though the CRT is capable of much higher resolutions,
and even if I attach a LCD capable of 1280x1024, there is
no way I can force X to support those modes.

Sadly, just using Ctrl+Alt+[+]/[-] to switch through a set of
resolutions doesn't seem to be possible anymore... :-(



> > And if you're using MATE, you're probably also using the dreaded
> > combination of HAL and Dbus, things long forgotten in Linux land,
>
> By the way, if the alternative to the dreaded combination of hald and
> dbus on Linux is the dreaded systemd, I don't really know which is worse.

Yes, it's hard to tell which one is worse. However, systemd
is currently in a maintained state (actively developed, taking
over many components of basic system startup and operations),
but HAL and DBus have been abandoned years ago, they only seem
to exist as legacy components. Don't ask me where the *Kit stuff
(PolicyKit, ConsoleKit, etc.) fit into this mess, I have to
admit that I never even tried to understand this on Linux.



> But, once it comes to that, if I wanted to run an X desktop on a FreeBSD
> system, like a modern fashionable guy, what alternatives do I have that
> would not require the dreaded HAL and Dbus?

You would need to compile the applications yourself, switching
off HAL and DBus support. I'm currently writing this on a system
that neither has nor runs HAL or DBUs, without their absence
causing any problems. :-)



> If I could find a way to run two independent sessions within one X
> server, I would do that.

This has been part of Gnome 2, and, if I remember correctly,
at least _has_ been working on MATE. On a system I once upgraded,
Gnome 2 became replaced with unusable Gnome 3, so I installed
MATE instead (leaving the remains of Gnome 2 and 3 on the disk),
and on the MATE desktop, there was the "Session switcher" still
available. In the german version, it was called "Benutzer wechseln"
(change user). I also replaced gdm by slim, so that probably is
not a required part. I wonder if MATE supports (supported?) it
natively, or if it really is just about what Gnome left behind...
Reply all
Reply to author
Forward
0 new messages