Multi GPU Folding Guide with WinAFC

Here you can find out about our Folding Team! Our goal: to understand protein folding, protein aggregation, and related diseases
Post Reply
User avatar
geokilla
Moderator
Moderator
Posts: 1048
Joined: Thu Mar 15, 2007 9:46 am
Location: Toronto, Canada

Multi GPU Folding Guide with WinAFC

Post by geokilla »

This guide is taken from the EVGA forums. The guide can be found here.

Again since there is reference posts available I am reposting this guide.

This guide is for setting up multiple GPU's along with using WinAFC to automatically set the affinity and priority as each new Work Unit is downloaded and started. I use WinAFC and not Lasso because I set the prioriteis and affinity for the VMware with command lines in the .vmx file that precludes the need for Lasso to do that. I am using Windows 7 so the pathways to some of the files may be a little different with XP and Vista.

Step 1:

First you must have your desktop extended to to all the GPU's in Vista and Windows 7. My understanding is that with XP you do not have to do this step. But for XP you do need to enable the multiple display mode in the display settings. Also, if you are using the 191.07 driver and have SLI enabled you do not have to use dummy plugs or extend the desktop for Vista and 7. I still use the bridge so I am not sure if SLI without the bridge will work. I do get more PPD with SLI disabled and use dummy plugs. To extend the desktop have your monitor connected to the primary port on the primary video card. Then install a dummy plug on the primary connector of each subsequent video card. Note: if you have a dual GPU card, ie; a 9800 GX2 or a GTX 295 you must have a dummy plug on all the video connectors on all the cards. One dummy plug for each GPU, except for the connector the monitor is attached to of course. Use this link for the instructions on making a dummy plug. Note: you actually only have to jump pin 1 and 6 with one resistor for it to work. The ones all the way on the right in the bottom picture. http://www.overclock.net/overclock-net- ... -plug.html . Also you can use up to a 100 ohm resistor. Then right click on your desktop and then left click on Personalize(this is what Windows 7 has), then in the bottom left click on display, then on left upper side click on change display settings, then click detect. You should see your primary or real monitor listed and smaller generic monitors listed that are the dummy plugs. Left click on the picture of each monitor and make sure that it says extend desktop to this display for each of the monitors. You will know they are when the picture of the monitor is blue and not grey. If they are not extended, drop that box down, click on extend desktop to this display and then click apply. You have to do this one at a time for each monitor. Make sure you keep the real monitor as the primary monitor. DO NOT check mark the box that says make this my main display for the generic monitors/dummy plugs. You will lose your display image and it will go black.

Step 2:

Create a new folder and name it GPU for now. You can put it on your desktop or your primary or secondary hard drive, if you have one. You want the file path short, ie; C:\GPU or D:\GPU. I put mine on the secondary hard drive. That way if you want to reinstall or install a new OS you do not lose the folding folders. All you have to doe is to create new shortcuts to the [email protected] files, the file with colored bubbles. Note: If you do not have secondary hard drive and are going to reinstall or install a new OS, you can copy your folding folders to a USB storage drive and then copy them back to your system after you install the OS and create the new shortcuts at that time.

Step 3:

Download the NVIDA GPU client for Windows from this link to the EVGA website, http://www.evga.com/folding/download.asp , click on where it says HERE. Go ahead and install it. IMPORTANT: do not start the client after you have installed it and also make sure it did not install a shortcut in the startup folder. To check, click on Start>All Programs>Startup. If it did, delete it by right clicking on it and left clicking delete.

Step 4:

