Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

aicul

macrumors 6502a
Original poster
Jun 20, 2007
809
7
no cars, only boats
Hi,

I am writing here because all my extrapolation from other peoples comments have failed. So if someone is will to provide some words of advice.

Installed mySQL, then build the databases, then set the php.ini file to point to the /var/mysql/mysql.sock but when

The problem is as follows :

With mysqladmin ping I get that the /var/mysql/mysql.sock is not available,

But if I cd /usr/local/mysql/bin and ./mysqladmin ping I get mysql is alive

So, my guess is that, mysqladmin is not the same as /user/local/mysql/bin/mysqladmin

But I do not know how to resolve this.

any Ideas
 
Last edited:

aicul

macrumors 6502a
Original poster
Jun 20, 2007
809
7
no cars, only boats
Hi

A little update.

Seems SL comes pre-installed with the mySQL programs, so my install of mySQL is sort of a duplicate.

The PATH variable is set to go to the pre-installed mySQL programs which explains the confusion above.

However, I could not find where the pre-installed mySQL actually stores the data, config files, etc.

So I have now set the whole thing to work with my install of mySQL, but I have to make sure I go to the correct /usr/local/mysql directory first.

If anyone has some science on how to get the pre-installed mySQL, I am all ears
(and would lead to me removing the one I installed).

thanks
 

aicul

macrumors 6502a
Original poster
Jun 20, 2007
809
7
no cars, only boats
Hi,

I had seen that post but it is not what I have on my mini server. That post specifically asks to de-install /usr/local/mysql. This is the normal place that mysql installs iteself.

On my mini I have /usr/bin which contains all the mysql executables and /usr/local/mysql which I installed.

Hence I conclude mysql seems to be pre-installed in SL server.

The situation I have is that the PATH command is set to go thru /usr/bin and not /usr/local/mysql/bin, so all my commands do not work.

The short-term-fix would be to change the PATH (which I do not know how to do) but the long-term fix would be to use the /usr/bin executables (but here folders such as /data are missing....)

So I am a little stuck

Am I the only person that noticed the mysql executables in /usr/bin ?? :confused:
 

aicul

macrumors 6502a
Original poster
Jun 20, 2007
809
7
no cars, only boats
I'm still at this, I hate to have 2 installs of the same thing on the same mac.

Is there some sueful reference that can tell me where to check for a mySQL install ?

I'm hoping to use this to see the extent of the duplicate install and remove the pointless extras.

Also more about the my.cnf file.


any comments welcome
 

slackman1

macrumors newbie
Jan 9, 2011
6
0
Hi,

I recommend that you take a look about what you bought at the info at apple.com about SL Server:
http://www.apple.com/server/macosx/specs.html
...and see that MySQL is indeed there, it even has a rudimentary preference in Server Admin, with which you can get it running in 3 seconds after install.

Then, you might be interested in the fine manual:
http://images.apple.com/server/macosx/docs/Web_Tech_Admin_v10.6.pdf

Furthermore, if you need the "stock" MySQL that Apple ships, you can find the right version(s) at: http://opensource.apple.com (10.6.6 not yet available)
These packages are also needed when you for example need the header files, because you want to compile a Ruby module for MySQL...
 

aicul

macrumors 6502a
Original poster
Jun 20, 2007
809
7
no cars, only boats
Hi

Thank you ever so much for these few but valuable pointers.

Indeed the mySQL server IS INCLUDED and it is easy to setup.

I could point out that this was a gift so I had not read the apple specs, and the micro booklet that was in the box made no mention of mysql... but then I could have looked at the apple site 1st, rather than google.

Anyway thanks. :)
 

aicul

macrumors 6502a
Original poster
Jun 20, 2007
809
7
no cars, only boats
Hi

Hate to say this but now mySQL is moaning that "mysql_connect(): Host '192.168.2.199' is not allowed to connect to this MySQL server".

I have checked for the network user setting and it is ticket. Various sites say I have to grant some privileges, but this was not the case with my self-installed mysql.

After various grant tries I can only access the mySQL standard test db, whilst the ones I create are all somehow blocked when accessed via web...

when will this end...
 

slackman1

macrumors newbie
Jan 9, 2011
6
0
Hi,

You have to grant rights to a user like:
root@192.168.2.199 in your case, for the concerned databases, read, write, create etc.

I think it would be best to install Navicat Lite (Free for non-commercial) on the server, then you would not have any problems to connect to localhost as root and then set the necessary permissions.
 

aicul

macrumors 6502a
Original poster
Jun 20, 2007
809
7
no cars, only boats
Hi

That was a simultaneous solution. Indeed Granting rights is necessary. I remain a little confused as to why this was not necessary before, but I think that will remain unanswered.

My Xmas gift is not humming away providing file server, web, mysql etc to the households. Nice little machine.

thanks to all input, although short and concise it was correct.
:eek:
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.