Skip to content

Instantly share code, notes, and snippets.

@GRMrGecko
Last active April 6, 2024 18:05
Show Gist options
  • Save GRMrGecko/d7782d433a41355df45488be185006e3 to your computer and use it in GitHub Desktop.
Save GRMrGecko/d7782d433a41355df45488be185006e3 to your computer and use it in GitHub Desktop.
x11vnc systemd service for HedgeHog4/Hog4OS to allow remote control of the light board.
[Unit]
Description=Start x11vnc at startup.
After=multi-user.target
[Service]
Type=simple
ExecStart=/usr/bin/x11vnc -display :0 -norc -forever -loop -noxdamage -repeat -rfbauth /etc/x11vnc.pwd -rfbport 5900 -shared -o /var/log/x11vnc.log
[Install]
WantedBy=multi-user.target
@GRMrGecko
Copy link
Author

GRMrGecko commented May 23, 2021

Gain root access with single user mode https://www.itzgeek.com/how-tos/linux/debian/how-to-reset-root-password-on-debian-9-stretch.html

Once booted, setup FixtureNet with an IP Address in the Control Panel.

Press ctrl-alt-3 to enter a TTY and login as root.

Verify internet access with ping 1.1.1.1 - if no internet access, you may have to replace /etc/network/interfaces with the following.

# Hog 4 network interfaces

# The loopback network interface
auto lo
iface lo inet loopback

Update /etc/apt/sources.list with the following:

deb http://ftp.debian.org/debian stable main contrib non-free
deb http://security.debian.org/debian-security stretch/updates main contrib non-free
deb-src http://security.debian.org/debian-security stretch/updates main contrib non-free

Install x11vnc:

apt update
apt install x11vnc

Feel free to setup SSH for remote access.

Add x11vnc.service to /etc/systemd/system

systemctl daemon-reload
systemctl enable x11vnc

You should be able to reboot to have it started on port 5900.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment