5

I would like to extract all tar.gz inside a folder but I am getting [Errno 13] Permission denied. I have been through different posts related to the problem but nothing helps. Even extracting a specific member inside tar.gz gives same error. Can someone help what could be wrong?

I want to create a script for unzip (.tar.gz) file via (Python)

Python: Extracting specific files with pattern from tar.gz without extracting the complete file

Overwrite existing read-only files when using Python's tarfile

tar = tarfile.open(fname, "r:gz")
tar.extractall()
tar.close()
koolmrsam
  • 51
  • 4

1 Answers1

0

Are you running this as a local user? Is this running on Unix/Linux? Does the account running the python script have the appropriate rights to the folder you are attempting to write to?

Dan S.
  • 3
  • 2
  • This is on Mac OSX. I have running this script on same machine in the past. Now I want to add capability to extract tar.gz in the same script – koolmrsam Dec 24 '17 at 15:42