[resolved] MySQL Client 'Access Denied' on database creation (3 posts)

  1. 100PercentNick
    Posted 4 years ago #

    Hi guys,

    I'm trying to go through the wordpress installation guide from MySQL Client (as found in the ( wordpress codex) and I'm having problems doing the basic steps.

    I'm using a Macbook and accessing MySQL from iTerm. I want to have a local wordpress installation on this machine for site development.

    When I go through the tutorial mentioned above and type the following command into iTerm: mysql -u adminusername -p (substituting adminusername for 'nickadams' my username on this machine) it prompts me for a password.

    If I use general password for my useraccount (typically used when I 'sudo' a command, for example) it throws up the error: ERROR 1045 (28000): Access denied for user 'nickadams'@'localhost' (using password: YES)

    If I try the above command again while leaving the password prompt blank, it lets me into mysql, but when I try the next command in the tutorial CREATE DATABASE databasename; I get another error message: ERROR 1044 (42000): Access denied for user ''@'localhost' to database 'wordpress'

    I'm not too sure what I'm doing wrong here. Any suggestions?

  2. Christi
    Posted 4 years ago #

    Hi 100PercentNick,

    This question really should have been posted in the Localhost Installs part of the forum but I'll offer some suggestions. Make sure you are following the instructions here from the Codex since you are wanting to install WordPress on your local computer instead of to a traditional web server environment:



    Hope that information helps!

  3. 100PercentNick
    Posted 4 years ago #

    I've solved the problem now.

    The username and password on my user area are not the same as the on mysql!.

    On my machine I needed to log into mysql as 'root':

    mysql -u root -p

    and then following everything else through the wordpress codex about creating a database and username worked fine

Topic Closed

This topic has been closed to new replies.

About this Topic