Navigate to the folder where the program was installed, which will be on your C: >Program Files (x86)>Folding@home. There are two files you are going to copy to the folder you made in Step 2. The file with the trademark F@H colored bubbles and one that is named viewer. I do not think you really need the viewer file, it is the application that lets you see the protein folding and trust me you do not want to open it and watch. It's pretty to look at but it will kill your PPD production and could possiblly crash your computer. This feature has been notoriously unstable since day one and even Stanford still recommends not using it. After you have done that you need to enable View Hidden folders. Go to Start>Control Panel>Folder Options. Click on the View tab, seven lines down it says Show hidden files, folders and drives. Click the dot to the left of it and then click Apply. Now, navigate to C:>Users>Main>AppData>Roaming>Folding@home-gpu. For XP it is C:\Documents and settings\Administrator(or whatever the name of your computer is)\Application Data\Folding@home-gpu. There are two files in this folder you want to copy to the folder you created in Step 2, cudart.dll and data_nv. The data_nv file is not necessary but will not hurt by putting in your folder. Once you have those files copied to your folder you can reverse the Folder Option to not show hidden files if you like.

Step 5:

Download WinAFC from this link, http://sourceforge.net/projects/affinitychanger/ and save it to where ever you save files to on your computer. Now, open this folder all the way till it is showing all the files that are in it. Copy all these files and put them in the GPU folder along with the Folding@home files you put in it from Steps 2, 3 and 4.

Step 6:

Now, make a copy of the folder you created so that you have one folder for each GPU you are going to fold on. I named them GPU1, GPU2 and so on if you have more GPU's.

Step 7:

Open each GPU folder one at a time and right click on the [email protected] file(the one with the pretty colored bubbles), click on "Send to" and then "Desktop". This will create a shortcut for each .exe file that you can use to start each client individually. Then rename each shortcut as you create them to corrospond to the GPU folders, ie; folder GPU1 has shortcut named GPU1 and so on. I would reccomend doing this one at a time to avoid mixing them up. I do this, along with rearranging the foling@home icons in the task bar to be in numerical order, so if I have problems with one of the clients while it is running, I know immediately which one it is.

Step 8:

While you are in folder GPU1, create a shortcut for the WinAFC file(the one that is four small colored squares making one larger sqaure) just like you did for the [email protected] files in Step 7. You only need to do this once, ie; only make one shortcut for WinAFC.

Step 9:

Time to startup the programs one by one and configure them. First, double click the WinAFC shortcut to start it and let it run. A window will open up, run and then it will reach a point where it stops and gives a message in yellow. Once it has reached this point, close the window.

Step 10:

Now open the first GPU folder. We will edit the WinAFC file first. Open the file that says: "affinityinput". It should automatically open with Notepad. At the end of the second paragraph it says: TestMode = 1, change the 1 to a 0. Now scroll down to where the line looks like this:

##################################################
## Application Profile lines <(add the command lines here)
##################################################

and paste the appropriate command lines in the above section so it looks like this:

##################################################
## Application Profile lines
*\FahCore_11.exe := PAIR0+PAIR1+PAIR2+PAIR3 [priority=High]
*\FahCore_14.exe := PAIR0+PAIR1+PAIR2+PAIR3 [priority=High]
##################################################

Note: the above setup for an i7. Use the appropriate command lines below for your processor:


For Dual core processors use this command:

*\FahCore_11.exe := PAIR0 [priority=High]
*\FahCore_14.exe := PAIR0 [priority=High]

For Quad core processors use this command:

*\FahCore_11.exe := PAIR0+PAIR1 [priority=High]
*\FahCore_14.exe := PAIR0+PAIR1 [priority=High]

For i7 processors use this command:

*\FahCore_11.exe := PAIR0+PAIR1+PAIR2+PAIR3 [priority=High]
*\FahCore_14.exe := PAIR0+PAIR1+PAIR2+PAIR3 [priority=High]

Note: where it says [prority=HIGH], you can change it so it will automatically set the priority to whatever you want, ie; [prioity=NORMAL] or what ever priority level you want. I leave it at HIGH. Win AFC cannot set the priority to Realtime. The important thing is to have the priority set higher than your VMware which should be set at idle or low. Change the priorities around if you like to find the setting that works best and gives you the most PPD. I believe WinAFC has to be stopped to edit the file.

