bash - unable to run commands in shell script after su mqm command,but able to run in putty?Pleae let me know how to execute.? -
my script is,
#!/bin/bash su mqm echo "display qlocal (<queuename>) curdepth" | runmqsc queuemanager
same command works in putty not through script.
putty interactive command line. try below. bash variables can used.
#!/bin/bash su - mqm -c "echo 'display qlocal (<queuename>) curdepth'|runmqsc queuemanager"
Comments
Post a Comment