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
Page URLs hostnames are not set correctly when importing logs with cs-host field #7341
Comments
Hi @Brutonix thanks for the report. Can you please paste here a short log file (maybe 10-20 lines) so we can try reproduce the issue? |
Mattab, |
Thanks for the instructions above, they are really great 👍 but to reproduce, since none of us use IIS, it would help to get the log file. Could you send it, even privately to hello@piwik.org ? |
Ah, I see, will do when I'm at work tomorrow. |
@Brutonix any update maybe about this short log file we could use to reproduce? |
Maybe it's similar or duplicate of #7396 |
Matthieu, An email was sent on the 4th March. Do you need me to send it again ? Regards
|
Thanks @Brutonix - it would be great if you could send your log again to hello@piwik.org as I didn't get it the last time. Also I've created an issue for this bug in log-analytics project: matomo-org/matomo-log-analytics#67 |
Scenario:
1 website installed on Windows 2008 r2 IIS 7.5. The website is configured with several bindings. eg. http://www.mysite1.com, http://www.mysite2.com, http://www.mysite3.com
The IIS logs are configured with the default settings and I have added cs-host to be recorded.
I have installed Piwik 2.11.1 on a linux server and configured a site with ID:16, Name:MySite, URLs:http://www.mysite1.com, http://www.mysite2.com, http://www.mysite3.com and left everything else as default.
I then run the import_logs.py that was supplied with the Piwik installation.
Within Piwik, the Vistor Log displays the default website address http://www.mysite1.com and not the correct URL that was hit.
The IIS logs report the correct URL / cs-host
If you amend some lines in import_logs.py, the correct information is displayed within Piwik.
From line 1468, make the following changes:
only prepend main url if it's a path
url = (main_url if path.startswith('/') else '') + path[:1024]
try:
url = 'http://' + hit.host + path
except AttributeError:
url = (main_url if path.startswith('/') else '') + path[:1024]
And now my Visitor Logs report the correct URL
The text was updated successfully, but these errors were encountered: