RE: packaged received but didn't run
- From: Matthew Hudson <MatthewHudson@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 23 Jul 2007 13:52:01 -0700
first you need to make sure your package is set to run whether someone is
logged on or off.
Run the shutdown command as an admin so it will have command over everything.
If you are going to push the shutdown command to the client use the Xp
version or set it to:
---"this package contains no source files"
---start in folder "%systemroot%\system32" and run the shutdown command that
is already on the system(server/workstation) it will run the version for that
OS
----Command line: shutdown -s -f -t:5
--run as admin
--- run whether user is logged on or logged out
If you are doing a 5 second down then just leave it off. I typically do a
15 min just so if someone is there they know they better get their act in
gear and get out, assuming they are working at 2AM.
--
-----------------------
http://sms-hints-tricks.blogspot.com/
"Chris" wrote:
Thanks, Mattew. I used a shutdown.exe saved on the SMS server for a previous.
package. I think it's from Win2k.
Release 2.0 written by A. Blatzheim 1993 at Microsoft GmbH
Usage: SHUTDOWN [/?] [\\Computer] [/L] [/A] [/R] [/T:xx] ["Msg"] [/Y] [/C]
/? Shows this screen.
\\Computer Specifies a remote computer to shutdown.
/L Specifies a local shutdown.
/A Abortes a systemshutdown. This is only possible during the
timeout period.If this switch is used, all other are ignored.
/R Specifies that the machine should reboot after shutdown.
/T:xx Sets the timer for system shutdown in seconds.[20 sec. default]
"Msg" Specifies an additional message
/Y Answer all following questinons with yes
/C Forces running applications to close.
ATTENTION: If you use the /C parameter NT ignores the
applications option to save data which may
have canged. You will see no File-Save dialog
box, because NT will force the application to
close. This will result in a loss of all data.
not previously saved !!!
What I tried to shutdown are XP. There is one came with the OS but the
syntax is a little different. Here is from XP.
Usage: shutdown [-i | -l | -s | -r | -a] [-f] [-m \\computername] [-t xx]
[-c "comment"] [-d up:xx:yy]
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 [u][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)
Both have switch L. The only from Win2K is /L for local shutdown and the
one from XP is -L for log off.
In my package, the command line is (I browse to the folder on SMS where the
shutdown.exe is)
shutdown.exe /L /T:5 /Y /C
When I ran test aganist some XP system I realized the it only shut down
systems they were logged on or locked, but not logged off. I think this is
what happened why others didn't get shut down. Because the log on the client
showed me that it's waiting for logon. And once loggon I saw from Status
that the machine was shutdown.
I thought the package will bundled shudown.exe from the server and run it
using the switch specified. But looks like the same command (shutdown.exe on
XP) also has impact on the switch, especially with different function for
option L. So, in such case I guess I have to use the local shutdown command
with its own switch. What the command I should set? Is it
%systemroot%\system32\shutdown.exe -s -f -t:5 or shutdown.exe -s -f -t:5?
"Matthew Hudson" wrote:
When using shutdown.exe you have 2 options, set the package with no source
files and use the version already on the machine or push it down.
When you run shutodown did you do it with a -f (force applications to close)
otherwise it could hang or just not execute. What command line did you use?
--
-----------------------
http://sms-hints-tricks.blogspot.com/
"Chris" wrote:
I created a simple package to use shutdown.exe to shutdown systems in one of
our office at 1 am Saturday. The packaged was tested OK at our HQ for a few
XP machines. Then I advertised it to the collection for that office and
about 53 systems received. But when I checked next moring around 8 am I
found there were only 4 system started the program. I need to find out with
our local admin if the SMS 2nd site server in the office was down during that
time because the purpose for shutdown was due to power maintenanc. But it
shouldn't hapen till 3 am.
how can I check the problem? If a package was received by a system does the
system have everyting to run locally or it still needs to download the
package when it starts?
Thanks.
- References:
- RE: packaged received but didn't run
- From: Chris
- RE: packaged received but didn't run
- Prev by Date: RE: packaged received but didn't run
- Next by Date: Re: Creating an MSI winth Winistall
- Previous by thread: RE: packaged received but didn't run
- Next by thread: Re: Creating an MSI winth Winistall
- Index(es):
Relevant Pages
|