Going to the next page after Pre-Flight created all Database Entrys
Getting the following Error Messages:
(3/3) QueryException
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'snipeit.oauth_clients' doesn't exist (SQL: insert into `oauth_clients` (`user_id`, `name`, `secret`, `redirect`, `personal_access_client`, `password_client`, `revoked`, `updated_at`, `created_at`) values (, Snipe-IT Personal Access Client, yaOQTCf8Jr0xUMrvGSiAWpstJifxZV6CoCVkXYWt, http://localhost, 1, 0, 0, 2017-11-14 14:08:55, 2017-11-14 14:08:55))
(2/3) PDOException
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'snipeit.oauth_clients' doesn't exist
(1/3) PDOException
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'snipeit.oauth_clients' doesn't exist
app/storage/logs and your webserver's logs.Please do not post an issue without answering the related questions above. If you have opened a different issue and already answered these questions, answer them again, once for every ticket. It will be next to impossible for us to help you.
Run php artisan migrate via command line
Hey @snipe
Many thanks! That did the trick. I didn't thought, that this has to be done in a freshly new installation.
@TheLux83 the quick start should be doing that for you but we might have gotten a few things out of order. The oauth stuff is weird and a little different. We'll take a look at the quick start and make sure there's nothing something we can optimize there.
Install snipe-IT is so bug, missing many things
@nhatdv I assure you it's not "so bug". We deploy this every day for customers using the same code base here. If you have an specific issue, feel free to open a ticket, but the system is stable.
Just ran into this problem as well, and running php artisan migrate inserted the tables into the database correctly.
php artisan migrate fixed this particular error for me too, but I also had to run php artisan passport:install --force to get token generation going.
I was getting this exception:
2019-11-23 11:57:22] production.ERROR: ErrorException: Trying to get property of non-object in /opt/snipe-it/vendor/laravel/passport/src/ClientRepository.php:81
Stack trace:
#0 /opt/snipe-it/vendor/laravel/passport/src/ClientRepository.php(81): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError(8, 'Trying to get p...', '/opt/snipe-it/v...', 81, Array)
#1 /opt/snipe-it/vendor/laravel/passport/src/PersonalAccessTokenFactory.php(71): Laravel\Passport\ClientRepository->personalAccessClient()
#2 /opt/snipe-it/vendor/laravel/passport/src/HasApiTokens.php(67): Laravel\Passport\PersonalAccessTokenFactory->make(1, 'TestToken', Array)
#3 /opt/snipe-it/vendor/laravel/passport/src/Http/Controllers/PersonalAccessTokenController.php(70): App\Models\User->createToken('TestToken', Array)
#4 /opt/snipe-it/vendor/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php(48): Laravel\Passport\Http\Controllers\PersonalAccessTokenController->store(Object(Illuminate\Http\Request))
#5 /opt/snipe-it/vendor/laravel/framework/src/Illuminate/Routing/Route.php(212): Illuminate\Routing\ControllerDispatcher->dispatch(Object(Illuminate\Routing\Route), Object(Laravel\Passport\Http\Controllers\PersonalAccessTokenControl
ler), 'store')
This was on CentOS 7.6, Zabbix v4.7.8 - build 4170 (master) and a manual install (IIRC).
I ran into this issue on a fresh install following the directions.
Version v4.8.0 - build 4186 (master)
APP_ENV = development
Had to drop the database before running the command because it said the tables already existed when I ran php artisan migrate after getting the error on the web gui.
Same here. Fresh install 4.9.2 on debian 10 with nginx/mariadb.
Had to run commands to make API token creation. First create the missing tables and second command generated the "Personal access client" & "Password grant client". Then I was able to create my own one.
php artisan migrate
php artisan passport:install --force
Same problem here, fresh install on 4.9.3.
When preessing the "Create database tables" button on the pre flight, I got a "Whoops, looks like something went wrong. "
After running
php artisan migrate
php artisan passport:install --force
I could setup a user.
Same problem here, fresh install on 4.9.3.
When preessing the "Create database tables" button on the pre flight, I got a "Whoops, looks like something went wrong. "
After running
php artisan migrate
php artisan passport:install --force
I could setup a user.
I had to run those commands as well in my fresh install.
Most helpful comment
Run
php artisan migratevia command line