On Sat, 11 Feb 2017 17:23:43 +0100 Thomas Wagner <wagner-thomas@gmx.at> wrote:
Hi!
I have a Leap 42.2 machine with no display-manager running. On this machine I want to start a simple X11-session which brings up a single window as non-root user. As root, "/usr/bin/startx /usr/bin/xterm" works (so X is correctly configured) but I want xterm to be started as user.
Reading the man pages I figured out that doing either /usr/bin/startx sudo -u thomas /usr/bin/xterm -- or /usr/bin/startx su thomas /usr/bin/xterm -- (the lines are started as root) should start xterm as user "thomas".
However, both variants produce an error. The "su"-version produces the error "/usr/bin/xterm: /usr/bin/xterm: cannot execute binary file" The "sudo"-version" produces the error "/usr/bin/xterm: Xt error: Can't open display: \n/usr/bin/xterm: DISPLAY is not set"
How about setting the DISPLAY environment variable as part of the command sudo executes? Or using the -display argument to xterm? I suspect :0.0 will work as the display value.
Anyone an idea how to start a simple X-program like xterm as user from a root-shell.
best regards
Thomas
-- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org