Skip to content

Document REDIS_PATH #125

@Showfom

Description

@Showfom

Hello,

I just try to install a new pixelfed today but failed when I run php artisan migrate --force

Database version

root@pixelfed ~ # mysql --version
mysql  Ver 15.1 Distrib 10.6.11-MariaDB, for debian-linux-gnu (x86_64) using readline EditLine wrapper

Firstly, I try to use 127.0.0.1 as the DB_HOST but failed:


   Illuminate\Database\QueryException 

  SQLSTATE[HY000] [1045] Access denied for user 'pixelfed_user2'@'127.0.0.1' (using password: YES) (SQL: select * from information_schema.tables where table_schema = pixelfed_database2 and table_name = migrations and table_type = 'BASE TABLE')

  at vendor/laravel/framework/src/Illuminate/Database/Connection.php:712
    708▕         // If an exception occurs when attempting to run a query, we'll format the error
    709▕         // message to include the bindings with SQL, which will make this exception a
    710▕         // lot more helpful to the developer instead of just the database's errors.
    711▕         catch (Exception $e) {
  ➜ 712▕             throw new QueryException(
    713▕                 $query, $this->prepareBindings($bindings), $e
    714▕             );
    715▕         }
    716▕     }

      +36 vendor frames

Then I switch to DB_SOCKET

   InvalidArgumentException 

  Missing UNIX domain socket path.

  at vendor/predis/predis/src/Connection/StreamConnection.php:193
    189▕      */
    190▕     protected function unixStreamInitializer(ParametersInterface $parameters)
    191▕     {
    192▕         if (!isset($parameters->path)) {
  ➜ 193▕             throw new \InvalidArgumentException('Missing UNIX domain socket path.');
    194▕         }
    195▕ 
    196▕         $flags = STREAM_CLIENT_CONNECT;
    197▕ 

      +21 vendor frames 
  22  database/migrations/2021_08_30_050137_add_software_column_to_instances_table.php:44
      App\Jobs\InstancePipeline\InstanceCrawlPipeline::dispatch()

  23  database/migrations/2021_08_30_050137_add_software_column_to_instances_table.php:24
      AddSoftwareColumnToInstancesTable::runPostMigration()

When I try to run the second time:

Migrating: 2021_08_30_050137_add_software_column_to_instances_table

   Illuminate\Database\QueryException 

  SQLSTATE[42S21]: Column already exists: 1060 Duplicate column name 'software' (SQL: alter table `instances` add `software` varchar(191) null, add `user_count` int unsigned null, add `status_count` int unsigned null, add `last_crawled_at` timestamp null)

  at vendor/laravel/framework/src/Illuminate/Database/Connection.php:712
    708▕         // If an exception occurs when attempting to run a query, we'll format the error
    709▕         // message to include the bindings with SQL, which will make this exception a
    710▕         // lot more helpful to the developer instead of just the database's errors.
    711▕         catch (Exception $e) {
  ➜ 712▕             throw new QueryException(
    713▕                 $query, $this->prepareBindings($bindings), $e
    714▕             );
    715▕         }
    716▕     }

      +12 vendor frames 
  13  database/migrations/2021_08_30_050137_add_software_column_to_instances_table.php:22
      Illuminate\Support\Facades\Facade::__callStatic()

      +22 vendor frames 
  36  artisan:37
      Illuminate\Foundation\Console\Kernel::handle()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions