commands to start and stop programs
Results 1 to 7 of 7

Thread: commands to start and stop programs

  1. #1
    Senior Member
    Join Date
    Jul 2003
    Posts
    634

    commands to start and stop programs

    Hey,

    sorry about the lame arse title, my heads defitiate of any meaningful words due to previously writing 8,000 words in the space of 12hrs (must check of them, there probably utter bullshit)

    anyway!

    Yea I've got a processor intensive program that I want to run and get some data from, however I want to be able to run it a couple of times with different variables, but I want to be able to with a command or a script automatically detect when the last program exits and then kick off the new one.

    so wanna do something like this -->

    program1 runs ---takes time to compute--->exits ---->shell starts up program2


    Can you think of a way to do this in both MS-DOS and also Linux, im planning on knocking together a cluster (clusterknoppix) in the next couple of days to compute something that normally takes 7hrs, but im going away so its a good oppurtunity to leave the computers running and getting me the data I want them to!

    Cheers in advance, its more the linux way of doing things im interested in

    thanks!

    i2c

  2. #2
    Senior Member
    Join Date
    Dec 2004
    Posts
    107
    In dos, you just create a batch file with two commands you want to run (i.e. two executable programs) and they will run consecutively (not concurrently), and of course, name it with a .bat extension.

    So if you want to run two programs, hello.exe and bye.exe, your batch file should look like this:

    Code:
    hello.exe
    bye.exe
    And that's it. From the command line, just run your file with the .bat extension and voila.

    In linux, I it's the same thing using scripts

    [edit] Make sure that you set executable permissions on the script you created: chmod +x File [/edit]

    -ik

    p.s. here's a link to bash scripting for reference:

    http://www.tldp.org/LDP/abs/html/
    Alright Brain, you don\'t like me, and I don\'t like you. But let\'s just do this, and I can get back to killing you with beer.
    -- Homer S.

  3. #3
    Senior Member
    Join Date
    Jul 2003
    Posts
    634
    Oh dear what a pleb I am! of course.....

    Iron-Kurton thanks for you help

    i2c

  4. #4
    THE Bastard Sys***** dinowuff's Avatar
    Join Date
    Jun 2003
    Location
    Third planet from the Sun
    Posts
    1,252

    Re: commands to start and stop programs

    Originally posted here by i2c

    Can you think of a way to do this in both MS-DOS and also Linux, im planning on knocking together a cluster (clusterknoppix)
    Are you going to cluster Linux and Windows/DOS together? If so Can you tell me what you are using. I'm thinking cross platform clustering. Perhaps I'm missing something?

    /edit: I didnt think knoppix works on windows

  5. #5
    Senior Member
    Join Date
    Jul 2003
    Posts
    634
    Nope im not cross clustering, I didnt beleive that was possible with the windows operating system? I didnt even think clustering was possible with windows? Maybe in the server edition, but im not sure I dont tend to use windows for much other than surfing and word processing these days.

    knoppix is a bootable CD distribution, you put it in boot it up and volia you have a linux operating system without installing anything, its a very cool toy, check it out

    i2c

  6. #6
    THE Bastard Sys***** dinowuff's Avatar
    Join Date
    Jun 2003
    Location
    Third planet from the Sun
    Posts
    1,252
    i2c:

    Somewhere in the back of my head I remember reading about clustering processors

    Did a search and found this thread

    http://www.antionline.com/showthread...ster+processor

    Just wondering if you were doing cross clustering. I learned about knoppix here at AO and have found it a most useful tool... (Sweet Dude)

    Anyway, just thought you found something that clustered workstations. I don't think it's possible either.

    edit: yes you can cluster windows servers. I have four servers two each in a cluster.

  7. #7
    Just Another Geek
    Join Date
    Jul 2002
    Location
    Rotterdam, Netherlands
    Posts
    3,401
    Originally posted here by i2c
    Nope im not cross clustering, I didnt beleive that was possible with the windows operating system? I didnt even think clustering was possible with windows? Maybe in the server edition, but im not sure I dont tend to use windows for much other than surfing and word processing these days.
    http://www.microsoft.com/windows2000...ng/default.asp

    We use it for a couple of things... We used to have a couple of NT4 clusters but these all got migrated to win2k.
    Oliver's Law:
    Experience is something you don't get until just after you need it.

Posting Permissions

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