<p>My suggestion is to run <code>prokka</code> from within <code>conda</code> by simply downloading <a href="https://docs.conda.io/projects/conda/en/stable/user-guide/install/download.html" rel="nofollow noreferrer">miniconda</a> then</p>
<pre><code>conda create --name prokka
conda activate prokka
conda install -c conda-forge -c bioconda -c defaults prokka
prokka --help
prokka --version
prokka mycontigs.fa # running prokka
</code></pre>
<p>You could always perform a</p>
<pre><code>chmod 700 /home/saurab/BIOIN/phastest-app/sub_programs/barrnap
</code></pre>
<p>or some variant like <code>chmod 500 ...</code></p>
<p>or possibly using a recursive <code>chmod -R 500</code> that sort of thing. Eventually it will work.</p>
<p><strong>However</strong>, it strikes me you are installing <code>prokka</code> outside any virtual environment such as <code>conda</code> or <code>brew</code> and I would not do that personally, because you are giving significant permissions to the algorithm.</p>
<p><code>conda</code> (or <code>brew</code>) will sort out all the permission needed and there's no need to do anything with <code>chmod</code> stuff.</p>
<p>Good luck with the annotation.</p>

CC BY-SA 4.0
2023-02-23T22:57:28.020Z
2023-02-24T18:42:06.677Z
2023-02-24T18:42:06.677Z
M__
<p>I am trying to run the <strong>Prokka annotation tool</strong> on my linux machine and have installed <strong>Barrnap and added it to $PATH and given the folder chmod 777 permission</strong>. However, when running Prokka, it gives the line <code>Could not parse version from 'sh: 1: barrnap: Permission denied'</code>.</p>
<p>Running Barrnap solely through the command line with a valid input works fine but does not seem to work when another script calls barrnap. I have tried checking path variables and giving max permissions to barrnap and Prokka but it does not seem to change this error. Here is the full log file:</p>
<pre><code>[15:01:28] This is prokka 1.14.6
[15:01:28] Written by Torsten Seemann &lt;torsten.seemann@gmail.com&gt;
[15:01:28] Homepage is https://github.com/tseemann/prokka
[15:01:28] Local time is Thu Feb 23 15:01:28 2023
[15:01:28] You are saurab
[15:01:28] Operating system is linux
[15:01:28] You have BioPerl 1.7.8
[15:01:28] System has 16 cores.
[15:01:28] Will use maximum of 8 cores.
[15:01:28] Annotating as &gt;&gt;&gt; Bacteria &lt;&lt;&lt;
[15:01:28] Generating locus_tag from 'jobs/NC_004556.faa' contents.
[15:01:28] Setting --locustag ECJHPMJE from MD5 ec31963ed5d3d76e28501fa7e45ca273
[15:01:28] Creating new output folder: PROKKA_02232023
[15:01:28] Running: mkdir -p PROKKA_02232023
[15:01:28] Using filename prefix: PROKKA_02232023.XXX
[15:01:28] Setting HMMER_NCPU=1
[15:01:28] Writing log to: PROKKA_02232023/PROKKA_02232023.log
[15:01:28] Command: /home/saurab/BIOIN/basys2-app/sub_programs/prokka/bin/prokka jobs/NC_004556.faa
[15:01:28] Appending to PATH: /home/saurab/BIOIN/basys2-app/sub_programs/prokka/bin/../binaries/linux
[15:01:28] Appending to PATH: /home/saurab/BIOIN/basys2-app/sub_programs/prokka/bin/../binaries/linux/../common
[15:01:28] Appending to PATH: /home/saurab/BIOIN/basys2-app/sub_programs/prokka/bin
[15:01:28] Looking for 'aragorn' - found /home/saurab/BIOIN/phastest-app/sub_programs/aragorn
[15:01:28] Determined aragorn version is 001002 from 'ARAGORN v1.2   Dean Laslett'
[15:01:28] Looking for 'barrnap' - found /home/saurab/BIOIN/phastest-app/sub_programs/barrnap
[15:01:28] Coult not parse version from 'sh: 1: barrnap: Permission denied'
</code></pre>

