Mac OS: Unable to expand zip file

Mac OS. I am unable to expand zip file. I have tried this: Unzip in Terminal:

  1. Open Terminal.
  2. Type unzip and a space, then drag/drop the zip file into the Terminal window.
  3. Press Enter and the zip file will be unzipped, storing all files on your computer.

When I try to open the zip file, it reads:

unable to expand (error 1- operation not permitted).

Online, p7zip seems to be recommended. Here are instructions:

You can install it via MacPorts or Homebrew with these commands, respectively:

sudo port install p7zip
brew install p7zip

Then, to unzip it, use:

7za x file.zip

Please explain the steps to enter this code, I don’t know what it means. But I am glad to learn a new thing!

1

11 Answers

The Mac Archive Utility doesn't allow you to unzip large files, use the command line.

unzip file.zip
1

I get a similar error with a zip file containing a very large file (5.5GB uncompressed). The error comes when I double-click on the file in the finder. That launches the MacOS Archive Utility, which is what gives the error. In my case it happens after it does the decompression, which takes quite a while.

Unable to expand "zip_file_name_here.zip" into "destination_folder_here".
(Error 1 - Operation not permitted.)

As it turned out, the uncompressed files were hidden away in a temporary directory, and they were fine, so it's some sort of sandbox error or something.

The easy solution for me: Download Stuffit Expander from the Mac App Store. It was able to deal with the file just fine.

1

I tried using Archive Utility but it was throwing the same error. Wasn't able to expand my file. I used another application (The Unarchiver) which is also free in Appstore. It works fine for me.

Sounds like you either don't have read permission on the zip file itself or write permission on the directory that is is contained in, which is where unzip is trying to create the files extracted.

just change the extension of the file to .RAR and expand it. It should uncompress the file without any problem. This error usually happens when a compression operation of a large folder is interrupted.

I had the same issue with a password protected .zip which may have something to do with it. I was able to open it with Keka but you can probably use any decent file archive tool / unzipper on the app store.

You can use The Unarchiver. Worked for me for a zip file generated with zip -r folder.zip folder on a Linux Machine.

I got this problem, when I was sent .zip from another macos computer. For some reason Macos includes hidden _MACOSX folder with duplicated hidden meta files. When I cleared this folder from archive with help of Winrar, it unarchived normally.

had the same problem used the following command to unzip it:

ditto -V -x -k --sequesterRsrc --rsrc FILENAME.ZIP DESTINATIONDIRECTORY

found this solution here

The issue for me was that I had zipped the files at a relative location with double dots i.e. I'd run zip -r zipfile_name.zip ../relative/path/to/folder. Recreating the zip but using an absolute path solved my problem e.g. zip -r zipfile_name.zip /absolute/path/to/the/same/folder.

unzip file.zip

works but where do the files go? They are in users/your_user_name/ Unless you cd first to another directory. To get the path to file.zip just drag it into the terminal window. Stuffit Expander also worked for me.

1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like