Hi,
Tonight the DPM-server-mysql at CSCS has been automatically updated by apt.
This led to the failure of dpm-qryconf commands (segmentation faults!!),
which we use to monitor the pool levels. A restart of DPM failed naturally,
because it needs a manual intervention, as we found out.
https://twiki.cern.ch/twiki/bin/view/LCG/DpmSrmv2Support
but there is a problem running the update script:
./dpm_support_srmv2.2 --db-vendor MySQL --db localhost --user dpmmgr
--pwd-file /root/mysqlpass --dpns-db cns_db --dpm-db dpm_db --verbose
Fri Mar 9 12:39:18 2007 : Starting to update the DPNS/DPM database.
Please wait...
failed to query and/or update the DPNS/DPM databases : DBD::mysql::db do
failed: Error on rename of './dpm_db/#sql-4083_25' to
'./dpm_db/dpm_pool' (errno: 150) at UpdateDpmDatabase.pm line 118.
Issuing rollback() for database handle being DESTROY'd without explicit
disconnect().
Issuing rollback() for database handle being DESTROY'd without explicit
disconnect().
The failing query seems to be
ALTER TABLE dpm_pool ADD def_lifetime INTEGER
but the error message made not much sense to me.
Now I looked a bit closer, and it turns out that it has to do with a
constraint and the way mysql handles ALTER commands (by copying the original
table first).
If I issue this command in mysql:
SHOW ENGINE INNODB STATUS;
I get:
------------------------
LATEST FOREIGN KEY ERROR
------------------------
070309 13:42:41 Error in foreign key constraint of table dpm_db/dpm_fs:
there is no index in referenced table which would contain
the columns as the first columns, or the data types in the
referenced table do not match to the ones in table. Constraint:
,
CONSTRAINT fk_fs FOREIGN KEY (poolname) REFERENCES dpm_pool (poolname)
The index in the foreign key in table is pk_fs
See http://dev.mysql.com/doc/mysql/en/InnoDB_foreign_key_constraints.html
for correct foreign key definition.
A description of these kind of errors is found here:
http://www.xaprb.com/blog/2006/08/22/mysqls-error-1025-explained/
Any suggestion on how to proceed?
Cheers,
Derek
--
Dr. Derek Feichtinger Tel: +41 56 310 47 33
AIT Group email: [log in to unmask]
PSI
CH-5232 Villigen PSI
-------------------------------------------------------
--
Dr. Derek Feichtinger Tel: +41 56 310 47 33
AIT Group email: [log in to unmask]
PSI
CH-5232 Villigen PSI
|