aonez / Keka

The macOS & iOS file archiver
https://www.keka.io
4.87k stars 241 forks source link

Error code 13 with unraring large files #362

Open chriselden opened 5 years ago

chriselden commented 5 years ago

Hi,

Everything is in the title!

using KEKA, on large files, i got this error code when i try to unrar them. it's 15 rar files of 5,5GB each.

I also noticed something strange. When i try to unrar with the Unrar X application, it telles me: not a rar files. which is really strange because other people succeed in unraring them all!

i got this problem only on large files and at every state of progress.. Something it happen at 5% after start sometimes 40% sometimes 55% etc... any time.

i try to unrar them on 4 différent HD on 2 different computers.

aonez commented 5 years ago

Hi @chriselden!

Can you enable the verbose mode on Keka, try again and let me know what the Console.app says? Full instructions in the link, you should enable both DevLog and DevLogReader:

defaults write com.aone.keka DevLog -bool true
defaults write com.aone.keka DevLogReader -bool true
chriselden commented 5 years ago

Hi

thanx for this so fast answer:)

the result is: (there is only the last lines inb the console app)

11:31:04.645561 +0100   Keka    Extraction output: 

Extracting  /Volumes/Download/sa/Orc/.Keka-4DFEC805-0C3B-44C0-9F55-61F4BC7B8B2C/Glo/S/A/ASk/altos_shakes_91-91_Eb4 - CLOSE1.ncw
11:31:04.682976 +0100   Keka    Extraction output: 
\^H\^H\^H\^H  0%
11:31:04.702744 +0100   Keka    Extraction output: 
\^H\^H\^H\^H\^H  OK
11:31:04.704273 +0100   Keka    Extraction output: 

Extracting  /Volumes/Download/sa/Orc/.Keka-4DFEC805-0C3B-44C0-9F55-61F4BC7B8B2C/Glo/S/A/ASk/altos_shakes_91-91_Eb4 - CLOSE2.ncw
11:31:04.737604 +0100   Keka    Extraction output: 
\^H\^H\^H\^H  0%
11:31:04.750137 +0100   Keka    Extraction output: 
\^H\^H\^H\^H\^H  OK
11:31:04.752047 +0100   Keka    Extraction output: 

Extracting  /Volumes/Download/sa/Orc/.Keka-4DFEC805-0C3B-44C0-9F55-61F4BC7B8B2C/Glo/S/A/ASk/altos_shakes_91-91_Eb4 - SPOT.ncw
13:07:56.122585 +0100   powerd  Process Keka.33264 Released PreventUserIdleSystemSleep "Extraction" age:01:37:57  id:4295009394 [System: DeclUser BGTask kDisp]
13:07:56.782426 +0100   Keka    done: 1
aonez commented 5 years ago

@chriselden Can you share the first lines too? Are those 15 files part of a volume, so it is a 82,5GB parted RAR? If so, be sure you have enough space in the destination HD. The resulting file might be well below 100GB, depending on the contents.

chriselden commented 5 years ago

