Building and installing BOINC on CentOS 6.5

Even with fun tools like yum, sometimes you have no choice but to build an executable from source on Linux. I found that I had to do this when installing BOINC on CentOS 6.5 due to the fact that the precompiled version of the most recent stable version of BOINC, 7.2.42, was compiled against several libraries that Cent)S 6.5 does not have. So here’s how I got everything up and running…

First, I grabbed the source from Git using the following command:

[codesyntax lang=”bash” container=”div” blockstate=”expanded”]

git clone git://boinc.berkeley.edu/boinc-v2.git boinc

[/codesyntax]

Then, I got the suggested stable version of the client, 7.2.42, by running this command:

[codesyntax lang=”bash” container=”div” blockstate=”expanded”]

git checkout client_release/7.2/7.2.42; git status

[/codesyntax]

 

I followed the steps here, but with a couple caveats. First, since I don’t need the GUI manager (I’m managing BOINC from another computer, I ran these commands:

[codesyntax lang=”bash” container=”div” blockstate=”expanded”]

./_autosetup
./configure --disable-server –-disable-manager --enable-client CXXFLAGS="-O3 "
make

[/codesyntax]

 

The instructions then say to go into the packages/generic/sea/ directory, but you don’t need to do this (and it apparently isn’t supported). When I tried, I kept on getting these errors:

 

[codesyntax lang=”bash” container=”div” blockstate=”expanded”]

cp ../../../stage//usr/local/bin/boinc BOINC/boinc

cp ../../../stage//usr/local/bin/boincmgr BOINC/boincmgr

cp: cannot stat `../../../stage//usr/local/bin/boincmgr': No such file or directory
make: *** [BOINC/boincmgr] Error 1

[/codesyntax]

 

Instead, just go into the client directory after that first make and the boinc, boinc_client, and boinccmd executables are all in there ready for use. What now? Well, you can run from there, but instead I installed it elsewhere. I copied the executables files to /var/lib/boinc/ and used that as my permanent run directory. I also created a boinc user and group and chown-ed that directory and all the files in it. Then, I grabbed a shell script from somewhere (this one is close) and tossed it in the /etc/init.d directory, configuring the variables as necessary. Finally, I went to the appropriate rcX.d directories and manually created the symlinks to that file, which is the hard way of just using chkconfig.

Next time, I’ll write about how I configured rsyslog to send BOINC messages to Splunk.