= Setting up a BOINC server = You can potentially use any Unix system as a BOINC server. Our recommendations are: * '''Hardware''': use a host with good CPU capacity (dual Xeon or Opteron), at least 2 GB of RAM, and at least 40 GB of free disk space. Do whatever you can to make it highly reliable (UPS power supply, RAID disk configuration, hot-swappable spares, tempurature-controlled machine room, etc.). If you anticipate a high-traffic project, use a machine whose RAM capacity is 8 GB or more and that uses 64-bit processors. If your server capacity is exceeded, you can increase capacity using [MultiHost multiple server hosts]. However, we recommend that you not do this initially. In most cases one host is enough. * '''Software''': use a recent Linux release. == Groups and permissions == We recommend that you create a separate user and group for the BOINC server, and add the web-server user to this group. Details are [GroupPermissions here]. == Installing BOINC software == * Download and install whatever [SoftwarePrereqsUnix software prerequisites] are needed on your system. * [SourceCode Download the BOINC software]. * [BuildSystem Configure and build] the BOINC software. == Operating system configuration == Some parts of the BOINC server (the feeder and scheduling server) use shared memory. Hosts where these run must have shared memory enabled, with a maximum segment size of at least 32 MB. How to do this depends on the operating system; some information is [http://developer.postgresql.org/docs/postgres/kernel-resources.html here]. == MySQL notes == * After installing and running the server, grant permissions for your own account and for the account under which Apache runs ('nobody' in the following; may be different on your machine). All mysql accounts should be password protected including root. {{{ mysql -u root grant all on *.* to yourname@localhost identified by 'password'; grant all on *.* to yourname identified by 'password'; grant all on *.* to nobody@localhost identified by 'password'; grant all on *.* to nobody identified by 'password'; }}} * Set your PATH variable to include MySQL programs (typically /usr/local/mysql and /usr/local/mysql/bin). * You'll need to back up your database. Generally this requires stopping the project, making a copy or snapshot, and restarting. An example is [http://boinc.berkeley.edu/mysql_backup.txt here]. * BOINC gets MySQL compiler and linker flags from a program called mysql_config which comes with your MySQL distribution. This sometimes references libraries that are not part of your base system installation, such as -lnsl or -lnss_files. You may need to install additional packages (often you can use something called 'mysql-dev' or 'mysql-devel') or fiddle with Makefiles. * MySQL can be the bottleneck in a BOINC server. To optimize its performance, read about [MysqlConfig configuring MySQL for BOINC]. * [http://boinc.berkeley.edu/mysql_cluster.txt Notes on running MySQL on a cluster]. == MySQLclient notes == * Configure mysql with the --enable-thread-safe-client switch. * Set your LD_LIBRARY_PATH to refer to the correct library. == Apache notes == In httpd.conf, set the default MIME type as follows (otherwise you'll get file upload signature verification errors): {{{ DefaultType application/octet-stream }}} To limit denial-of-service attacks, we recommend turning off directory indexing by adding -Indexes to the Options directive. == PHP notes == * Make sure 'magic quotes' are enabled (this is the default). The file /etc/php.ini should contain {{{ magic_quotes_gpc = On }}} * By default, BOINC uses PHP's mail function to send email to participants. This uses sendmail. If this doesn't work, you can use [http://phpmailer.sourceforge.net/ PHPMailer] instead, which is a very flexible mail-sending mechanism. To do this: * Download PHPMailer and put it under PROJECT/html/inc/phpmailer. * Set the following variables in your PROJECT/html/project/project.inc file (substitute your own values): {{{ = true; = "xxx.xxx.xxx"; = "smtp"; }}}