Announcement

Collapse
No announcement yet.

Batchfile schtasks problem

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

  • Batchfile schtasks problem

    Hi all!

    Here's my problem: I want all domain computer to run at logon a script, that will create a schedule task, like this:


    schtasks /create /TN redemarrage /RU domain\administrator /RP password /SC "toutes les semaines" /D JEU /TR c:\Scripts\reboot_pc.bat /ST 04:00:00

    sorry, parameter are in french as the hole company has french OS

    The issue? if the user is not an admin, I get this message:

    WARNING: The Scheduled task "redemarrage" has been created, but may not run because the account information could not be set.

    It will create the task but with the user as creator and as run as.. Can't get rid of it. I tried using SYSTEM, same error.

    ANyone already seen this?

    Thanks for any help

  • #2
    Re: Batchfile schtasks problem

    Well, if I stop the tasks scheduler, and restart it, wait for 15 mins, it works, but if I attempt again removing them and recreate, it doesn't work, but shouldn't need to be removed after it works.

    Comment


    • #3
      Re: Batchfile schtasks problem

      Originally posted by ChristTheGreat View Post
      Hi all!
      WARNING: The Scheduled task "redemarrage" has been created, but may not run because the account information could not be set.
      What error number and its description comes with the warning message? What's the OS on the clients?


      /Rems

      This posting is provided "AS IS" with no warranties, and confers no rights.

      __________________

      ** Remember to give credit where credit's due **
      and leave Reputation Points for meaningful posts

      Comment


      • #4
        Re: Batchfile schtasks problem

        Why not schedule the task by group policy?
        http://technet.microsoft.com/en-us/l.../cc725745.aspx
        gerth

        MCITP sa, ea & va, [email protected]

        Comment


        • #5
          Re: Batchfile schtasks problem

          Originally posted by gerth View Post
          Why not schedule the task by group policy?
          http://technet.microsoft.com/en-us/l.../cc725745.aspx

          Sorry long delay, I was not in good shape, but better than ever now

          Well, this appleis for 2008 +, our Domain controller are Windows 2003 R2. I doN't think we are going to move to 2008/2012 sicne a couple of time.. Budget

          but I'll keep this in note for other customer

          + Rep


          @Rems

          I changed mind and went with only reboot from WSUS with the updates, for now, I'll work on this after holidays, and post the error.

          Thanks

          Comment

          Working...
          X