Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: Colord: mapping.db not found (Read 1576 times) previous topic - next topic
0 Members and 4 Guests are viewing this topic.

Colord: mapping.db not found

Hi,
Artix/Plasma/runit, I'm trying to use colord with colord-runit and colord-kde (I also installed the ICC profile for my monitor through Plasma).

Colord does not start at boot, with the error:
Code: [Select]
CdMain: failed to load mapping database: Can't open database: unable to open database file

Tried to run it manually with sudo chpst -u colord /usr/lib/colord --verbose, I got:
Code: [Select]
Verbose debugging enabled (on console 1)
CdMappingDb: trying to open database '/var/lib/colord/mapping.db'
CdMain: failed to load mapping database: Can't open database: unable to open database file

Then I checked, and the directory /var/lib/colord does not exist, searched for a mapping.db file on the whole filesystem and it does not exist, so... How am I supposed to create it?

I can't use colormgr because, as colord isn't running, it fails with the error
Code: [Select]
No connection to colord: Error calling StartServiceByName for org.freedesktop.ColorManager: Launch helper exited with unknown return code 1

Re: Colord: mapping.db not found

Reply #1
opened pamac and searched for colord.  colord does not provide a file on install to that location or such a named file db.  Same is true for colord-runit and colord-kde.



You didn't install one of these from the aur?  Nothing in the repos for artix should even be installed to such a directory or such a db file.

have you installed arch repos maybe and put them in pacman.conf out of order?
Cat Herders of Linux

Re: Colord: mapping.db not found

Reply #2
opened pamac and searched for colord.  colord does not provide a file on install to that location or such a named file db.  Same is true for colord-runit and colord-kde.
Ok, so how should I generate this file/otherwise solve the error?

You didn't install one of these from the aur?  Nothing in the repos for artix should even be installed to such a directory or such a db file.
None of these packages is from the AUR


have you installed arch repos maybe and put them in pacman.conf out of order?

No (?)

Config below
Spoiler (click to show/hide)

Re: Colord: mapping.db not found

Reply #3
you could open a terminal and create the path and the file as root user but i wouldn't expect much from that.  Crazy as it sounds it might just work.

If you use pamac you could look and see what repo you installed colord and the others from.  My first thought is you installed something from a repo other than artix.
Cat Herders of Linux

Re: Colord: mapping.db not found

Reply #4
you could open a terminal and create the path and the file as root user but i wouldn't expect much from that.  Crazy as it sounds it might just work.

Tried, didn't work:
Code: [Select]
Verbose debugging enabled (on console 1)
CdMappingDb: trying to open database '/var/lib/colord/mapping.db'
CdMappingDb: creating table to repair: no such table: mappings
CdMappingDb: altering table to repair: no such table: mappings
CdMappingDb: altering table to convert: no such table: mappings_v2
CdMain: failed to load mapping database: Failed to migrate mappings: SQL error: no such table: mappings

If you use pamac you could look and see what repo you installed colord and the others from.  My first thought is you installed something from a repo other than artix.

I configured the repositories as in the wiki, so that Artix ones take precedence , and apparently Colord is not in Artix repos. I checked with Octopi, and colord has been installed from Arch's extra repository

EDIT: colord is in Artix repos and I reinstalled it from world, but the problem is the same

Re: Colord: mapping.db not found

Reply #5
search the web for the error
Code: [Select]
CdMappingDb: trying to open database '/var/lib/colord/mapping.db'
and see what you find?


Also, diod you reboot after installing colord?
Cat Herders of Linux

Re: Colord: mapping.db not found

Reply #6
search the web for the error
Code: [Select]
CdMappingDb: trying to open database '/var/lib/colord/mapping.db'
and see what you find?

Nothing useful, as most question do not have a reply, or are related to an existing but corrupted mapping.db, while here I don't have such a file nor I do find instructions on how to create it

Re: Colord: mapping.db not found

Reply #7
did you try rebooting after installing colord?
Code: [Select]
https://github.com/clearlinux/distribution/issues/1374
Perhaps the error is with artix after all?  Maybe the app wasn't built properly since the files it generates don't include the db file?  But according to the post above it seems colord is making the file when it runs as someone had a corrupted file and deleted it in order to fix the corrupted file.
Cat Herders of Linux

Re: Colord: mapping.db not found

Reply #8
did you try rebooting after installing colord?

Yes, same results as above

Perhaps the error is with artix after all?  Maybe the app wasn't built properly since the files it generates don't include the db file?  But according to the post above it seems colord is making the file when it runs as someone had a corrupted file and deleted it in order to fix the corrupted file.
I'll open an issue

