Thread: mySql problems
View Single Post
  #1   (View Single Post)  
Old 24th May 2008
dctr dctr is offline
Port Guard
 
Join Date: May 2008
Posts: 30
Default mySql problems

I installed Apache22, php5, php5-extensions, phpmyadmin and mysql mainly for the purpose of snort / snortreport.

Quote:
#
Installing MySQL:

1. Go to the mysql50-server port directory by typing the command:

cd /usr/ports/databases/mysql50-server

2. Build the port by typing: (This takes AGES - good time for some food.)

make BUILD_OPTIMIZED=yes BUILD_STATIC=yes

3. Install by typing:

make install clean

4. Open /etc/rc.conf with your favourite text editor and add the line shown below. This will ensure mysql is enabled and starts on boot.

mysql_enable="YES"

5. Start mysql manually to avoid having to reboot now by typing:

/usr/local/etc/rc.d/mysql-server start

6. Set a password for the MySQL root user by executing the command, subtituting your own password in place of new-password:

/usr/local/bin/mysqladmin -uroot password 'new-password'

And you're done! MySQL is installed.
Everything works fine, UNTIL
Quote:
/usr/local/bin/mysqladmin -uroot password 'new-password
I'll get error

Code:
r00tr00t# /usr/local/bin/mysqladmin -uroot password newpassword
/usr/local/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'root'@'localhost' (using password: NO)'
when i change it up.

Code:
r00tr00t# /usr/local/bin/mysqladmin -u root -p password
Enter password:
/usr/local/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'root'@'localhost' (using password: YES)'
other times i get using password: NO

I don't know what my problem is, do you?

Last edited by dctr; 24th May 2008 at 10:26 AM.
Reply With Quote