2

I have followed both the directions here and here. I have gotten very far, but the last task on those guides is to run systemctl start vncserver@:10.service and there I get an error.

When I run that command, (where 10 is I believe what is known as the port offset), I get the following error:

Job for vncserver@:10.service failed. See "systemctl status vncserver@:10.service" and "journalctl -xe" for details.

I have run the command both as a user with sudo and as root. Both times I get the same error.

To summarize, the guides say to:

  • yum install tigervnc-server
  • cp/lib/systemd/system/vncserver@.service/etc/systemd/system/vncserver@.service

  • Edit that file to replace user variable

  • restart (~]# systemctl daemon-reload)

  • set vncpasswd

  • Run: systemctl enable vncserver@:display_number.service

  • Run: systemctl start vncserver@:display_number.service

This is the output from systemctrl status vncserver@:10.service

    ● vncserver@:10.service - Remote desktop service (VNC)
       Loaded: loaded (/etc/systemd/system/vncserver@:10.service; enabled)
       Active: failed (Result: exit-code) since Fri 2015-04-10 04:26:21 UTC; 41s ago
      Process: 22788 ExecStart=/sbin/runuser -l myusername -c /usr/bin/vncserver 10 (code=exited, status=126)
      Process: 22785 ExecStartPre=/bin/sh -c /usr/bin/vncserver -kill %i > /dev/null 2>&1 || : (code=exited, status=0/SUCCESS)

This is the output from journalctl -xe

Apr 10 04:44:59 democom runuser[23597]: pam_unix(runuser-l:session): session closed for user user1
Apr 10 04:44:59 democom systemd[1]: vncserver@:.service: control process exited, code=exited status=126
Apr 10 04:44:59 democom systemd[1]: Failed to start Remote desktop service (VNC).
-- Subject: Unit vncserver@:.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit vncserver@:.service has failed.
-- 
-- The result is failed.
Apr 10 04:44:59 democom systemd[1]: Unit vncserver@:.service entered failed state.
Apr 10 04:44:59 democom systemd[1]: vncserver@:.service failed.
Apr 10 04:45:11 democom su[23801]: (to root) user1 on pts/1
Apr 10 04:45:11 democom su[23801]: pam_unix(su:session): session opened for user root by user1(uid=1000)
Apr 10 04:46:59 democom systemd[1]: Reloading.
Apr 10 04:46:59 democom systemd[1]: Configuration file /usr/lib/systemd/system/auditd.service is marked world-inaccessible. This has no effect as configuration data is accessible via APIs without restri
Apr 10 04:47:06 democom su[23833]: (to user1) user1 on pts/1
Apr 10 04:47:06 democom su[23833]: pam_unix(su:session): session opened for user user1 by user1(uid=0)
Apr 10 04:47:24 democom su[23833]: pam_unix(su:session): session closed for user user1
Apr 10 04:47:33 democom systemd[1]: Starting Remote desktop service (VNC)...
-- Subject: Unit vncserver@:display_number.service has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit vncserver@:display_number.service has begun starting up.
Apr 10 04:47:33 democom systemd[1]: Starting Session c11 of user user1.
-- Subject: Unit session-c11.scope has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit session-c11.scope has begun starting up.
Apr 10 04:47:33 democom systemd[1]: Started Session c11 of user user1.
-- Subject: Unit session-c11.scope has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit session-c11.scope has finished starting up.
-- 
-- The start-up result is done.
Apr 10 04:47:33 democom runuser[23853]: pam_unix(runuser-l:session): session opened for user user1 by (uid=0)
Apr 10 04:47:33 democom runuser[23853]: -bash: /usr/bin/vncserver: /usr/bin/perl: bad interpreter: Permission denied
Apr 10 04:47:33 democom runuser[23853]: pam_unix(runuser-l:session): session closed for user user1
Apr 10 04:47:33 democom systemd[1]: vncserver@:display_number.service: control process exited, code=exited status=126
Apr 10 04:47:33 democom systemd[1]: Failed to start Remote desktop service (VNC).
-- Subject: Unit vncserver@:display_number.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit vncserver@:display_number.service has failed.
-- 
-- The result is failed.
Apr 10 04:47:33 democom systemd[1]: Unit vncserver@:display_number.service entered failed state.
Apr 10 04:47:33 democom systemd[1]: vncserver@:display_number.service failed.

I think that display_number is the "port offset" (how many ports to add to 5900) but this is the error I am getting. Would appreciate any help, thanks.

closed as off-topic by Anthony Geoghegan, slm Jul 5 '18 at 20:52

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – Anthony Geoghegan, slm
If this question can be reworded to fit the rules in the help center, please edit the question.

  • Fedora 21 has been end of life for quite some time, I doubt that anyone is still interested in this. – dreua Jul 5 '18 at 8:59
  • @dauer it had only been out for 4 months when I asked this question. – Startec Jul 7 '18 at 5:54
  • This question was put to the front page by the Community Bot a few days ago since it didn't have an accepted answer. I commented in order to inform others seeing this as they might not be aware of the current Fedora release. You were on topic at the time of writing. – dreua Jul 9 '18 at 12:35
0

The most relevant line from your log is:

Apr 10 04:47:33 democom runuser[23853]: -bash: /usr/bin/vncserver: /usr/bin/perl: bad interpreter: Permission denied

Is it possible that perl is not installed in /usr/bin? Otherwise, something appears to be going wrong very early in the execution of that perl script. One way to debug would be to take whatever command is being executed in the systemd unit file and execute it by hand, to see what the error is.

-1

Check on /tmp/.X11-unix directory if X? file already exists (? the display #). If yes, rm -f that file and restart vncserver. If not, something else is blocking the way ?

Not the answer you're looking for? Browse other questions tagged or ask your own question.