WordPress.org

Ready to get started?Download WordPress

Forums

trouble selecting proper database (8 posts)

  1. gryffin
    Member
    Posted 10 years ago #

    I looked at the similar posts, and eliminated the problems specified there. I am familiar with both PHP and MySQL, so I know how to manually check for user and db info. When I run wp-admin/install-config.php, it goes through the process of getting the settings I want, and then at step 2 (wp-admin/install-config.php?step=2), it gives me the famous error screen:
    "We're having a little trouble selecting the proper database for WordPress.
    Are you sure it exists?
    Your database name is currently specified as wordpress. Is this correct?
    On some systems the name of your database is prefixed with your username, so it would be like username_wordpress. Could that be the problem?"
    Editing the wp-config.php file manually doesn't seem to help. When I load wp-admin/install.php, it tells me "There doesn't seem to be a wp-config.php file. You must create one before moving on." A neat little Catch-22.
    I can confirm that the user/password are correct. I can confirm that the server name is correct ( I'm testing wordpress on a local box I control ), and both the prefix and the db name ought to be arbitrary. It's like it's skipping the step where the db is created, and won't continue if I provide my own config file. I can check mysql and confirm that no db is created at any point. Even when I give wordpress root access to mysql, nothing happens.
    WTF, over? Thanks!

  2. Matt Mullenweg
    Troublemaker
    Posted 10 years ago #

    Just to confirm, by "editing wp-config.php manually" do you mean opening up wp-config-sample.php, filling in your database connection information, and saving it as wp-config.php in that same directory?

  3. gryffin
    Member
    Posted 10 years ago #

    Yes. Saving the file as wp-config.php in the wordpress root dir.

  4. philor
    Member
    Posted 10 years ago #

    "having a little trouble selecting" comes from the ezSQL class thinking it has a good connection to the db, but then failing on the mysql_select_db() call. You might try going in to wp-includes/wp-db.php and removing the @ in both line 32 (the mysql_connect()) and line 58 (the mysql_select_db()) just to see if there's some useful error message in either one that it's hiding from you.

  5. gryffin
    Member
    Posted 10 years ago #

    Thanks!
    After mucking around a bit, I found out the basic problem. I had assumed the wp scripts would create the db. ( Tables, data yea; the db itself, apparently not. ) This wasn't clear to be from the docs or FAQ or read me. Having created a fresh install, established a fresh config file, install.php progresses! Yay! And there was much rejoicing amongst the cursing.
    But it comes to an odd stop when trying to create the tables. The install page comes up with an error on the top that says:
    SQL/DB Error:
    [Table 'terranop.top_options' doesn't exist]
    SELECT option_name, option_value FROM top_options
    I found that I could copy and paste the create table statements in, but then I would have to copy and past /all/ of the create and insert statements in and I wouldn't be sure the install was complete.
    So I was wondering if you guys had any further insight. Thanks!
    ( Oh, thanks for your quick responses! )

  6. gryffin
    Member
    Posted 10 years ago #

    scratch that, I rumbled through the install process, as recommended elsewhere, and got to step 4 where it barfed. I then went to steps 1-3, and it said setup was already installed. I went to upgrade.php as recommended elsewhere. Okay, now I have db installed ( 88 records in options table, rather than 85 as I was expecting ).
    No it seems to be up, but I don't have the admin password. How is the default password hashed?
    The system really needs some polishing. I dunno why this setup works for others without error.

  7. gryffin
    Member
    Posted 10 years ago #

    if I knew the hashing algorithm used, I could use it to manually change the passwd directly thru mysql

  8. gryffin
    Member
    Posted 10 years ago #

    ah achaa!
    I was looking for a much more complex system than it was in truth. I'm in, but I'm not sure how stable the setup actually is or why it balked ( crapping out at step 3 ) in the first place.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.