Wireguard fails after reboot (2.8.0)
-
Do you see any errors when you reinstall WG?
If you look in /conf you should see the pkg_log file for fro the last install.
-
@Buffalo0207 Try restarting dpinger followed by starting wireguard.
-
@Misterb Thanks - that semi worked. Although WG still stops after a reboot, by restarting dpinger, I no longer need to reinstall the WG package as the 'restart service' tab works.
-
@stephenw10 The only errors I see are the php errors.
-
Hmm, when it stops and fails to start when you try to start it manually do you see anything logged then?
I can't replicate that on anything I have here.
Try running
pkg upgrade
and see if it offers any upgrades. Something may not have upgraded. -
@stephenw10 When it stops and fails to start and then I try to start it manually there are no new pkg_log files. The WG pkg_log file remains on the date 13/08/25. Even when I reinstall the WG package, the log remains the same.
I did, however, get the following error...
check_upgrade: "Updating repositories metadata" returned error code 1 @ 2025-08-16 00:22:12
BTW - yesterday, I reinstalled all 10 packages, in case something hadn't installed correctly.
-
Yes you won't see anything in the pkg_log, that only covers the pkg install, but I'd expect to see something logged in the main log. For example when I restart it I see in the main log:
Aug 16 02:15:46 php-fpm 77985 /status_services.php: The command '/usr/local/etc/rc.d/wireguardd stop' returned exit code '1', the output was '' Aug 16 02:15:47 kernel wg0: changing name to 'tun_wg0' Aug 16 02:15:47 kernel tun_wg0: link state changed to UP Aug 16 02:15:47 php_wg 19350 /usr/local/pkg/wireguard/includes/wg_service.inc: Gateway, none 'available' for inet6, use the first one configured. 'GIF0_TUNNELV6'
If any of those things failed with an error I'd expect to see that there too.
-
@Buffalo0207 The problem seems to be remarkably similar to one discussed in 2023 Wireguard Site-to-Site Gateways disabled after reboot - service not starting
-
@stephenw10 Can you tell me exactly where the main log is and I will download it for you. I also have WinSCP, so can access it from there if this is easier.
-
@Misterb Thanks for this. I will add a cron job to automatically install the WG package.