Version 9 (modified by 18 years ago) (diff) | ,
---|
How to Use SCDB
TracNav
Table of Contents
Getting Started
To know how to install a Quattor server with SCDB or how to migrate from CDB, refer to the specific page about SCDB installation?.
Template Compilation
All the template processing needed to build machine profiles is done with ant
tools, a Java based equivalent of make
. ant
brings the advantage of platform independance, allowing to do Quattor management tasks on any platform (Unix, Windows, MacOS).
Specific management tasks (called targets
) are passed as a parameter to ant
command, in much the same way this is done with make
. There are 3 main targets for managing Quattor (other targets are used internally by ant
) :
compile.all
: this task recompiles all the machine profiles affected by template changes. This is the default if no target is specified.deploy
: this task deploys the new machine profiles on the Quattor server. This can occurs only after successful compilation of all clusters.update.rep.templates
: this task updates templates describing RPM repositories contents by scanning each repository associated directory.
Checking Compilation Results
When doing changes in configuration, this is often useful to check the resulting profiles before deploying. There is a small tool to help doing that, src/utils/profiles/compare_xml. This tool is part of SCDB base.
To use this tool, before compiling your changes, you need to copy your current (or reference) build
directory to something else, by example build.saved
(default name used by the script). After the compilation, if you run the script without arguments, it will display the list of all profiles that have changed. You can inspect the changes (require a bit of knowledge of profile contents) using option -v
. Or you can restrict the check to one specific profile with option -p
. By example :
# src/utils/profiles/compare_xml Comparing XML files (*.xml)... Differences found in build/xml/profile_grid05.xml Differences found in build/xml/profile_grid06.xml Differences found in build/xml/profile_grid07.xml # src/utils/profiles/compare_xml -v -p profile_grid05 Comparing XML files (profile_grid05.xml)... Differences found in build/xml/profile_grid05.xml --- build.saved/xml/profile_grid05.xml 2006-07-28 11:41:45.000000000 +0200 +++ build/xml/profile_grid05.xml 2006-07-28 11:50:58.000000000 +0200 @@ -960,7 +960,6 @@ <options> <dpm> <db> - <adminpwd type="string">MyPrefPwd</adminpwd> <adminuser type="string">root</adminuser> <configfile type="string">/opt/lcg/etc/DPMCONFIG</configfile> <password type="string">DpmMgrPwd</password>
Another option available, -d
, extends the comparaison to profile dependencies. This is generally not useful but can be used to do a regression test with a new version of the compiler, for example.