How do I shut down the terminal version of F@H?

Discussion in 'Distributed Computing' started by kilpajr, Nov 30, 2004.

  1. kilpajr macrumors regular

    Joined:
    Aug 24, 2004
    Location:
    Auburn, AL
    #1
    The only way I know to quit the terminal version of F@H is to quit the terminal window. But, when I restart F@H, I notice that it says the core was incorrectly terminated. What is the correct way to shut it down?
     
  2. Dreadnought macrumors 68020

    Dreadnought

    Joined:
    Jul 22, 2002
    Location:
    Almere, The Netherlands
    #2
    Yes, I have the same with the new version V5 in windows. It's very annoying, because it suddenly start automatically another program called folding, which you can't stop or get rid of, and it's folding.... nothing.

    Under your terminal on your mac, you just type stop, and folding stops. Type work and starts working again.
     
  3. daveL macrumors 68020

    daveL

    Joined:
    Jun 18, 2003
    Location:
    Montana
    #3
    If you running the stuff the way mc68k set it up, it should start up in the background when your system boots up. Once the system is up, you should have the following aliases available in your shell (Terminal window):

    alias pause='killall -STOP -m "FahCore*"'
    alias resume='killall -CONT -m "FahCore*"'
    alias start1='cd ~/F@H1; ./fah4 -local -advmethods > /dev/null &'
    alias start2='cd ~/F@H2; ./fah4 -local -advmethods > /dev/null &'
    alias stop='killall fah4'
    alias work='~/.work'

    Note I'm running the DP version, thus the 'start1' and 'start2'. On a SP machine, I believe there's just 'start'. So, you can pause, resume, start, stop and get status (work).

    HTH
     
  4. mc68k macrumors 68000

    mc68k

    Joined:
    Apr 16, 2002
    #4
    find the process number using either ps or top

    send it a kill signal with the kill command

    %kill PID

    there doesnt seem to be a flag that the executable uses to terminate itself, so u have to kill it in this manner. also, if ur closing the window to terminate the process, the process is prob still in the foreground.
     
  5. Apple Hobo macrumors 6502a

    Apple Hobo

    Joined:
    Mar 19, 2004
    Location:
    A series of tubes
    #5
    I use control-c

    [15:56:09] Completed 200000 out of 2500000 steps (8)
    ^C
    Folding@Home Client Shutdown.
     
  6. Nermal Moderator

    Nermal

    Staff Member

    Joined:
    Dec 7, 2002
    Location:
    New Zealand
    #6
    Yeah, Control-C seems to be the 'proper' way to shut it down, because it reports that it's shutting down when you press it.
     
  7. daveL macrumors 68020

    daveL

    Joined:
    Jun 18, 2003
    Location:
    Montana
    #7
    I guess I just don't understand why you're doing so much work. Let cron start it up at boot time; usually you won't touch it again. If you want to run a benchmark or dedicate every single cycle to a large rendering job, you can pause and resume (with mc68k's aliases and scripts, permanently posted in this forum). There's no need to open a terminal window and manually start and stop the process(es). Maybe I'm missing something?
     
  8. kylos macrumors 6502a

    kylos

    Joined:
    Nov 8, 2002
    Location:
    MI
    #8
    m68k, what are the -local and -advmethods flags for?
     
  9. kilpajr thread starter macrumors regular

    Joined:
    Aug 24, 2004
    Location:
    Auburn, AL
  10. bousozoku Moderator emeritus

    Joined:
    Jun 25, 2002
    Location:
    Gone but not forgotten.
    #10
    I'm not mc68k, but I can provide the same answers. The -local flag tells folding@home to use the work directory within the directory where the fah client resides. If folding@home is in ~/F@H1/ then the data exists in ~/F@H1/work. The -advmethods flag is to signal that testing work units and cores should be downloaded and used, as available. While the Gromacs WUs were in beta, this flag would allow them to be used.

    There is also a -forceasm flag which tells the client to use whatever optimisations the core has available, even if there was a crash.
     
  11. kylos macrumors 6502a

    kylos

    Joined:
    Nov 8, 2002
    Location:
    MI
    #11
    Thanks, so the -local flag is really only necessary for dual processors? And where are the flags specified, at the stanford site or is there some documentation i missed.

    I tried folding on my 500mhz ibook a while ago, but I was running too many other processes for it to finish wu's in a timely fashion. Now that I have a 1.33 ghz pbook, folding is able to get a lot more clock cycles. Just submitted a wu recently.

    Also, anybody know if entering
    bg %foldingjobid > /dev/null
    will redirect output so folding won't suspend when outputting progress data. I like to have output from folding visible at times as well, so if the previous command would work as I expect, would the proper command to foreground the app be
    fg %foldingjobid > 1
     
  12. daveL macrumors 68020

    daveL

    Joined:
    Jun 18, 2003
    Location:
    Montana
    #12
    Why not just put this in your 'crontab' ?

    # Start dual Folding@Home engines
    @reboot cd ~/F@H1; ./fah4 -local -advmethods &
    @reboot cd ~/F@H2; ./fah4 -local -advmethods &
    # END

    I have a DP, thus the 2 entries. These assume the directory (F@H) is in you home directory. If you have your F@H directory somewhere else, modify the above accordingly.
     
  13. kylos macrumors 6502a

    kylos

    Joined:
    Nov 8, 2002
    Location:
    MI
    #13
    I'm interested in backgrounding and foregrounding the app at will. After running it in the background for a while without redirecting the output, I've found that it will come to the foreground when it has something to output. I read somewhere that a background app will be suspended if it tries to output to stdout. Neither situation is desirable. I'd like to fg and bg at will and change the output file at the same time.
     

Share This Page