Solved How-to call a VBS in Win7 Pro to Telnet a shutdown to a NAS

methinks

New member
Greetings (1st Post),

I have a Win7 Pro PC and a NAS Unix box both powered on a single APC UPS. The Win7 PC has a USB connected to a data port on the APC UPS so when there is a power hit and the settings with the APC s/w are meet, the Win7 Pro PC will start shutdown procedures before batteries expire!

My goal is to initiate a "shutdown.vbs" script (which I have put together and tested) that will telnet to my NAS box which is Linux and perform a shutdown routine on the NAS. The NAS is also plugged into the same APC UPS but there is no s/w are connectivity between the NAS and UPS directly other than the power cable.

Anyone know how I could get Win7 Pro to activate the "shutdown.vbs" just prior to it starting it's own showdown processes? I've looked through the Computer Mgmt area but didn't come across anything that stood out.

Thank You
 

My Computer

OS
Win7 Pro 32-bit
You could set it to run as a computer shutdown script, but you'd have to test it to make sure it actually worked. If you have Win7 Pro, you should be able to go into gpedit.msc and view the local group policy, from which you can set a shutdown script for the machine under Computer Configuration\Windows Settings\Scripts (and once configured, run gpupdate /force from an elevated cmd prompt).
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Custom
OS
Windows 10 Pro x64
CPU
Intel Core i7 4790K @ 4.5GHz
Motherboard
Asus Maximus Hero VII
Memory
32GB DDR3
Graphics Card(s)
Nvidia GeForce GTX970
Sound Card
Realtek HD Audio
Screen Resolution
1920x1200
Hard Drives
1x Samsung 250GB SSD
4x WD RE 2TB (RAIDZ)
PSU
Corsair AX760i
Case
Fractal Design Define R4
Cooling
Noctua NH-D15
Thanks for the Advice

Cluberti,

I implemented your suggestions. Worked great! Now when my house takes a power hit I know my PC will telnet shutdown to the NAS box and both systems will shutdown in a orderly manner.

Best Regards
 

My Computer

OS
Win7 Pro 32-bit
Back
Top