I just found that I if I include the host name in the sensor path, then the scriptutil will execute.
WIN2008R2# scriptutil -s //WIN2008R2.main.ads.com/c/Users/jmorndorff-admin/test.sh -h hosta.domain.com -h hostb.domain.com
this is a test running on host hosta.domain.com
Linux hosta.domain.com 2.6.18-308.1.1.el5 #1 SMP Fri Feb 17 16:51:01 EST 2012 x86_64 x86_64 x86_64 GNU/Linux
this is a test running on host hostb.domain.com
Linux hostb.domain.com 2.6.18-308.1.1.el5 #1 SMP Fri Feb 17 16:51:01 EST 2012 x86_64 x86_64 x86_64 GNU/Linux
That is painful - wish there was a way to just use the filename without the path.
It is inconsistent between Windows and Linux.
On Windows you need to provide a full pathname for the scanner (-s option) and the host (-f option). You can only provide a file name on Linux.
Also - it is strange how when using a full path name (without the host name prefix) the scriptutil will be successful on the first host in the list only.
Where are you running nsh from?
What is in the NSH/share/sensors directory on that system?
“//WIN2008R2.main.ads.com/c/Users/jmorndorff-admin” is not the NSH/share/sensors directory so I would expect you to have to provide the explicit path.
If you put the files in the ‘NSH/share/sensors’ directory on the system that you run the nsh binary this will work, however there are some naming conventions and formatting rules in the file to follow.
I am used to using the scriptutil command on a Linux server, similar to the example in the NSH Command Reference:
Example of using an existing script
host% cd //athens/tmp
athens% scriptutil -h rome -s rr -d /tmp/nsh
I guess on a Windows server, you have to fully qualifiy the path name of the script if it is not in the local sensors directory.