What is in the current script ?
What no longer works about it? is there an error?
The NSH Script is
autolic User Password $1
cd: software not licensed: //SGI-NOT-BUHA03/
you can use blcli
Server licenseSingleServerWithLicensingPortalForCLI $SEVER true
Can this be run from the Console against Numerous Servers at once?
Yes just add it to a script job with some parameters
It should be a type 2 job, not a type 1. And it should run like:
For server in $@
autolic user password $server
this would have never worked as a type 1 job btw.
And it must be a type 2 script.
That is the root of your problem. if you use the blcli but a type 1 script, it will still fail.
I don't understand what type1/2 jobs are?
If you open the script object in the depot there are 4 types to select from. the licensing job should be the 2nd one. there should be more on the different types in the user guide or online help.
I created type-1 (1st option in NSH script) script and it is working fine for me.
echo "Assigning variables based on the script parameters"
echo "Server group is $server_group"
Server_list=`blcli Server listServersInGroup "$server_group"`
echo Server are $server_list
for target in $server_list
autolic -u user password $target
Is the target of your job a licensed server ?
That’s a really bad way to do it. this is what happens:
- job runs against smart group
- each server in smart group gets an instance of the job run against it
- each instance of the job runs the listAllServers command and iterates through the server list
So your licensing process is running many times in parallel. And you will still not avoid the problem that if one of the targets is not licensed you cannot cd into it when the job starts.
So you should make this a type 2 job and have simply:
For server in $@
Autolic user pass $server
And target the same smart group.
Thanks for the suggestion , and i tried with type-2 as well and working for me. One more query how to re-license the server having already license?