[drupal-support] Installation issues
Paul Greene
techlists at comcast.net
Tue Apr 26 20:31:37 UTC 2005
Thanks to Eric, Torgeir, Alejandro, Djun, and Gerhard,
Between your comments, and a "MySQL in 24 Hours" book, I got the
databases created, and added a couple of user accounts; one with full
privileges, and one with select and insert (is select and insert enough
privileges to give a regular user?).
I do intend to put this online at some point, so security is a concern.
Thanks,
Paul
Eric Scouten wrote:
> Paul Greene wrote:
>
>>>> I ran the next line in the installation instructions:
>>>>
>>>> mysqladmin -u dba_user -p create drupal
>>>>
>>>> It prompted for a password; I entered a password and got the following
>>>> response:
>>>>
>>>> mysqladmin: CREATE DATABASE failed; error: 'Access denied for user
>>>> ''@'localhost' to database 'drupal''
>
>
>> How do you create a user in MySQL? (let me reiterate I'm just as new
>> at MySQL as I am at Drupal).
>>
>> Or does MySQL use operating system level user accounts? I've tried
>> "mysql", "dba_user", and "root" and none of them have worked. MySQL
>> only added the "mysql" account on its own.
>
>
> As Torgeir said, MySQL maintains its own list of user accounts that is
> unrelated to the Unix system's user accounts.
>
> If you've been given a username and password by someone else who runs
> the MySQL server, you *must* put a space between the -u and the user
> name and you must *not* put a space between the -p and the password.
> (Yes, I know this is confusing.) Thus:
>
> $ mysql -u whoami -psecret drupal
>
> assuming username "whoami", password "secret", database name "drupal".
>
> If you are running your own machine, you probably have root access to
> MySQL which you can then use to create new MySQL accounts. It would look
> something like this:
>
> $ mysql -u root
>
> mysql> create database mysite;
> Query OK, 1 row affected (0.04 sec)
>
> mysql> grant all on mysite.* to whoami at localhost identified by
> "secret";
> Query OK, 0 rows affected (0.22 sec)
>
> mysql> exit;
> Bye
>
> $ mysql -u whoami -psecret mysite
>
> The "grant all" command creates a new user and password and grants that
> user all permissions on the specified database.
>
> Hope this helps...
>
> -Eric
More information about the drupal-support
mailing list