Overclock.net › Member Blogs › Bloxcache Boinc Caching Batch File Initialisation Full Instructions

Bloxcache Boinc Caching Batch File Initialisation Full Instructions



Intro

We're going to setup multiple Boinc Data Dirs and run each for an hour.
Also we're going to keep our Main Boinc running, but only on CPU tasks.

Please note I am currently using Boinc 6.12 on Win7_64, so my exe path is c:\program files\boinc\boinc.exe. If you are using 6.10 you will need to change the path in the batch files to c:\program files (x86)\boinc\boinc.exe

http://boinc.berkeley.edu/download_all.php

You can work out how many caches you need by working out how long your GPUs will take to do 1 full cache. You get 6 tasks max per allowed CPU. Let's say you have 4 CPUs, 2 GPUs and each WU takes 2 minutes.

Maximum cache is 6x4 = 24 tasks
24 WU takes 2x24 minutes = 48 min, but 2 GPUs so halve that = 24 min. In hours that is 24/60 = 0.4 hours per cache.

So to have 48 hours of work cached, you would need 48/0.4 = 120 caches.

Also we have to work out how long we want each to run for as the deadline is 8 days. If we switch 120 caches at 1 per hour it takes 120 hours.. 8 days is 192 hours.

It might be better to cycle them per 15 min as ideally we don't want to completely exhaust a cache if poss.

By default, your main Boinc runs in c:\programdata\BOINC , which is a hidden dir, so you will have to change folder options so you can view it(also make sure show file extensions is on or your whatever.bat file could really be whatever.bat.txt but with the .txt hidden, and remember when saving from notepad to change "save as type" to all files)

http://boinc.berkeley.edu/wiki/Client_configuration

Config Files

There are 4 config files, 3 for standard boinc and an extra one.
CC_config.xml is a config file read by boinc.exe on startup.
Gui_rpc_auth.cfg holds the password to use when connecting using the GUI.
Remote_hosts.cfg specifies which hosts can connect remotely to your boinc.
CC_config_gpu.xml is the config file used for the new boincs.

Firstly create cc_config.xml in c:\programdata\BOINC using notepad or a text editor.

Mine is
Code:
<cc_config>
  <options>
    <ignore_ati_dev>0</ignore_ati_dev>
    <ignore_ati_dev>1</ignore_ati_dev>
    <ignore_ati_dev>2</ignore_ati_dev>
    <ignore_ati_dev>3</ignore_ati_dev>
  </options>
</cc_config>
This tells the main boinc to ignore GPU 0 - 3
You will have to quit and restart your main boinc then check the messages to be sure it is ignoring the GPUs.


Now create cc_config_gpu.xml in the same dir.

Mine is
Code:
<cc_config>
  <options>
    <exit_when_idle>1</exit_when_idle>
    <report_results_immediately>0</report_results_immediately>
    <suppress_net_info>1</suppress_net_info>
  </options>
</cc_config>
This cc_config_gpu.xml will get copied by one of the batch files to each individual new dir as cc_config.xml

gui_rpc_auth.cfg - we need to set the password for later.. e.g.
Code:
123
remote_hosts.cfg - create this file and tell it which hosts are allowed to view your boinc. No need for this if you only want to view on the local PC

Creating the New Boinc Dirs
The first batch file to run is bloxcache-init-dirs.bat edit the line set x=32
Code:
set x=32

if not exist bloxcache%x% (
for /l %%i IN (1,1,%x%) do (
mkdir bloxcache%%i
if not exist gui_rpc_auth.cfg (copy c:\programdata\boinc\gui_rpc_auth.cfg bloxcache%%i\gui_rpc_auth.cfg)
if not exist global_prefs.xml (copy c:\programdata\boinc\global_prefs.xml bloxcache%%i\global_prefs.xml)
if not exist global_prefs_override.xml (copy c:\programdata\boinc\global_prefs_override.xml bloxcache%%i\global_prefs_override.xml)
if not exist remote_hosts.cfg (copy c:\programdata\boinc
emote_hosts.cfg bloxcache%%i
emote_hosts.cfg)
if not exist cc_config.xml (copy c:\programdata\boinc\cc_config_gpu.xml bloxcache%%i\cc_config.xml)
))
This creates a new directory for each new boinc cache and copies the config files to each.

Attaching each New Boinc to Milkyway

The next batch file tells each new boinc to attach to Milkyway. You need to get your authenticator from c:\programdata\BOINC\account_milkyway.cs.rpi.edu_m ilkyway

It's on the 2nd line.

bloxcache-init-attach.bat
Code:
set x=32
for /l %%i in (1,1,%x%) do (
"c:\Program Files\BOINC"\boinc --dir bloxcache%%i --attach_project http://milkyway.cs.rpi.edu/milkyway/ YOUR_KEY --

exit_after_app_start 90 --allow_multiple_clients --gui_rpc_port 5000 --master_fetch_interval 60)
This batch starts the first boinc and tells it to attach, then(hopefully) quits after 90 sec. If it doesn't quit then do ctrl + c in the command prompt that it is running in and choose 'no' when asked if you want to exit(this is the batch script handler asking if you want to exit or run the next). I think it also does a cpu benchmark on each.. which is a bit annoying, anyone know which file it stores this in?

Initialization is finished

So at this point we should have a new dir for each cache and be attached to milkyway on each.

Comments

There are no comments yet
Overclock.net › Member Blogs › Bloxcache Boinc Caching Batch File Initialisation Full Instructions