Super user edit config.ini.php to correct login URL


#1

Hi, I’ve moved my website provider and successfully transferred Piwik as well. I now have the problem, that when trying to log in from mydomain.com/piwik/ I get the following error message:

[quote=“How do I fix this problem and how do I login again? The Piwik Super User can manually edit the file piwik/config/config.ini.php and add the following lines: [General] trusted_hosts[] = “user.server.uberspace.de” After making the change, you will be able to login again.”]

[/quote]

(user is my usersname and server is the server I am on with uberspace (the hoster)).

Now I’m unsure, where in that file to add that line.

config.ini.php looks like:

; <?php exit; ?> DO NOT REMOVE THIS LINE
; file automatically generated or modified by Piwik; you can manually override the default values in global.ini.php by redefining them in this file.
[General]
trusted_hosts[] = “user.server.uberspace.de

[database]
host = "127.0.0.1"
username = "user"
password = "pw"
dbname = "user_piwik"
tables_prefix = “piwik_”

[superuser]
login = "loginname"
password = "pw"
email = "mail"
salt = “saltgoeshere”

[PluginsInstalled]
list of plugins

After modifying the file I put it back into the config folder. But nothing changes. The login trouble persists. Thanksful for any help…


(Matthieu Aubry) #2

Do you have only one [General] section in your file? is the error the same always displayed?


#3

Hi Matt,

  1. yes only this one line for [General] exists and I’ve put it up there. As the error message does not include any info, where to put that info.
  2. Yes, the error message when trying to login from mydomain.com/piwik is always the same.

If this is not solvable maybe I should just change the bookmark although that isn’t that nice? But at least it works.


(Matthieu Aubry) #4

it works for me, can’t reproduce?


#5

Issue persists here. Maybe I should get in touch with the hoster. Might be a known issue.


(Matthieu Aubry) #6

This bug was fixed in 2.0 beta, please confirm

http://forum.piwik.org/read.php?2,106854,106854#msg-106854

NOTE: the message is changed to output the correct help message. as you will see the suggestion to add to config file has changed :slight_smile:


#7

Hi Matt,

was reluctant because I was afraid to run into more trouble with a beta version. Well during the automatic update something went very wrong. I got the following critical error message:

/var/www/virtual/username/html/piwik/core/Updates/2.0-a13.php:
Error trying to execute the query 'UPDATE piwik_option SET option_name = ‘version_ScheduledReports’ WHERE option_name = ‘version_PDFReports’ '.
The error was: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘version_ScheduledReports’ for key ‘PRIMARY’

Now I’m completely stuck.


(Matthieu Aubry) #8

Apply this patch which should fix it for you Fixing issue reported in http://forum.piwik.org/read.php?2,106895 · matomo-org/matomo@7c2111d · GitHub


#9

Consider this closed. I had someone fix all open issues. Both the critical error and the login via the correct URL.