ReferencePlatforms/Test/Mac: Difference between revisions
Line 96: | Line 96: | ||
=== Setting up a Talos Buildbot slave === | === Setting up a Talos Buildbot slave === | ||
How to setup a Buildbot Talos slave (replace the master.host, username, and password with the correct values) | How to setup a Buildbot Talos slave (replace the master.host, username, and password with the correct values) | ||
cd ~ | cd ~ | ||
mkdir talos-slave | mkdir talos-slave | ||
buildbot create-slave talos-slave master.host:9989 username password | buildbot create-slave --umask=022 talos-slave master.host:9989 username password | ||
You should then start the slave once to create the proper directory structure. | You should then start the slave once to create the proper directory structure. | ||
buildbot start talos-slave | buildbot start talos-slave |
Revision as of 00:50, 19 January 2008
Talos on Mac
Important: Do _NOT_ upgrade past 10.4.8. hdiutil has a bug/feature in 10.4.9 and above that prevents Talos Buildbot's from working properly.
OS Setup
- Change the resolution
- System Preferences -> Displays
- Select 1024x768
- Turn off the screen saver
- System Preferences -> Desktop & Screen Saver
- Move 'Start screen saver' to 'Never'
- Autohide the dock
- Turn off sleep
- System Preferences -> Energy Saver
- "Put the computer to sleep when it is inactive for..." Never
- In options set dock to autohide
- Create a 'mozqa' account
niutil -create / /Users/mozqa niutil -createprop / /Users/mozqa uid 503 niutil -createprop / /Users/mozqa gid 503 niutil -createprop / /Users/mozqa realname "Mozilla QA" niutil -createprop / /Users/mozqa home "/Users/mozqa" niutil -createprop / /Users/mozqa shell "/bin/bash" niutil -createprop / /Users/mozqa passwd "*" niutil -create / /Groups/mozqa niutil -createprop / /Groups/mozqa gid 503 passwd mozqa
- Enable VNC
- System Preferences -> Sharing
- Make sure 'Apple Remote Desktop' is checked.
- Click 'Access Privileges'
- Change the VNC password
- Install the mozqa ssh key in ~/.ssh
XCode Installation
- The next step is to retrieve the Mac reference platform packages from CVS:
export CVS_RSH=ssh ocvs -d :ext:unittest@cvs.mozilla.org:/mofo co ref-platforms/mac
- Install Xcode
- Mount the Xcode dmg
- Double click on XcodeTools.mpkg
- In the 'Installation Type' section choose 'Customize' and enable everything under 'Cross-Development'
Wget
curl ftp://ftp.gnu.org/pub/gnu/wget/wget-1.10.2.tar.gz > wget-1.10.2.tar.gz tar -zvxf wget-1.10.2.tar.gz cd wget-1.10.2 ./configure --prefix=/usr make sudo make install
Throttling
Install Mac CHUD tools http://developer.apple.com/tools/download/, then run
reggie_se -S 0b1100 -b 4:1 -i a -n IA32_CLOCK_MODULATION
BuildBot Setup
Install Python 2.4.4
- Download and install MacPython
wget http://www.pythonmac.org/packages/py24-fat/dmg/python-2.4.4-macosx2006-10-18.dmg hdiutil attach python-2.4.4-macosx2006-10-18.dmg cd /Volumes/Univeral\ MacPython\ 2.4.4 sudo installer -pkg MacPython.mpkg -target / cd .. hdiutil detach /Volumes/Univeral\ MacPython\ 2.4.4
- You must logout and log back in to make sure you are using the new version of Python.
Install Twisted and Zope-Interface
wget http://tmrc.mit.edu/mirror/twisted/Twisted/2.4/Twisted-2.4.0.tar.bz2 tar -jvxf Twisted-2.4.0.tar.bz2 cd Twisted-2.4.0 cd ZopeInterface-3.1.0c1 python setup.py build sudo python setup.py install cd ../TwistedCore-2.4.0/ python setup.py build sudo python setup.py install cd .. python setup.py build sudo python setup.py install cd ..
Install BuildBot
ocvs -d:pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot co -d buildbot mozilla/tools/buildbot cd buildbot python setup.py build sudo python setup.py install cd .. rm -rf buildbot/
Talos Setup
Install PyYAML
wget http://pyyaml.org/download/pyyaml/PyYAML-3.05.tar.gz tar -zvxf PyYAML-3.05.tar.gz cd PyYAML-3.05 python setup.py build sudo python setup.py install
Setting up a Talos Buildbot slave
How to setup a Buildbot Talos slave (replace the master.host, username, and password with the correct values)
cd ~ mkdir talos-slave buildbot create-slave --umask=022 talos-slave master.host:9989 username password
You should then start the slave once to create the proper directory structure.
buildbot start talos-slave buildbot stop talos-slave
When running Buildbot slaves on Mac you must start it from a Terminal window in VNC and leave that window open (even though it's a daemon process). hdiutil will throw errors if you do not.
Apache Setup
Install apache from http://httpd.apache.org/download.cgi (use unix source) - the copy of apache bundled with the mac is too old.
In the apache directory:
./configure --prefix=/etc/apache2 make make install
Stop the built in apache:
sudo apachectl stop
The DocumentRoot will be dependent on the builddir of your Buildbot slave. In this section that directory will be referred to as $BUILDDIR.
Pageset
You will need to install a pageset in /Users/mozqa/pages
The rest
- Create an empty directory so Apache doesn't complain:
cd ~/talos-slave/$BUILDDIR mkdir talos
- Open up /etc/apache2/httpd/httpd.conf and change both references of "/Library/WebServer/Documents" to "/Users/mozqa/talos-slave/$BUILDDIR/talos".
Add an alias so Apache knows where the pageset is. Add this to your configuration file:
Alias /page_load_test/pages /Users/mozqa/pages <Directory /Users/mozqa/pages> Options Indexes Order allow,deny Allow from all </Directory>
Turn off logging, remove any lines that begin with "CustomLog"
Restart apache with:
sudo /etc/apache2/bin/apachectl restart
Updating Talos
Assuming your Buildbot master configuration is proper, Buildbot will automatically update Talos on every performance run. If the pageset is updated, you will need to refresh /home/mozqa/pages.