Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

PHP MyAdmin: No Privelages

  • 18-02-2015 6:56pm
    #1
    Registered Users, Registered Users 2 Posts: 2,608 ✭✭✭


    Hi guys, working on a small project for college and have run into some trouble when setting up a local host server (running Mac OS X 10.9.5). I have setup my MySQL and phpMyAdmin but i have "No Privileges" to create a database. I've also tried to create a database through terminal commands with mysql but get this error:
    ERROR 1044 (42000): Access denied for user ''@'localhost' to database 'testbase'

    I have set up username as 'root' and password as 'password'. I'm at a complete loss here and tried everything i could find online. Any ideas??

    I followed this tutorial to set it up


Comments

  • Registered Users, Registered Users 2 Posts: 6,262 ✭✭✭Buford T Justice


    How are you connecting via the command line? Looks like you've not specified a username. You should be connecting using
    mysql -u root 'password'
    

    in order to specify the username to have admin privileges.


  • Registered Users, Registered Users 2 Posts: 2,608 ✭✭✭irish_stevo815


    How are you connecting via the command line? Looks like you've not specified a username. You should be connecting using
    mysql -u root 'password'
    

    in order to specify the username to have admin privileges.

    That just returns an error:
    ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)


  • Technology & Internet Moderators Posts: 28,830 Mod ✭✭✭✭oscarBravo


    Use
    mysql -u root -p<password>
    
    (without a space between -p and the password) or just
    mysql -u root -p
    
    to be prompted for a password.


  • Registered Users, Registered Users 2 Posts: 2,608 ✭✭✭irish_stevo815


    Ok so i uninstalled MySQL and tried starting over. Using this tutorial http://www.maketecheasier.com/setup-web-server-in-mountain-lion/, it was all going ok until I got to setting up thre MySQL root password:
    /usr/local/mysql/bin/mysqladmin -u root password 'password'

    Returned the same errors:
    connect to server at 'localhost' failed
    error: 'Access denied for user 'root'@'localhost' (using password: NO)'


  • Technology & Internet Moderators Posts: 28,830 Mod ✭✭✭✭oscarBravo


    I'm not sure what's going on - have a look here and see if it helps.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 1,299 ✭✭✭moc moc a moc


    /usr/local/mysql/bin/mysqladmin -u root password 'password'

    This command will only work as-is if you don't already have a root password set up. Use the command oscarBravo gave you:

    mysql -u root -p


Advertisement