# Error: Unable to find the mpa\_pkl file at: mpa\_pklExiting

**URL:** https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568
**Category:** MetaPhlAn
**Created:** [January 19, 2021, 3:31pm UTC](https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568 "2021-01-19T15:31:36Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![DanielePietrucci](https://avatars.discourse-cdn.com/v4/letter/d/a183cd/32.png) [@DanielePietrucci](https://forum.biobakery.org/u/DanielePietrucci)
#### Post date: [January 19, 2021, 3:31pm UTC](https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568/1 "2021-01-19T15:31:36Z")

</div>

Hi.  
I’ve installed metaphlan 3 using this command:

`conda create --name mpa -c bioconda python=3.7 metaphlan`

Then I’ve installed the database using this command:

`mkdir -p $WORK_DIR/mpa_db metaphlan --install --bowtie2db $WORK_DIR/mpa_db`

Inside the directory mpd\_db I can find these files:

-rw-rw-r-- 1 dpietruc interactive 342M Jun 30 2020 mpa\_v30\_CHOCOPhlAn\_201901.fna.bz2  
-rw-r–r-- 1 dpietruc interactive 26 Jan 19 14:26 mpa\_latest  
-rw-r–r-- 1 dpietruc interactive 367M Jan 19 14:27 mpa\_v30\_CHOCOPhlAn\_201901.tar  
-rw-r–r-- 1 dpietruc interactive 64 Jan 19 14:27 mpa\_v30\_CHOCOPhlAn\_201901.md5  
-rw-rw-r-- 1 dpietruc interactive 286M Jan 19 14:28 mpa\_v30\_CHOCOPhlAn\_201901.4.bt2  
-rw-rw-r-- 1 dpietruc interactive 9.9M Jan 19 14:28 mpa\_v30\_CHOCOPhlAn\_201901.3.bt2  
-rw-rw-r-- 1 dpietruc interactive 286M Jan 19 14:35 mpa\_v30\_CHOCOPhlAn\_201901.2.bt2  
-rw-rw-r-- 1 dpietruc interactive 601M Jan 19 14:35 mpa\_v30\_CHOCOPhlAn\_201901.1.bt2  
-rw-rw-r-- 1 dpietruc interactive 286M Jan 19 14:43 mpa\_v30\_CHOCOPhlAn\_201901.rev.2.bt2  
-rw-rw-r-- 1 dpietruc interactive 601M Jan 19 14:43 mpa\_v30\_CHOCOPhlAn\_201901.rev.1.bt2

However, when I run the command:

`metaphlan $Name_file_forward,$Name_file_reverse --bowtie2db $WORK_DIR/mpa_db/ --input_type fastq --read_min_len 30 --bowtie2out $Bam --input_type fastq --nproc 8 --stat_q 0.01 -t rel_ab_w_read_stats > $Out`

I get this error:

`Error: Unable to find the mpa_pkl file at: mpa_pklExiting...`

Can you help me to solve this problem? Thanks in advance!

---

<div class="post-metadata">

### Author: ![fbeghini](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/fbeghini/32/81_2.png) [@fbeghini](https://forum.biobakery.org/u/fbeghini)
#### Post date: [January 19, 2021, 3:50pm UTC](https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568/2 "2021-01-19T15:50:35Z")

</div>

Have you tried unpacking `mpa_v30_CHOCOPhlAn_201901.tar`?

---

<div class="post-metadata">

### Author: ![DanielePietrucci](https://avatars.discourse-cdn.com/v4/letter/d/a183cd/32.png) [@DanielePietrucci](https://forum.biobakery.org/u/DanielePietrucci)
#### Post date: [January 20, 2021, 10:03am UTC](https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568/3 "2021-01-20T10:03:51Z")

</div>

Thanks, I’ve unpacked the file and now it’s working!

---

<div class="post-metadata">

### Author: ![bellazzzyy](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/bellazzzyy/32/639_2.png) [@bellazzzyy](https://forum.biobakery.org/u/bellazzzyy)
#### Post date: [February 19, 2021, 7:12am UTC](https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568/4 "2021-02-19T07:12:41Z")

</div>

Hi, I have unpacked `mpa_v30_CHOCOPhlAn_201901.tar` but still get the same error when I run the command:  
‘metaphlan unmapped.ASD001\_r1.fastq,unmapped.ASD001\_r2.fastq --bowtie2db /home/yanz/miniconda3/envs/biosoftware/lib/python3.6/site-packages/metaphlan/metaphlan\_databases --nproc 12 --input\_type fastq -o unmapped\_metagenome.txt’  
‘Error: Unable to find the mpa\_pkl file at: mpa\_pklExiting…’

can anyone help me ☹

---

<div class="post-metadata">

### Author: ![fbeghini](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/fbeghini/32/81_2.png) [@fbeghini](https://forum.biobakery.org/u/fbeghini)
#### Post date: [February 19, 2021, 5:02pm UTC](https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568/5 "2021-02-19T17:02:11Z")

</div>

Have you built the database using `bowtie2-build` or `metaphlan --install`?  
Can you post there the output of `ls -l /home/yanz/miniconda3/envs/biosoftware/lib/python3.6/site-packages/metaphlan/metaphlan_databases` ?

---

<div class="post-metadata">

### Author: ![Pearl](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/pearl/32/2548_2.png) [@Pearl](https://forum.biobakery.org/u/Pearl)
#### Post date: [December 20, 2023, 4:59pm UTC](https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568/7 "2023-12-20T16:59:07Z")

</div>

Hi all,

I got the same error, can you help me to have a look at?

```auto
humann \
> --input final/ff05623391_kneaddata.fastq \
> --threads 12 \
> --nucleotide-database 16SrRNA/humann/chocophlan/ \
> --protein-database 16SrRNA/humann/uniref/ \
> --output humann/

```

```auto
Running metaphlan ........

CRITICAL ERROR: Error executing: /home/c.c2050857/.conda/envs/microbio/bin/metaphlan /scratch/c.c2050857/James/Microbiota/kneaddata/final/ff05623391_kneaddata.fastq -t rel_ab -o /scratch/c.c2050857/James/Microbiota/humann/ff05623391_kneaddata_humann_temp/ff05623391_kneaddata_metaphlan_bugs_list.tsv --input_type fastq --bowtie2out /scratch/c.c2050857/James/Microbiota/humann/ff05623391_kneaddata_humann_temp/ff05623391_kneaddata_metaphlan_bowtie2.txt --nproc 12

Error message returned from metaphlan :
/home/c.c2050857/.conda/envs/microbio/lib/python3.10/site-packages/h5py/ __init__.py:36: UserWarning: h5py is running against HDF5 1.14.3 when it was built against 1.14.2, this may cause problems
  _warn(("h5py is running against HDF5 {0} when it was built against {1}, "
Error: Unable to find the mpa_pkl file at: mpa_pklExiting...

```

```auto
metaphlan --install
/home/c.c2050857/.conda/envs/microbio/lib/python3.10/site-packages/h5py/ __init__.py:36: UserWarning: h5py is running against HDF5 1.14.3 when it was built against 1.14.2, this may cause problems
  _warn(("h5py is running against HDF5 {0} when it was built against {1}, "
The database is installed

```

Any advice would be highly appreciated! Thanks.

---

<div class="post-metadata">

### Author: ![Pearl](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/pearl/32/2548_2.png) [@Pearl](https://forum.biobakery.org/u/Pearl)
#### Post date: [December 20, 2023, 5:24pm UTC](https://forum.biobakery.org/t/error-unable-to-find-the-mpa-pkl-file-at-mpa-pklexiting/1568/8 "2023-12-20T17:24:35Z")

</div>

[Marco solved this problem!](https://forum.biobakery.org/t/unable-to-find-the-mpa-pkl/503/5)

**step1: download metaphlan databases**

```auto
wget http://cmprod1.cibio.unitn.it/databases/MetaPhlAn/metaphlan_databases/mpa_v31_CHOCOPhlAn_201901.tar

```

**step2: uncompress metaphlan databases**

```auto
tar -xvf mpa_v31_CHOCOPhlAn_201901.tar

```

**step3: specific the metaphlan databases location**

```auto
humann \
--input final/ff05623391_kneaddata.fastq \
--threads 12 \
--metaphlan-options "--bowtie2db /16SrRNA/metaphlan/" \
--nucleotide-database 16SrRNA/humann/chocophlan/ \
--protein-database 16SrRNA/humann/uniref/ \
--output Microbiota/humann/

```
