You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

unzip error 22: invalid argument

Upgraded to MacOS Catalina and now I cannot unzip any zipped file. I had no problems before. Also, moving the file or redownloading is not fixing it. Multiple files of different sizes failed. MacBook user here.

MacBook

Posted on Oct 13, 2019 10:08 PM

Reply
Question marked as Top-ranking reply

Posted on Feb 10, 2020 10:56 PM

Working solution: The Unarchiver is a free Zip/Unzip program for Mac which handles these files perfect in Catalina, it solved this issue for me. Good luck.


https://apps.apple.com/se/app/the-unarchiver/id425424353?mt=12

77 replies

Jan 19, 2020 12:56 PM in response to Mackytack

Mackytack wrote:

I'm not really sure I know what to do? Pretend i'm a kindergartener and walk me through it?


Please read through the thread.


Start at the original question and first post, read through the investigation and the findings, and see if any of that seems familiar to your particular case, then continue reading through the replies and to the “here’s how to use...” replies listing the various options and alternatives, and links to more info.


This including using add-on tools, and using the integrated ditto command line tool.


If you have questions after reading the thread and having more background on this, and the options available here, post’m up.


Jan 19, 2020 2:18 PM in response to Mackytack

Use one of the downloaded apps. That’ll probably be more comfortable for you.


The macOS command line is accessed using Terminal.app. That app is located in /Applications/Utilities Launch that.


Assuming your zip file foo.zip is in your home directory, assuming the file name contains no “special” characters such as spaces or quotes, and assuming you want to unpack it to the bar subdirectory under your home directory...


mkdir ~/bar
ditto -x -k  ~/foo.zip  ~/bar

Jan 20, 2020 4:03 AM in response to MrHoffman

One of what downloaded apps? You mean like ditto? Or are you telling me to type those commands into terminal? And will that automatically unzip ALL the files, or will I have to do each file/doc one at a time? As you can see, this is all very confusing, and most frustrating to me. I can't begin to tell you how SORRY and ANGRY I am about updating to catalina

Jan 20, 2020 4:20 AM in response to MrHoffman

Sooo, i've tried typing in these 2 command you gave...

mkdir ~/bar

ditto -x -k ~/foo.zip ~/bar

When I do the first one it says 'file exists', if I do the 'ditto' one, it says 'no such file or directory'

Either way, this means nothing to me. Nothing has changed. Am I supposed to highlight something?

I don't understand.

This all happened upon the update. I NEVER had ANY zipped files prior to the catalina update

Jan 20, 2020 11:27 AM in response to Mackytack

Okay, then this question is entirely unrelated to the rest of this thread.


Your Microsoft Office installation was Office 2011 or earlier, and all versions of Office prior to a middling-patched Office 2016 are so-called 32-bit apps, and are using older and now-deprecated interfaces, and are incompatible with Catalina.


You’ll need to purchase Office 2019, or acquire an Office 365 subscription, or use the free LibreOffice, and many Microsoft Office documents can be read and written using Apple iWork Pages, Numbers and Keynote.


You can find your existing and problematic 32-bit apps using a tool such as Go64. All of these existing 32-bit apps will have to be upgraded to more current and 64-bit apps, or replaced with different apps, or deprecated. Check with the developers of each of these various 32-bit apps for any available updates, upgrades, or alternatives.


Unzipping Office documents is not the path you want to be on.

Jan 27, 2020 10:26 AM in response to Mackytack

Mackytack wrote:

@Namronksly, I downloaded the 'unarchiver' and it's still not helping. When I click to open the file, the unarchiver (or previously windup) pops up for a moment and disappears. Not unzipping


Your issue is not related to the rest of this thread.


You need to acquire and install a current Microsoft Office package or subscription, or install a recent LibreOffice, or maybe use the Apple iWork apps


Office and some other tools use zip as a storage container.


If you have a current Microsoft Office for Catalina loaded or an analog, you will be able to open and process these documents.


If you do manage to unzip these Office files without using Office or an equivalent, you’ll still be left with a wad of Office internal data, and not a meaningful file.


Feb 4, 2020 1:16 PM in response to Chemostat

Look at https://docs.microsoft.com/en-us/windows/win32/intl/character-sets-used-in-file-names File names are handled differently on FAT FAT32 and NTFS in Windows.


Apparently, Windows handles non-Roman characters in file and path names on different file formats. This is probably the root of the problem. However, I don't think that Catalina has GUI zip/unzip tool. Nothing show up when I search for programs using LaunchPad. When I run unzip -v, I receive a message that I'm using InfoZip 6.00. From the dates I suspect that that came with Catalina. Are you saying that it works from CLI but not with GUI. By GUI, do you mean double clicking on file in finder. If so, do Get Info on the file and see what the default tool is. If the default tool is a third party tool that wasn't from Apple, you may need to change the default tool. That's what MrHoffman was referring to.


Using the which command for zip and unzip commands in the CLI will tell you which program the shell is looking at zip -v and unzip -v will give you information on the source of this program.


The fact that a program is 64 bit does not mean that it will run correctly in Catalina. If you are using old third party programs, strange things can happen.


If you have a method that works with CLI, list what you entered as a command and use the zip -v and unzip -v to determine which version the CLI is using. By the way, unzip -v also gives the name of the person to send bug reports to. zip and unzip are not supplied by Apple but by the UNIX community.



Feb 10, 2020 9:10 AM in response to STremby

STremby wrote:

Unable to unzip using the native zip utility. I'm attempting to unzip a file of text files. Never had this problem before Catalina.


1: read the whole thread. You’ll see how I debugged the details of the particular case being reported here, too.

2: What error messages shown, background and details, zip and unzip versions, sequences used, what have you tried?

Feb 29, 2020 7:31 PM in response to 215HurriKaneDJ

215HurriKaneDJ wrote:

I get the error 22: invalid argument when trying to unpack zip files that I downloaded from an application called mediafire.


Contact the Mediafire support folks, and apprise them of the error, and a pointer to this thread. Unless you want to read through this thread. And given whatever this is is clearly failing on Catalina, there may well other problems awaiting with this kit.

Mar 17, 2020 12:47 AM in response to Chemostat

mine works fine with .zip files


i used Apples archive tool and have zero "3rd party apps" installed. worked one click no problem: it created a folder right next to the file for me to browse into (NOTE: your new filesystem is not case sensitive - keep in mind some archives cannot extract correctly if they are from a case sensitive OS and or try to set OS bits on files)


you've may have installed a 3rd party "multi-archive aware" app that "changed the arguments to zip". it is not the "freeware zip" and does not have the same arguments. also "freeware" apps might use "high" compression methods that apple's doesn't have (meaning and old GPL linux or pkzip .zip file does work in Catalina)


just change the plist or icon for zip so there is no argument mismatch ?


Mar 17, 2020 1:06 AM in response to QuietMacFan

QuietMacFan wrote:

mine works fine with .zip files

i used Apples archive tool and have zero "3rd party apps" installed. worked one click no problem:


Many zips work just fine.


It’s the compatibility of some that’s at issue...


If it wasn’t one of the zips you’ve tested here, download the problematic zip from earlier in this thread, and try that.


Assuming that zip is still posted.


Also post your Catalina version, in the off chance this has been patched recently.

unzip error 22: invalid argument

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.