PDA

View Full Version : Can't connect to database



gariac
2007-09-03, 15:58
I am running Suse 10.2 64 bit. When I launch slimserver, here is the result:
================
gariac@susususe:/usr/local/src/slimserver/SlimServer_v6.5.4> ./slimserver.pl --d_server
2007-09-03 15:42:47.4847 SlimServer OSDetect init...
2007-09-03 15:42:47.4849 SlimServer OS Specific init...
2007-09-03 15:42:47.4850 SlimServer saving pid file.
2007-09-03 15:42:47.4851 SlimServer settings effective user and group if requested...
2007-09-03 15:42:47.4852 SlimServer settings init...
2007-09-03 15:42:47.4898 SlimServer strings init...
2007-09-03 15:42:47.6300 SlimServer Setup init...
2007-09-03 15:42:47.6373 SlimServer setting language...
2007-09-03 15:42:47.6376 SlimServer MySQL init...
070903 15:42:47 [ERROR] Error message file '/usr/local/src/slimserver/SlimServer_v6.5.4/MySQL/errmsg.sys' had only 463 error messages,
but it should contain at least 472 error messages.
Check that the above file is the right version for this program!
070903 15:42:47 [ERROR] Aborting

2007-09-03 15:43:17.8673 ERROR: MySQLHelper: createSystemTables() Couldn't connect to database: [Can't connect to local MySQL server through socket '/home/gariac/Cache/slimserver-mysql.sock' (2)]

2007-09-03 15:43:17.8681 Got to the END.
2007-09-03 15:43:17.8682 Got sigint.
2007-09-03 15:43:17.8683 SlimServer cleaning up.
==============
The relevant (I guess!) part of the configuration file is:
-------------------
dbpassword: ''
dbsource: dbi:mysql:hostname=127.0.0.1;port=9092;database=%s
dbusername: slimserver
disableStatistics: 0
disabledextensionsaudio: ''
disabledextensionsplaylist: ''
disabledplugins: []
----------------------

Suggestions?

mherger
2007-09-03, 23:32
> 070903 15:42:47 [ERROR] Error message file
> '/usr/local/src/slimserver/SlimServer_v6.5.4/MySQL/errmsg.sys' had only
> 463 error messages,
> but it should contain at least 472 error messages.
> Check that the above file is the right version for this program!

I think that's a version conflict or something. I can't remember where,
when and why exactly I encountered this before, though. :-(

How did you install SlimServer? Make sure it's really using its own MySQL
and not another one installed on your system.

--

Michael

-----------------------------------------------------------------
http://www.herger.net/SlimCD - your SlimServer on a CD
http://www.herger.net/slim - AlbumReview, Biography, MusicInfoSCR

gariac
2007-09-04, 12:38
I used the tarball. I know zip about perl and mysql, so I'm at a loss here. I believe the default is NOT to use an existing MySQL installation.

I did install MySQL, though I haven't gotten around to using it.

Mark Miksis
2007-09-04, 13:24
This is a known bug. Slimserver only ships with an i386 version of mysqld. On an x86_64 system it will usually find and launch it's own instance of the 64-bit mysqld binary on the system. The error is because your Suse box has a newer version of mysqld but slimserver is using it's older copy of errmsg.sys. The easiest fix is to find your system's copy of errmsg.sys (probably in /usr/share/mysql/english) and copy it over the one in the slimserver MySQL directory.

4mula1
2007-09-04, 15:39
I used the tarball. I know zip about perl and mysql, so I'm at a loss here. I believe the default is NOT to use an existing MySQL installation.

I did install MySQL, though I haven't gotten around to using it.

You will need to manually configure MySQL then. See ExistingMySQLInstance in the Wiki. I installed SlimServer on Solaris using the tarball and I used that to configure SlimServer. Take a look at the SolarisInstallationGuide for a good look at installing from the tarball. It's Solaris-centric but you'll figure it out.

gariac
2007-09-05, 00:31
You will need to manually configure MySQL then. See ExistingMySQLInstance in the Wiki. I installed SlimServer on Solaris using the tarball and I used that to configure SlimServer. Take a look at the SolarisInstallationGuide for a good look at installing from the tarball. It's Solaris-centric but you'll figure it out.
-----------

I tried to follow the instructions as best as I could. In suse, you need to enable the mysql service. That is, you can install it, but that doesn't mean it is running. I got mysql running and tried to follow the instructions. As a side note, it would help if user specific fields were italics. I assume the only thing I had to change was 'slimserver_password" and the admin user name.

Here is the current result:
------------------------
gariac@susususe:~> /usr/local/src/slimserver/SlimServer_v6.5.4/slimserver.pl --d_server --d_info --d_import --d_sql --d_mysql
2007-09-05 00:04:31.8515 SlimServer OSDetect init...
2007-09-05 00:04:31.8517 SlimServer OS Specific init...
2007-09-05 00:04:31.8518 SlimServer saving pid file.
2007-09-05 00:04:31.8519 SlimServer settings effective user and group if requested...
2007-09-05 00:04:31.8520 SlimServer settings init...
2007-09-05 00:04:31.8567 SlimServer strings init...
2007-09-05 00:04:31.9965 SlimServer Setup init...
2007-09-05 00:04:32.0036 SlimServer setting language...
2007-09-05 00:04:32.0039 SlimServer MySQL init...
2007-09-05 00:04:32.0042 MySQLHelper: createConfig() Creating config from file: [/usr/local/src/slimserver/SlimServer_v6.5.4/MySQL/my.tt] -> [/home/gariac/Cache/my.cnf].
2007-09-05 00:04:32.0719 MySQLHelper: init() Creating system tables..
2007-09-05 00:04:32.0725 MySQLHelper: startServer() About to start MySQL with command: [/usr/sbin/mysqld --defaults-file=/home/gariac/Cache/my.cnf]
070905 0:04:32 [ERROR] Error message file '/usr/local/src/slimserver/SlimServer_v6.5.4/MySQL/errmsg.sys' had only 463 error messages,
but it should contain at least 472 error messages.
Check that the above file is the right version for this program!
070905 0:04:32 [ERROR] Aborting

2007-09-05 00:05:02.5014 ERROR: MySQLHelper: createSystemTables() Couldn't connect to database: [Can't connect to local MySQL server through socket '/home/gariac/Cache/slimserver-mysql.sock' (2)]

2007-09-05 00:05:02.5023 Got to the END.
2007-09-05 00:05:02.5024 Got sigint.
2007-09-05 00:05:02.5025 SlimServer cleaning up.
-------------------------------

This is my preference file, with the password ****'d out:
---
allowedHosts: 127.0.0.1,127.0.0.2
artfolder: ''
audiodir: ''
authorize: 0
browseagelimit: 100
bufferSecs: 3
cachedir: /home/gariac/Cache
checkVersion: 1
checkVersionInterval: 86400
clients: {}

commonAlbumTitles:
- Greatest Hits
- Best of...
- Live
commonAlbumTitlesToggle: 0
composerInArtists: 0
coverArt: ''
coverThumb: ''
csrfProtectionLevel: 1
dbpassword: ******
dbsource: dbi:mysql:hostname=127.0.0.1;port=9092;database=%s ;mysql_socket=/var/lib/mysql/mysql.sock
dbusername: slimserver
disableStatistics: 0
disabledextensionsaudio: ''
disabledextensionsplaylist: ''
disabledplugins: []

displaytexttimeout: 1
enabledfonts:
- small
- medium
- large
- huge
filterHosts: 0
groupdiscs: 0
guessFileFormats:
- (ARTIST - ALBUM) TRACKNUM - TITLE
- /ARTIST/ALBUM/TRACKNUM - TITLE
- /ARTIST/ALBUM/TRACKNUM TITLE
- /ARTIST/ALBUM/TRACKNUM. TITLE
httpport: 9000
ignoreDirRE: ''
ignoredarticles: The El La Los Las Le Les
itemsPerPage: 50
itemsPerPass: 5
language: EN
livelog: 102400
longdateFormat: "%A, %B |%d, %Y"
mDNSname: SlimServer
maxBitrate: 320
maxWMArate: 9999
noGenreFilter: 0
password: ''
persistPlaylists: 1
playlistdir: ''
playtrackalbum: 1
plugins-onthefly: 0
prefsWriteDelay: 30
rank-PLUGIN_PICKS_MODULE_NAME: 4
refreshRate: 30
remotestreamtimeout: 5
reshuffleOnRepeat: 0
saveShuffled: 0
scannerPriority: 0
searchSubString: 0
securitySecret: 7ead901c53d79e3c700d22e85c9776b8
serverPriority: ''
shortdateFormat: "%m/%d/%Y"
showYear: 0
skin: Default
splitList: ''
streamWriteMaximum: 30
tcpConnectMaximum: 30
tcpReadMaximum: 20
tcpWriteMaximum: 20
thumbSize: 100
timeFormat: "|%I:%M:%S %p"
titleFormat:
- TITLE
- DISC-TRACKNUM. TITLE
- TRACKNUM. TITLE
- TRACKNUM. ARTIST - TITLE
- TRACKNUM. TITLE (ARTIST)
- TRACKNUM. TITLE - ARTIST - ALBUM
- FILE.EXT
- TRACKNUM. TITLE from ALBUM by ARTIST
- TITLE (ARTIST)
- ARTIST - TITLE
titleFormatWeb: 1
udpChunkSize: 1400
upgrade-6.2.1-2005-11-07-script: 0
upgrade-6.2b1-2005-09-19-script: 0
upgrade-6.2b1-script: 0
upgrade-6.5b1-2006-01-25-script: 0
upgrade-6.5b1-2006-02-03-script: 0
upgrade-6.5b1-2006-03-31-script: 1
useBandAsAlbumArtist: 0
username: ''
variousArtistAutoIdentification: 0
webproxy: ''

------------------
Note also the instructions say the preference file for *nix files is ~/.slimserver.conf
but I find the file to be ~/slimserver.conf

4mula1
2007-09-05, 05:05
070905 0:04:32 [ERROR] Error message file '/usr/local/src/slimserver/SlimServer_v6.5.4/MySQL/errmsg.sys' had only 463 error messages,
but it should contain at least 472 error messages.
Check that the above file is the right version for this program!
070905 0:04:32 [ERROR] Aborting

Fletch was right about the errmsg.sys file but you shouldn't have a copy of SlimServer's MySQL. Odd.

You can trim down that dbsource line in your pref file. Mine is dbsource: dbi:mysql:database=slimserver

gariac
2007-09-05, 12:07
Fletch was right about the errmsg.sys file but you shouldn't have a copy of SlimServer's MySQL. Odd.

You can trim down that dbsource line in your pref file. Mine is dbsource: dbi:mysql:database=slimserver

I copied the error message file, which did the trick.

I also had to put port 3483 into the suse firewall. I put it in udp and tcp since it wasn't clear which was needed.

Thanks all for the help, and I'm sure you will see me elsewhere on the forum.

4mula1
2007-09-05, 12:10
Glad to hear it's working. Port 3483 UDP is used by the Slim Discovery Protocol. It allows your Squeezebox or Transporter to find SlimServer without manually entering the IP address. Everything else is TCP on ports 3483 and 9000.