New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
Comments
use systemd instead of init.d
It should be simple
sudo nano /etc/systemd/system/vncserver.service
[Unit]
Description=VNC Server
After=syslog.target network.target
[Service]
Type=forking
User=orangepi
PAMName=login
PIDFile=/home/orangepi/.vnc/%H:1.pid
ExecStartPre=-/usr/bin/vncserver -kill :1 > /dev/null 2>&1
ExecStart=/usr/bin/vncserver -depth 24 -geometry 1440x900 :0
ExecStop=/usr/bin/vncserver -kill :1
RestartSec=15
Restart=on-failure
[Install]
WantedBy=multi-user.target
Just change orangepi to your user id ...
chmod 755 /etc/systemd/system/vncserver.service
chmod o+x /etc/systemd/system/vncserver.service #(not NECESSARY)
systemctl start vncserver
systemctl status vncserver
systemctl enable vncserver
He didn't ask for a systemd reccomedation.
While you're at it OP, just use Windows. Much easier. @noaman