Offline Software Installation

From Daya Bay
Jump to navigation Jump to search
Offline Documentation: [Offline Category] [FAQ] [Howto] [Reference] [Manual]


Offline Documentation
This article is part
of the Offline Documentation
Other pages...

Offline Category
FAQ
How Tos
Reference
Manual
Getting Started
Software Installation

See also...

General Help on this Wiki


This describes how to build the Gaudi based Daya Bay offline software. For instructions on building the "legacy" code, see dbp:BuildSystem.

Automatic installation with dybinst

You can automatically install "trunk" or a frozen release with dybinst. If there is a pending upgrade, you can also install that with dybinst.

Download dybinst script

The dybinst script should always be freshly downloaded from our SVN Repository, either from the trunk or a release. If you have a pre-existing one, remove it.

For example, getting from the trunk:

svn export http://dayabay.ihep.ac.cn/svn/dybsvn/installation/trunk/dybinst/dybinst

This svn command fails for some people, as an alternative you can also use a web browser or command line download tool (such as wget or curl) to download it from here. You will need to supply a correct SVN user/password.

For the URL of other releases of dybinst see their respective topics. For information on installing "upgrade releases" see Software Upgrades.

Run dybinst

To download, compile and build everthing, just run:

./dybinst <release_version> all

Note that <release_version> can be 'trunk', to get the bleeding edge, or 'upgrade' to try out a pending upgrade.

That's it.

More about dybinst

Using dybinst -e

dybinst -e allows the use of a pre-built or common external/ directory. The correct usage is described in Trac ticket #304 (look for comment by csjlin).

Check out the latest successful build

  1. To determine the latest successful build, examine the build status in Trac.
    You may want to check the optimized and debug build history to find a successful build of your liking.
  2. If NNNN was the revision number (also called "Chgset" on the build page) latest successful build, then dybinst -z NNNN will checkout the code at that revision number.
  3. Note that you can view the contents of revision by clicking "Chgset" number.

Saving space during build of external/

Before beginning the build, create external/tarFiles and external/build as softlinks to another (scratch) disk. After the build, the contents of these two subdirectories are not needed.

Building Optional Externals

Some external dependencies are not needed to run most of NuWa or are only needed at a specific site. To learn how to install these optional packages see the topic Installing Optional External Packages.

Test the Installation

Once you have finished the installation, you can test it as follows (replace "trunk" with the release number if installing a frozen release):

Set your NuWa environment
cd /path/to/your/NuWa-trunk
source setup.sh
cd dybgaudi/DybRelease/cmt
source setup.sh

See details on setting your environment.

Compile the Test Package
cd /path/to/your/NuWa-trunk/dybgaudi/Tutorial/DybHellowWorld/cmt
cmt config
source setup.sh
make
Run the Test
cd ../
nuwa.py -n 1 share/RunHelloWorld.py

You should see a series of messages as the analysis framework is loaded, initialized, and run.


Optimized vs. Debug builds

By default the code is installed with debugging symbols and without compiler optimizations. While this makes the libraries larger and leads to much slower running, it greatly facilitates development and tracking down bugs.

When building and running production jobs one should use an optimized build. For information on this see the topic on optimized builds.

Releases

See Category:Offline Software Releases

Binary or relocated installations

Binary installation tar files can be produced and installed with dybbin. In addition one can build a release, relocate it and re-configured the relocated copy with dybbin. More information at Binary Releases.

Introducing New Platforms

During the installation on previously unused platforms you may see a message like:

Stage: "external"... 

Found CMTCONFIG="" from lcgcmt
Checking your CMTCONFIG=""... 

ERROR: CMTCONFIG is not compatible!

Or it may complain about "Unknown" parts of the platform name. It gives some guidance on how to introduce your new platform. For additional guidance see Porting To A New Platform.

VirtualBox Appliance Install

NuWa in a box is a new project to get a virtual machine version of NuWa releases that can be run on any hardware supporting Virtual Box.

This is currently in development and somewhat experimental, but can already be used to run NuWa. The most recent version is Scientific Linux 4.8 and NuWa Release 1.6.0

Virtual Box http://www.virtualbox.org/

   Go here to download Virtual Box software. This VM software is needed to run the NuWa in a box appliance. 

Disk Image http://dayabay.lbl.gov/pandora/nuwabox160/shire.vmdk (Note: This file is huge and download can take hours. It is the entire Linux + NuWa installation disk image.)

   Right-click and "Save Link As" to download the diskimage (~3.5GB). 

Virtual Appliance http://dayabay.lbl.gov/pandora/nuwabox160/SL%204.8%20NuWa%201.6.0-20100430b.ovf

   Right-click and "Save Link As" to download the Virtual Appliance. 

Axillary File http://dayabay.lbl.gov/pandora/nuwabox160/SL%204.8%20NuWa%201.6.0-20100430b.mf

   Right-click and "Save Link As" to download the extra file.

Afterwards, launch the VirtualBox application. In VirtualBox: "File" => "Import Appliance" => select the *.ovf appliance file.

The above virtual appliance is version 1.6.0 of NuWa on SLC 4.8. It should run without any intervention or further configuration. There are 2 accounts already available (Usernames = root, dayabay). Contact Craig for the passwords on this version. You will find text help files in the home directory of the dayabay user account.

If you wish to run a more recent version, you can either proceed with dybinst, as usual, or wait for the next release of the virtual appliance. We will release a new appliance with the MDC10a release tag, and keep the appliances up to date with production releases.

virtual box + OS + NuWa installation

  1. Download appropriate Virtual Box for your host machine from http://www.virtualbox.org/
  2. Download OS. Ubuntu9.10 can be obtained from http://mirror.bnl.gov/ubuntu-iso/CDs/karmic/ubuntu-9.10-desktop-i386.iso
  3. Start VirtualBox. "File" ==> "Virtual Media Manager" ==> "CD/DVD Images" . Add path to downloaded .iso file.
  4. In VirtualBox. click "New" and let the wizard guide you.
  5. boot Ubuntu9.10. You will need to sudo apt-get install svn emacs and perhaps more stuff
  6. Proceed with usual installation with dybinst

Setup of daily builds and validations

Functions that perform and manage coordinated daily builds and validations are provided by daily.bash. Detailed configuration and usage instructions are provided within this script.

The daily script uses many functions from dyb__.sh. Functions of particular note for validating builds and debugging failed builds are

  • dyb__testall_ls
  • dyb__testall_summary
  • dyb__validate

Usage instructions are provided within this script.

Further Details

Well, in reality, that isn't all there is to it. For further details see this topic.

Offline Software Documentation: [Offline Categories] [FAQ] [Offline Reference Category]