Page 1 of 1

MySQL Installation in Slackware 12.1

PostPosted: Sun Jul 20, 2008 9:10 pm
by cire_08
Hi Guys,

I already installed MySql 5.0.45 in Slackware 12.1.

While in cpan prompt and run this command "force install DBD::mysql", It prompted me a lot of error, pls find below:

failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at t/40server_prepare.t line 16
t/40server_prepare_error....skipped: ERROR: DBI connect('test;mysql_server_prepare=1','root',...) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at t/40server_prepare_error.t line 18
t/40types...................skipped: ERROR: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2). Can't continue test
t/41bindparam...............skipped: ERROR: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2). Can't continue test
t/41blobs_prepare...........skipped: ERROR: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2). Can't continue test
t/42bindparam...............skipped: ERROR: DBI connect('test','root',...) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at t/42bindparam.t line 13
t/50chopblanks..............skipped: ERROR: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2). Can't continue test
t/50commit..................skipped: ERROR: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2). Can't continue test
t/55utf8....................skipped: ERROR: DBI connect('test','root',...) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at t/55utf8.t line 18
t/60leaks...................skipped: Skip $ENV{SLOW_TESTS} is not set
t/65types...................skipped: ERROR: DBI connect('test','root',...) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (

How can I resolve this problem. Pls advise.

Regards,

PostPosted: Sun Jul 20, 2008 10:42 pm
by codehaxor
it looks like a test connection initiated by the perl module, i got that too when installing the DBD::Mysql module. Also you could check if you have the mysql client libraries installed.

PostPosted: Sun Jul 20, 2008 11:05 pm
by cire_08
hi codehaxor,

thanks for your prompt reply.

sorry im newbie in installing mysql, how can I check if i have mysql client lib installed. If i don't have it, how can i get that..im really sorry this is my first time to install mysql.

your advice is highly appreciated.

regards,

PostPosted: Mon Jul 21, 2008 1:11 am
by cire_08
hello everyone,

My problem was resolved already.

Since the mysql.sock was missing in tmp folder (ERROR 2002), so what i did i just copy the mysql.sock file from /var/lib/mysql/ and supplied this command ln -s /var/lib/mysql/mysql.sock /tmp/mysql.sock. After that I start mysql (/usr/local/mysql/bin/mysqld_safe --user=mysql &) run (/usr/local/mysql/bin/mysql) and it works!

However, how to automatically start my mysql??? I noticed that everytime i restarted my server, i have to manually start it. Pls advice.

regards,

PostPosted: Mon Jul 21, 2008 8:19 am
by devafree
cire_08,

Following the scratch install, you will come to entries for rc.local. There it is explained how to do what you asked.

Regards

devafree

PostPosted: Mon Jul 21, 2008 8:50 am
by cire_08
Hi devafree,

Thanks for your advice.

I’ll definitely check that tomorrow.

regards