Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

something missing on setting db on install #13812

Closed
NathanQ opened this issue Dec 7, 2018 · 5 comments
Closed

something missing on setting db on install #13812

NathanQ opened this issue Dec 7, 2018 · 5 comments
Labels
worksforme The issue cannot be reproduced and things work as intended.

Comments

@NathanQ
Copy link

NathanQ commented Dec 7, 2018

I had an issue if I didn't set the db info before using the composer, installing didn't work and the site said ""Error: Matomo is already installed." I went back and forth a little bit on this trying to set it in the config.ini.php after set up with this result. Maybe a bit of chicken and egg issue. The matomo/config/global.ini.php states "Edit the config.ini.php instead," but it is not present before setup. Anyway, setting db in the matomo/config/global.ini.php like so got me running.

[database]
host = "127.0.0.1"
username = "matomo"
password = "matomolikeamomo"
dbname = "matomodb"
tables_prefix =
port = 3306
adapter = PDO\MYSQL
type = InnoDB
schema = Mysql

Maybe I missed something in the docs?

Thanks

@tsteur
Copy link
Member

tsteur commented Dec 9, 2018

Can you confirm you installed Matomo through git, init & updated all submodules, ran composer, and did not have yet a config/config.ini.php? Is this the full error message?

If you don't want to develop on top of Matomo, I recommend to download the latest version from https://matomo.org/download/ btw compared to git.

@NathanQ
Copy link
Author

NathanQ commented Dec 10, 2018

Hi @tsteur, I can confirm this, but I ran into issues with permissions issues and had to run the sudo chown -R www-data:www-data ./*various_dirs* create directories in the tmp directory during setup which may be where this stems from. This was a fresh install of php, mysql, and nginx and they're users ran as their default installed on Ubuntu 18.04 server. For instance, when I run the composer, the new directories' permissions were displayed as question marks. My user wasn't meshing right. I did get up and running, but I'll try it again.

@tsteur
Copy link
Member

tsteur commented Dec 10, 2018

AFAIK there aren't any known issues from our side and I reckon it is indeed just some server configuration. The various_dirs are expected to need write permission, eg also the config directory. The config/config.ini.php is created during the installation. Where are you stuck in the installation process exactly? Does it even load? Otherwise composer should for sure not require any DB configuration.

@NathanQ
Copy link
Author

NathanQ commented Aug 23, 2019

Hi again.
Went to update and ran into permission issues. Updating under one user and my webserver runs as another unable to read the other user's files. Where are the server user and group permissions documented?
Thank you!

@NathanQ
Copy link
Author

NathanQ commented Aug 23, 2019

Got it running. If the server setup includes say a user other than the web server user. Mine's matomo and my web server is www-data.

On setup and after updates, in the matomo/tmp directory these commands must be run:

sudo chown matomo:www-data -R .
sudo find . -type d -exec chmod 2775 {} \;
sudo find . -type f -exec chmod 664 {} \;

@NathanQ NathanQ closed this as completed Aug 23, 2019
@tsteur tsteur added the worksforme The issue cannot be reproduced and things work as intended. label Aug 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
worksforme The issue cannot be reproduced and things work as intended.
Projects
None yet
Development

No branches or pull requests

2 participants