Using BC to completely restart a server

I was wondering if there was a way to use BC to connect to a remote server and restart it? I am not sure if this is possible but any help would be greatly appreciated.

If you introspect the source of /packages/WmRoot/pub server-shutdown.dsp you’ll see this line:
%invoke wm.server.admin:shutdown%

This tells you the service being invoked in the background. You’ll also see input parameters. These are the one that stand out to me:

bounce: “yes” to restart, “no” to shutdown
option: “drain” to wait for all sessions to end, “force” for immediate.

This may vary depending on your version.

For more control build your own service that then invokes the shutdown service and call that using remote invoke.

Good luck!