aetaric / checkrr

Checkrr Scans your library files for corrupt media and replace the files via sonarr and radarr
MIT License
184 stars 8 forks source link

"fatal error: runtime: out of memory" when scanning a directory with many files (1.1.0 on Ubuntu 20.04) #7

Closed Emstar closed 1 year ago

Emstar commented 1 year ago

After writing this I tried 1.1.1 and the issue is fixed! So, this can probably be resolved.


On doing checkrr check checkrr immediatly exits with "fatal error: runtime: out of memory". I was able to determine that this happens when checkrr tries to scan a folder where I have tons of video files.

The folder in question contains 547 video files, plus 8 folders each of which has a few video files.

checkrr did great scanning a directory that had over 1000 folders, each of them having a handful of subfolders and files.

I doubt it matters but the files were all mounted via smb sharing.

I THINK I am using v 1.1.0 because the release notes mention CSV output, which I have... And I started playing with it before the 1.1.1 release was available But, I don't see a --version command in checkrr so I can't be sure. I'll file that as an enhancement idea.

My config file is below and the complete error output is attached. Let me know if I can provide anything else.

checkpath:
- "/mnt/media/movies/"
lidarraddress: ""
lidarrapikey: ""
lidarrbaseurl: /
lidarrport: 8686
processlidarr: false
processradarr: false
processsonarr: false
radarraddress: ""
radarrapikey: ""
radarrbaseurl: /
radarrport: 7878
removeunknownfiles: false
sonarraddress: 127.0.0.1
sonarrapikey: ""
sonarrbaseurl: /
sonarrport: 8989
database: /var/lib/checkrr/checkrr.db
csvfile: /var/lib/checkrr/badfiles.csv

checkrr_kaboom.txt

aetaric commented 1 year ago

Yeah, pull down 1.1.1 and see if that works for you. 1.1.0 and earlier were memory hungry and your stacktrace is for an Out of Memory event. Kernel said checkrr couldn't have more RAM, so it panic'd. I'll look into #8 for the 1.2.0 release.

Emstar commented 1 year ago

1.1.1 worked great!

Apparently I don't have enough things to say about software during the workweek, I gotta do this too, haha. Looking forward to the updates.

aetaric commented 1 year ago

Apparently I don't write enough Golang during the work week lol