+ Post New Thread
Page 1 of 2 12 LastLast
Results 1 to 15 of 17
Network and Classroom Management Thread, psshutdown runs out of steam in Technical; I've been experimenting with psshutdown recently to automatically shutdown stations I have listed in a file. I have a .txt ...
  1. #1

    Join Date
    May 2008
    Location
    Irlanda del Norte
    Posts
    32
    Thank Post
    10
    Thanked 1 Time in 1 Post
    Rep Power
    8

    psshutdown runs out of steam

    I've been experimenting with psshutdown recently to automatically shutdown stations I have listed in a file. I have a .txt file listing the stations in each room and another .bat file for each room.
    e.g bio_lab1.bat is simply:
    psshutdown.exe @bio_lab1.txt -k

    This works for stations at the start of the .txt file, but then starts to ignore/timeout the remaining stations with the message:

    "Timeout accessing //strangeways/station123

    If //strangeways/station123 is already performing a shutdown operation you must abort it before issuing a different command"

    I've tried cutting the top off the .txt file so it just had the last two stations -and it worked.
    Has anyone any suggestions?

    P.S. running an RM CC3 setup - RM's tool too slow for what I want.

  2. #2
    richard.thomas's Avatar
    Join Date
    Sep 2007
    Posts
    492
    Thank Post
    5
    Thanked 11 Times in 10 Posts
    Rep Power
    11
    I've never used psShutdown. We use window's built in shutdown magicness for shutting down machine here.

    Have you checked for firewalls on the problem clients?

  3. #3
    browolf's Avatar
    Join Date
    Jun 2005
    Location
    Mars
    Posts
    1,364
    Blog Entries
    36
    Thank Post
    73
    Thanked 76 Times in 63 Posts
    Rep Power
    30
    i use down from lstools
    its more robust. its still slow waiting if the computer isnt on.

    what happens if someone's using the pc when you're shutting it down?
    see also shutdown system

  4. #4
    ICT_GUY's Avatar
    Join Date
    Feb 2007
    Location
    Weymouth
    Posts
    2,217
    Thank Post
    592
    Thanked 278 Times in 199 Posts
    Rep Power
    98
    Try LanShutdown from lantricks, saves a lot of hassle.

  5. #5
    Ravening_Wolf's Avatar
    Join Date
    Oct 2006
    Location
    Essex :(
    Posts
    290
    Thank Post
    1
    Thanked 3 Times in 3 Posts
    Rep Power
    12
    Could be timeouts caused by multiple stations accessing the same txt file at once?

  6. #6

    Join Date
    May 2008
    Location
    Irlanda del Norte
    Posts
    32
    Thank Post
    10
    Thanked 1 Time in 1 Post
    Rep Power
    8
    I might try some of the alternatives, or *have* to try some of the alternatives.

    Here's more information:
    I don't think there is a firewall issue as the stations respond to a direct command and also when they are in a small file i.e two stations and also I am not aware there is a firewall.
    I'm only running commands and the batch file when the room is empty and the stations are a mixture of OFF or at log-on screen.
    I don't think the stations are trying to acccess the .txt file - I am running one instance of psshutdown at my workstation which should send out the necessary shut-down instructions to each workstation in the .txt file - they shouldn't need to know any more.

  7. #7
    Joanne's Avatar
    Join Date
    Nov 2007
    Location
    Lancashire
    Posts
    1,036
    Blog Entries
    17
    Thank Post
    39
    Thanked 38 Times in 35 Posts
    Rep Power
    17
    we once had the problem of the switches blocking 'broadcasts'

    Could you switches be doing this? So you send the command and the switches realise halfway through and stop it?

  8. #8

    Join Date
    May 2008
    Location
    Irlanda del Norte
    Posts
    32
    Thank Post
    10
    Thanked 1 Time in 1 Post
    Rep Power
    8
    I've figured out the "problem".

    PSShutdown.exe batch command works through the list fine, until it meets a station already off. Once it encounters a station already off, it barfs on the rest of the list no matter how many are on.
    Blinking fan-tas-tic!

  9. #9
    gshaw's Avatar
    Join Date
    Sep 2007
    Location
    Essex
    Posts
    1,765
    Thank Post
    91
    Thanked 130 Times in 121 Posts
    Rep Power
    45
    Quote Originally Posted by diagram View Post
    I've figured out the "problem".

    PSShutdown.exe batch command works through the list fine, until it meets a station already off. Once it encounters a station already off, it barfs on the rest of the list no matter how many are on.
    Blinking fan-tas-tic!
    I hope that's wrong

    Although I've got 2 test PCs at the end of my list that seem to be shutting down so it must be making it through... hmm very odd

  10. #10

    maniac's Avatar
    Join Date
    Feb 2007
    Location
    Kent
    Posts
    3,003
    Thank Post
    192
    Thanked 413 Times in 300 Posts
    Rep Power
    136
    Easiest way I've found of shutting down machines is to create two batchfiles.

    Set one to run at machine startup with the commands;

    Code:
    at /DELETE /YES
    at 21:00 /every:M,T,W,Th,F "\\domain\netlogon\shutdwn.bat"
    This adds a scheduled task that calls a script called shutdwn.bat on the netlogon share at 9:00 pm every day. You can adjust this as you need to of course.

    Then in the shutdwn.bat file, simply use this command

    Code:
    shutdown -s -f -t 60 -c "End of day shutdown. Please save your work now, this workstation will shutdown in 1 Minute. This cannot be cancelled."
    Which obviously calls the windows built in shutdown command, and displays the appropreate message.

    This works like a charm for us and has done for the last year. It's pretty flexible as well as if you ever need to change or cancel it you can simply change the shutdwn.bat file accordingly. Every month or so we make it call defrag insted of shutdown.

    Incidently, do not name the batchfile 'shutdown.bat' else it will run itself in an endless loop!

    Mike.

  11. 2 Thanks to maniac:

    Alis_Klar (20th January 2011), gshaw (9th May 2008)

  12. #11
    richard.thomas's Avatar
    Join Date
    Sep 2007
    Posts
    492
    Thank Post
    5
    Thanked 11 Times in 10 Posts
    Rep Power
    11
    We shutdown our machines with a cmd file for each room. Inside the file are

    shutdown -s -t25 -m \\COMPUTER NAME

    This are ran from the server via a scheduled task. This means we can change the time or disable a shutdown script at short notice.

    Seems to do the trick

  13. #12
    gshaw's Avatar
    Join Date
    Sep 2007
    Location
    Essex
    Posts
    1,765
    Thank Post
    91
    Thanked 130 Times in 121 Posts
    Rep Power
    45
    Cheers for that maniac, I like the look of that method - going on the test area now

  14. #13

    Join Date
    Apr 2008
    Posts
    69
    Thank Post
    11
    Thanked 12 Times in 11 Posts
    Rep Power
    10
    Quote Originally Posted by maniac View Post
    Easiest way I've found of shutting down machines is to create two batchfiles.

    Set one to run at machine startup with the commands;

    Code:
    at /DELETE /YES
    at 21:00 /every:M,T,W,Th,F "\\domain\netlogon\shutdwn.bat"
    Mike.
    Hey, that sounds a brilliant idea.

    Definitely on my list for sorting - after Ofsted next week...

    Now if only we could do the same for WOL...

    Peter.

  15. #14

    Join Date
    May 2008
    Posts
    1
    Thank Post
    0
    Thanked 0 Times in 0 Posts
    Rep Power
    0
    Hey Mike, how did you get around users having no access to at.exe?

  16. #15
    Gibbo's Avatar
    Join Date
    Feb 2008
    Location
    Cheshire
    Posts
    1,840
    Thank Post
    124
    Thanked 279 Times in 185 Posts
    Rep Power
    72
    To prevent it stopping at a machine already shut down you could always use a Magic Packet utility to turn all the machines on first, then run the shutdown script.

    I just use a batch file with the SHUTDOWN command. It does hang if the machine is already off, but soon moves onto the next computer in the list.

SHARE:
+ Post New Thread
Page 1 of 2 12 LastLast

Similar Threads

  1. PsShutdown help needed!
    By tech_guy in forum Windows
    Replies: 13
    Last Post: 18th February 2010, 12:29 AM
  2. Psshutdown problem
    By SpuffMonkey in forum Scripts
    Replies: 7
    Last Post: 6th November 2008, 02:59 PM
  3. Logging psshutdown?
    By gshaw in forum Windows
    Replies: 3
    Last Post: 23rd April 2008, 09:11 PM
  4. Pre-terminated fibre runs
    By localzuk in forum Hardware
    Replies: 6
    Last Post: 15th December 2007, 01:23 AM
  5. MAC OS X 10.4.8 runs on any PC
    By ITWombat in forum Mac
    Replies: 4
    Last Post: 26th October 2006, 12:48 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •