Digikam/Using digiKam with MySQL: Difference between revisions
(Marked this version for translation) |
m (add tags) |
||
(One intermediate revision by the same user not shown) | |||
Line 19: | Line 19: | ||
<!--T:6--> | <!--T:6--> | ||
Enter the IP address of your '''MySQL''' server in the Host Name field and specify the correct port in the Port field (the default port is 3306). In the Schema Name field, enter the name of the database for storing photo metadata, and specify the name of the database for storing thumbnails in the Thumbnails Schema Name field. Enter your '''MySQL''' user name and password in the appropriate fields. To check whether the database connection works properly, press the <menuchoice>Check DB Connection</menuchoice> button. If everything works as it’s supposed to, switch to the <menuchoice>Collections</menuchoice> section, and add the directories containing your photos. Hit <menuchoice>OK</menuchoice>, and wait till '''digiKam''' populates the databases with data from photos. This can take a while if you have a lot of photos. | Enter the IP address of your '''MySQL''' server in the <menuchoice>Host Name</menuchoice> field and specify the correct port in the <menuchoice>Port</menuchoice> field (the default port is 3306). In the <menuchoice>Schema Name</menuchoice> field, enter the name of the database for storing photo metadata, and specify the name of the database for storing thumbnails in the <menuchoice>Thumbnails Schema Name</menuchoice> field. Enter your '''MySQL''' user name and password in the appropriate fields. To check whether the database connection works properly, press the <menuchoice>Check DB Connection</menuchoice> button. If everything works as it’s supposed to, switch to the <menuchoice>Collections</menuchoice> section, and add the directories containing your photos. Hit <menuchoice>OK</menuchoice>, and wait till '''digiKam''' populates the databases with data from photos. This can take a while if you have a lot of photos. | ||
Line 27: | Line 27: | ||
<!--T:8--> | <!--T:8--> | ||
If you are already using '''digiKam''' with '''SQLite''', you can use the database migration tool to move the existing data to '''MySQL''' databases. Choose <menuchoice>Tools -> Database Migration</menuchoice>, and select the <menuchoice>MySQL</menuchoice> item in the <menuchoice>Type</menuchoice> drop-down list in the right section. Fill out the required fields as previously described, and use the <menuchoice>Check DB Connection</menuchoice> button to test the connection. Finally, press the <menuchoice>Migrate</menuchoice> button to copy the data from <menuchoice>SQLite</menuchoice> to < | If you are already using '''digiKam''' with '''SQLite''', you can use the database migration tool to move the existing data to '''MySQL''' databases. Choose <menuchoice>Tools -> Database Migration</menuchoice>, and select the <menuchoice>MySQL</menuchoice> item in the <menuchoice>Type</menuchoice> drop-down list in the right section. Fill out the required fields as previously described, and use the <menuchoice>Check DB Connection</menuchoice> button to test the connection. Finally, press the <menuchoice>Migrate</menuchoice> button to copy the data from <menuchoice>SQLite</menuchoice> to <menuchoice>MySQL</menuchoice>. | ||
<!--T:9--> | <!--T:9--> |
Latest revision as of 17:52, 14 March 2011
Using digiKam with MySQL
Transcribed from Dmitri Popov's blog, 15 October 2010
By default, digiKam uses SQLite as its back-end for storing important metadata and thumbnails. But the photo management application also provides support for the popular MySQL database engine, and it comes with a database migration tool that can help you to move your data from SQLite to MySQL. Of course, you might wonder why you’d want to switch to MySQL when SQLite already does a good job of managing the data? Using MySQL as digiKam’s database back-end allows you to store the data on a remote server. This way, you can use multiple digiKam installations (e.g., on your notebook and desktop machine) to access and manage your photo collections. You can also use MySQL tools to back up and analyze digiKam’s data.
Obviously, to use digiKam with MySQL, you need a MySQL server. You also have to create two MySQL databases: one for storing photo metadata (e.g., digikam) and the other for storing thumbnails (e.g., thumbnails-digikam). And before you proceed, note the database connection information such as MySQL server address, user name, and password — you’ll need it when configuring MySQL settings in digiKam.
There are two ways to switch digiKam from SQLite to MySQL. If you’ve just installed digiKam, and you haven’t yet added any collection to it, choose
, and switch to the section. Select the item from the drop-down list.
Enter the IP address of your MySQL server in the field and specify the correct port in the field (the default port is 3306). In the field, enter the name of the database for storing photo metadata, and specify the name of the database for storing thumbnails in the field. Enter your MySQL user name and password in the appropriate fields. To check whether the database connection works properly, press the button. If everything works as it’s supposed to, switch to the section, and add the directories containing your photos. Hit , and wait till digiKam populates the databases with data from photos. This can take a while if you have a lot of photos.
If you are already using digiKam with SQLite, you can use the database migration tool to move the existing data to MySQL databases. Choose , and select the item in the drop-down list in the right section. Fill out the required fields as previously described, and use the button to test the connection. Finally, press the button to copy the data from to .