/build/static/layout/Breadcrumb_cap_w.png

Shutting Down Machines

I've just install kbox and I'm using the default shutdown script the clients are not respoding to it. They are in the inventory. Any suggestions?

0 Comments   [ + ] Show comments

Answers (16)

Posted by: 2bexact 15 years ago
Senior Yellow Belt
1
just tried shutdown.exe in the script. same result
Posted by: bgatech 15 years ago
Orange Senior Belt
1
I assume that the machine you are testing is near by. Did you up the shutdown time from 10 to 90 seconds. 10 seconds is not enough time to respond that the script ran. I would also try running the command line on the machine and see if it shuts down without the kbox.
Posted by: MACSnow 15 years ago
Senior Yellow Belt
1
This is something I use a lot, but it sounds like you're in a situation where you may not have tested any scripts before on remote machines... Is that right? It could be that your credentials are not set up (worth a call to support to check that out!)

Another interesting point to note: at the user conference this week we were discussing power management, and there was a suggestion to use psshutdown (free download from MS) to get additional capability. It has more features than the standard Windows utility.

You might find the video or slides of that session on the Kace website.
http://www.kace.com/kacekonference09/agenda-detail.php?tab=3

Good Luck!
Rich
Posted by: MACSnow 15 years ago
Senior Yellow Belt
1
Here's something else that I see with the default script:

Log for 'Shutdown Windows' on 'Some Machine'


[hr]



Started: Nov 14 2009 07:38:27 PM
Finished: Nov 14 2009 07:38:27 PM
Elapsed Time: 0 seconds
Status: in state 'verification_success'

Output LogC:\WINDOWS\System32\cmd.exe
standard output:
The machine is locked and can not be shut down without the force option.

C:\WINDOWS\System32\cmd.exe: process exited with code: 0

So in this case I have to change the script to force shutdown.

Edit:C:\WINDOWS\System32\cmd.exe /C shutdown -s -c "Shutdown by KBOX" -t 90 -d U:00:00
To add -f
C:\WINDOWS\System32\cmd.exe /C shutdown -f -s -c "Shutdown by KBOX" -t 90 -d U:00:00

Of course they could lose open docs if they are not saved.

Best,

Rich
Posted by: MACSnow 15 years ago
Senior Yellow Belt
1
ORIGINAL: MACSnow

Of course they could lose open docs if they are not saved.

Best,

Rich


Or I could do what was suggested in the conference:


Dependencies:
psshutdown.exe


Task 1
Attempts:
On Failure: Break Continue
Verify
On Success
Launch “$(KACE_DEPENDENCY_DIR)\psshutdown.exe”
with params “-c -f -m ”Shutdown by MountAuburn Administrator, click to cancel...“ -t 90 -e p:00:00”.
Log “PSSHUTDOWN Command Issued Successfully.” to “status”.

Hope this helps.
Seems to allow the user to cancel the forced shutdown...

Rich
Posted by: brondum9 15 years ago
Senior Yellow Belt
1
Pstools would have to be on the workstation for psshutdown to work? YEs? It isnt on the xp machine by default.
Posted by: MACSnow 15 years ago
Senior Yellow Belt
1
Hi,

Well actually no, pstools does not have to be placed on the machine in advance.
By specifying the dependency - psshutdown.exe - the script will load it onto the PC.
Then as you see in the script, where it says: "Launch “$(KACE_DEPENDENCY_DIR)\psshutdown.exe” "
The token $(KACE_DEPENDENCY_DIR) specifies the folder on the machine where the psshutdown.exe
binary is placed.

So when you run the script, it will place the file on the PC for you and then run it.

Hope that helps!

Rich
Posted by: cblake 15 years ago
Red Belt
1
The Shutdown commands send by KBOX scripting are the built in Windows commands (I'm assuming you're using Windows?). If you're having trouble check the KBOX logs as well as the event logs for clues. If your machines are in keyboard lock mode you'll need to add the "-f" switch to force the shutdown.

Other options include:
Usage: shutdown [-i | -l | -s | -r | -a] [-f] [-m \\computername] [-t xx] [-c "comment"] [-d u

No args Display this message (same as -?)
-i Display GUI interface, must be the first option
-l Log off (cannot be used with -m option)
-s Shutdown the computer
-r Shutdown and restart the computer
-a Abort a system shutdown
-m \\computername Remote computer to shutdown/restart/abort
-t xx Set timeout for shutdown to xx seconds
-c "comment" Shutdown comment (maximum of 127 characters)
-f Forces running applications to close without warning
-d [p]:xx:yy The reason code for the shutdown
u is the user code
p is a planned shutdown code
xx is the major reason code (positive integer less than 256)
yy is the minor reason code (positive integer less than 65536)
Posted by: GillySpy 15 years ago
7th Degree Black Belt
1
The machines are in inventory is good but more importantly:

1. Are the machines connected (ie. green light shown in inventory)
2. are you using an online script. i can't remember if the built-in script is online (i.e. kbox scheduled while connected) or offline (ie. lient scheduled)
3. is the kbox busy with other tasks in progress? settings->support->troubleshooting tools -> tasks
Posted by: 2bexact 15 years ago
Senior Yellow Belt
1
The machines are connected. I can see the kace management software running in processes. I have altered the script in a couple ways but nothing happens. The machines are assigned to two groups/ labels. I tried targeting the machine by IP and the group(s) by name. Still nothing. I've used both online/offline in the script. No other task are active other then weekly email alerts.
Posted by: 2bexact 15 years ago
Senior Yellow Belt
1
I am awaiting Board Approval for this project and this is of urgent interest.
Posted by: 2bexact 15 years ago
Senior Yellow Belt
1
All machines being tested are.....

IBM/Lenovo
windows XP sp2/3
joined to domain
Has multiple user profiles.
Has wake on land capabilities but don't wake either.
Posted by: bgatech 15 years ago
Orange Senior Belt
1
The old build in shutdown script used to be for 10 seconds. We had to up it to 90 so that the kbox would know it ran. I also have it set as an online script. That way it only runs the script at the given time.

Check the scripting logs for one of the machines it is suppose to run on.
Posted by: kdasanmartino 15 years ago
Second Degree Green Belt
1
I had to add shutdown.exe as a dependency before I could get it to work.
Not sure if you have that in your scrip or not.
Posted by: chrisgrim 15 years ago
Senior Purple Belt
1
2bexact,

It seems like maybe the scripts aren't running at all. Let's take a step back. If you look at the scripting logs for one of the target machines in inventory, does it show a log for your shutdown script? Another good way to test is to go to the Run Now tab under Scripting, choose the script and one or more machines and you will get immediate feedback and a log. If you post that log, maybe we can help a bit more.
Posted by: 2bexact 15 years ago
Senior Yellow Belt
1
Its now 9.23am. The log has the script as still running for what I'm seeing here. This is under ther the run now status

Start Time: Nov 02 2009 08:44:22 AM
Script Name: Shutdown a Windows system
Total Machines: 1

Pushed Machines: 1 (100%)
Push Successes: 1 (100%)
Push Failures: 0 (0%)

Completed Machines: 0 (0%)
Running Machines: 1 (100%)

Successes: 0 (0%)
Failures: 0 (0%)

When i click on scripts running, it shows the machine with a ? mark
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