Документ взят из кэша поисковой машины. Адрес
оригинального документа
: http://www.atnf.csiro.au/vlbi/dokuwiki/doku.php/difx/difxdb
Дата изменения: Unknown Дата индексирования: Sun Apr 10 21:23:33 2016 Кодировка: IBM-866 Поисковые слова: earth orbit |
The difxdb package is a collection of tools developed at MPIfR for storing an administrating correlation related information in a relational database. There is a NRAO specific package with the same name which you can find in the sites/NRAO section of the SVn repository.
The difxdb programs can be used to keep track of experiments processed at your correlator, as well as keep track of disk modules currently located at the correlator center. Some of the difx programs can communicate with the database, e.g. genmachines can tell you the location of a disk module when it is needed for correlation. Also the difx gui interacts with the database to schedule correlation jobs and to keep track of the correlation state and progress.
Note: difxdb is a convenience package and is purely optional. It is not required in any way in order to correlate.
difxdb will need access to a relational database server in order to run. Difxdb supports a large number of different database systems including MySQL, PostGreSQL, Oracle, and many others (see http://docs.sqlalchemy.org/en/rel_0_8/dialects/index.html ).
MPIfR is using a MySQL based system. So if you do not have a different DB server running already or have other preferences installing MySQL might be the best option as this is well tested to work. All examples below are for the MySQL case and might differ when using a different system.
For installation instruction of the DB server please consult the various sites on the web (e.g. http://dev.mysql.com/doc/refman/5.1/en/installing.html).
The DB schema and some table contents must be imported into the DB server. The relevant sql files are located under: utilities/trunk/difxdb/database.
To import the initial schema (version 1.0) and data issue the following commands (machine must have mysql client installed and have access to the database server):
mysql -h <DBSERVER> -u root -p < difxdb_mysql_full_1_0.sql mysql -h <DBSERVER> -u root -p < difxdb_data.sql
where <DBSERVER> referes to the IP adress of your DB server. root is the mysql root user (not the system root) and you will be asked for the database root user password accordingly.
Now you must import all schema updates later than version 1.0:
mysql -h <DBSERVER> -u root -p < difxdb_mysql_update_1_1.sql mysql -h <DBSERVER> -u root -p < difxdb_mysql_update_1_2.sql ...
Make sure you inport all update scripts in accending version order. For more details about schema versions please take a look at the README file located under utilities/trunk/difxdb/database.
Please make sure to consult your local system administrator for details about the DB configuration as there might be security issues involved. In any case you should not access the difxdb using the DB root user but rather create a dedicated user with minimal access rights. This user should have SELECT,INSERT,UPDATE and DELETE priviliges on the difxdb database only! Make a note of the user name and the password as you will need this later.
The home of the difxdb source code in the SVN repository is: utilities/trunk/difxdb
Normally the difxdb utilities do not get installed by default when running install_difx
. In order
to manually install difxdb go to utilities/trunk/difxdb and run:
aclocal autoconf autoheader automake -a ./configure --prefix=${DIFXROOT} make install
difxdb imports various python site packages which need to be manually installed. Go to: libraries/python/trunk and issue:
aclocal autoconf autoheader automake -a ./configure --prefix=${DIFXROOT} make install
This will copy the python packages to: $DIFXROOT/lib/python
In order for the dixdb programs to run you need to include $DIFXROOT/lib/python
in your $PYTHON_PATH
environment variable.
the difxdb programs are implemented in python and require a few python packages to be installed. The package names below are for RHEL based systems and might differ for other linux distributions:
tkinter python-imaging python-sqlalchemy MySQL-python (or relevant package for a different DB server)
pybarcode is typically not included in linux distros by default and must be installed manually if you plan to use the comedia tool (see below). Download pybarcode from https://pypi.python.org/pypi/pyBarcode/
after unpacking run (as root):
python setup.py install
TO BE CONTINUED