Hi,
It seems this is a question about logic. Per my understanding, we can run any command, other than restart/stop the agent command, which will break the running environment. The restart/start agent command should be run at OS level, for example, crond. To confirm this, we can run other commands, for example, ps -e | grep omi to see if it works.
<p:ExecuteShellCommand_INPUT xmlns:p="http://schemas.microsoft.com/wbem/wscim/1/cim-schema/2/SCX_OperatingSystem"><p:command>ps -e | grep omi</p:command><p:timeout>120</p:timeout></p:ExecuteShellCommand_INPUT>
Alex
If the response is helpful, please click "Accept Answer" and upvote it.