help running windows services at a particular time.

Discussion in 'NZ Computing' started by T.N.O., Oct 9, 2003.

  1. T.N.O.

    T.N.O. Guest

    Anyone got any ideas on how to run a service(any service) at a particular
    time? and then stop at a later time...

    I dont have a great need for this, but I want to know how to do it.

    I also want it to do it whether someone is logged in or not, I assume I can
    do some sort of schedule tasks type thing, only not associated with a login?
    T.N.O., Oct 9, 2003
    #1
    1. Advertising

  2. T.N.O.

    Biggles Guest

    Closest thing I have used, which may be worth looking into, is a program
    called xyntservice
    It DOESN'T support scheduling, but you could write an app to do that.
    xyntservice will allow you to run a standard exe or com as a service.
    You can list what programs you need run, what order to start them (and
    delays in between).
    You can also set how often to check its running (down to every minute) - if
    you have set an order to run programs and the 2nd out of 3 has crashed, it
    will close the 3rd, then open the 2nd, then wait the delay set for between
    the 2nd and third and then open the third.

    I use it to run my own database engine and an internet ap that accesses the
    database - in my case, the database HAS to be running for about 4 seconds
    before the internet ap is started. xyntservice takes care of this.......

    AND its free!

    - John
    f i l e - i t ( a t ) i h u g . c o . n z

    "T.N.O." <> wrote in message
    news:bm2ek2$h2e4u$-berlin.de...
    > Anyone got any ideas on how to run a service(any service) at a particular
    > time? and then stop at a later time...
    >
    > I dont have a great need for this, but I want to know how to do it.
    >
    > I also want it to do it whether someone is logged in or not, I assume I

    can
    > do some sort of schedule tasks type thing, only not associated with a

    login?
    >
    >
    Biggles, Oct 9, 2003
    #2
    1. Advertising

  3. T.N.O.

    Jay Guest

    T.N.O. wrote:

    > Anyone got any ideas on how to run a service(any service) at a particular
    > time? and then stop at a later time...
    >
    > I dont have a great need for this, but I want to know how to do it.
    >
    > I also want it to do it whether someone is logged in or not, I assume I
    > can do some sort of schedule tasks type thing, only not associated with a
    > login?


    "crontab" or "at"
    Jay, Oct 9, 2003
    #3
  4. T.N.O.

    Rob Guest

    In news:bm2ftt$hm4nl$-berlin.de,
    Jay roused me from near catatonia by blurting:
    > T.N.O. wrote:
    >
    >> Anyone got any ideas on how to run a service(any service) at a
    >> particular time? and then stop at a later time...
    >>
    >> I dont have a great need for this, but I want to know how to do it.
    >>
    >> I also want it to do it whether someone is logged in or not, I
    >> assume I can do some sort of schedule tasks type thing, only not
    >> associated with a login?

    >
    > "crontab" or "at"


    The subject mentioned windows, which tends to have trouble running *nix
    commands.

    I'll write that again. The subject mentioned windows, which tends to have
    trouble running
    Rob, Oct 9, 2003
    #4
  5. T.N.O.

    T.N.O. Guest

    "Biggles" wrote
    > Closest thing I have used, which may be worth looking into, is a program
    > called xyntservice
    > It DOESN'T support scheduling, but you could write an app to do that.
    > xyntservice will allow you to run a standard exe or com as a service.
    > You can list what programs you need run, what order to start them (and
    > delays in between).


    Handy... I guess I could run them with a 12 hr delay between them :)

    > I use it to run my own database engine and an internet ap that accesses

    the
    > database - in my case, the database HAS to be running for about 4 seconds
    > before the internet ap is started. xyntservice takes care of this.......
    >
    > AND its free!



    I'll look into it.
    T.N.O., Oct 9, 2003
    #5
  6. T.N.O.

    T.N.O. Guest

    "Rob" wrote
    > The subject mentioned windows, which tends to have trouble running *nix
    > commands.
    > I'll write that again. The subject mentioned windows, which tends to have
    > trouble running


    There is always one, always...
    T.N.O., Oct 9, 2003
    #6
  7. T.N.O.

    XboxLover Guest

    "Jay" <> wrote in message
    news:bm2ftt$hm4nl$-berlin.de...
    > T.N.O. wrote:
    >
    > > Anyone got any ideas on how to run a service(any service) at a

    particular
    > > time? and then stop at a later time...
    > >
    > > I dont have a great need for this, but I want to know how to do it.
    > >
    > > I also want it to do it whether someone is logged in or not, I assume I
    > > can do some sort of schedule tasks type thing, only not associated with

    a
    > > login?

    >
    > "crontab" or "at"


    Doh! Stupid penguin fuckers.

    XboxLover!
    XboxLover, Oct 9, 2003
    #7
  8. T.N.O.

    T.N.O. Guest

    "XboxLover" wrote
    > > > Anyone got any ideas on how to run a service(any service) at a

    > particular
    > > > time? and then stop at a later time...


    > > "crontab" or "at"


    > Doh! Stupid penguin fuckers.


    nasty...
    T.N.O., Oct 9, 2003
    #8
  9. T.N.O.

    T.N.O. Guest

    "T.N.O." wrote
    > Anyone got any ideas on how to run a service(any service) at a particular
    > time? and then stop at a later time...


    If I made a service, that was run using the user "timer" which was
    restricted to only logging on during the hours of 5pm till 9am would this
    work? as the rest of the time the service wouldn't be able to run due to
    logon restrictions.

    This is all just theory.
    T.N.O., Oct 9, 2003
    #9
  10. T.N.O.

    SNOman Guest

    T.N.O. wrote:

    > Anyone got any ideas on how to run a service(any service) at a particular
    > time? and then stop at a later time...
    >
    > I dont have a great need for this, but I want to know how to do it.
    >
    > I also want it to do it whether someone is logged in or not, I assume I can
    > do some sort of schedule tasks type thing, only not associated with a login?
    >
    >

    Why not just use a net start and net stop in a batch file which is then
    scheduled using task scheduler?
    SNOman, Oct 9, 2003
    #10
  11. T.N.O.

    Rider Guest

    "T.N.O." <> wrote in message
    news:bm2gtj$i9aog$-berlin.de...
    > "Rob" wrote
    > > The subject mentioned windows, which tends to have trouble running *nix
    > > commands.
    > > I'll write that again. The subject mentioned windows, which tends to

    have
    > > trouble running

    >
    > There is always one, always...
    >
    >


    They cant help themselves. Theyre just so eager to spout off about Linux
    they dont even read the post properly.
    Rider, Oct 9, 2003
    #11
  12. T.N.O.

    T.N.O. Guest

    "SNOman" wrote
    > Why not just use a net start and net stop in a batch file which is then
    > scheduled using task scheduler?


    AFAIK, task scheduler needs someone logged in

    Oops, forgot to mention OS, this is on Win2k pro
    T.N.O., Oct 9, 2003
    #12
  13. T.N.O.

    AD. Guest

    On Thu, 09 Oct 2003 15:29:42 +1300, XboxLover wrote:

    >> "crontab" or "at"

    >
    > Doh! Stupid penguin fuckers.


    Don't be so quick off the mark.

    at is the command line interface to the Scheduler service in Windows (NT
    based ones that is).

    And as far as I'm aware you can also get 3rd party cron clones for Windows
    too, and syslog etc clones.

    Cheers
    Anton
    AD., Oct 9, 2003
    #13
  14. T.N.O.

    AD. Guest

    On Thu, 09 Oct 2003 16:44:59 +1300, T.N.O. wrote:

    > "SNOman" wrote
    >> Why not just use a net start and net stop in a batch file which is then
    >> scheduled using task scheduler?

    >
    > AFAIK, task scheduler needs someone logged in


    Not in my experience, especially if you are just running a batch file
    with no user input required. All our NT backups scripts used to run just
    fine like that - they started and stopped services too.

    at /?

    Cheers
    Anton
    AD., Oct 9, 2003
    #14
  15. T.N.O.

    Steven H Guest

    In article <bm2ek2$h2e4u$-berlin.de>,
    says...
    > Anyone got any ideas on how to run a service(any service) at a particular
    > time? and then stop at a later time...
    >
    > I dont have a great need for this, but I want to know how to do it.
    >
    > I also want it to do it whether someone is logged in or not, I assume I can
    > do some sort of schedule tasks type thing, only not associated with a login?
    >
    >
    >


    Create a "master service", this will get loaded and read off
    instructions form a config file.

    IMPORTANT DONT CREATE A USER INTERFACE FOR THIS (OR ANY) SERVICE

    insted create a UI that interacts ONLY with the config file the Master
    Service uses.

    in this config file you can tell it to load a DLL and run a command on
    that DLL at a particular time.

    EG:
    Master Servce gets loaded up and reads off its list of things to do
    when it comes time for one of these things to be ran it will simply fire
    off a thread that loads the dll and fires off the interface that it is
    told to.

    of course in the master service engine you will need to keep an eye on
    any changes made to the config file, and you will need to know what to
    do about exceptions when (not if - thats lazy programming) they happen.

    not to hard to do, .NET makes things simplar.

    ===================================================
    Steven H
    Steven H, Oct 9, 2003
    #15
  16. T.N.O.

    Steven H Guest

    In article <bm2id4$hr6rc$-berlin.de>,
    says...
    > "XboxLover" wrote
    > > > > Anyone got any ideas on how to run a service(any service) at a

    > > particular
    > > > > time? and then stop at a later time...

    >
    > > > "crontab" or "at"

    >
    > > Doh! Stupid penguin fuckers.

    >
    > nasty...


    espically the penguin std's

    --
    ===================================================
    Steven H
    Steven H, Oct 9, 2003
    #16
  17. T.N.O.

    Armpit Guest

    "T.N.O." <> wrote in message
    news:bm2ek2$h2e4u$-berlin.de...
    > Anyone got any ideas on how to run a service(any service) at a particular
    > time? and then stop at a later time...
    >
    > I dont have a great need for this, but I want to know how to do it.
    >
    > I also want it to do it whether someone is logged in or not, I assume I

    can
    > do some sort of schedule tasks type thing, only not associated with a

    login?
    >

    Use the "at" command, which IS available on win2000.
    Within the script you run, use "net start <servicename>" at the start of the
    script, and "net stop <servicename>" at the end of your script.
    Armpit, Oct 9, 2003
    #17
  18. T.N.O.

    AD. Guest

    On Thu, 09 Oct 2003 18:32:40 +1300, Armpit wrote:

    > Use the "at" command, which IS available on win2000. Within the script you
    > run, use "net start <servicename>" at the start of the script, and "net
    > stop <servicename>" at the end of your script.


    Or better yet two scripts (one start and one stop script) scheduled to run
    at their respective times.

    Cheers
    Anton
    AD., Oct 9, 2003
    #18
  19. T.N.O.

    Max Burke Guest

    > Rider scribbled:
    > "T.N.O." <> wrote in message
    > news:bm2gtj$i9aog$-berlin.de...
    >> "Rob" wrote
    >>> The subject mentioned windows, which tends to have trouble running
    >>> *nix commands.
    >>> I'll write that again. The subject mentioned windows, which tends
    >>> to have trouble running

    >>
    >> There is always one, always...


    > They cant help themselves. Theyre just so eager to spout off about
    > Linux they dont even read the post properly.



    I put it down to their inferiority complex; Of course they'll now start
    posting about how superior they are because they use *nix even as they
    claim no one has any choice to use anything but Windows because
    Microsoft denies everyone any right to choose.....
    ;-)))


    What you have to believe in if you want to be a Linux user.....
    Things Linux is good for #2134
    Personal empowerment and Linux.
    Once you've switched to a REAL OS like Linux (LGX), it's truly
    liberating and empowering on so many levels.
    Rapskat, COLA, 22-9-2002.

    Freedom and Linux....
    Though I've known this since I first started using Linux (LGX), the full
    implication never hit me until now....I'M FREE!
    Rapskat, COLA, 22-9-2002.

    Empowerment and Linux....
    Once you've switched to a REAL OS like Linux (LGX), it's truly
    liberating and empowering on so many levels.
    Rapskat, COLA, 22-9-2002.

    COLA newsgroup subject line, 12-8-2002
    OSS and Linux may save us from a new dark age.

    Que All the OSS/*nix users of nz.comp to provide evidence of the above
    beliefs so loved by so many Linux users.....

    OTOH
    The only thing you need to consider when you choose to be a Windows
    user.....
    Things Windows is good for #1
    Running your computer....

    --
    mlvburke@#%&*.net.nz
    Replace the obvious with paradise to email me.
    See Found Images at:
    http://homepages.paradise.net.nz/~mlvburke/
    Max Burke, Oct 9, 2003
    #19
  20. T.N.O.

    Enkidu Guest

    On Thu, 09 Oct 2003 17:08:38 +1300, "AD." <> wrote:

    >On Thu, 09 Oct 2003 15:29:42 +1300, XboxLover wrote:
    >
    >>> "crontab" or "at"

    >>
    >> Doh! Stupid penguin fuckers.

    >
    >Don't be so quick off the mark.
    >
    >at is the command line interface to the Scheduler service in Windows (NT
    >based ones that is).
    >

    Erm, no, it comes with the resource pack. But there are free clones
    around too.

    Cheers,

    Clifff
    --

    The complete lack of evidence is the surest sign
    that the conspiracy is working.
    Enkidu, Oct 9, 2003
    #20
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Szymi
    Replies:
    0
    Views:
    597
    Szymi
    Nov 3, 2003
  2. For Sale
    Replies:
    1
    Views:
    345
    mark24951
    Oct 13, 2004
  3. Joe Donaldson
    Replies:
    4
    Views:
    443
    Joe Donaldson
    Nov 27, 2003
  4. Peabody
    Replies:
    9
    Views:
    335
    Wolfgang Weisselberg
    Jan 22, 2010
  5. Nikki Bergeron
    Replies:
    0
    Views:
    1,316
    Nikki Bergeron
    Mar 20, 2010
Loading...

Share This Page