Save the changes and close the file. Repeat this step for the "affinityinput" file in each GPU folder.

Step 11:

Now we will start up and configure each GPU client one at a time. Double click your shortcut for GPU1, the little bubble icon should appear in the task bar at he bottom right of your screen and a window should open up. In this first tab that is labeled "User", type in your User(folding) name, Team number and Passkey in the appropriate lines. Then click on the "Connection" tab and check mark the box in front of "Allow receipt of work assignments and return of results greater than 10MB in size". Now click on the "Advanced" tab, click the dot next to "Core Priority:" that says "Slightly higher". Check mark the box that says "Do NOT lock cores to specific CPU". In line at the bottom that says "Additional Client Parameters" we will add the GPU flags and in the box below that set the Machine ID. Paste the appropriate line for each GPU client. By adding the flags here you do not have to modify the shortcut properties, ie; the target path line in the shortcut properties window.

For GPU1:

-gpu 0 -forcegpu nvidia_g80 -advmethods

make this Machine ID 1 and click OK.

For GPU2:

-gpu 1 -forcegpu nvidia_g80 -advmethods

make this Machine ID2 and click OK.

and so on for each GPU client with the following flag lines:

-gpu 2 -forcegpu nvidia_g80 -advmethods (make this Machine ID 3)
-gpu 3 -forcegpu nvidia_g80 -advmethods (make this Machine ID 4)
-gpu 4 -forcegpu nvidia_g80 -advmethods (make this Machine ID 5)
-gpu 5 -forcegpu nvidia_g80 -advmethods (make this Machine ID 6)

There is also a flag, -verbosity 9, you can add to each line that creates more detailed fahlogs as the clients run. Example: -gpu 0 -forcegpu nvidia_g80 -advmethods -verbosity 9

You get the idea. If you have more than 6 GPU's, just change the -gpu number to the next consecutive number and the use the next consecutive Machine ID number. You can use any Machine ID number combination you want AS LONG AS none of the GPU clients on the same computer have the same Machine ID number. You do not have to worry about Machine ID number conflicts with VMware since they run as there own separate entities.

NOTE: As you do this, once you have configured the GPU client, you need to stop the client and restart it for the configuration to be accepted. So as you configure each client, put your cursor on the bubble icon in the task bar, right click and then left click on "Quit". Repeat this step for each GPU client one at a time.

You have now setup and configured all your GPU software.

Step 12:

Now start your GPU clients one at a time. As the icons appear in the task bar, right click on them and then left click on "Configure" and open each of the tabs just ot make sure they have configured the way you set them up.

Step 13:

Once you have all the GPU clients running, double click your WinAFC shortcut and start it up. When the window opens and runs you should see two entry lines for each fahcore, one that shows the CPU core setting and one that shows the priority setting. Once that is done running make sure that window is the currently viewed window and press Ctrl and C at the same time and it will minimize to the task bar and be out of the way.

Step 14:

Now to setup Fahmon to see the GPU clients. Open Fahmon, right click in the white area of the window and click on "Add a new client". In the first line type in the name you want for that particular GPU client. In the second line, click on the box with the three dots in it next to line that says "location" and navigate to that particular GPU folder and then click "OK". Repeat this step for each GPU client.

You are done. Hopefully there are no problems and you can sit back and watch your computer produce mass PPD's.

CREDITS:
Although I developed my own method of setting up all the folding clients in my own way, I want to give full credit to _Nite_ on the EVGA folding@home forum for the WinAFC portion of this guide. I would not have been able to obtain the GPU PPD I produce without that part.
Intel Core i5-3570K @ 4.2Ghz @ 1.16V (CPU-Z + LinX)
Gigabyte Z77X-UD5H F14 BIOS
ASUS GTX 460 768MB @ 800/1950
Kingston HyperX DDR3 8GB @ DDR-1333
Corsair AX750
Crucial M4 128GB
Western Digital Black 1TB
Cooler Master Hyper 212+ EVO
BenQ E2420HD
---------------------
I AM CANADIAN!
User avatar
skier
Moderator
Moderator
Posts: 4450
Joined: Mon Mar 26, 2007 3:29 pm
Location: Maine
Contact:

