Shutdown Script
I got the below info from a WindowsNt book. But i don't understand the last paragraph in the script. I want a script only to decrease the time of my machine to shutdown but here it seems that last paragraph is related to reboot also.
I got the below info from a WindowsNt book. But i don't understand the last paragraph in the script. I want a script only to decrease the time of my machine to shutdown but here it seems that last paragraph is related to reboot also. Can anyone help me to modify the last paragraph.
shutfast reboot, or shutfast shutdown
@echo off
net stop "computer Browser"
net stop "Messenger"
net stop "Net Logon"
net stop "NT LM Security Support Provider"
net stop "plug and play"
net stop "Protected Storage"
net stop "Remote Access Autodial Manager"
net stop "Server"
net stop "Spooler"
net stop "TCP/IP NetBIOS Helper" /Y
net stop "Workstation"
if %1==reboot goto reboot
shutdown /1 /Y /t:0
exit
:reboot
shutdown /1 /Y /r /t:0
exit
Thanks
shutfast reboot, or shutfast shutdown
@echo off
net stop "computer Browser"
net stop "Messenger"
net stop "Net Logon"
net stop "NT LM Security Support Provider"
net stop "plug and play"
net stop "Protected Storage"
net stop "Remote Access Autodial Manager"
net stop "Server"
net stop "Spooler"
net stop "TCP/IP NetBIOS Helper" /Y
net stop "Workstation"
if %1==reboot goto reboot
shutdown /1 /Y /t:0
exit
:reboot
shutdown /1 /Y /r /t:0
exit
Thanks
Participate on our website and join the conversation
This topic is archived. New comments cannot be posted and votes cannot be cast.
Responses to this topic
I think the %1 means the first parameter, so if you typed "shutfast reboot" then it would skip to the reboot section at that point, which adds the /r switch to the "shutdown" command, telling it to reboot. If you typed "shutfast shutdown" it would leave out the /r, shutting the system down.
If you wanted this to be JUST a shutdown script, you could remove that second paragraph and replace it with this:
shutdown /1 /Y /t:0
exit
and then all you would have to type is "shutfast" to shutdown the computer.
/L.A
If you wanted this to be JUST a shutdown script, you could remove that second paragraph and replace it with this:
shutdown /1 /Y /t:0
exit
and then all you would have to type is "shutfast" to shutdown the computer.
/L.A
I've tried the below script but still it's not working.
shutfast shutdown
@echo off
net stop "computer Browser"
net stop "Messenger"
net stop "Net Logon"
net stop "NT LM Security Support Provider"
net stop "plug and play"
net stop "Protected Storage"
net stop "Remote Access Autodial Manager"
net stop "Server"
net stop "Spooler"
net stop "TCP/IP NetBIOS Helper" /Y
net stop "Workstation"
if %1==reboot goto reboot
shutdown /1 /Y /t:0
exit
:reboot
shutdown /1 /Y /t:0
exit
I am a newbie. I will be grateful If anyone can elaborate the steps to execute this script.
I've saved the notepad like "SHUTFAST.CMD". Is that correct?
Thanks in advance.
shutfast shutdown
@echo off
net stop "computer Browser"
net stop "Messenger"
net stop "Net Logon"
net stop "NT LM Security Support Provider"
net stop "plug and play"
net stop "Protected Storage"
net stop "Remote Access Autodial Manager"
net stop "Server"
net stop "Spooler"
net stop "TCP/IP NetBIOS Helper" /Y
net stop "Workstation"
if %1==reboot goto reboot
shutdown /1 /Y /t:0
exit
:reboot
shutdown /1 /Y /t:0
exit
I am a newbie. I will be grateful If anyone can elaborate the steps to execute this script.
I've saved the notepad like "SHUTFAST.CMD". Is that correct?
Thanks in advance.
Okay. A few things here. First, lose the first line in the script. Next, this should be a .bat file, and the way I understand it, it should be named shutfast.bat and you would run this by typing "shutfast shutdown" or "shutfast reboot" at a command prompt.
[size:9]
@echo off
net stop "computer Browser"
net stop "Messenger"
net stop "Net Logon"
net stop "NT LM Security Support Provider"
net stop "plug and play"
net stop "Protected Storage"
net stop "Remote Access Autodial Manager"
net stop "Server"
net stop "Spooler"
net stop "TCP/IP NetBIOS Helper" /Y
net stop "Workstation"
if %1==reboot goto reboot
shutdown /1 /Y /t:0
exit
:reboot
shutdown /1 /Y /t:0
exit
The last thing I'll say is this will not shut down faster than it takes you to go to Start->Shutdown. Not only that but if your system is configured weird in any way, this could just crash your computer rather than shut it down.
[size:9]
@echo off
net stop "computer Browser"
net stop "Messenger"
net stop "Net Logon"
net stop "NT LM Security Support Provider"
net stop "plug and play"
net stop "Protected Storage"
net stop "Remote Access Autodial Manager"
net stop "Server"
net stop "Spooler"
net stop "TCP/IP NetBIOS Helper" /Y
net stop "Workstation"
if %1==reboot goto reboot
shutdown /1 /Y /t:0
exit
:reboot
shutdown /1 /Y /t:0
exit
The last thing I'll say is this will not shut down faster than it takes you to go to Start->Shutdown. Not only that but if your system is configured weird in any way, this could just crash your computer rather than shut it down.
The reason Why I am doing this is b'coz my system is not shutting down properly. Once I click the shutdown button on the start menu it just hangs on. After time sometime the EndTask menu is coming up.Even after clicking the EndTask menu it just hangs on. So I thought by doing this it will get shutdown fastly. I know this is all b'coz of the Norton AntiVirus which i've installed in my system. According to others suggestion I've turned on the APM under the power management option but still it's just like this.
I've tried ur script. It's asking whether the services should be stopped or not. Once I give "Y" it's not shutting down. Is there any other remedy available for my problem?.
Right now, What i am doing is going to control panel, Selecting the services panel and disabling the Norton Antivirus Client. Once i done this the system shutdowns properly. I've reinstalled the Norton Antivirus lot of time but still no remedy.
Thanks for your reply Lactic.Acid. Please excuse my english.
I've tried ur script. It's asking whether the services should be stopped or not. Once I give "Y" it's not shutting down. Is there any other remedy available for my problem?.
Right now, What i am doing is going to control panel, Selecting the services panel and disabling the Norton Antivirus Client. Once i done this the system shutdowns properly. I've reinstalled the Norton Antivirus lot of time but still no remedy.
Thanks for your reply Lactic.Acid. Please excuse my english.
What version of NAV are you using? I ran this before and never had shutdown issues. The fact that the "End Task" menu comes up implies to me that a program has crashed but not terminated, or is "Not Responding" as MS puts it. If this program is Norton AntiVirus, and it is actually locking up before you shut down, you may as well stop using it. If it's just hanging when you go to shutdown, try exiting NAV before shutting down, or alt-ctrl-del and kill NAV before you shutdown.
/L.A
/L.A