CaronLab / MhcVizPipe

A reporting pipeline for visualization of immunopeptidomics MS data.
MIT License
7 stars 6 forks source link

Permission denied: 'netMHCpan' #2

Closed courcelm closed 4 years ago

courcelm commented 4 years ago

The install script doesn`t set correctly the permission for excuting netMHCpan.

PermissionError: [Errno 13] Permission denied: 'netMHCpan'

(base) mathieu@protub1-iric:~$ ls -Fla /usr/local/bin/netMHC -rwxr-xr-x 1 root root 1557 Sep 14 09:12 /usr/local/bin/netMHCIIpan -rwxr-x--- 1 root root 1408 Sep 14 09:12 /usr/local/bin/netMHCpan*

On that topic, I dont think it is reasonable to expect that user have sudo access. This will be denied on most server managed by university. If I dont put netMHCpan in /usr/local/bin, it doesn`t work out of the box for an easy install.

I think you should modify the PATH environment variable. That`s what I was expecting when your script ask the question.

courcelm commented 4 years ago

After fixing manually the execute permission I get this error. My PATH is not available to subprocess. Use the following to fix.

    my_env = os.environ.copy()
    p = subprocess.Popen(command, stderr=subprocess.PIPE, stdout=subprocess.PIPE, env=my_env, ,shell=True)

multiprocessing.pool.RemoteTraceback: """ Traceback (most recent call last): File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/multiprocessing/pool.py", line 121, in worker result = (True, func(*args, *kwds)) File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/multiprocessing/pool.py", line 44, in mapstar return list(map(args)) File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/site-packages/MhcVizPipe/Tools/jobs.py", line 39, in run File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/site-packages/MhcVizPipe/Tools/jobs.py", line 32, in run my_env = os.environ.copy() File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/subprocess.py", line 800, in init restore_signals, start_new_session) File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/subprocess.py", line 1551, in _execute_child raise child_exception_type(errno_num, err_msg, err_filename) FileNotFoundError: [Errno 2] No such file or directory: 'netMHCpan': 'netMHCpan' """

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/site-packages/MhcVizPipe/gui.py", line 1011, in run_analysis cl_tools.run_jubs() File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/site-packages/MhcVizPipe/Tools/cl_tools.py", line 247, in run_jubs self.jobs = _run_multiple_processes(self.jobs, n_processes=int(self.Parameters.THREADS)) File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/site-packages/MhcVizPipe/Tools/jobs.py", line 45, in _run_multiple_processes def _run_multiple_processes(jobs: List[Job], n_processes: int): File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/multiprocessing/pool.py", line 268, in map return self._map_async(func, iterable, mapstar, chunksize).get() File "/home/mathieu/MhcVizPipe/python/install/lib/python3.7/multiprocessing/pool.py", line 657, in get raise self._value FileNotFoundError: [Errno 2] No such file or directory: 'netMHCpan': 'netMHCpan'

courcelm commented 4 years ago

Ubuntu 18.04 LTS doesn`t have tcsh shell installed by default. Quick install will fail.

bash: /usr/local/bin/netMHCpan: /bin/tcsh: bad interpreter: No such file or directory

kevinkovalchik commented 4 years ago

Thanks, this is a good point. I will add a bin folder to the installation directory and put all the scripts in there. Also will modify the permissions.

I'm waiting for my car at the mechanic right now, so i won't get to this until later this morning it afternoon.

Kevin

On Mon, Sep 14, 2020, 9:23 AM courcelm, notifications@github.com wrote:

The install script doesn`t set correctly the permission for excuting netMHCpan.

PermissionError: [Errno 13] Permission denied: 'netMHCpan'

(base) mathieu@protub1-iric:~$ ls -Fla /usr/local/bin/netMHC -rwxr-xr-x 1 root root 1557 Sep 14 09:12 /usr/local/bin/netMHCIIpan -rwxr-x--- 1 root root 1408 Sep 14 09:12 /usr/local/bin/netMHCpan*

On that topic, I dont think it is reasonable to expect that user have sudo access. This will be denied on most server managed by university. If I dont put netMHCpan in /usr/local/bin, it doesn`t work out of the box for an easy install.

I think you should modify the PATH environment variable. That`s what I was expecting when your script ask the question.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/CaronLab/MhcVizPipe/issues/2, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD2PTUEM4IOCSVUOLKTFDY3SFYKNFANCNFSM4RLTEQDA .

kevinkovalchik commented 4 years ago

It doesn't have tcsh? Ugh. Thanks. I'll guess I'll rewrite the scripts for NetMhcPan etc in Bash then...

On Mon, Sep 14, 2020, 9:57 AM courcelm, notifications@github.com wrote:

Ubuntu 18.04 LTS doesn`t have tcsh shell installed by default. Quick install will fail.

bash: /usr/local/bin/netMHCpan: /bin/tcsh: bad interpreter: No such file or directory

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/CaronLab/MhcVizPipe/issues/2#issuecomment-692069954, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD2PTUDD7WQ3HYKRNESVIVDSFYOMHANCNFSM4RLTEQDA .

kevinkovalchik commented 4 years ago

Hello,

I believe I have addressed most of these issues now.

The new version is 0.4.6, and changes were made to the installation script as well.

Thanks a bunch!

Kevin

courcelm commented 4 years ago

On Ubuntu 18.04 LTS .profile is ignored by my bash terminal when I open a new terminal. I guess you will need to modify both.

There is a typo for "Procced" in the install script.

courcelm commented 4 years ago

My last comment is now fixed.