Menu

Database creation by phpgedview problem

Help
2020-03-18
2020-03-30
  • David Ledger

    David Ledger - 2020-03-18

    After my last few questions I got phpgedview running reasonably reliably
    on my Mac Mini upstairs. It is an oldish machine and the database
    sometimes needs to be restarted. For other reasons I have started a
    Lightsail server on Amazon Web Services (AWS). I decided to add
    phpgedview to it so I had a more reliable server.

    When I've installed it before the Installation Wizard has had no
    problems creating the database tables. This time it does one table each
    time it is run.

    My database user for phpgedview is 'pgv43'.
    mysql version:- Ver 8.0.18 for linux-glibc2.12 on x86_64 (MySQL
    Community Server - GPL)

    Logging in to mysql as either 'root' or 'pgv43' gives me:
    mysql> show grants for pgv43;
    +--------------------------------------------------------------------------------+
    | Grants for pgv43@%
    |
    +--------------------------------------------------------------------------------+
    | GRANT USAGE ON . TO pgv43@%
    |
    | GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX ON pgv43.*
    TO pgv43@% |
    +--------------------------------------------------------------------------------+
    2 rows in set (0.00 sec)

    After running the Wizard seven times I see:
    mysql> show tables;
    +------------------+
    | Tables_in_pgv43 |
    +------------------+
    | pgv_blocks |
    | pgv_favorites |
    | pgv_individuals |
    | pgv_messages |
    | pgv_mutex |
    | pgv_news |
    | pgv_site_setting |
    +------------------+
    7 rows in set (0.00 sec)

    Each time it failed with:
    SQLSTATE[42000]: Syntax error or access violation: 1142 INDEX command
    denied to user 'pgv43'@'localhost' for table 'pgv_...'

    with pgv_... being each of the created tables in turn.

    The Wizard is obviously connecting to the database correctly.

    Even if I set:
    mysql> show grants for pgv43;
    +--------------------------------------------------+
    | Grants for pgv43@% |
    +--------------------------------------------------+
    | GRANT USAGE ON . TO pgv43@% |
    | GRANT ALL PRIVILEGES ON pgv43.* TO pgv43@% |
    +--------------------------------------------------+
    2 rows in set (0.00 sec)

    it produces the same error.

    I've been working with Postgres recently, so I may have something
    obvious wrong. Any ideas please?

    David

     
    • David Ledger

      David Ledger - 2020-03-30

      On 2020-03-18 16:00, David Ledger wrote:

      After my last few questions I got phpgedview running reasonably reliably
      on my Mac Mini upstairs. It is an oldish machine and the database
      sometimes needs to be restarted. For other reasons I have started a
      Lightsail server on Amazon Web Services (AWS). I decided to add
      phpgedview to it so I had a more reliable server.

      When I've installed it before the Installation Wizard has had no
      problems creating the database tables. This time it does one table each
      time it is run.

      I haven't yet got a proper diagnosis for this, but repeating a forwards
      <-> back until all tables were created got it running. The installation
      da been working for a week ans a half now.

      I now have an unrelated question and a bug, which I'll create new
      threads for.

      David

       

Log in to post a comment.