Question: Error running OrthoMCL
gravatar for johane92
3.0 years ago by
johane920 wrote:

Hi all,

I'm developing a pipeline for using OrthoMCL and I can't get around an error that occurs when running OrthoMCLPairs:

DBD::mysql::st execute failed: Table 'BestQueryTaxonScore' already exists at /home/user/software/orthoMCL/bin/orthomclPairs line 709, <f> line 14.

I went to check line 709 in orthomclPairs, which really didn't tell me much why the error occurs.

When the pipeline is run one row at a time, this error isn't raised and therefore this makes no sense to me. The orthomcl.config is unique for each run, meaning that my SimiliarSequencesTable will be unique.

This is basically the source code from where the error occurs:

Install schema in MySQL: (cd $dir/my_orthomcl_dir && /home/user/software/orthoMCL/bin/orthomclInstallSchema "orthomcl_LK.config")

Load BLAST: (cd $dir/my_orthomcl_dir && time /home/user/software/orthoMCL/bin/orthomclLoadBlast "orthomcl_LK.config" "similarSequences_LK_test_5.txt")

Find pairs: (cd $dir/my_orthomcl_dir && time /home/user/software/orthoMCL/bin/orthomclPairs "orthomcl_LK.config" "pairs_LK_paramOAD.log" cleanup=yes)

Anyone else that has encountered this error?

orthomcl mysql • 1.9k views
ADD COMMENTlink modified 3.0 years ago by Nari870 • written 3.0 years ago by johane920

The error indicates that the program is trying to create a MySQL table that already exists. This can happen when the same command runs twice, maybe the table was created in a previous run. Just drop the table (or the whole database) and start again. To avoid this, the code should probably run DROP TABLE ... IF EXISTS before trying to create the table.

ADD REPLYlink written 3.0 years ago by Jean-Karim Heriche20k

This is correct - OrthoMCL expects a "clean" and empty database after orthoMCLInstallSchema, so in between runs it's easiest to run "DROP DATABASE orthomcl;", "CREATE DATABASE orthomcl," inside the mysql command line and then to do orthoMCLinstallSchema again

ADD REPLYlink written 3.0 years ago by Philipp Bayer6.3k

Yes I've thought of that too, but according to my supervisor the OrthoMCL database where I run the pipeline is used by several computers in the department, and therefore I'm not really sure that it should/can be removed. When the commands is run separately, this problem doesn't occur which feels like that the existence of the database cannot be the problem. The same goes for the table. But maybe it should be removed, which feels like the only reason and solution to the problem!


ADD REPLYlink written 3.0 years ago by johane920


Do you know how to troubleshoot this error from orthomclLoadBlast?

Error: DBD::mysql::st execute failed: Data too long for column 'SUBJECT_ID' at row 1567

ADD REPLYlink written 13 months ago by bioinfool20

This tells you that you're trying to insert data that is longer than the specified length of the field. Check what is the data type and size of the column SUBJECT_ID and either change its size or make sure that your data is always smaller. Alternatively if you can accept truncation of your data, make the error go away by disabling MySQL strict mode (not recommended anyway).

ADD REPLYlink written 13 months ago by Jean-Karim Heriche20k

Hi Karin, An error prompt in my run in orthomclDumpPairsFiles

DBD::mysql::st execute failed: Error writing file '/tmp/MYza1d1c' (Errcode: 28 - No space left on device) at /home/.../bin/orthomclDumpPairsFiles line 54, <f> line 14.

Do you know how to solve this? Thanks!

ADD REPLYlink modified 13 months ago • written 13 months ago by bioinfool20

This error means one of two things: either you're running out of disk space or you're running out of inodes. This usually happens when some processes don't clean up temporary files after themselves and the system accumulates lots of files over time either eating up all available space or eating up all available inodes (e.g. with lots of small files).

ADD REPLYlink written 13 months ago by Jean-Karim Heriche20k

Thanks for the reply. But can you share to me the steps to troubleshoot it?

ADD REPLYlink written 13 months ago by bioinfool20

On the affected filesystem, start with checking the available space with: df -h . If there's still space left, there are two possibilities: either you're filling up all the remaining space when running your pipeline (MySQL creates temporary files that can be large) and that's been cleaned up or you're running out of inodes and you'll have to find where the unwanted files are. Most likely they are in temporary directories like /tmp. Monitor the available space while running your pipeline and see if it is getting full. Also on some systems, a reboot clears tmp directories and some caches so that's worth a try.

ADD REPLYlink written 13 months ago by Jean-Karim Heriche20k

Doing df -h gives me tmpfs avail ~1.9G. In line with this, I am wondering if I can change the writing of the files from /tmp/MY40oycE to other folder? I had this folder with 613G available so I change the tmpdir of mysqld.cnf into its path. Apparently, when i restart mysql to take effect the change I made I got this error:

Job for mysql.service failed because the control process exited with error code. See "systemctl status mysql.service" and "journalctl -xe" for details.

I would also try to reboot to try my luck. How to do the rebooting? Im just new to this so Im sorry if im asking too many question. Thanks.

ADD REPLYlink modified 13 months ago • written 13 months ago by bioinfool20

tmpfs is irrelevant, you want data fro the affected filesystem, i.e. the one you're running things one, most likely the one where /tmp is located. So assuming the current directory is on the affected filesystem, you should run:

df -h .

Notice the dot. Or list all output of df -h (i.e. without the dot). Rebooting is done either by using the shutdown/restart menu or by pressing the power button on the computer. If you're accessing the machine via a terminal, you can run:

sudo reboot now

It would be easier and more efficient if you could find someone knowledgeable near you. Also there are other places dedicated to this type of problems such as Unix & Linux StackExchange or StackOverflow.

ADD REPLYlink written 13 months ago by Jean-Karim Heriche20k
gravatar for Nari
3.0 years ago by
United States
Nari870 wrote:

refer to this thread.

ADD COMMENTlink written 3.0 years ago by Nari870
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 626 users visited in the last hour