snipe / snipe-it

A free open source IT asset/license management system
https://snipeitapp.com
GNU Affero General Public License v3.0
11.12k stars 3.19k forks source link

Can not complete preflight #6196

Closed kevinhopper closed 5 years ago

kevinhopper commented 6 years ago

Please confirm you have done the following before posting your bug report:

Describe the bug During Snipe-IT Pre-Flight I am able to make it to Step 3. After filling out the requested information and upon selecting "Next: Save User" the page just refreshes and fails to proceed. I'm seeing no dialogue as to why this isn't proceeding. I'm running with docker compose and tail the log for snipe but am not getting any output.

To Reproduce Steps to reproduce the behavior:

  1. Go to 'page 3 "Create Admin user'
  2. Fill out all requested information
  3. Click on "Next: Save User"
  4. Page reloads empty

Expected behavior Enter the information, and proceed on to the snipe-it gui.

Screenshots I don't think a screenshot of preflight would be helpful, if you disagree I can of course add one.

Server (please complete the following information):

Desktop (please complete the following information):

Error Messages -- none of this is applicable and console in chrome returns no valuable information.

Additional context

Add any other context about the problem here.

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.

snipe commented 6 years ago

Turn on debugging and check the requests section of the debugger for any errors or messages. https://snipe-it.readme.io/docs/advanced-debugging

kylehemker commented 6 years ago

@kevinhopper were you able to resolve this? I'm having the same exact issue. I've tried regenerating a new APP key, clearing the config cache and re-caching to no avail. I'm also not seeing any errors in the request section after enabling debugging.

EarlRamirez commented 6 years ago

@kylehemker are you getting any errors in from the storage log?

kylehemker commented 6 years ago

Yeah this one stands out.

Next Doctrine\DBAL\Driver\PDOException: SQLSTATE[HY000] [1045] Access denied for user 'sniper'@'localhost' (using password: YES) in C:\inetpub\wwwroot\snipe-it\vendor\doctrine\dbal\lib\Doctrine\DBAL\Driver\PDOConnection.php:47

I can connect to the DB in HeidiSQL with the parameters set in the .env file so I'm not sure what the issue is.

EarlRamirez commented 6 years ago

What version of MySQL/MariaDB are you running, the latest version of MySQL had significant changes and unfortunately PHP is a tad bit behind; therefore, I'll recommend downgrading your version of the DB and try again.

kylehemker commented 6 years ago

MariaDB 10.1

What version should I shoot for?

EarlRamirez commented 6 years ago

my bad, it shows that the password for user sniper is incorrect, that version should work 10.1.17 or a version around there has a problem. I saw you mentioned that the credentials worked using HeidiSQL, can you confirm your credentials in the .env and clear the cache and give it a shot.

kylehemker commented 6 years ago

Okay so I should be good with this version of MySQL?

Yes they work when connecting from HS, here are the creds from the .env:

DB_CONNECTION=mysql DB_HOST=localhost DB_DATABASE=snipeit DB_USERNAME=sniper DB_PASSWORD=supersecretpassword DB_PREFIX=null DB_DUMP_PATH='C:\PROGRA~1\MariaDB 10.1\bin' DB_CHARSET=utf8mb4 DB_COLLATION=utf8mb4_unicode_ci

Here's a snippet from HS: image image

See any issues there?

EarlRamirez commented 6 years ago

for the sake of troubleshooting can you try the root credentials in the .env?

kylehemker commented 6 years ago

I tried swapping the snipe it user for root credentials and the behavior is the same. Just reloads the add user page with wiped out fields.

Any other thoughts?

EarlRamirez commented 6 years ago

I think I'm out of options, the errors show that it is credentials, can you share the output of apt list mariadb-server

kylehemker commented 6 years ago

I'm not sure what command you're referring to but running show databases; produces the following.

+--------------------+ | Database | +--------------------+ | information_schema | | mysql | | performance_schema | | snipeit | | test | +--------------------+

EarlRamirez commented 6 years ago

From the command line (terminal)

kylehemker commented 6 years ago

I'm running on Windows Server 2016 and using IIS, unlike kevinhopper above.

However, running mysql -h localhost -V returns the following:

mysql Ver 15.1 Distrib 10.0.14-MariaDB, for Win64 (x86)

EarlRamirez commented 6 years ago

@kylehemker can you try and downgrade your version of MySQL and let us know how it goes?

kylehemker commented 6 years ago

Sure what version should I downgrade to @EarlRamirez? I just installed the version mentioned in the SnipeIT documentation. https://snipe-it.readme.io/docs/requirements MariaDB 10.0.14 for Windows

stale[bot] commented 5 years ago

Is this still relevant? We haven't heard from anyone in a bit. If so, please comment with any updates or additional detail. This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Don't take it personally, we just need to keep a handle on things. Thank you for your contributions!

stale[bot] commented 5 years ago

This issue has been automatically closed because it has not had recent activity. If you believe this is still an issue, please confirm that this issue is still happening in the most recent version of Snipe-IT and reply to this thread to re-open it.