Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Search | Today's Posts | Mark Forums Read
BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6
This is the forum to discuss the Wrox book Beginning PHP, Apache, MySQLWeb Development by Michael K. Glass, Yann Le Scouarnec, Elizabeth Naramore, Gary Mailer, Jeremy Stolz, Jason Gerner; ISBN: 9780764557446
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old April 6th, 2004, 09:09 PM
Registered User
 
Join Date: Apr 2004
Location: Madison, AL, USA.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to randbert96310
Default MYSQL Configuration

After installing MYSQL I've followed the “Configuring Your Installation”. All seemed to go well and in step 5 on page 24 when asked my password it wouldn’t let me in. I could access the MYSQL database that was there before changing these privileges. How can I fix this or what can I read to learn about set up of users and privileges. I’m running MYSQL on Windows 2000.
Example of error:
C:\MYSQL\BIN\mysql –h localhost –u root –p
Enter password:*********
ERROR 1045: Access denied for user: ‘root@localhost’ <Using password: YES>
Reply With Quote
  #2 (permalink)  
Old April 7th, 2004, 04:04 PM
Friend of Wrox
Points: 2,570, Level: 21
Points: 2,570, Level: 21 Points: 2,570, Level: 21 Points: 2,570, Level: 21
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: San Diego, CA, USA
Posts: 836
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You need to reload MySQL's grant tables before any permissions settings (usernames, passwords, etc) take effect. Simplest way to do this is to shut down and restart MySQL.


Take care,

Nik
http://www.bigaction.org/
Reply With Quote
  #3 (permalink)  
Old April 13th, 2004, 02:24 PM
Registered User
 
Join Date: Apr 2004
Location: Madison, AL, USA.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to randbert96310
Default

This din't work. I'm going to retry the setup on a new install of WIN XP wish me luck.

Reply With Quote
  #4 (permalink)  
Old April 22nd, 2004, 04:19 PM
Registered User
 
Join Date: Apr 2004
Location: , , .
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

How did this work out? I am having the same problem...

Quote:
quote:Originally posted by randbert96310
 This din't work. I'm going to retry the setup on a new install of WIN XP wish me luck.

Reply With Quote
  #5 (permalink)  
Old April 23rd, 2004, 09:01 AM
Registered User
 
Join Date: Apr 2004
Location: Madison, AL, USA.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to randbert96310
Default

Well I haven't tried the MySQL yet. I've just been working on PHP on the Apache server. Stoping and starting SQL didn't work. After reading the last reply I plan to do more reading on MySql. I think the book is missing something.
Randbert

Reply With Quote
  #6 (permalink)  
Old April 23rd, 2004, 03:39 PM
Friend of Wrox
Points: 2,570, Level: 21
Points: 2,570, Level: 21 Points: 2,570, Level: 21 Points: 2,570, Level: 21
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: San Diego, CA, USA
Posts: 836
Thanks: 0
Thanked 0 Times in 0 Posts
Default

How about this -- to make sure it's working, remove the password from the root user. See if you can log in without a password.

Whenever you're confronted with a problem you can't figure out, it's best to eliminate as many possibilities as possible. In your case, you don't know if the problem is that the password isn't being accepted, or the server isn't configured right, or it isn't accepting connections, etc.


Take care,

Nik
http://www.bigaction.org/
Reply With Quote
  #7 (permalink)  
Old April 25th, 2004, 12:56 PM
Registered User
 
Join Date: Apr 2004
Location: , , .
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for the advice. I am a total newbie at this and almost no part of this process is intuitive. I googled error 1045 and found a lot of info, but alas still have not solved the problem. As far as eliminating possiblities to find identify and hopefully solve the actual problem... I have this question. When I opened the GUI mysql admin program there was a localhost name of MJOHNSONHOME, I never set that up... I have XP, with two profiles one profile for work and one for home... the IT guys at my previous job set it up that way so i could connect my laptop at work. is this possibly the source of my problem?

Reply With Quote
  #8 (permalink)  
Old April 26th, 2004, 01:45 AM
Registered User
 
Join Date: Apr 2004
Location: , , .
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Nevermind, I unintstalled, reinstalled, reconfigured and it appears to have worked this time. my next question is this. my "my-medium", and so on .cnf files have an icon that says speed dial. when i try to open them, nothing happens. i moved "my-medium" into the c:\ directory as the book recommends, and named it my.cnf. i still can't open it. if anyone has any thoughts.
thanks.
-matt

Reply With Quote
  #9 (permalink)  
Old April 27th, 2004, 05:28 PM
Friend of Wrox
Points: 2,570, Level: 21
Points: 2,570, Level: 21 Points: 2,570, Level: 21 Points: 2,570, Level: 21
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: San Diego, CA, USA
Posts: 836
Thanks: 0
Thanked 0 Times in 0 Posts
Default

That's because Windows associates .cnf files with another application. It's a config file, so you should open it with your text editor (e.g. notepad).


Take care,

Nik
http://www.bigaction.org/
Reply With Quote
  #10 (permalink)  
Old June 24th, 2004, 07:50 PM
Registered User
 
Join Date: Jun 2004
Location: , , .
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Seems there are several problems announced in this thread. This solution helped me on the root password problem:

Connect as root using the following command:
mysql -u root -p mysql

After this the prompt will ask you for a password which is set to 'root' as default in newer versions of MySQL. Like this:

-------------------------------------------------------------------
C:\mysql\bin>mysql -u root -p mysql
Enter password: ****
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 5 to server version: 4.0.20a-nt

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> use mysql;
-------------------------------------------------------------------

You can set the password for individual databases by using the 'update' command:

-------------------------------------------------------------------
update mysql.user set password='wrox' where user='root'
-------------------------------------------------------------------

This will change 'wrox' as a password for root user.

(Thx to anand_smart@http://forums.devshed.com)

Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
need help in testing and configuration of mysql nofences84 MySQL 2 January 5th, 2007 01:04 PM
tomcat configuration madi Apache Tomcat 1 May 18th, 2006 11:48 AM
about php and mysql configuration spbharti BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5 1 April 23rd, 2006 08:25 AM
Configuration Problem azmatazz Biztalk 3 December 22nd, 2005 11:39 AM
Struggling with Configuration RPG SEARCH ASP.NET 1.0 and 1.1 Basics 3 September 29th, 2004 03:06 AM



All times are GMT -4. The time now is 08:28 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.