root@OPNsenseMaster:/usr/local/etc/rc.syshook.d/carp # /usr/local/sbin/pluginctl -s wireguard statuswireguard[846d1fe6-cb46-4f32-8ca8-dcc31f9ff267] is running.root@OPNsenseMaster:/usr/local/etc/rc.syshook.d/carp # /usr/local/sbin/pluginctl -s wireguard stopService `wireguard[846d1fe6-cb46-4f32-8ca8-dcc31f9ff267]' has been stopped.root@OPNsenseMaster:/usr/local/etc/rc.syshook.d/carp # /usr/local/sbin/pluginctl -s wireguard statuswireguard[846d1fe6-cb46-4f32-8ca8-dcc31f9ff267] is running.
root@OPNsenseMaster:/usr/local/etc/rc.syshook.d/carp # /usr/local/opnsense/scripts/Wireguard/wg-service-control.php -a stoproot@OPNsenseMaster:/usr/local/etc/rc.syshook.d/carp # /usr/local/sbin/pluginctl -s wireguard statuswireguard[846d1fe6-cb46-4f32-8ca8-dcc31f9ff267] is running.
/usr/local/sbin/pluginctl -s wireguard status
sockstat -l -4
Maybe you can use the actions:https://github.com/opnsense/core/blob/master/src/opnsense/service/conf/actions.d/actions_wireguard.confThey can be called with configctl, e.g.:configctl wireguard stopThe configctl Actions call this script:https://github.com/opnsense/core/blob/98878a9eb90c1150b232bfbc7e9a012a3e3462a0/src/opnsense/scripts/Wireguard/wg-service-control.php