How do I startstoprestart the Gateway service

Use the gateway helpers:
openclaw gateway status
openclaw gateway restart
If you run the gateway manually, openclaw gateway --force can reclaim the port. See Gateway.