[Lxc-users] GUI container

Matto Fransen matto at matto.nl
Fri Dec 17 10:28:53 UTC 2010


Hi,

>>
> >> It is no problem to run GUI apps in a container.
> >> I have set up one of my containers as an X-server. From an
> >> old laptop I do "X -query <ip-number> and run the window-manager
> >> that is installed on the container.
> >>
> >> You can use ssh -X to log in into the container and start
> >> your X-app.
 
> Do I need to start container with X (level 5?). I tried these steps :
> 1. Start container in level 3.
> 2.  lxc-console into container
> 3. Run Xvfb (that returned error as)
> #Xvfb :0 -screen 0 1024x768x16 -ac &
> SELinux: Invalid object class mapping, disabling SELinux support.
> (EE) AIGLX error: dlopen of /usr/lib/dri/swrast_dri.so failed
> (/usr/lib/dri/swrast_dri.so: cannot open shared object file: No such
> file or directory)
> (EE) GLX: could not load software renderer
> 4. Run mwm
> # mwm
> Error: Can't open display: 0.0
> I have set display to 0.0

If you want the LXC container to be a xserver, then there is no
need to start X in it :) 
That is only needed on the client (your workstation), that you 
run like an old-fashioned X-terminal.

Just configure xdm to allow remote login. 
At 'boot' of the container, do a /etc/init.d/xdm start
that is enough.
From your workstation do either: X -query <ip-number of xserver>
or: X -indirect <ip-number of xserver>
depending on the configuration of xdm.

See: http://tldp.org/HOWTO/XDM-Xterm/index.html

Remove your /etc/init.d/rcS (in Debian that is, don't know if
fedora uses that too) and create a new minimal one that just 
starts your sshd (so you have a loginmethod for troubleshooting) 
and xdm. Perhaps you need to set up your default gateway in
that rcS file too. Nothing else needs to be started.

Cheers,

Matto
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20101217/5f8a6fc5/attachment.pgp>


More information about the lxc-users mailing list