Laravel can not open SQLite database

Posted 3 years ago by vlehnen

Hy, I got a very strange behaviour in my L 5.1 app. I use two databases. One is an MySQL, the other is a SQLIte. If the SQLite file does not exist, is automaticaly created within a provider. The only table inside is also created here. I created a model to access the SQLite. The database file has the owner and group of the httpd.

The strange thing here is, that the app runs on Homestead and on my Ubuntu/NginX box without problems. On the live platform, the SQLite gots created and can be accessed using PHP CLI without any problems, but when Laravel tries to access the database I got the message: 'PDOException' with message 'SQLSTATE[HY000] [14] unable to open database file' in /is/htdocs/wp1112779_D78VPLAD5V/dev/cmadmin/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:50.

The path must be correct, because it is defined in a config file and the provider that creates the database uses this path also.

I got no idea, what is going on there.

Please sign in or create an account to participate in this conversation.