# IOError: \[Errno 13\] Permission denied: './med-3.2.1\_SRC/doc/

**URL:** <https://code-saturne.org/forum/t/ioerror-errno-13-permission-denied-med-3-2-1-src-doc/1461>\
**Category:** Installation issues\
**Created:** [October 6, 2017, 10:23pm UTC](https://code-saturne.org/forum/t/ioerror-errno-13-permission-denied-med-3-2-1-src-doc/1461 "2017-10-06T22:23:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ffan](https://code-saturne.org/forum/letter_avatar_proxy/v4/letter/f/50afbb/32.png) [@ffan](https://code-saturne.org/forum/u/ffan)\
**Post date:** [October 6, 2017, 10:23pm UTC](https://code-saturne.org/forum/t/ioerror-errno-13-permission-denied-med-3-2-1-src-doc/1461/1 "2017-10-06T22:23:26Z")

</div>

Hi,

My system is RHEL 6.8. In building MED 3.2.1 for Code\_Saturne 5.0.4, it encountered the following problem. Why does it happen and how to get around it? Thanks.

Fa-Gung Fan

MED (Model for Exchange of Data)  
version: 3.2.1  
url: [http://files.salome-platform.org/Salome/other/med-3.2.1.tar.gz](http://files.salome-platform.org/Salome/other/med-3.2.1.tar.gz)  
package: med  
source\_dir: None  
install\_dir: /user/fanf4/Code\_Saturne/5.0.4/med-3.2.1/arch/Linux\_x86\_64  
config\_opts: --with-med\_int=long --disable-fortran --disable-python --with-hdf5=/user/fanf4/Code\_Saturne/5.0.4/hdf5-1.8.17/arch/Linux\_x86\_64

Extract of MED  
Traceback (most recent call last):  
File “../code\_saturne-5.0.4/install\_saturne.py”, line 1419, in   
setup.install()  
File “../code\_saturne-5.0.4/install\_saturne.py”, line 1157, in install  
p.extract()  
File “../code\_saturne-5.0.4/install\_saturne.py”, line 292, in extract  
tar.extractall()  
File “/cadtools/contrib/python/lib/python2.7/tarfile.py”, line 2047, in extractall  
self.extract(tarinfo, path)  
File “/cadtools/contrib/python/lib/python2.7/tarfile.py”, line 2084, in extract  
self.\_extract\_member(tarinfo, os.path.join(path, tarinfo.name))  
File “/cadtools/contrib/python/lib/python2.7/tarfile.py”, line 2160, in \_extract\_member  
self.makefile(tarinfo, targetpath)  
File “/cadtools/contrib/python/lib/python2.7/tarfile.py”, line 2200, in makefile  
with bltn\_open(targetpath, “wb”) as target:  
IOError: [Errno 13] Permission denied: ‘./med-3.2.1\_SRC/doc/jpg/xmdump4.jpg’

---

<div class="post-metadata">

**Author:** ![Yvan\_Fournier](https://code-saturne.org/forum/letter_avatar_proxy/v4/letter/y/4bbf92/32.png) [@Yvan\_Fournier](https://code-saturne.org/forum/u/Yvan_Fournier)\
**Post date:** [October 10, 2017, 11:41pm UTC](https://code-saturne.org/forum/t/ioerror-errno-13-permission-denied-med-3-2-1-src-doc/1461/2 "2017-10-10T23:41:09Z")

</div>

Hello,

Which directory are you installing from ? Did you create a directory as root, or using sudo, or did you only use you standard account (which is the recommended option) ?

Regards,

Yvan

---

<div class="post-metadata">

**Author:** ![ffan](https://code-saturne.org/forum/letter_avatar_proxy/v4/letter/f/50afbb/32.png) [@ffan](https://code-saturne.org/forum/u/ffan)\
**Post date:** [October 13, 2017, 11:36pm UTC](https://code-saturne.org/forum/t/ioerror-errno-13-permission-denied-med-3-2-1-src-doc/1461/3 "2017-10-13T23:36:28Z")

</div>

Hi Yvan,

Thank you for reply. I installed it from my Downloads directory with my standard account (without using sudo or su). It is a cluster machine, and I don’t have the super user right anyway. Now, I checked the permissions of the reported file and the directories “./med-3.2.1\_SRC/doc/jpg/xmdump4.jpg”. They are as the following:  
drwx------ 9 fanf4 leads 600 Nov 7 2016 med-3.2.1\_SRC  
drwx------ 8 fanf4 leads 190 Nov 7 2016 doc  
drwx------ 2 fanf4 leads 266 Nov 7 2016 jpg  
-r–r–r-- 1 fanf4 leads 121849 Apr 14 2016 xmdump4.jpg

I also installed the same downloaded Code\_Saturne-5.0.4 package on a Ubuntu workstation. Again, from my Downloads directory and using only standard account right. This time, the med-3.2.1 package was successfully installed. Checked permissions of the file and the directories:  
drwxrwxr-x 9 ffan ffan 4096 Oct 13 09:50 med-3.2.1\_SRC  
drwxr-xr-x 8 ffan ffan 4096 Nov 7 2016 doc  
drwxr-xr-x 2 ffan ffan 4096 Nov 7 2016 jpg  
-r–r–r-- 1 ffan ffan 121849 Apr 14 2016 xmdump4.jpg

Apparently, the Ubuntu installation gave more permissions to group and other, but they both were installed with user account and to user directory.

- ffan
