English
Ask Your Question
1

F26 Tiger VNC server still has blank screen.

asked 2017-07-12 18:18:42 +0000

estrauch gravatar image

The vncserver 'black screen' issue persists into Fedora 26. Here are the workarounds I've done so far. 1) Disable SELinux (setenforce 0) so I can get vncserver running using systemctl. 2) Login using 'GNOME on Xorg' for both server and client. 3) On the server, edit $HOME/.vnc/xstartup. Replace 'exec /etx/X11/xinit/xinitrc' with 'exec gnome-session'.

The vncviewer comes up with cursor working, but always a blank screen. This appears to be a GNOME display manager issue.

edit retag flag offensive close merge delete

Comments

Have you tried running it from the command line to see if there are any error messages?

Samuel Sieb ( 2017-07-12 22:05:17 +0000 )edit

When I run vncserver :1 from command line, it works. When I run from systemctl, I get this error message in $HOME/.vnc/<hostname>:1.log Failed to import environment: Process org.freedesktop.systemd1 exited with status 1

estrauch ( 2017-07-13 05:27:27 +0000 )edit

4 answers

Sort by ยป oldest newest most voted
1

answered 2017-07-13 05:43:30 +0000

Samuel Sieb gravatar image

See https://bugzilla.redhat.com/show_bug....

edit flag offensive delete link more

Comments

1

This bugzilla thread provides a patch for the SELinux problem. I'm just disabling SELinux for now using 'setenforce 0' command. Additionally, it suggests adding Environment=XDGSESSIONTYPE=x11 to vncserver@.service file. I tried that but still same problem, i.e. "Failed to import environment: Process org.freedesktop.systemd1 exited" message in .vnc/<host>:1.log file. Running vncserver from command line works just fine, but not from systemctl. It appears the problem may be that systemctl tries to run vncserver as root, as I get the sudo password prompt.

estrauch ( 2017-07-13 15:57:19 +0000 )edit
1

Did you run systemctl daemon-reload after changing the service file? If you didn't, the changes won't be used.

Samuel Sieb ( 2017-07-13 18:01:04 +0000 )edit

yes I did this.

estrauch ( 2017-07-14 13:02:24 +0000 )edit
0

answered 2017-09-12 18:04:07 +0000

emike gravatar image

updated 2017-09-12 18:20:13 +0000

From what I can tell, vncserver failes when started from 'systemctl' but works when started from the command line.

I did both and checked gnome-session-binary:

emike 1932 1 0 03:22 ? 00:00:00 /usr/libexec/gnome-session-binary

emike 2684 1 0 03:24 pts/0 00:00:00 /usr/libexec/gnome-session-binary

The one on pts/0 was started from the command line. The other from systemctl.

Under the one started from the command line, there is a 'gnome-shell'. Not under the other. Also, a diff of the log files (:1 systemctl and :2 command line) the only noteable difference is:

< Failed to import environment: Process org.freedesktop.systemd1 exited with status 1

I can assume that this is because there is no controlling tty. This is definitely a bug. I don't yet know of a workaround.

Hope this helps.

emike

edit flag offensive delete link more
0

answered 2017-09-12 17:59:17 +0000

emike gravatar image

So far as I can tell, starting from the command line works, starting from systemctl does not:

emike 1932 1 0 03:22 ? 00:00:00 /usr/libexec/gnome-session-binary emike 2684 1 0 03:24 pts/0 00:00:00 /usr/libexec/gnome-session-binary

The gnome-session-binary on pts/2 was started from "vncviewer :2" on the command line. The other gnome-session-binary was started by 'systemctl start vncviewer#:1.service"

Further proof, "DISPLAY=:1 gnome-shell" from the command line will get the blank screen working.

From the .vnc logs for both :1 (blank) and :2 (working, command line) is this:

< Failed to import environment: Process org.freedesktop.systemd1 exited with status 1

Likely because there is no controlling tty. This is a bug. Don't know what the workaround would be.

emike at emike.org

edit flag offensive delete link more
0

answered 2017-07-13 16:33:53 +0000

mfoged gravatar image

I had the same issue on CentOS 7 until a few days ago. I had also put the line EXEC=gnome-session but changed it to gnome-session &

this is my xstartup file: unset SESSIONMANAGER unset DBUSSESSIONBUSADDRESS exec /etc/X11/xinit/xinitrc gnome-session &

As you can see from below I use SELinux, as it's a bad idea to disable it. SELinux status: enabled SELinuxfs mount: /sys/fs/selinux SELinux root directory: /etc/selinux Loaded policy name: targeted Current mode: enforcing Mode from config file: enforcing Policy MLS status: enabled Policy deny_unknown status: allowed Max kernel policy version: 28

edit flag offensive delete link more

Comments

Changing 'exec gnone-session' to just 'gnone-session' in startup did fix error message "Failed to import environment". Still blank screen.

estrauch ( 2017-07-14 13:06:11 +0000 )edit

when logged in with vncviewer, have you tried to hit <enter>? That's the only way I can invoke the Gnome login screen on CentOS 7.

mfoged ( 2017-07-16 14:24:56 +0000 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

[hide preview]

Use your votes!

  • Use the 30 daily voting points that you get!
  • Up-vote well framed questions that provide enough information to enable people provide answers.
  • Thank your helpers by up-voting their comments and answers. If a question you asked has been answered, accept the best answer by clicking on the checkbox on the left side of the answer.
  • Down-voting might cost you karma, but you should consider doing so for incorrect or clearly detrimental questions and answers.

Question Tools

Follow
1 follower

Stats

Asked: 2017-07-12 18:18:42 +0000

Seen: 1,637 times

Last updated: Sep 12