Closed VegethB closed 3 years ago
Your logs don't show anything abnormal.
Is the drive where you store your libraries a network drive, or an external drive?
Is the drive where you store your libraries a network drive, or an external drive?
Internal Sata 2.5". The problem is that if it were HDD I would have problems all over the server (that disk holds all the server and app data to get the server going ... Ex: Plex, Emby, Sonarr, Minecraft, IIS, WebMail etc,) if it was broken or with bad sectors I would immediately notice the problem (I would be told by those who use these services, as well as the raid software would immediately report the damage). The only hypothesis from a person who does not know anything about it ... While he was managing the tags table, the power went out and being seen as corrupt it was reset (opening the .sqlite the book_tags table is empty ... in fact there is no a tags in my library). What I don't understand is why instead all the saved tags have disappeared and some have ended up in the list of actual tags (when they are tags for genres). I had also activated the backup but the folder is empty (I probably had to remove ""). The fact is that now I do not save the tags and that in any case regardless ... I have to redo all the tags of each book from scratch (I have not lost only tags, also the descriptions, been in progress / concluded. In practice, it is like if I had put new books without metadata.If the db had been reset I would no longer have users and libraries, things that are the only ones left together in the collections.
Restarting now saves me the new tags ... in the end I still lost descriptions, tags and read statuses. More old logs: https://mega.nz/folder/YotSnZ7C#MZ1crLnVInPurRWJ1FtiVA
To come back to your initial problem :
In addition, the backup entry in the configuration is deprecated since v0. 48.0. If you need backups you can use whatever software you like to perform the backups of the database.
I understand that you know have a normal behavior, even though you lost some of the data you added. There's nothing that can be done about that, unless you did some backups of the database by yourself.
- logs don't show any issues, so there's no way to know what happened to your book tags
But I saw the logs and they are full of spam from the "delete library of files no longer present" (that should be reduced or removed from the info, for me it should be redone and put in a weekly scheduler where every week on Sunday from 3 to 7 ago start all the tasks to clean / optimize the database, for example. As for plex, the management tasks must not be spam every 3 hours but periodically every 7 or as many days as you like, settable from the config). This is why I said before that in my opinion he dropped / reset the table in use with the power-loss. But checking the DB some metadata (only 4 6 out of 320 books) remained (such as author / description) as if the DB had regressed the first few times I used Komga with those 20 30 manga in the library. In short, something happened but we are not understanding how it happened 😵🙃😥.
- the tag list is generated on the fly from tags on the items (books or series). So if no books have tags anymore, the list of tags will subsequently only show existing tags.
- you mention tags moving from Genre to Tags, but Genre is a Series metadata, and you mentioned books. Can you clarify that part?
Simply some tags of the genres (action, manga, fantasy) ended up in the list of tags (gore, only male protagonist, swordplay, magic etc.) but by now I have solved it by cleaning the .sqlite by hand and starting practically from 0.
I want to specify one thing: It does not want to be a comment of insults / outbursts but only of clarification and possible feature request.
But I saw the logs and they are full of spam from the "delete library of files no longer present"
Indeed, that was in your "old" log. Next time try to pinpoint logs that are meaningful, i don't necessarily have the time to skim through thousands of lines of log.
I think there is a regression introduced from that change, where before the scanner would throw an exception if the library path was not reachable, while now it swallows the exception and returns 0 Series, hence deleting the whole library.
I have created #392 to track that problem.
As to what happened, clearly your folders where not accessible when the scan happened:
2021-01-16 16:45:06.099 WARN 16224 --- [DefaultMessageListenerContainer-1] o.g.k.domain.service.FileSystemScanner : Could not access: G:\folder\IMG\Manga-Hentai\RaMa
The deletion is a normal process, but there is a feature request for a trash bin, to handle such cases. See #217.
Why not everything was wiped ? In the logs i can see only 6 of your libraries were not accessible, and wiped. Those libraries seemed to be on your G:\
drive. The ones on your I:\
and H:\
drives were accessible, and not wiped. That explains why some data was still there.
I don't understand why the server has to delete tags if they are not associated with anything
Tags are not stored in a tags table. They are denormalized and stored per book or series. When you delete a book or series, the associated tags with that book/series are deleted, as any other metadata, and thumbnail.
it does not make sense.Because if I move things, he instantly deletes any associated metadata.
See #217.
It does not want to be a comment of insults / outbursts but only of clarification and possible feature request.
No problem, thanks for clarifying. English is not my primary language, and it doesn't seem to be yours either. Hope i managed to clarify what happened.
Indeed, that was in your "old" log. Next time try to pinpoint logs that are meaningful,
ALL logs are like this. That's why I sent them all. I too lost 4 hours reading them all on visual studio. What I wanted to point out is that that "scann" is spammed to the point of filling 95% of the logs of that text. I think it is better to find a way to decrease the output of that spam. Example if it finds no problems (0 changes) then it is not written to the output. Obviously thanks to visual studio it was easy for me to tell him to delete all that spam from the logs. That's all.
Tags are not stored in a tags table. They are denormalized and stored per book or series. When you delete a book or series, the associated tags with that book/series are deleted, as any other metadata, and thumbnail.
And that's a problem though ... Why is there no tags table? I don't understand the disadvantages compared to putting tags in a random book that if one day I delete, I lose that tag too. In fact with problem #392 here is the devastating combo: 70-90 lost tags.
In this case I open a new issue as a feature request to ensure that the tags are saved in a dedicated table and that table is used by komga when it has to suggest the tags. I assume the advantage of the current system (I haven't tried, so I might be wrong) is that you show all tags used only in that library (so you don't see tags used in other libraries). Otherwise, honestly, I don't understand the benefit.
One solution is to create 2 tables for the 2 Genres: Table1 Book: Table1-1 Genres Table1-2 Tags
Table2 Series: Table1-1 Genres Table1-2 Tags
and then populate the tables when I add the tags in the various sections in the meta. Example: I add Fantasy and action in the genres of a series and swordplay, male protagonist in its tags: These tags are added with a unique ID (which will be used to recall them in the future and associated with the metadata of the books / series) to their respective tables.
Table 1-1 Genres (in Table2 Series table) ID: | Name 55 | Fantasy 56 | action
and so when in a new book / series I go into the genre tags, if I click on the suggestion "Fantasy", that metadata is added in the tags_generi category ID 55 (which komga will then display as Fantasy).
It's a guess, surely you will know how to use a better method.
Anyway, thank you for the support and patience to keep up with me 👍
Komga environment
jar
Describe the bug
I start Komga after a power loss and ALL tags have disappeared from the books. Furthermore, the tag list is as if it had been brought back to the very first time (with only 10 15 selectable tags). If I add new tags they are NOT added and the selectable ones have been moved from the "genre" list to the normal Tag list. HDD where Komga resides (.sqlite etc) has NO problems.
Log file
https://mega.nz/folder/Yp90lCoD#_blS-pbWggrMv-Bhp5gkGg