Re: Multi GPU Folding Guide with WinAFC

Post by skier »

wtf is WinAFC?
-Austin
Image
Screamin' BCLK: Image
775 System (Overclocking Platform): Q8400/Q8300/E8400/E7400/E7500 - GA-EP45-UD3R v1.1 - 4GB (2x2) OCZ Reaper HPC DDR2 1066 CL5 2.1v Corsair TX-750w
Gamer: Asrock Z77 Extreme4, i7 3770K @4.6GHz, ThermalTake Armor A90 modded, 2x4GB GSKILL RipjawsX DDR3 2133 CL9, Corsair HX-750w, MSI GTX660 Twin Frozr
Server2012: Q9300 - 8GB DDR2 - Asus P5QL Pro - Corsair CX430 - Mirrored 2TB Seagate's with 2TB WD cav for fileshare backups, 1TB WD for OS backups
User avatar
geokilla
Moderator
Moderator
Posts: 1048
Joined: Thu Mar 15, 2007 9:46 am
Location: Toronto, Canada

Re: Multi GPU Folding Guide with WinAFC

Post by geokilla »

skier wrote:wtf is WinAFC?
Manages the Windows Affinity. Though there's probably another way, I thought this guide would be helpful for those with multi-GPU folding.
Intel Core i5-3570K @ 4.2Ghz @ 1.16V (CPU-Z + LinX)
Gigabyte Z77X-UD5H F14 BIOS
ASUS GTX 460 768MB @ 800/1950
Kingston HyperX DDR3 8GB @ DDR-1333
Corsair AX750
Crucial M4 128GB
Western Digital Black 1TB
Cooler Master Hyper 212+ EVO
BenQ E2420HD
---------------------
I AM CANADIAN!
User avatar
skier
Moderator
Moderator
Posts: 4450
Joined: Mon Mar 26, 2007 3:29 pm
Location: Maine
Contact:

Re: Multi GPU Folding Guide with WinAFC

Post by skier »

geokilla wrote:
skier wrote:wtf is WinAFC?
Manages the Windows Affinity. Though there's probably another way, I thought this guide would be helpful for those with multi-GPU folding.
for multi GPU i just use My Guide :?
-Austin
Image
Screamin' BCLK: Image
775 System (Overclocking Platform): Q8400/Q8300/E8400/E7400/E7500 - GA-EP45-UD3R v1.1 - 4GB (2x2) OCZ Reaper HPC DDR2 1066 CL5 2.1v Corsair TX-750w
Gamer: Asrock Z77 Extreme4, i7 3770K @4.6GHz, ThermalTake Armor A90 modded, 2x4GB GSKILL RipjawsX DDR3 2133 CL9, Corsair HX-750w, MSI GTX660 Twin Frozr
Server2012: Q9300 - 8GB DDR2 - Asus P5QL Pro - Corsair CX430 - Mirrored 2TB Seagate's with 2TB WD cav for fileshare backups, 1TB WD for OS backups
User avatar
geokilla
Moderator
Moderator
Posts: 1048
Joined: Thu Mar 15, 2007 9:46 am
Location: Toronto, Canada

Re: Multi GPU Folding Guide with WinAFC

Post by geokilla »

I didn't see that thread ](*,)

Should I delete this thread from EVGA?
Intel Core i5-3570K @ 4.2Ghz @ 1.16V (CPU-Z + LinX)
Gigabyte Z77X-UD5H F14 BIOS
ASUS GTX 460 768MB @ 800/1950
Kingston HyperX DDR3 8GB @ DDR-1333
Corsair AX750
Crucial M4 128GB
Western Digital Black 1TB
Cooler Master Hyper 212+ EVO
BenQ E2420HD
---------------------
I AM CANADIAN!
Post Reply