Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

stromie952

macrumors regular
Original poster
Apr 22, 2002
201
0
Rochester, NY
I want to run the folding command line client, but I do not want to have a console window up while it is running, nor do I want to have the Terminal loaded at all.

I want to have the folding client run as a background process instead of in an active terminal window.

I want to help out (with my new 1Ghz iMac and a couple other computers I have access to at my university), but I can't seem to be able to figure this out. This would make it much easier to run it on the other machines and also I would definitely like it on my machine.

Any help would be appreciated.

Thanx
 

howard

macrumors 68020
Nov 18, 2002
2,017
4
talk to mc68k, pm him or something, he knows how to do that..i don't unfortunatly...are you new to the folding team? if so welcome! by the way i like your sig, homestarrunner is hilarious
 

stromie952

macrumors regular
Original poster
Apr 22, 2002
201
0
Rochester, NY
I am fairly confident in the Terminal and would be glad to give it a shot if you would be so kind as to help me out with the details.

:)
 

Falleron

macrumors 68000
Nov 22, 2001
1,609
0
UK
I would quite like to know as well. Currently, I have a terminal window minimised into my dock.
 

Rower_CPU

Moderator emeritus
Oct 5, 2001
11,219
2
San Diego, CA
OK, here goes (mc68k can correct me if I'm wrong ;) ):

Open the Terminal and type "crontab -e". This will install a new crontab. Here's a little page that describes what crontabs do : http://kb.indiana.edu/data/afiz.html

You will now be in the vi editor. This sucker is much trickier than pico, so you have to watch your step. Hit "i" to make sure you're in "insert mode", then type the following.
@reboot cd /Your/Path/To/F@H/; ./OSX-3.24 (-local)

All of that should be on one line. Let me explain what it does. It issues the command that whenever your machine reboots it should cd into your F@H directory, then run it. I put the -local switch in paranthesis, because you may or may not be using it. If you are, use it here, otherwise leave it off.

If you make a mistake in typing you won't be able to use the delete key to take out the mistake. You'll have to hit escape, position the cursor, then hit "x" to remove the letter(s). Then hit "i" to return to insert mode. Once you're done and it's correct, hit escape and type ":wq" to save out the crontab. You should get an affirmation that it was installed. Restart your machine to test it out.

Hope this was straightforward enough...
 

stromie952

macrumors regular
Original poster
Apr 22, 2002
201
0
Rochester, NY
I get everything except the -local switch.

What does that do?

I looked in the help for the Folding Command Line client and didn't see it listed among the options it has.
 

crazzyeddie

macrumors 68030
Dec 7, 2002
2,792
1
Florida, USA
I found another way to do this, but it isnt automatic, its nice for on-the-fly if youre going to leave your computer, or want to start/stop F@H.

Open F@H however you usually do.
Type ctrl-z
(It should say process suspended, and you should have a promt.)
Type bg

Now you have a promt again, type top to show your processes. You should see FahCore using processor time, as a percent (usually more than 50% if youre just reading this).

Also, if you want to bring it back to the front, just type fg . This works for all Unix apps, have fun.
 

mc68k

macrumors 68000
Apr 16, 2002
1,996
0
heres what i would do:

the character & at the end of any expression signals the OS to send that process to the background. Any backgrounded process will still run after the Terminal window is closed.

so for example, if you wanted to run F@H in the background:

./OSX-3.24 &

all the info associated with F@H will be stored in:
/Users/[username]/Library/Folding@home

The switch -local is to make the current directory the target directory for the information instead of the default location listed above.

./OSX-3.24 -local &
 

mc68k

macrumors 68000
Apr 16, 2002
1,996
0
Originally posted by stromie952
One more question.

Is it possible to have the graphical client look elsewhere than the users folder so I can check progress?
no it's only default.

what do you mean by check progress? can't you already do that?
 

G4scott

macrumors 68020
Jan 9, 2002
2,225
5
USA_WA
Do all or any of these techniques get F@H running behind the login screen?

Also, is it possible to fold while other users are logged on?

And how do I find out the progress of my folding with the console?
 

G4scott

macrumors 68020
Jan 9, 2002
2,225
5
USA_WA
Originally posted by Rower_CPU
Mine does. :) (behind login and with other users)

OK, I did the ctrl-Z and BG thing, and it runs in the background without the terminal being open. It's running under my user name. When I log out, does it keep on running, or do I have to install it as the root user or something to get it to do this?
 

mc68k

macrumors 68000
Apr 16, 2002
1,996
0
Originally posted by G4scott
Do all or any of these techniques get F@H running behind the login screen?
as long as the task is backgorunded, it doesn't matter how it was done— so yes.
Also, is it possible to fold while other users are logged on?
yes it is.
And how do I find out the progress of my folding with the console?
if you left everything default, go to:

/Users/[username]/Library/Folding@home/work

you will find a file called logfile_0#.txt

this will have all the information you need.
 

mc68k

macrumors 68000
Apr 16, 2002
1,996
0
Originally posted by G4scott
OK, I did the ctrl-Z and BG thing, and it runs in the background without the terminal being open. It's running under my user name. When I log out, does it keep on running, or do I have to install it as the root user or something to get it to do this?
with non-root admin accounts ive been able to get it to run at the login window.

the best way to find out is to run it, bg it, log in as another user, and use top in the terminal to find out if it's still running.
 

G4scott

macrumors 68020
Jan 9, 2002
2,225
5
USA_WA
thanks mc68k... I'm quite new to the terminal, but I've gotten it up and running on my iBook. I'm going to get it going on my 1ghz DP G4. I need to set it up to start every time the computer is booted. Does the method described at the beginnign of this thread do this?

Also, what's that Quartz Extreme thing in your download folder?
 

mc68k

macrumors 68000
Apr 16, 2002
1,996
0
Originally posted by G4scott
thanks mc68k... I'm quite new to the terminal, but I've gotten it up and running on my iBook. I'm going to get it going on my 1ghz DP G4. I need to set it up to start every time the computer is booted.
my DP script does the reboot stuff for you.

Does the method described at the beginnign of this thread do this?
yes it does. vi is a bitch if you don't know how to use it, so you can make a plain text file with one line (using some editor like pico).

@reboot pathname to client (OSX-3.24) &

then type in:

sudo crontab -u username pathname to file

type in your password. this file is now your crontab for that user.

check to see if it runs by rebooting. then first thing open terminal and type in top

Also, what's that Quartz Extreme thing in your download folder?
that's the program used in the power of x videos at macworld. it's for benchmarking QE.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.