[ensembl-dev] Can't connect Ensembl Database

JiangMei gingerplum at hotmail.com
Sat Oct 27 05:33:48 BST 2012


Hi All. Sorry to bother you.

I can't connect the Ensembl database.

My code is as following
use Bio::EnsEMBL::Registry;
my $registry = 'Bio::EnsEMBL::Registry';
$registry->load_registry_from_db(
      -host       =>'ensembldb.ensembl.org',
      -user       =>'anonymous',
      -db_version =>'67');
my @adaptors=@{$registry->get_all_adaptors(-GROUP => 'core', -TYPE => 'gene')};

open IN,"IDs.txt";
while(<IN>){
      chomp;
      my ($gene,$name,$species);
      $id=$_;
      for $adaptor(@adaptors){
       $gene=$adaptor->fetch_by_stable_id($id);
       }
      $name=$gene->external_name;
      $species=$gene->species;
}
close IN;

Then I got the following error:
MSG: Cannot connect to the Ensembl MySQL server at ensembldb.ensembl.org:5306; check your settings & DBI error message: Can't connect to MySQL server on 'ensembldb.ensembl.org' (111)
STACK Bio::EnsEMBL::Registry::load_registry_from_db /root/Ensembl-67/ensembl/modules/Bio/EnsEMBL/Registry.pm:1576

Is there anything wrong with my code? Wish your help! Thanks very much! I really appreciate it.


Best regards,

Mei

 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ensembl.org/pipermail/dev_ensembl.org/attachments/20121027/56f05493/attachment.html>


More information about the Dev mailing list