You are not logged in.

#1 2014-09-16 02:18:15

Ravenman
Member
Registered: 2009-07-03
Posts: 236

[Solved] TigerVNC Bootup and Shutdown Script doesn't run

Hi to everyone:

I'm followed step by step these instructions, but I'm getting this error:

[root@localhost ~]# systemctl -l status vncserver@:1.service
● vncserver@:1.service - Remote desktop service (VNC)
   Loaded: error (Reason: Invalid argument)
   Active: inactive (dead)

sep 15 21:13:47 localhost systemd[1]: [/etc/systemd/system/vncserver@:1.service:28] Executable path is not absolute, ignoring: x0vncserver -display :0 -passwordfile /home/user/.vnc/passwd
sep 15 21:13:47 localhost systemd[1]: vncserver@:1.service lacks ExecStart setting. Refusing.
[root@localhost ~]# 

What I'm doing wrong?

Last edited by Ravenman (2014-09-21 15:24:55)

Offline

#2 2014-09-16 08:44:34

R00KIE
Forum Fellow
From: Between a computer and a chair
Registered: 2008-09-14
Posts: 4,734

Re: [Solved] TigerVNC Bootup and Shutdown Script doesn't run

The two status lines tell you that your service file is not correct. Recheck your service file and fix it so that the first error goes away, at that time I suspect the second error will also go away.


R00KIE
Tm90aGluZyB0byBzZWUgaGVyZSwgbW92ZSBhbG9uZy4K

Offline

#3 2014-09-17 02:39:01

Ravenman
Member
Registered: 2009-07-03
Posts: 236

Re: [Solved] TigerVNC Bootup and Shutdown Script doesn't run

R00KIE wrote:

The two status lines tell you that your service file is not correct. Recheck your service file and fix it so that the first error goes away, at that time I suspect the second error will also go away.

This is my service file:

# The vncserver service unit file
#
# 1. Copy this file to /etc/systemd/system/vncserver@:x.service
#  Note that x is the port number on which the vncserver will run.  The default is 1 which 
#  corresponds to port 5901.  For a 2nd instance, use x=2 which corresponds to port 5902.
# 2. Edit User=
#   ("User=foo")
# 3. Edit  and vncserver parameters appropriately
#   ("/usr/bin/vncserver %i -arg1 -arg2 -argn")
# 4. Run `systemctl --system daemon-reload`
# 5. Run `systemctl enable vncserver@:<display>.service`
#
# DO NOT RUN THIS SERVICE if your local area network is untrusted! 
#
# See the wiki page for more on security
# https://wiki.archlinux.org/index.php/Vncserver

[Unit]
Description=Remote desktop service (VNC)
After=syslog.target network.target

[Service]
Type=forking
User=user

# Clean any existing files in /tmp/.X11-unix environment
ExecStartPre=-/usr/bin/vncserver -kill %i
ExecStart=x0vncserver -display :0 -passwordfile /home/usuario1/.vnc/passwd
ExecStop=/usr/bin/vncserver -kill %i

[Install]
WantedBy=multi-user.target

I can't find the mistake. Can you help me, please?

Offline

#4 2014-09-17 09:53:26

Gusar
Member
Registered: 2009-08-25
Posts: 3,606

Re: [Solved] TigerVNC Bootup and Shutdown Script doesn't run

Specify full path to x0vncserver.

Or even better, don't use x0vncserver at all, it's an inefficient screen scraper. Use the X module instead, by creating /etc/X11/xorg.conf.d/40-vnc.conf

Section "Module"
        Load            "vnc"
EndSection

Section "Screen"
        Identifier      "Default Screen"
        Option          "PasswordFile"          "/home/usuario1/.vnc/passwd"
EndSection

Offline

#5 2014-09-21 15:26:44

Ravenman
Member
Registered: 2009-07-03
Posts: 236

Re: [Solved] TigerVNC Bootup and Shutdown Script doesn't run

Gusar wrote:

Specify full path to x0vncserver.

Or even better, don't use x0vncserver at all, it's an inefficient screen scraper. Use the X module instead, by creating /etc/X11/xorg.conf.d/40-vnc.conf

Section "Module"
        Load            "vnc"
EndSection

Section "Screen"
        Identifier      "Default Screen"
        Option          "PasswordFile"          "/home/usuario1/.vnc/passwd"
EndSection

A lot of thanks by your explanation, help and patience.

Offline

Board footer

Powered by FluxBB