LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-31-2007, 04:04 AM   #1
Net_Spy
Member
 
Registered: Nov 2006
Posts: 119

Rep: Reputation: 17
Mysql issue with fc6


Greetings to all...

I just install the FC6 on my machine and also install httpd ,php,mysql,proftpd.now with mysql im trying to setting up the pass and user for my mysqladmin -u root password "new-password" im getting this error message

Quote:
mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'root'@'localhost' (using password: NO)'


infact i just try to login using mysql for resetting my password for

update mysql.user set password=password("NEW-PASSWORD") where user="root";
flush privileges;
quit

root but getting this anoying error

update mysql.user set password=password("*******") where user="root";ERROR 1142 (42000): UPDATE command denied to user ''@'localhost' for table 'user'
I installed these packages
ive installed these packages.

libdbi-dbd-mysql-0.8.1a-12.2
mysql-connector-odbc-3.51.12-2.2
mysql-5.0.27-1.fc6
mysql-server-5.0.27-1.fc6
php-mysql-5.1.6-3

Im looking forward for your kind resonse.

Regards
Net_Spy
 
Old 03-31-2007, 05:29 AM   #2
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
First of all, is the mysql service running?

According to the manual, initially, the root and anonymouse accounts have no password.
Code:
To use SET PASSWORD on Unix, do this:
shell> mysql -u root
mysql> SET PASSWORD FOR ''@'localhost' = PASSWORD('newpwd');
mysql> SET PASSWORD FOR ''@'host_name' = PASSWORD('newpwd');
...
For Unix, do this:
shell> mysql -u root
mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('newpwd');
mysql> SET PASSWORD FOR 'root'@'host_name' = PASSWORD('newpwd');
Be sure to read section 2.9.3 of the mysql manual at /usr/share/doc/packages/mysql/manual.pdf
2.9.3. Securing the Initial MySQL Accounts

Something else to check is that the SELinux configuration isn't denying access to the tables or other files. Check your logs to make sure.

Last edited by jschiwal; 03-31-2007 at 08:15 AM.
 
Old 04-01-2007, 08:27 AM   #3
Net_Spy
Member
 
Registered: Nov 2006
Posts: 119

Original Poster
Rep: Reputation: 17
Guys ive tried all the possible way try to reseting root but one thing i want to clear it out does mysql read the file /etc/my.cnf for user if it doest then there is no user added in my.cnf file. here is the file
there is only a single user mysql and it doesnt have the rights to create database and its without pass.Im looking forward for your kind response.
Code:
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1

[mysql.server]
user=mysql
basedir=/var/lib

[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
Code:
getting this error when using mysql -u root

ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
 
Old 04-01-2007, 05:30 PM   #4
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
I wonder if the root account was disabled, or the password was changed. The mysql user is a system user that the mysql server runs as instead of as root.

Try
Code:
mysql -u root -p
<password>
This works for me whereas "mysql -u root" gives the same error message as you had.

Last edited by jschiwal; 04-02-2007 at 03:21 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Adobe and FC6 issue tmick Fedora 5 02-25-2007 09:31 AM
FC6 on a Dell PE2950 & MySQL ACDII Fedora 0 02-15-2007 02:24 PM
Printing Issue on Minolta2300DL on FC6 xiaostrong8 Linux - General 1 12-08-2006 09:00 PM
keyboard issue Fc6 Guignol Linux - Hardware 5 12-07-2006 04:35 PM
FC6 - php-mysql moduie help Doomhammer Linux - Server 1 12-02-2006 02:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration