473,750 Members | 2,520 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Mysql: access denied

Hi,
I can only access mysql through the root by typing mysql -u root -p. But
when I use any other user to connect to mysql I get the access denied error
message. Mysql is installed on windows xp. I looked up information online
to solve this problem and saw that there are some scripts that i may be able
to run in order to fix the problem. But I am not sure how to handle those
scripts since they are only made for unix systems. I tried to connect to
the server using PHP, but i cant connect as well. I am really new to this
and would appreciate the least help..

The way i am create users is by inserting a user in the user table.. or by
granting privileges to a random user. Is there any other way of creating
users? The way I am checking whether a user account is working is by typing
mysql -u username -ppassword. Is there any other way of doing this.. Anyone
know why access denied but the users i created do show in the user table

Thanks

Jul 20 '05 #1
2 2976

"adnan alsamari" <sc*******@roch ester.rr.com> wrote in message
news:RR******** ***********@twi ster.nyroc.rr.c om...
Hi,
I can only access mysql through the root by typing mysql -u root -p. But
when I use any other user to connect to mysql I get the access denied error message. Mysql is installed on windows xp. I looked up information online
to solve this problem and saw that there are some scripts that i may be able to run in order to fix the problem. But I am not sure how to handle those
scripts since they are only made for unix systems. I tried to connect to
the server using PHP, but i cant connect as well. I am really new to this
and would appreciate the least help..

The way i am create users is by inserting a user in the user table.. or by
granting privileges to a random user. Is there any other way of creating
users? The way I am checking whether a user account is working is by typing mysql -u username -ppassword. Is there any other way of doing this.. Anyone know why access denied but the users i created do show in the user table


Try logging in as root then grant access to other users:

suppose your database you are granting access is called "mydb"

GRANT ALL ON mydb.* TO username@localh ost;

Check the mysql documentation for more information at
http://dev.mysql.com/doc/mysql/en/SQL_Syntax.html
Jul 20 '05 #2
mysql> GRANT ALL PRIVILEGES ON yourdb.* TO 'root'@'localho st'
IDENTIFIED BY 'yourpass'
--
raqueeb hassan
congo (drc)
Jul 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
3394
by: Ryan Schefke | last post by:
------=_NextPart_000_0077_01C34C8B.2B90C960 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit ..I just sent this out to the win32 distribution list but no one has replied.can someone on this list please help? The issue should be trivial for experienced MySQL users, I'm just a novice, thanks!
3
3131
by: c_chen | last post by:
Hi, i am a beginner in PHP and mySQL. Whenever I try to connect my php and mysql database, i get this error.: MySQL error : access denied for myuser@localhost (Using password:yes) I have created a database called mydatabase at the SQLmonitor, mySQL> create database mydatabase; then i try to grant the access to mydatabase by mySQL>GRANT usage on mydatabase.* to myuser@localhost;
0
1581
by: bruce | last post by:
Hi... A mysql/Apache issue: I get the following when I'm trying to run a test web site on an Apache 2.0/RH8.0 setup. -------------------------------- Warning: Access denied for user: 'apache@localhost' (Using password: YES) in /var/www/html/dbid/mysql/database.php on line 17
0
2031
by: bruce | last post by:
Hi... Update.... We have the following setup in our httpd.conf file. We've tried to give what's related to the issue. We're trying to set up a virtual host for a test project. The behavior that we're seeing is that we can type: http://foo.com but the url that gets displayed is
4
5852
by: Adam Smith | last post by:
I have a dedicated server running 'FreeBSD 4.9 STABLE' at a hosting site. They have done some default installations, presumably from the CVS ports package ??. Herein lies the problem, "I do not know" what they have done! At first it was apparent that MySQL was installed mysql_install_db ; GRANT TABLES etc. ??? so I ran "mysql_install_db --force"
2
478
by: adnan alsamari | last post by:
Hi, I can only access mysql through the root by typing mysql -u root -p. But when I use any other user to connect to mysql I get the access denied error message. Mysql is installed on windows xp. I looked up information online to solve this problem and saw that there are some scripts that i may be able to run in order to fix the problem. But I am not sure how to handle those scripts since they are only made for unix systems. I tried to...
1
2389
by: Maxim. V. | last post by:
Hello to everone, As mentioned in this *guide(1), i've compiled mysql on my fedora Core 2 system, with the following spec's : *(1) http://hulan.info/blog/index.php?itemid=576 --------------- bash START -------------- $ uname -a Linux localhost.localdomain 2.6.8-1.521 #1 Mon Aug 16 09:01:18 EDT
4
2701
by: Chefry | last post by:
I'm trying to set up an off the shelf script and keep getting an error. My host set up the mysql on my site and I changed the variables I had to in the settings.php file but I keep getting the following errors Warning: mysql_pconnect(): Access denied for user: 'ODBC@localhost' (Using password: NO) in f:\wwwroot\professionalchef\Back\JobsOnline\mysql.php on line 121 Warning: mysql_pconnect(): Access denied for user: 'ODBC@localhost'...
4
7397
jepler
by: jepler | last post by:
I find myself in a circular reference loop that I can't seem to resolve. I recently upgraded from MySQL 4.0.x to MySQL 4.1.21 on OS 10.3.9 Server. Then, I *thought* I set my open master root password correctly using usr/local/mysql/bin/mysqladmin -u root password new_password and /usr/local/mysql/bin/mysqladmin -u root -h `hostname` password "newpasswd" . After setting my master root password I then connected via phpMyAdmin 2.5.4 as...
0
9000
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8838
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9577
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9396
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9256
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8260
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4713
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3322
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2804
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.