ospower command

Use the ospower commands to power on, power off, reboot the host server OS, and display the current OS power state of the host server. The ospower commands support in-band and out-of-band mode.

ospower command syntax

OneCli.exe misc ospower <cmds> [<options>] [<connect opts>] 

Options

--help
Displays help information for commands and then exits without executing the command.
--output <arg>
Specifies the output directory.

Connection option

--imm <arg>
Specifies the IMM connection information.
Table 1. ospower commands and examples
Command Syntax example Description
turnon
OneCli.exe logmgr turnon
 --imm USERID:PASSW0RD@
10.240.xx.xx
Lenovo OneCli tcli01d-1.0.0
  • Powers on the host server OS.
  • Powers on the remote system host OS using:
    --imm user:password@ip:port
turnoff
OneCli.exe ospower turnoff
 --imm USERID:PASSW0RD@
10.240.xx.xx
  • Powers off the host server OS.
  • Powers off the remote system host OS using:
    --imm user:password@ip:port
reboot
OneCli.exe misc ospower
 reboot --imm USERID:
PASSW0RD@10.240.xx.xx
  • Reboots the host server OS.
  • Reboots the remote system host OS using:
    --imm user:password@ip:port
  • Reboot only works if the current power state is on.
state
OneCli.exe misc ospower
 state --imm USERID:
PASSW0RD@10.240.xx.xx
  • Checks the host server OS power states.
  • Checks the power state of the remote system host OS using:
    --imm user:password@ip:port

Example of the state command output

Lenovo ToolsCenterSuite CLI tcliXXX-X.X.X
Based on module version X.X.X
Licensed Materials - Property of Lenovo
(C) Copyright Lenovo Corp. 2013-2016 All Rights Reserved
Invoking SHOW command ...
Connected to IMM by IP address 10.240.252.102
start to check the System OS state
Server Power is currently On!