Changes

Jump to navigation Jump to search
336 bytes added ,  23:52, 27 February 2015
no edit summary
Line 186: Line 186:     
Issuing commands could shutdown your server unexpectedly!}}
 
Issuing commands could shutdown your server unexpectedly!}}
 +
 
= SME 9 =
 
= SME 9 =
   Line 201: Line 202:  
   
 
   
 
  /sbin/e-smith/expand-template /etc/ups/upsd.users
 
  /sbin/e-smith/expand-template /etc/ups/upsd.users
  service nut restart
+
  /usr/sbin/upsd -c reload
    
===UPS Variables and Commands===
 
===UPS Variables and Commands===
Line 226: Line 227:     
  /sbin/e-smith/expand-template /etc/ups/upsd.users
 
  /sbin/e-smith/expand-template /etc/ups/upsd.users
  service nut restart
+
  /usr/sbin/upsd -c reload
   −
{{Note box|To disabled the admin user once you have changed the UPS parameters or issued commands as required, issue the commands
+
{{Note box|To disabled the administrative privileges once you have changed the UPS parameters or issued commands as required, issue the commands
 
  config setprop nut AdminUser disabled
 
  config setprop nut AdminUser disabled
 
  /sbin/e-smith/expand-template /etc/ups/upsd.users
 
  /sbin/e-smith/expand-template /etc/ups/upsd.users
  service nut restart
+
  /usr/sbin/upsd -c reload
 
}}
 
}}
   Line 250: Line 251:  
  config setprop nut access localhost   
 
  config setprop nut access localhost   
 
  /sbin/e-smith/expand-template /etc/ups/upsd.conf
 
  /sbin/e-smith/expand-template /etc/ups/upsd.conf
service nut restart
+
  /usr/sbin/upsd -c reload
    
In localhost or public mode ( no remote access ), access to your ups is ( UPS name is '''UPS''' )
 
In localhost or public mode ( no remote access ), access to your ups is ( UPS name is '''UPS''' )
Line 272: Line 273:  
You can now modify the variables you wish using a command similar to the following (Note the order of the arguments is important, and you may need quotes around the value being set, "20"):
 
You can now modify the variables you wish using a command similar to the following (Note the order of the arguments is important, and you may need quotes around the value being set, "20"):
 
  upsrw -s battery.charge.low=20 -u admin -p admin UPS
 
  upsrw -s battery.charge.low=20 -u admin -p admin UPS
 +
 +
For remote host (slave UPS ), we need to add the IP from master UPS to run command.
 +
upsrw -s battery.charge.low=20 -u admin -p admin UPS@192.168.2.1
    
Where the value after '''-s''' should be one of the parameters identified by the '''upsrw ups''' command. You can of course verify your changes using     
 
Where the value after '''-s''' should be one of the parameters identified by the '''upsrw ups''' command. You can of course verify your changes using     
Line 278: Line 282:  
  upsc UPS
 
  upsc UPS
   −
After you are done, clean up by disabling the '''upsd''' administrative user '''admin''':
+
After you are done, clean up by disabling the '''upsc''' administrative privileges:
 
{{Warning box|Make sure you understand the meaning or the UPS variables and their available setting options. Verify that your changes meet your intended behaviour!}}
 
{{Warning box|Make sure you understand the meaning or the UPS variables and their available setting options. Verify that your changes meet your intended behaviour!}}
   Line 294: Line 298:  
  upscmd -l UPS
 
  upscmd -l UPS
   −
You can now issue a command to the UPS with similar to the following:
+
You can now issue a command to the localhost UPS with similar to the following:
 
  upscmd -u admin -p admin UPS test.battery.start
 
  upscmd -u admin -p admin UPS test.battery.start
 +
 +
For remote host (slave UPS ), we need to add the IP from master UPS to run command.
 +
upscmd -u admin -p admin UPS@192.168.2.1 test.battery.start
    
Where the command '''test.battery.start''' is a valid command for your UPS as previously determined by '''upscmd -l UPS'''. Depending upon the command issued you may get broadcast messages and emails relating to and confirming what the UPS is doing.
 
Where the command '''test.battery.start''' is a valid command for your UPS as previously determined by '''upscmd -l UPS'''. Depending upon the command issued you may get broadcast messages and emails relating to and confirming what the UPS is doing.
   −
After you are done, clean up by disabling the '''upsd''' administrative user '''admin''':
+
After you are done, clean up by disabling the '''upsc''' administrative privileges:
 
{{Warning box|Before issuing any commands verify what they do for your particular UPS via the relevant documentation and ensure that the command meets your intended behavioural requirement!
 
{{Warning box|Before issuing any commands verify what they do for your particular UPS via the relevant documentation and ensure that the command meets your intended behavioural requirement!
  
66

edits

Navigation menu