oh i have to restart it to get the first lines. (but i think it's the same for each parts?) i will do it. yep the whole thing is about >100GB. i regularly have this kind of files. i have 6,2TB free on this HD

aonez commented 5 years ago

@chriselden if you give Keka Desktop file access (Keka - Preferences - File access -> Add your Desktop to the list) it will create a file named Keka-log.log in your desktop with all the future logs.

You can also try to extract the files using the terminal:

/Applications/Keka.app/Contents/Resources/kekaunrar x /THE_RAR_PATH.rar /YOUR_BIG_HDD_DESTINATION_PATH

Let me know what Keka-log.log &/or the Terminal operation says.

aonez commented 5 years ago

I forgot to ask if those files are public or you can share them with me?

chriselden commented 5 years ago

The first lines:

par défaut  16:03:33.852256 +0100   launchservicesd CHECKIN:0x0-0x119119 35285 com.aone.keka
par défaut  16:03:33.930947 +0100   Keka    Updating user defaults from 3248...
par défaut  16:03:33.933511 +0100   Keka    Dev mode enabled
par défaut  16:03:33.940778 +0100   Keka    Dev reader mode enabled
par défaut  16:03:33.942424 +0100   Keka    Running on OS X/macOS version 10.13.6 (assemblage 17G5019)
par défaut  16:03:33.944007 +0100   Keka    Running sandboxed Keka (MAS) version 1.1.11 (3248)
par défaut  16:03:33.946678 +0100   Keka    Used localization: fr
par défaut  16:03:34.096132 +0100   Keka    MessageTracer: load_domain_whitelist_search_tree:73: Search tree file's format version number (0) is not supported
par défaut  16:03:34.270079 +0100   Keka    Adding 1 files
par défaut  16:03:34.271988 +0100   Keka    Waiting for more input: 0.250000
par défaut  16:03:34.276879 +0100   Keka    Requesting access to all bookmarks...
par défaut  16:03:34.279638 +0100   Keka    Bookmarks updated: 3
par défaut  16:03:34.576041 +0100   Keka    Format detected: Rar
par défaut  16:03:34.655968 +0100   Keka    Binary used: kekaunrar
par défaut  16:03:34.657635 +0100   Keka    Arguments: (
    x,
    "-idcd",
    "-x*/__MACOSX",
    "-y",
    "/Volumes/Download/GD.BBH.5GB.part01.rar",
    "/Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB/"
)
par défaut  16:03:34.724852 +0100   Keka    Extraction output: 

Extracting from /Volumes/Download/GD.BBH.5GB.part01.rar
par défaut  16:03:34.726892 +0100   Keka    Extraction output: 

Creating    /Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB  OK
Creating    /Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB/G  OK
Extracting  /Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB/G/CAPSULE.nkc     \^H\^H\^H\^H  0%
par défaut  16:03:34.729051 +0100   Keka    Extraction output: 
\^H\^H\^H\^H\^H  OK 
Extracting  /Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB/G/CAPSULE.nkr     \^H\^H\^H\^H  0%
par défaut  16:03:35.183673 +0100   Keka            OSErr AERemoveEventHandler(AEEventClass, AEEventID, AEEventHandlerUPP, Boolean)(spec,phac handler=0x7fff39315a98 isSys=YES) err=0/noErr
par défaut  16:03:35.184519 +0100   Keka            OSErr AERemoveEventHandler(AEEventClass, AEEventID, AEEventHandlerUPP, Boolean)(ascr,gdut handler=0x7fff38265670 isSys=YES) err=0/noErr
par défaut  16:03:36.487814 +0100   Keka    Extraction output: 
\^H\^H\^H\^H\^H  OK
par défaut  16:03:36.800904 +0100   Keka    Extraction output: 

Creating    /Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB/G/Data  OK
par défaut  16:03:36.802934 +0100   Keka    Extraction output: 

Extracting  /Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB/G/br_arr.nka     \^H\^H\^H\^H  0%\^H\^H\^H\^H\^H  OK 
Creating    /Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB/G/Data/presets  OK
Extracting  /Volumes/Download/.Keka-2C021107-226C-4E75-88F0-A3B4251C17AB/G/Data/presets/1st Preset.nka     \^H\^H\^H\^H  0%
par défaut  16:03:36.804774 +0100   Keka    Extraction output: 
\^H\^H\^H\^H\^H  OK 

and the 2 last lines when i got error code 13:

ar défaut   16:05:43.159398 +0100   powerd  Process Keka.35285 Released PreventUserIdleSystemSleep "Extraction" age:00:02:08  id:4295010128 [System: PrevSleep DeclUser BGTask kCPU kDisp]
par défaut  16:05:43.246454 +0100   Keka    done: 1
chriselden commented 5 years ago

i can share it with you but in a private way

chriselden commented 5 years ago

i'm wondering if it's a problem because of APFS?

aonez commented 5 years ago

In the logs I don't see the error cause. I don't think it's because APFS, but could be. Can you send me a link to the files to info@keka.io?

chriselden commented 5 years ago

i have to upload it first... would take some times:)

aonez commented 5 years ago

Would be interesting to check the MD5 or SHA signature of this files, if the source shared them with you. Maybe some of those 15 parts are corrupted. This is common in downloaded parted files.

If you want to try the extraction with the Terminal, here the updated line with your real paths:

mkdir /Volumes/Download/ExtractionTest; /Applications/Keka.app/Contents/Resources/kekaunrar x /Volumes/Download/GD.BBH.5GB.part01.rar /Volumes/Download/ExtractionTest
chriselden commented 5 years ago

i'm extracting with terminal. I can check, but i am theoricaly sure the files are ok. Others users who took them from the same source, doesn't seems to get any problem. (or they don't tryed to unrar them? i can't believe that)

aonez commented 5 years ago

I mean that if you downloaded those files, maybe some were corrupted during the download process, so downloading them again will be needed. Maybe this will be quicker, just test the files:

/Applications/Keka.app/Contents/Resources/kekaunrar t /Volumes/Download/GD.BBH.5GB.part01.rar
chriselden commented 5 years ago

Great news!! it's 100% working when extracting with terminal!!

aonez commented 5 years ago

Glad to hear that! If you can share them with be will be very helpful to try to replicate the issue :)

On 5 Feb 2019, at 19:14, chriselden notifications@github.com wrote:

Great news!! it's 100% working when extracting with terminal!!

— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub, or mute the thread.

chriselden commented 5 years ago

ok i will upload them

ghost commented 5 years ago

I still have the same problem with the latest Keka v.1.1.12. It works after restarting the unrar process a couple of times.

aonez commented 5 years ago

@iDjay can you share the files that fail?

