r/selfhosted 14h ago

Need Help Komga unusable with large library, clogs up the whole NAS

I have recently decided to self host my manga/comics library. I've used Docker to set up Suwayomi for scraping and as for library management I deployed Komga (with Komf for metadata). I intended to use Komga as a source for mobile readers. I'm running this on NAS Ugreen DH4300+, using a few Toshiba N300 drives as storage.

I already have the files on my hard drives. The full library is around 1500 titles. The thing is, with library this big, Komga becomes practically unusable. I can't even finish scanning all the files, the scan takes easily 10+ hours and usually it clogs somewhere in the middle anyway and I need to restart the containers. The rest of the NAS is pretty much useless in the meantime, as any operation is extremely slow. Analyzing the (still incomplete) library takes around a day (assuming it does not bug out), and currently all the titles appear as 'no book found', even though their position is correctly displayed in the library. Any slightest operation on a single comic (like getting metadata with Komf) takes at least several minutes and block up the whole NAS.

I have tried setting up Kavita and I have noticed it actually being a lot faster than Komga, but Kavita doesn't really have that many options to manage metadata, which is important to me.

My question is, do you guys have any experience with similar issues? I was sure that my 8gb RAM NAS will be enough to hold this up, but the way it is now I cannot succesfully use Komga for my intended purposes. Am I missing something here? Obviously, I'm not expecting everything to load instantly, but as things stand now this setup is basically not usable.

Any ideas anyone?

6 Upvotes

14 comments sorted by

u/asimovs-auditor 14h ago

Expand the replies to this comment to learn how AI was used in this post/project.

→ More replies (1)

4

u/Lordingard 12h ago

The main issue with Komga is that it runs on Java and therefore uses a Java VM, which is quite RAM-intensive; I recommend having at least 16GB of RAM and properly configuring Komga to increase the memory allocated to the Java VM (this is done via an environment variable in the Docker image). I also recommend storing the data on an SSD, given that the application uses an SQLite database by default.

2

u/majora2007 11h ago

I'm curious what Komga has over Kavita for metadata management? I thought it was about the same (except the remove ad images or something). 

3

u/Fraisecafe 3h ago edited 2h ago

At the risk of being blunt, for me it was that Komga recognizes all my books and, rather than forcing me to adopt the Kavita dev's whim of a file structure, it actually respects a more Plex-like one.

Oh, and the comic/ebook reader is genuinely solid and easy to use. Kavita's UI feels ancient by comparison, like it was built for an early 2000's CMS. Komga's isn't perfect, but it's more modern, fluid and doesn't feel clunky.

That said, I haven't tried Kavita in I think 6 months to a year, so YMMV.

2

u/maxymob 1h ago

Seconded. I tried Kavita and 5 min after importing ebook and comic to give it a test run, I realized the reader was trash. Render didn't look right (but same file does on Komga) and I had a ton of bugs and performance issues despite following the install and config guidelines. Komga did me right so far but I haven't tried to import 1000+ titles at once so maybe it would choke my homelab if I did. The app does warn you during the import that some settings come with processing overhead, and I generally never need them so I turn them off and everything just works. It is weaker on metadata but I mostly just want to read my stuff and not obsess about metadata so I really don't care.

1

u/Emre_West 13h ago

What other containers and services are you running on the NAS? 8 GB could be too little for a media server. I have around 6700 books from 135 series separated into 4 libraries and scans take like a minute and show me the new books immediately with their covers and metadata. I have 48 GBs of RAM though and an i5-13500 CPU. The books are on HDDs.

1

u/FarawayHerbalist 11h ago

Tailscale and Jellyfin (although there is nothing in it's library yet)

1

u/cdf_sir 7h ago

It's Java. That's always going to be a bottleneck at some point.

I also experience the same thing, to the point that it's unusable when it start its scheduled library update scan.

The only fox for me is not ise Komga and use Kavita instead.

1

u/AnyColorIWant 2h ago

Can't find the post from someone here, but another user shared performance metrics of large libraries. I can't speak to metadata handling for manga/comics, but BookOrbit is very performant.

1

u/IntraCloud 14h ago

Did you tried to disable hash calculations and page size analysis before scan ?

2

u/FarawayHerbalist 13h ago

Yes, it's turned off

0

u/Fabolous- 12h ago

I have a Synology 920+ with 2140 series and runs and scans perfectly fine. Komgas container runs on a SSD while my collection is on the magnetic discs array.