Installing mysql for digikam /resetting mysql user data

Ryan Schmidt ryandesign at macports.org
Fri Dec 13 10:11:37 PST 2013


On Dec 12, 2013, at 12:07, David Lyon wrote:

> To try to clarify my earlier e-mail. You kindly provided the following resource (http://userbase.kde.org/Digikam/Using_digiKam_with_MySQL) and suggested from the support page that the port was 3306.

Yes, 3306 is the default port for all MySQL servers ever.

> It may be but the date of that information was 3/14/11. Nonetheless, on that same page the illustration suggests that the Host Name is 192.168.1.11.

The author of the article is showing a screenshot of his configuration. On his network, his computer’s IP address happened to be 192.168.1.11. The author of the article cannot possibly know what the address of your computer is on your network. You need to fill in the correct IP address or hostname for the computer on your network that is running the MySQL server. If that’s the same computer that’s running digikam, you can use “localhost” or “127.0.0.1”.

> And as I said, I saw during my effort to install the mysql server that my DI was 10. Perhaps it was referring to something else but I assumed that it had generated the user-name for the new account.

MySQL usernames aren’t ever referred to as “IDs” so you must’ve seen something else. Perhaps you saw this message:

Your MySQL connection id is 10

If so, that’s a completely pointless piece of information that MySQL displays for some reason but that you don’t need to know and is not helpful to you.

MySQL doesn’t generate usernames. You can tell it to create a new user account with a specific name if you want to. Or you can configure digikam to use the existing “root” user and the password that you used when setting up the MySQL server, or the empty string if you did not set up a root password for MySQL.

> So I launched digikam and it seemed much more stable than ever before. I opened preferences and installed the newly acquired data-(Port 3306/Host Name 192.168.1.11/User ID 10/ Password [the one that was confirmed]. I quit digikam. The attempt to re open provided the error message:
> ash-3.2$ /Applications/MacPorts/KDE4/digikam.app/COntents/MacOS/digikam
> digikam(4634)/digikam (core) Digikam::AlbumWatch::connectToKDirWatch: KDirWatch method =  "FAM"
> digikam(4634)/digikam (core) Digikam::AlbumManager::setDatabase: DatabaseParameters: [ Type "QMYSQL", Name "digikam" (Thumbnails Name "thumbnails-digikam"); Host Name and Port: "192.168.1.11" 3306; Username and Password: "10", "selkirk"]
> digikam(4634)/digikam (core): Error while opening the database. Error details [ QSqlError(2003, "QMYSQL: Unable to connect", "Can't connect to MySQL server on '192.168.1.11' (60)") ]
> 2013-12-12 09:59:41.189 digikam[4634:507] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
> digikam(4634)/digikam (core): Error while opening the database. Error details [ QSqlError(2003, "QMYSQL: Unable to connect", "Can't connect to MySQL server on '192.168.1.11' (60)") ]
> QSqlDatabasePrivate::removeDatabase: connection 'ConnectionTest' is still in use, all queries will cease to work.

I’m not surprised it failed to connect to the server, since you didn’t provide the correct hostname or username.

> And now digikam will not open

Ah, that’s unfortunate. I’d figure out where digikam stores its preference files and delete them, then digikam should be able to open again. Then you can configure it properly.

> so I need to change some settings on the mysql server.

I doubt it. The MySQL server is probably running fine.

> Therefore I have been trying to find
> resources that will allow me to determine the HOST and PORT and confirm my user-name and pw. I was able to find the attached. I presume that by executing the proper code and sequence, one can access information on the mysql server. I have been trying various configurations but all seem to return me to the code page (attached-same one).
> 
> For example if I wanted to find the port : "from code page: -P, --port=#        Port number to use for connection or 0 for default to, in  order of preference, my.cnf, $MYSQL_TCP_PORT,  /etc/services, built-in default (3306)."
> 
> How would I format the request?
> sudo /opt/local/bin/mysqladmin5 -P --port#
> or
> sudo /opt/local/bin/mysqladmin5 -P, --port#      Etc-I have tried several sequences but the command and others using different codes for various discreet information from the code list only return me to the code page.
> 
> I am sorry that I have confused things but if I can modify correctly through the mysql server the critical account information, I think digikam will be operational. I have all the documentation which I have been through and could easily create a flow sheet to successfully install digikam on Mac OS 109 if that would be helpful.


On Dec 12, 2013, at 20:19, David Lyon wrote:

> I believe that I now understand the particulars to reinstall MacPorts and digikam successfully. I will un-install digikam and Macports and all associated dependences and reinstall in reverse order. Thank you for your support and if I can be helpful by providing a flow chart for installing digikam from scratch, on Mac OS 10.9., I will be happy to provide it.

Why uninstall anything? The ports seem to be installed correctly. You just need to configure digikam correctly to access the MySQL server.




More information about the macports-users mailing list