Announcement

Collapse
No announcement yet.

Task Schdule activation through GPO

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Task Schdule activation through GPO

    I've places a batch file that will shutdown the workstations
    now i need to make it work on all the workstations.
    can i do it in a GPO (task schedule job)? and how.

  • #2
    Re: Task Schdule activation through GPO

    Search the forums. This has been discussed several times. If you can't find anything after searching, post back and we will see if we can point you in the right direction.
    1 1 was a racehorse.
    2 2 was 1 2.
    1 1 1 1 race 1 day,
    2 2 1 1 2

    Comment


    • #3
      Re: Task Schdule activation through GPO

      When do you want to run this batch file ?
      When user logs off, at night ..?

      Regards

      Comment


      • #4
        Re: Task Schdule activation through GPO

        Checkout the SHUTDOWN command:

        C:\>shutdown /?
        Usage: shutdown [-i | -l | -s | -r | -a] [-f] [-m \\computername] [-t xx] [-c "comment"] [-d upx: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]x: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)

        C:\>

        You can specify the computer name in the command. You could run this from the server? Just an option for you to consider.
        |
        +-- JDMils
        |
        +-- Regional Systems Engineer, DotNet programmer & Jack of all trades
        |

        Comment


        • #5
          Re: Task Schdule activation through GPO

          I want all workstations to shutdown at 21:00

          i couldn't find any discutions about it in this forum.
          if any of you remember when was it, please send me a link and i'll follow the instructions from there.

          thanks

          Yoav

          Comment


          • #6
            Re: Task Schdule activation through GPO

            Checkout PowerDown
            Checkout Variety from Free Downloads
            Last edited by JDMils; 30th October 2006, 11:06.
            |
            +-- JDMils
            |
            +-- Regional Systems Engineer, DotNet programmer & Jack of all trades
            |

            Comment


            • #7
              Re: Task Schdule activation through GPO

              the batch file i wrote is as simple as it gets.

              "@echo off
              shutdown -s -f -t 15 -c "Go Home, It's Late"
              exit"

              the batch is in \\servername\netlogon

              i need to make it work on all of my computers at 21:00

              I have several options:

              1) go to every computer and create a task scheduler for the batch file.
              2) maybe - create a task schedule through the server
              3) work with external tools (i dont want to work with external tools)

              how can i establish the second option?

              Comment


              • #8
                Re: Task Schdule activation through GPO

                Originally posted by yoav30 View Post
                the batch file i wrote is as simple as it gets.

                "@echo off
                shutdown -s -f -t 15 -c "Go Home, It's Late"
                exit"

                the batch is in \\servername\netlogon

                i need to make it work on all of my computers at 21:00

                I have several options:

                1) go to every computer and create a task scheduler for the batch file.
                2) maybe - create a task schedule through the server
                3) work with external tools (i dont want to work with external tools)

                how can i establish the second option?
                http://forums.petri.com/showthread.php?t=6944

                Michael
                Michael Armstrong
                www.m80arm.co.uk
                MCITP: EA, MCTS, MCSE 2003, MCSA 2003: Messaging, CCA, VCP 3.5, 4, 5, VCAP5-DCD, VCAP5-DCA, ITIL, MCP, PGP Certified Technician

                ** Remember to give credit where credit is due and leave reputation points sigpic where appropriate **

                Comment


                • #9
                  Re: Task Schdule activation through GPO

                  Iv'e downloaded it, and checked it, but i don't want to use external tools.

                  Comment


                  • #10
                    Re: Task Schdule activation through GPO

                    Originally posted by yoav30 View Post
                    Iv'e downloaded it, and checked it, but i don't want to use external tools.
                    Why not?

                    the pstools suite of applications are extremely useful and I wont be supprised if they start to a make an apperance in vista / longhorn since MS acquired them.

                    Michael
                    Michael Armstrong
                    www.m80arm.co.uk
                    MCITP: EA, MCTS, MCSE 2003, MCSA 2003: Messaging, CCA, VCP 3.5, 4, 5, VCAP5-DCD, VCAP5-DCA, ITIL, MCP, PGP Certified Technician

                    ** Remember to give credit where credit is due and leave reputation points sigpic where appropriate **

                    Comment


                    • #11
                      Re: Task Schdule activation through GPO

                      thanks Michael.

                      i'll look into it.

                      but only for the sake of learning a new thing.

                      is ther a way to get a batchfile to run at a certine hour on all computers or some computers without an external tool?

                      Comment


                      • #12
                        Re: Task Schdule activation through GPO

                        In one word: nope.
                        I couldn't find anywhere in the GPO a way to schedule tasks. I even tried to create the task on my computer and copy it to the others. It was copied, but it won't run (looks like a permission issue).

                        Sorin Solomon


                        In order to succeed, your desire for success should be greater than your fear of failure.
                        -

                        Comment


                        • #13
                          Re: Task Schdule activation through GPO

                          Thanks anyway.

                          Comment


                          • #14
                            Re: Task Schdule activation through GPO

                            Without reading everything before;

                            You can create a sheduled task via script which you can run via startup/shutdown script.

                            http://www.microsoft.com/technet/scr...4/hey0922.mspx
                            http://www.microsoft.com/technet/scr....mspx?mfr=true
                            Marcel
                            Technical Consultant
                            Netherlands
                            http://www.phetios.com
                            http://blog.nessus.nl

                            MCITP(EA, SA), MCSA/E 2003:Security, CCNA, SNAF, DCUCI, CCSA/E/E+ (R60), VCP4/5, NCDA, NCIE - SAN, NCIE - BR, EMCPE
                            "No matter how secure, there is always the human factor."

                            "Enjoy life today, tomorrow may never come."
                            "If you're going through hell, keep going. ~Winston Churchill"

                            Comment


                            • #15
                              Re: Task Schdule activation through GPO

                              Tell me, is it necesarry for you to display your users a message? Or you can just shut their stations down?

                              Sorin Solomon


                              In order to succeed, your desire for success should be greater than your fear of failure.
                              -

                              Comment

                              Working...
                              X