ghost commented 5 years ago

@aonez it's not a specific file, it happens on various files, but I'll send you the next file the issue appears!

aonez commented 5 years ago

Thanks @iDjay! That would be awesome :)

aonez commented 5 years ago

This bot is playing with me

aonez commented 5 years ago

@chriselden and @iDjay, if you find another file that reproduces this issue, please check if this build works and let me know:

Keka-unrar570.7z

chriselden commented 5 years ago

Hello

Nice! I’m going to try right away

chriselden commented 5 years ago

Hi There

Seems to work fine! No problem to unbar 4 bigs ones:) up to 60GB for one of them

chriselden commented 5 years ago

Hi,

i just got the issue again :( on 4 bigs .rar. I tryed a second time to unrar then it worked! on exactly the same files!

aonez commented 5 years ago

Thanks for the feedback @chriselden. It was again a parted RAR? If so, yo had to select all the parts when extracting? Or do you have file access in the folder containing all the parts?

chriselden commented 5 years ago

yes it's a parted on. 4 parts. i just clicked the first .rar. As i said the first time i got an error when reaching avbout 80-85%. THe second time i exactly did the same: i clicked on the first .rar only. Then 100% ok no error at the end of the unrar process.

chriselden commented 5 years ago

i noticed something strange but i have to try more to investigate this : when i try to use UnrarX on these .rar files it says: not a rar files!! i'm wondering if there is a problem with .rar format itself recently?

aonez commented 5 years ago

@iDjay do you recall if the times it failed was on parted RAR files?

@chriselden UnrarX does not get an update since 2006. RAR newest (current) format 5 was introduced in 2013, so it's normal that it fails.

yes it's a parted on. 4 parts. i just clicked the first .rar.

So you did not had to select the parts with a window similar to this one?

Screen Shot 2019-03-09 at 10 02 21

chriselden commented 5 years ago

no i do got any window

ghost commented 5 years ago

@aonez I've found new files which didn't work. How can I send you the dl links?

aonez commented 5 years ago

@iDjay info@keka.io. Thanks!

aonez commented 5 years ago

@iDjay thanks for the files, finally reproduced the issue. I think it will be fixed in 1.1.13, releasing it in 1-2 days. @chriselden and @iDjay let me know if you reproduce the issue in the future with that version. Thanks a lot for all the feedback!

chriselden commented 5 years ago

Good!!!! i LOVE Keka too much you have to fix it :)

aonez commented 5 years ago

Sadly reproduced the issue again 😤 I think the kernel is preventing (via sandbox) unrar to access the file randomly.

aonez commented 5 years ago

This is what I've got in the Console.app, although not always:

kernel  Sandbox: kekaunrar(31086) deny(1) file-read-data /Volumes/Disk/File.rar

Really strange, given that the process already had access to that file and the extraction already started.

ghost commented 5 years ago

Got the same issue now with a zip file. Do you need the file too @aonez ?

Sent with GitHawk

aonez commented 5 years ago

Sure! I’ve already reproduced it with a 7Z. It worked retrying?

ghost commented 5 years ago

Yes it worked, 2nd try

Sent with GitHawk

ghost commented 5 years ago

Still happening even with 20mb files

Sent with GitHawk

aonez commented 5 years ago

Do you restart the Mac with frequency? I’ve only replicated this issue when doing a lot of operations, without a restart.

ghost commented 5 years ago

@aonez restarting every day

Sent with GitHawk

aonez commented 5 years ago

I will rework the file access behavior in 1.2.0 version, let's see if that helps fixing this rare issue.

chriselden commented 5 years ago

Hi again, on 1.1.14 i got code error 13 again. on .rar files any sizes. When it happen i run again the uncompress process then it's working. Seem's a little bit hazardous.

aonez commented 5 years ago

@chriselden (and @iDjay), could you try to remove all the File Access of Keka and then give it Full Disk Access (that would be selecting the macOS disk). Restart and just work with that from now on and let me know if it fails again.

File access should look like this:

Screen Shot 2019-04-23 at 11 35 01

ghost commented 5 years ago

@aonez it was set like in the screenshot before... what about system preferences -> security -> privacy -> file access?

Sent with GitHawk

aonez commented 5 years ago

system preferences -> security -> privacy -> file access

I've read about this one some time ago and found this was no useful, ~but will be worth trying~. @chriselden reported this one on 10.13, and that "Full Disk Access" feature appeared on 10.14 Mojave, so it's a no go. Also the process fails randomly not always 🤯

chriselden commented 5 years ago

i tryed to unrar a big archive (16 files 5,3GB each). Impossible always getting the problem randomly. I tryed with another app: "The Unarchiver" it worked 100%. No problem.

aonez commented 5 years ago

@chriselden do you also have Keka set as stated here? https://github.com/aonez/Keka/issues/362#issuecomment-485728553