Ryan McDougall wrote:
when I do this this is what I get:
starting mysql with databases from /var/lib/mysql

This may be your culprit right here... not sure where the mysql_install_db
defaults its installs to, but I'm guessing its not /var/lib/mysql. And you
installed everything into /usr/local/mysql, so you may need to edit your config
file to tell it where to look for the install.

At least SuSE has the homedir of user mysql at /var/lib/mysql.
So it might be the default for red hat's mysql installation, too.
If one installs the binary from mysql.com there are some paths to be redirected.


One problem is that a number of applications (e.g. PHP) have the path to mysql's socket and data-dir compiled in their binary. Just setting up mysql in /usr/local/mysql and editing /etc/my.cnf won't solve all issues.


shell>> ./mysqladmin ping
I get the error message:
./mysqladmin: connect to server at 'localhost' failed
error: 'can't connect to local MySQL server through socket '/tmp/mysql.sock'
(2)'
check that mysqld is running and that the socket: '/tmp/mysql.sock' exists!

The error message above said the server couldn't properly start. That's why ther is no mysql.sock



This is happening because mysqld is not running... I believe that when you run
safe_mysqld it creates the /tmp/mysql.sock file. So if it never runs no file is
ever made.

no mysql.sock exists when the mysqld (server daemon) is running.


People please correct me if I'm wrong... I've never done a binary install. I've
only installed MySQL at the time of my RH8.0 install.

There you are. I only know SuSE. They install it like that: Mysql's Base dir is /usr Data. logs and socket in /var/lib/mysql


Mysql.com's binary is setup like this: Basedir /usr/local/mysql Datadir /usr/local/mysql/data Socket in /tmp


1) If you already have data in /var/lib/mysql make a backup. a) install the old software again which you used to create the database. b) mysqldump all important stuff and store it under your pillow c) uninstall the old mysql binary

2) lets fix the "missing" socket
a) Erase /var/lib/mysql
b) create symlink so that /var/lib/mysql points to /tmp
c) light a candle for the saint that manages system security
d) mysql.com's binary will put it's socket in /tmp so edit the socket-parameter in /etc/my.cnf to this location. Some clients will actually read it.


3) extract mysql.com's binary and put it where it is supposed
--> /usr/local/mysql
(OK, put it where you like, but point a symlink from /usr/local/mysql to the right place)


4) find a place for the data-files like e.g. /var/lib/mysql/data
(OK, ... bla ... symlink ... bla)
b) edit  /etc/my.cnf  acordingly

5) read the INSTALL docu and follow what they say
b) the user mysql will probaply already exist but perhaps not in the group mysql ... so what ? ;)
c) set the right rights acording to the documentation


6) if you mindlessly do everything on the console with MC, like I do, use a plain shell to start mysqld_save.
I had a hard time to find out why the mysql daemon came up but died instantly all the time for no imaginal reason.



All above should bring you at least near a working mysql.com binary install. It's by far not the proper way to do it, but it's either that or recompiling mysql and/or a lot of other packets that came with you linux distribution.
Obviously it's not the way to go in a production environment but it should be OK to get started.


The whole crap results from distributors who don't use /usr/local for applications they provide precompiled.
A SuSE dude told me they weren't "allowed" to do that. Users should be certain that there are only applications they put there themselves so it was easier to backup stuff which was applied later.
Yeah great ... now we fight hardcoded non standard paths.


BS ! I say.


regards



--------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



Reply via email to