I switched to Pop!_OS earlier this year from Manjaro KDE. One feature that KDE had is that you could write a comment on any file by clicking Properties and going to the metadata. I assumed that this wrote the comment into the metadata of every file and that this would translate over to other distributions, but it doesn’t appear to be the case.
I found this old thread from 2012 which said that KDE stores it’s comments in ~/.kde/share/apps/nepomuk/. If that’s still true today, I’m really worried now that all of that comment data I spent hours writing has been deleted along with Manjaro, because I had no idea that the data wasn’t store inside the file itself, since it was always listed with the rest of the metadata for every file in it’s properties. Is there no hope of me getting these comments back, or is there some way?
Update: Despite what that old thread seemed to imply, it turns out the comments do in fact get stored in metadata. After getting help in the comments, I found the easiest solution was to simply install Dolphin (KDE’s file manager) into Pop!_OS, which allowed me to view the comments just as they were when I used KDE. For future readers, some other options that I didn’t try that probably also work are:
- Load a Linux distro using KDE into a virtual machine on top of Pop!_OS and view comments that way
- Flash a distro like KDE Neon onto a live USB and view the comments that way
- Use the command
getfattr FILENAME -n user.xdg.comment
to view the comment data within the Pop! terminal (I didn’t get this working, but this was suggested to me)
Those comments are not lost, the nepomuk (later baloo) is only a indexing service that scrape the file metadata for search purposes.
The attributes are actually stored inside the files in file metadata supported by filesystem. So If those original files still reside in their original filesystem (they ware not like moved to different filesystem that doesn’t support those attributes or like compressed (into zip that probably would not retain those metadata)) you can read it.
I did some local digging into it and after searching whole drive while not finding the content of the comment, after searching some filesystem docs, found a explanation at https://en.wikipedia.org/wiki/Extended_file_attributes
You can read them using:
like
getfattr test.txt -n user.xdg.comment
It sounds like you move those files directly from Linux FS to Linux FS, so they should be preserved (might not be if copied).
But I think if those comments are important, you should still have them stored in some markdown file next to them to avoid losing them if you move them accidentally to a Filesystem that doesn’t support Extended file attributes or the “tool” that you are going to use instead of attributes goes away.
Thanks, I’ll try to do this tomorrow. Do you think that loading Manjaro KDE or any other distro using KDE into a VM, and connecting my drive with the files to the VM would allow me to view the comments just as I previously could using KDE?
If you conmect and mount the whole drive (or at last whole partition) directly to the VM then yes. Before doing all that work, personaly I would just use the command to manually confirm the metadata is thereo on files you know that has comments. Or even simpler - boot a KDE neon (or any other KDE live disto) live from USB, and connect the drive.
But … Why not just install Dolphin file manager in your current distro? It should be as easy as installing any other package/app. You can have more than one file manager installed at a time.
Thanks so much for all the suggestions. I couldn’t figure out how to use the command because it was giving me errors (which is probably just something I did wrong). But I’ll try to figure that out for the sake of learning.
What did work for me, was downloading Dolphin (it looks so messes up in Cosmic though, lol) and the comments are absolutely there, thank God! So now I can recover them and I think I’m going to try to find an alternative solution for making these records that works easily across distros (because I don’t plan to stick with Pop! forever)