[X2Go-User] Advice needed on a somewhat working x2go configuration

Yohan public at scimetis.net
Wed Aug 21 18:19:08 CEST 2013


Hi Mike,
> There should be no need for using Xvfb. X2Go has its own X-Server 
> (x2goagent/nxagent), so when using Xvfb, you actually use X-Servers.
>
> Why not go this approach...
>
> pyhoca-cli --server localhost -N -c LXDE --user yohan \
>            --add-to-known-hosts --password mypasswd \
>            --kbd-layout fr --kbd-type pc105/fr &
>
> sleep 5
> X2GO_SESSION=$(<detect-session-id-of-just-started-session>)
> <launch whatever application you want to launch in session $X2GO_SESSION>
>
> # Whenever you need that application on screen...
> pyhoca-cli --resume $X2GO_SESSION --server localhost
>
I just tried but it failed for some reason... LXDE was never started and 
the session terminated.
I also tried as root just to be sure :
# pyhoca-cli --server localhost -N -c LXDE --user yohan 
--add-to-known-hosts --password mypasswd --kbd-layout fr --kbd-type 
pc105/fr &
[1] 5440
# xwininfo: error: unable to open display ""
pyhoca-cli[5440] NOTICE: preparing requested X2Go session
pyhoca-cli[5440] (PyHocaCLI) NOTICE: preparing requested X2Go session
pyhoca-cli[5440] (x2gosessregistry-pylib) NOTICE: registering X2Go 
session Pyhoca-Client_Session...
pyhoca-cli[5440] (x2goclient-pylib) NOTICE: initializing X2Go session...
pyhoca-cli[5440] (x2gocontrolsession-pylib) NOTICE: connecting to 
[localhost]:22
pyhoca-cli[5440] (x2goproxy-pylib) ERROR: Bringing up NX3 proxy failed.
pyhoca-cli[5440] (x2goproxy-pylib) WARN: X2Go proxy shutdown gave a 
message that we may ignore: [Errno 3] No such process
pyhoca-cli[5440] (x2goclient-pylib) WARN: HOOK_session_startup_failed: 
session startup for session profile ,,Pyhoca-Client_Session failed.
pyhoca-cli[5440] (PyHocaCLI) NOTICE: give the X2Go session some time to 
come up...

# pyhoca-cli -l
xwininfo: error: unable to open display ""

Available X2Go session profiles
===============================
configuration files: ['/root/.x2goclient/sessions']
user configuration file: /root/.x2goclient/sessions

[1]+  Fini                    pyhoca-cli --server localhost -N -c LXDE 
--user yohan --add-to-known-hosts --password mypasswd --kbd-layout fr 
--kbd-type pc105/fr
> This can also be done rootless, just by not using a desktop shell 
> command as --command:
>
> pyhoca-cli --server localhost -N -c <YOUR-COMMAND-IN-$PATH> --user 
> yohan \
>            --add-to-known-hosts --password mypasswd \
>            --kbd-layout fr --kbd-type pc105/fr &
I tried this without any luck either :
pyhoca-cli --server localhost -N -c /usr/bin/xlogo --user yohan 
--add-to-known-hosts --password mypasswd --kbd-layout fr --kbd-type pc105/fr

It seems pyhoca-cli requires an active xserver to start. No ?
Both commands work if I launch them from my PC, but as I said I am 
trying to start the application on my headless server when it boots with 
/etc/rc.local. Hence the ugly hack I did with Xvfb. If there is no way 
to do that (other than using Xvfb), I'll probably start the application 
from my PC with the command you suggested. My server does not reboot 
that often anyway.

Thanks for helping me out.
Regards,
Yohan



More information about the x2go-user mailing list