Building sources with BuildBot

Unless your in the desert under a rock (where rain is clearly needed), you will have heard of Drizzle – A Lightweight SQL Database for Cloud and Web. My company 42SQL is sponsoring the BuildBot for the Drizzle project. BuildBot is a system to automate the compile/test cycle required by most software projects to validate code changes.

Check out Installing Buildbot for what’s necessary to get a working installation. This is necessary for the Master and Slaves.

Configuration was a little more complicated then expected, due to lack of accurate documentation, and reading old docs at sourceforge. Be sure now to read here .

This is a step by step approach I used to successfully configure Drizzle Build Bot (Master and Slave).

  1. Create OS User.
su -
useradd buildbot
su - buildbot
  1. Create Master Installation
buildbot create-master /home/buildbot/master
cd /home/buildbot/master
cp master.cfg.sample master.cfg
vi master.cfg

Here is a diff of what simple changes I made to the master.cfg.sample work in my environment.

$ diff master.cfg.sample master.cfg
23c23
< c['slaves'] = [BuildSlave("bot1name", "bot1passwd")]
---
> c['slaves'] = [BuildSlave("centos5_64", "paSSw0rd")]
95c95
< cvsroot = ":pserver:anonymous@cvs.sourceforge.net:/cvsroot/buildbot"
---
> cvsroot = ":pserver:anonymous@buildbot.cvs.sourceforge.net:/cvsroot/buildbot"
105c105
< f1.addStep(Trial(testpath="."))
---
> #f1.addStep(Trial(testpath="."))
108c108
< 'slavename': "bot1name",
---
>       'slavename': "centos5_64",
148c148
< #c['debugPassword'] = "debugpassword"
---
> c['debugPassword'] = "paSSw0rd"
156c156
< #                                       "admin", "password")
---
> #                                       "admin", "paSSw0rd")
166,167c166,167
< c['projectName'] = "Buildbot"
< c['projectURL'] = "http://buildbot.sourceforge.net/"
---
> c['projectName'] = "Drizzle Buildbot"
> c['projectURL'] = "https://launchpad.net/drizzle/"

Initially I’m just going to test with a CVS checkout of buildbot to confirm operations.
NOTE: The example provided pserver URL in master.cfg.sample is invalid.

  1. Start Master
buildbot start /home/buildbot/master > start.log
tail -f /home/buildbot/master/twistd.log
  1. Confirm Master
lynx http://drizzlebuild.42sql.com:8010
  1. Create Slave
buildbot create-slave /home/buildbot/slave drizzlebuild.42sql.com:9989 centos5_64 PaSSw0rd

I got stuck here based on docs, be sure the port number is the client port.

  1. Configure Slave
cd /home/buildbot/slave/info
echo "Ronald Bradford < ronald .bradford @ google mail >" > admin
echo "Drizzle CentOS 5 64bit "`uname -a` > host
cat admin host
  1. Start Slave
cd /home/buildbot/slave
buildbot start /home/buildbot/slave > start.log
tail -f /home/buildbot/slave/twistd.log
  1. Confirm Slave

If everything is working by the time you look at the twistd.log you will see work happening.
You can also via the web interface and see in Lasted Builds the first build is working.

  1. Stop Services

To stop the BuildBot master and slave.

buildbot stop /home/buildbot/master
buildbot stop /home/buildbot/slave
  1. Change Master Configuration

Should you make any changes to master.cfg the following command will re-read the configuration file.

buildbot sighup /home/buildbot/master
  1. Startup
    The following was added to cron
@reboot buildbot start /home/buildbot/master
@reboot buildbot start /home/buildbot/slave

The @reboot is new sytax for me, so I can’t yet confirm it’s operation.

If you want to be a build slave for Drizzle, check out Instructions here

Tagged with: 42SQL Databases Drizzle MySQL

Related Posts

Tracking new AWS Database Infrastructure Availability

AWS can drop 10+ articles a day just in the What’s New feed. You either need an eagle eye, or luck to keep up if you run multiple AWS database products across multiple regions and managing infrastructure.

Read more

Evaluating Readyset Caching for MySQL

Readyset is a database caching solution for MySQL and PostgreSQL . For applications that have increased load on your primary database, or use scale-out infrastructure to support a high-read workload, ReadySet can be a drop-in solution to address current performance issues.

Read more

Creating a More Realistic Benchmark

Common benchmark approaches fall into two general categories, synthetic testing and realistic testing. You have the most generic operations from a synthetic test, starting with the most simple example using a single table, a single column, and for a single DML operation.

Read more