Re: VNC Window Manager won't start

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I got a solution.

Seems if you add:

Environment=XDG_SESSION_TYPE=x11

to /etc/systemd/systems/vncserver@.service then do:

# systemctl daemon-reload
# systemctl restart vncserver@:1.service

I get a window manager when I log in and everything works as expected.

This is using the default xstartup file generated in my user's ~/.vnc directory when running vncpasswd:

#!/bin/sh

unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
exec /etc/X11/xinit/xinitrc

Got this info from:
http://forums.fedoraforum.org/showthread.php?t=313406

Thanks MrRonMan wherever you are!

I assume this has something to do with wayland vs x11. This is a virtual machine and maybe it's video driver for vnc doesn't support wayland so I have to tell it to use x11.

Whatever the reason it seems to be working for me now.

Thanks
Chris K

On 4/14/2017 5:22 PM, Rick Stevens wrote:
On 04/14/2017 12:53 PM, Chris Kottaridis wrote:

On 4/14/2017 12:38 PM, stan wrote:
On Fri, 14 Apr 2017 02:02:19 -0500
Chris Kottaridis <chriskot@xxxxxxxxxxxxx> wrote:

I have a Fedora 25 installation that was setup originally with server
installation and have since added gnome desktop package groups and
others.

On the console I get a standard non-graphical login prompt and from
there I can type startx and get into gnome just fine.

I don't want to change that.

I do want to use VNC to connect in over net and run gnome. I have
[snip]
Before any of the exec lines those apps seem to be running.

Just no window manager.

Any pointers would be appreciated.

I want to keep the console with an ASCII login and then use startx to
get a GUI from the console, but I want to also be able to get a GUI
via VNC
I have a script that I run in multiuser that allows me to select which
desktop I will use when I run startx.  It acts like a text greeter.
This is an edited version of what I have in that script that could be
used to always start Gnome.

XCLIENTS=/home/$USER/.Xclients

echo '*** Replacing existing ~/.Xclients or creating new one.'
echo '#! /bin/bash' > $XCLIENTS
echo ' ' >> $XCLIENTS
chmod +x $XCLIENTS
echo 'GSESSION="$(type -p gnome-session)"' >> $XCLIENTS
echo 'exec $GSESSION' >> $XCLIENTS
echo 'Starting X with Gnome...'
startx -- vt10
exit 0
I think I need to be more careful as I might have interchanged startx
and xstartup. When I log into the console via an ASCII login I can run
startx and everything is fine.

When  vncserver starts it runs the xstartup script, and I know it is
indeed running that because I can see output differences as I make
changes. It just doesn't seem to be getting a Window Manager going
It's been a while, but IIRC just doing "startx" brings up a greeter
(such as lightdm or sddm-greeter). You log into the greeter (that's
your authentication step) and select the type of session you want
(Gnome, XFCE, KDE, whatever). startx uses that to eventually call xinit
and pass it the session manager you want to run. The session manager is
supposed to start the appropriate window manager.

If you looked at my script, we bypass the greeter (the machines are only
accessed via a VPN so authentication is unnecessary), so when Xvnc
starts, it "assumes" we're already authenticated. Our ~/.vnc/xstartup
script just starts Xfce4 via Xfce4's startup script. That script (and
others it calls) loads Xfce's session manager (xfce4-session) which, in
turn, loads it's window manager (xfwm4). Et tu, voila! (or something
like that--my romance language skills are awful)
----------------------------------------------------------------------
- Rick Stevens, Systems Engineer, AllDigital    ricks@xxxxxxxxxxxxxx -
- AIM/Skype: therps2        ICQ: 226437340           Yahoo: origrps2 -
-                                                                    -
-  Money won't buy happiness, but it will pay the salary of a large  -
-        research staff to study the problem. - Bill Vaughan         -
----------------------------------------------------------------------
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux