PDA

View Full Version : 6.5.0 with MySql - config error?



jimwillsher
2006-09-22, 06:30
Hi, can anybody help? I've compiled 6.5.0 from the tarball, and I've created my MySql database and user as per the notes here:

http://wiki.slimdevices.com/index.cgi?ExistingMySQLInstance

I've also updated my .slimserver.prefs file (which alarmingly seems to now live in the / folder?). Anyway, when I start slimserver I get the following in the /tmp/slimserver.log file:


2006-09-22 14:20:25.5866 SlimServer settings effective user and group if requested...
2006-09-22 14:20:25.5871 SlimServer settings init...
2006-09-22 14:20:25.5990 SlimServer strings init...
2006-09-22 14:20:25.7783 SlimServer Setup init...
2006-09-22 14:20:25.7905 SlimServer setting language...
2006-09-22 14:20:25.7907 SlimServer MySQL init...
060922 14:20:25 [ERROR] Fatal error: Please read "Security" section of the manual to find out how to run mysqld as root!

060922 14:20:25 [ERROR] Aborting

060922 14:20:25 [Note] /usr/local/SlimServer_v6.5.0/Bin/i386-linux/mysqld: Shutdown complete

2006-09-22 14:20:56.1861 ERROR: MySQLHelper: createSystemTables() Couldn't connect to database: [Can't connect to local MySQL server through socket '/root/Cache/slimserver-mysql.sock' (2)]

2006-09-22 14:20:56.1871 Got to the END.
2006-09-22 14:21:50.0227 SlimServer settings effective user and group if requested...
2006-09-22 14:21:50.0231 SlimServer settings init...
2006-09-22 14:21:50.0535 SlimServer strings init...
2006-09-22 14:21:50.2191 SlimServer Setup init...
2006-09-22 14:21:50.2314 SlimServer setting language...
2006-09-22 14:21:50.2316 SlimServer MySQL init...
060922 14:21:50 [ERROR] Fatal error: Please read "Security" section of the manual to find out how to run mysqld as root!

060922 14:21:50 [ERROR] Aborting

060922 14:21:50 [Note] /usr/local/SlimServer_v6.5.0/Bin/i386-linux/mysqld: Shutdown complete

2006-09-22 14:22:20.7311 ERROR: MySQLHelper: createSystemTables() Couldn't connect to database: [Can't connect to local MySQL server through socket '/root/Cache/slimserver-mysql.sock' (2)]

2006-09-22 14:22:20.7321 Got to the END.

I can manually log in to mysql via


mysql -uslimserver -pmypass

Any thoughts?

Many thanks,



Jim (sitting in a very quiet house....)

EDIT: I'm running MySql 5.0.24 on Ubuntu 6.06

mherger
2006-09-22, 06:46
>> 060922 14:20:25 [ERROR] Fatal error: Please read "Security" section of
>> the manual to find out how to run mysqld as root!

add "user = root" to MySQL/my.tt if you want to run it as user root. And
read the section about Security in the MySQL manual for more information
:-)

--

Michael

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

jimwillsher
2006-09-22, 06:56
Oh dear, how embarrassing. I've never had these issues before, but I had simply forgotten this aspect!

I've now done a

chown -R /usr/slimserver slimserver

and

chown /tmp/slimserver.log slimserver

and it's now working fine.

Sorry....and thanks!


Jim

jimwillsher
2006-09-22, 07:22
I lied, it's not working.

I can get into the GUI, but when I choose to rescan my library I get:



2006-09-22 15:13:53.6703 Use of uninitialized value in concatenation (.) or string at /usr/local/SlimServer_v6.5.0/Slim/Schema.pm line 915.
2006-09-22 15:13:53.6705 Merging entry for clientplaylist://00:04:20:06:1c:47 readTags is: []
2006-09-22 15:13:53.6709 Updating clientplaylist://00:04:20:06:1c:47 : title to Now Playing - 192.168.1.102
2006-09-22 15:13:53.6712 Updating clientplaylist://00:04:20:06:1c:47 : year to 0
2006-09-22 15:13:53.6715 Updating clientplaylist://00:04:20:06:1c:47 : content_type to cpl
2006-09-22 15:13:53.6717 Updating clientplaylist://00:04:20:06:1c:47 : remote to 0
2006-09-22 15:13:53.6720 Updating clientplaylist://00:04:20:06:1c:47 : titlesearch to NOW PLAYING 192 168 1 102
2006-09-22 15:13:53.6722 Updating clientplaylist://00:04:20:06:1c:47 : titlesort to NOW PLAYING 192 168 1 102
2006-09-22 15:13:53.6724 Updating clientplaylist://00:04:20:06:1c:47 : rating to 0
2006-09-22 15:13:53.6745 DELETE FROM playlist_track WHERE ( playlist = ? ): '1'
2006-09-22 15:13:54.2774 SlimServer OSDetect init...
2006-09-22 15:13:54.2777 SlimServer OS Specific init...
2006-09-22 15:13:54.2778 SlimServer settings init...
2006-09-22 15:13:54.2837 SlimServer strings init...
2006-09-22 15:13:54.4518 SlimServer Info init...
2006-09-22 15:13:54.5204 ERROR: DBI Connection failed: DBI connect('database=slimserver','slimserver',...) failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) at /usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 652

2006-09-22 15:13:54.5206 ERROR: Backtrace follows:

2006-09-22 15:13:54.5208 Backtrace:

frame 0: Slim::Schema::Storage::throw_exception (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 658)
frame 1: DBIx::Class::Storage::DBI::_connect (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 616)
frame 2: DBIx::Class::Storage::DBI::_populate_dbh (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 543)
frame 3: DBIx::Class::Storage::DBI::ensure_connected (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 557)
frame 4: DBIx::Class::Storage::DBI::dbh (/usr/local/SlimServer_v6.5.0/Slim/Schema.pm line 118)
frame 5: Slim::Schema::init (/usr/local/SlimServer_v6.5.0/Slim/Music/Info.pm line 71)
frame 6: Slim::Music::Info::init (/usr/local/SlimServer_v6.5.0/scanner.pl line 239)
frame 7: main::initializeFrameworks (/usr/local/SlimServer_v6.5.0/scanner.pl line 86)
frame 8: main::main (/usr/local/SlimServer_v6.5.0/scanner.pl line 330)

Carp::Clan::__ANON__(): DBI Connection failed: DBI connect('database=slimserver','slimserver',...) failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) at /usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 652
2006-09-22 15:13:54.5211 Got to the END.
2006-09-22 15:13:54.5212 Got sigint.
2006-09-22 15:13:54.5212 SlimServer cleaning up.
2006-09-22 15:13:54.5224 ERROR: DBI Connection failed: DBI connect('database=slimserver','slimserver',...) failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) at /usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 652

2006-09-22 15:13:54.5226 ERROR: Backtrace follows:

2006-09-22 15:13:54.5228 Backtrace:

frame 0: Slim::Schema::Storage::throw_exception (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 658)
frame 1: DBIx::Class::Storage::DBI::_connect (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 616)
frame 2: DBIx::Class::Storage::DBI::_populate_dbh (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 543)
frame 3: DBIx::Class::Storage::DBI::ensure_connected (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 557)
frame 4: DBIx::Class::Storage::DBI::dbh (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 677)
frame 5: DBIx::Class::Storage::DBI::txn_begin (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Schema.pm line 487)
frame 6: DBIx::Class::Schema::txn_begin (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Schema.pm line 567)
frame 7: DBIx::Class::Schema::txn_do (/usr/local/SlimServer_v6.5.0/scanner.pl line 253)
frame 8: (eval) (/usr/local/SlimServer_v6.5.0/scanner.pl line 245)
frame 9: main::setIsScanning (/usr/local/SlimServer_v6.5.0/scanner.pl line 321)
frame 10: main::cleanup (/usr/local/SlimServer_v6.5.0/Slim/bootstrap.pm line 300)
frame 11: Slim::bootstrap::sigint (/usr/local/SlimServer_v6.5.0/Slim/bootstrap.pm line 331)
frame 12: Slim::bootstrap::END (/usr/local/SlimServer_v6.5.0/scanner.pl line 0)
frame 13: (eval) (/usr/local/SlimServer_v6.5.0/scanner.pl line 0)

2006-09-22 15:13:54.5230 ERROR: Scanner: Failed to update isScanning: [Carp::Clan::__ANON__(): DBI Connection failed: DBI connect('database=slimserver','slimserver',...) failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) at /usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 652
]

2006-09-22 15:13:54.5231 ERROR: forceCommit: Trying to commit transactions before DB is initialized!

2006-09-22 15:13:54.5241 ERROR: DBI Connection failed: DBI connect('database=slimserver','slimserver',...) failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) at /usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 652

2006-09-22 15:13:54.5243 ERROR: Backtrace follows:

2006-09-22 15:13:54.5245 Backtrace:

frame 0: Slim::Schema::Storage::throw_exception (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 658)
frame 1: DBIx::Class::Storage::DBI::_connect (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 616)
frame 2: DBIx::Class::Storage::DBI::_populate_dbh (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 543)
frame 3: DBIx::Class::Storage::DBI::ensure_connected (/usr/local/SlimServer_v6.5.0/CPAN/DBIx/Class/Storage/DBI.pm line 557)
frame 4: DBIx::Class::Storage::DBI::dbh (/usr/local/SlimServer_v6.5.0/Slim/Schema.pm line 247)
frame 5: (eval) (/usr/local/SlimServer_v6.5.0/Slim/Schema.pm line 247)
frame 6: Slim::Schema::disconnect (/usr/local/SlimServer_v6.5.0/scanner.pl line 324)
frame 7: main::cleanup (/usr/local/SlimServer_v6.5.0/Slim/bootstrap.pm line 300)
frame 8: Slim::bootstrap::sigint (/usr/local/SlimServer_v6.5.0/Slim/bootstrap.pm line 331)
frame 9: Slim::bootstrap::END (/usr/local/SlimServer_v6.5.0/scanner.pl line 0)
frame 10: (eval) (/usr/local/SlimServer_v6.5.0/scanner.pl line 0)


I've searched the boards but found no solution - but I don't really know what I am searching for!

Slim has happily created 15 tables in the database, so I know the connection is valid. It's written one records to two of the tables.

I'm running the process as slimserver:

su - slimserver
/etc/init.d/slimserver start



Jim


Edit: Some additional info. If I choose to browse the music folder int eh web itnerface I can play a song happily. THEN my library stats show "1 Album with 2 Songs by 1 Artist". It's the full rescan that falls in a heap.

Could it be the spawned scanning processes?

jimwillsher
2006-09-22, 08:08
Okay, muppet award of the day goes to me.

Having read, and REread the notes here:

http://wiki.slimdevices.com/index.cgi?ExistingMySQLInstance

I've now added



;mysql_socket=/var/run/mysqld/mysqld.sock


to my dbsource line. And all is now well.

(off to hang head in shame)


Jim