Re: Colord: mapping.db not found

Reply #9
Additional detail: now I remembered that I had to create the folder manually, as at first it gave Error creating directory /var/lib/colord: Permission denied, so I tried to chmod 777 the folder and now colord works.

Obviously it is NOT a solution, but a workaround, I'll have to understand what's happening

Re: Colord: mapping.db not found

Reply #10
i was just about to assert this is a permissions issue
Code: [Select]
hp-i7:[catherdersoflinux]:~/Desktop$ /usr/lib/colord --verbose
14:14:45 Verbose debugging enabled (on console 1)
14:14:45 CdMain: failed to load mapping database: Error creating directory /var/lib/colord: Permission denied
hp-i7:[catherdersoflinux]:~/Desktop$ mkdir /var/lib/colord
mkdir: cannot create directory ‘/var/lib/colord’: Permission denied
hp-i7:[catherdersoflinux]:~/Desktop$ sudo mkdir /var/lib/colord
[sudo] password for catherdersoflinux:
hp-i7:[catherdersoflinux]:~/Desktop$ /usr/lib/colord --verbose
14:15:30 Verbose debugging enabled (on console 1)
14:15:30 CdMappingDb: trying to open database '/var/lib/colord/mapping.db'
14:15:30 CdMain: failed to load mapping database: Can't open database: unable to open database file

you beat me to the punch

Code: [Select]
hp-i7:[catherdersoflinux]:~/Desktop$ sudo chmod 777 /var/lib/colord
hp-i7:[catherdersoflinux]:~/Desktop$ /usr/lib/colord --verbose
14:18:07 Verbose debugging enabled (on console 1)
14:18:07 CdMappingDb: trying to open database '/var/lib/colord/mapping.db'
14:18:07 CdMappingDb: creating table to repair: no such table: mappings
14:18:07 CdMappingDb: altering table to convert: no such table: mappings_v2
14:18:07 CdDeviceDb: trying to open database '/var/lib/colord/storage.db'
14:18:07 CdDeviceDb: creating table to repair: no such table: devices
14:18:07 CdProfileDb: trying to open database '/var/lib/colord/storage.db'
14:18:07 display card0-DP-2 has ID 'xrandr-UW40T2BW-7041Y22902679' from MD5 4fc175d95554ba7e4ae4707e1f8c28fe
14:18:07 searching for plugins in /usr/lib/colord-plugins
14:18:07 run cd_plugin_initialize on /usr/lib/colord-plugins/libcolord_sensor_scanner.so
14:18:07 finished cd_plugin_initialize
14:18:07 run cd_plugin_initialize on /usr/lib/colord-plugins/libcolord_sensor_camera.so
14:18:07 finished cd_plugin_initialize
14:18:07 System vendor: 'Hewlett Packard', System model: 'HP EliteDesk 800 G3 SFF'
14:18:07 CdMain: lost name: org.freedesktop.ColorManager
14:18:07 run cd_plugin_destroy on /usr/lib/colord-plugins/libcolord_sensor_scanner.so
14:18:07 finished cd_plugin_destroy
14:18:07 run cd_plugin_destroy on /usr/lib/colord-plugins/libcolord_sensor_camera.so
14:18:07 finished cd_plugin_destroy

verified your error and solution fwiw
Cat Herders of Linux


Re: Colord: mapping.db not found

Reply #12
Additional detail: now I remembered that I had to create the folder manually, as at first it gave Error creating directory /var/lib/colord: Permission denied, so I tried to chmod 777 the folder and now colord works.

Obviously it is NOT a solution, but a workaround, I'll have to understand what's happening

Artix Devs will create the fix.  Clearly colord needs to write to a directory it doesn't have permissions for.  They can do that and rebuild the package.  Meanwhile everyone has your workaround thanks to your efforts.
Cat Herders of Linux

Re: Colord: mapping.db not found

Reply #13
Artix Devs will create the fix.  Clearly colord needs to write to a directory it doesn't have permissions for.  They can do that and rebuild the package.  Meanwhile everyone has your workaround thanks to your efforts.

Thank you, is there a procedure to notify the devs?

By the way, I want to highlight that probably this is not the best solution, 777 permission should be used with caution...

 

Re: Colord: mapping.db not found

Reply #14
Thank you, is there a procedure to notify the devs?

By the way, I want to highlight that probably this is not the best solution, 777 permission should be used with caution...


Code: [Select]
https://forum.artixlinux.org/index.php/topic,814.msg19119.html#msg19119
Cat Herders of Linux