CC BY-SA 4.0
2023-02-24T09:28:44.823Z
Please [edit] your question and add the output of `ls -l /home/saurab/BIOIN/phastest-app/sub_programs/barrnap`. You say you set the directory to 777 but what about the actual script/executable?
terdon
<sequence-annotation><perl><bacteria><functional-annotation>
Barrnap Bacterial rRNA Predictor script permission denied error when running Prokka
# Barrnap Bacterial rRNA Predictor script permission denied error when running Prokka

(Asked by: username_0 on 2023-02-23)

I am trying to run the Prokka annotation tool on my linux machine and have installed Barrnap and added it to $PATH and given the folder chmod 777 permission. However, when running Prokka, it gives the line Could not parse version from 'sh: 1: barrnap: Permission denied'.
Running Barrnap solely through the command line with a valid input works fine but does not seem to work when another script calls barrnap. I have tried checking path variables and giving max permissions to barrnap and Prokka but it does not seem to change this error. Here is the full log file:
[15:01:28] This is prokka 1.14.6
[15:01:28] Written by Torsten Seemann 
[15:01:28] Homepage is https://github.com/tseemann/prokka
[15:01:28] Local time is Thu Feb 23 15:01:28 2023
[15:01:28] You are saurab
[15:01:28] Operating system is linux
[15:01:28] You have BioPerl 1.7.8
[15:01:28] System has 16 cores.
[15:01:28] Will use maximum of 8 cores.
[15:01:28] Annotating as >>> Bacteria <<<
[15:01:28] Generating locus_tag from 'jobs/NC_004556.faa' contents.
[15:01:28] Setting --locustag ECJHPMJE from MD5 ec31963ed5d3d76e28501fa7e45ca273
[15:01:28] Creating new output folder: PROKKA_02232023
[15:01:28] Running: mkdir -p PROKKA_02232023
[15:01:28] Using filename prefix: PROKKA_02232023.XXX
[15:01:28] Setting HMMER_NCPU=1
[15:01:28] Writing log to: PROKKA_02232023/PROKKA_02232023.log
[15:01:28] Command: /home/saurab/BIOIN/basys2-app/sub_programs/prokka/bin/prokka jobs/NC_004556.faa
[15:01:28] Appending to PATH: /home/saurab/BIOIN/basys2-app/sub_programs/prokka/bin/../binaries/linux
[15:01:28] Appending to PATH: /home/saurab/BIOIN/basys2-app/sub_programs/prokka/bin/../binaries/linux/../common
[15:01:28] Appending to PATH: /home/saurab/BIOIN/basys2-app/sub_programs/prokka/bin
[15:01:28] Looking for 'aragorn' - found /home/saurab/BIOIN/phastest-app/sub_programs/aragorn
[15:01:28] Determined aragorn version is 001002 from 'ARAGORN v1.2   Dean Laslett'
[15:01:28] Looking for 'barrnap' - found /home/saurab/BIOIN/phastest-app/sub_programs/barrnap
[15:01:28] Coult not parse version from 'sh: 1: barrnap: Permission denied'

**Tags:** sequence-annotation, perl, bacteria, functional-annotation
> **Comments:**
> **username_1**: Please [edit] your question and add the output of `ls -l /home/saurab/BIOIN/phastest-app/sub_programs/barrnap`. You say you set the directory to 777 but what about the actual script/executable?  

---

## 1 answers

### Answer by username_2 on 2023-02-23. Score: 3 | Accepted answer

My suggestion is to run prokka from within conda by simply downloading miniconda then
conda create --name prokka
conda activate prokka
conda install -c conda-forge -c bioconda -c defaults prokka
prokka --help
prokka --version
prokka mycontigs.fa # running prokka

You could always perform a
chmod 700 /home/saurab/BIOIN/phastest-app/sub_programs/barrnap

or some variant like chmod 500 ...
or possibly using a recursive chmod -R 500 that sort of thing. Eventually it will work.
However, it strikes me you are installing prokka outside any virtual environment such as conda or brew and I would not do that personally, because you are giving significant permissions to the algorithm.
conda (or brew) will sort out all the permission needed and there's no need to do anything with chmod stuff.
Good luck with the annotation.


---

