HPE SimpliVity
1753471 Members
4863 Online
108794 Solutions
New Discussion

Re: running svt-shutdown-safe from a remote server

 
SOLVED
Go to solution
jlangmead
Regular Advisor

running svt-shutdown-safe from a remote server

Hi

Is it possible to shutdown an OVC via an SSH command line executed from a remote server?

If I putty into the OVC I can execute svt-shutdown-safe all fine and the OVC will shut down as expected. 

If I run #sshpass -p '<OVC password>' ssh -l administrator@vsphere.local <OVC IP address> 'svt-shutdown-safe'   it logs in ok but I get an error saying that 'svt-shutdown-safe' cannot be found. Is this expected and, if so, is there a way to get this to work?

kind regards

3 REPLIES 3
db13
HPE Pro

Re: running svt-shutdown-safe from a remote server

@jlangmead, running this command requires that the environment variables be set prior. To do this, you will need to use...
. /var/tmp/buil/bin/appsetup
... in your command line.

Try this command:
#sshpass -p '<OVC password>' ssh -l administrator@vsphere.local <OVC IP address> '. /var/tmp/buil/bin/appsetup;svt-shutdown-safe' 

I am an HPE Employee
A quick resolution to technical issues for your HP Enterprise products is just a click away HPE Support Center Knowledge-base

Accept or Kudo

jlangmead
Regular Advisor

Re: running svt-shutdown-safe from a remote server

Hi

Thanks for that - that works well

I don't suppose you also know the syntax for being able to use the svtcli user for this? I'd need to add the --emgergency to the end of the command line but then also include a method to input the password again?

many thanks in advance

db13
HPE Pro
Solution

Re: running svt-shutdown-safe from a remote server

@jlangmead, there is no natively supported way to automate svtcli logins with the commands. 

I am an HPE Employee
A quick resolution to technical issues for your HP Enterprise products is just a click away HPE Support Center Knowledge-base

Accept or Kudo