I'm getting a 403 error when attempting to import my (nginx) logs using import_logs.py. I've verified:
- The web UI is working fine and collecting statistics.
- I've verified that the token_auth is correct by accessing the API over HTTP
- The same error occurs whether I use token_auth or login/password with import_logs.py
- I've verified that the server can access the web UI, so it's not a weird firewall rule preventing it from accessing itself
root@harrenhal:~# python /home/piwik/piwik/misc/log-analytics/import_logs.py --url='http://piwik.petterhaggholm.net' --enable-static --enable-bots --enable-http-errors --enable-http-redirects /var/log/nginx/phnet.access.log --idsite='1' --debug --token-auth='********************************' 2013-08-06 16:02:37,180: [DEBUG] Accepted hostnames: all 2013-08-06 16:02:37,180: [DEBUG] Piwik URL is: http://piwik.petterhaggholm.net 2013-08-06 16:02:37,180: [DEBUG] Authentication token token_auth is: ******************************** 2013-08-06 16:02:37,181: [DEBUG] Resolver: static 2013-08-06 16:02:37,216: [DEBUG] Error when connecting to Piwik: HTTP Error 403: Forbidden 2013-08-06 16:02:39,250: [DEBUG] Error when connecting to Piwik: HTTP Error 403: Forbidden 2013-08-06 16:02:41,291: [DEBUG] Error when connecting to Piwik: HTTP Error 403: Forbidden Traceback (most recent call last): File "/home/piwik/piwik/misc/log-analytics/import_logs.py", line 1573, in <module> resolver = config.get_resolver() File "/home/piwik/piwik/misc/log-analytics/import_logs.py", line 529, in get_resolver return StaticResolver(self.options.site_id) File "/home/piwik/piwik/misc/log-analytics/import_logs.py", line 872, in __init__ 'SitesManager.getSiteFromId', idSite=self.site_id File "/home/piwik/piwik/misc/log-analytics/import_logs.py", line 854, in call_api return cls._call_wrapper(cls._call_api, None, None, method, **kwargs) File "/home/piwik/piwik/misc/log-analytics/import_logs.py", line 843, in _call_wrapper raise Piwik.Error(message) __main__.Error: ForbiddenAnyone have any advice/ideas?