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

Piwik Auto Archiving - archive.windows.ps1 - 'superuser' access #1959

Closed
anonymous-matomo-user opened this issue Jan 5, 2011 · 7 comments
Closed
Labels
Task Indicates an issue is neither a feature nor a bug and it's purely a "technical" change. wontfix If you can reproduce this issue, please reopen the issue or create a new one describing it.
Milestone

Comments

@anonymous-matomo-user
Copy link

Hi, I recently set up auto archiving on a Windows server using archive.windows.ps1.

PDF Reports aren't being sent out so I ran the script and this is the output:

Starting Piwik archiving...
Piwik archiving finished.
Starting Scheduled tasks...

X-Powered-By: PHP/5.2.13
Set-Cookie: PIWIK_SESSID=660b885c100e129d6672ae898793b22b; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-type: text/html

Error: You can't access this resource as it requires a 'superuser' access.
Finished Scheduled tasks.

Do you know why I'm getting "Error: You can't access this resource as it requires a 'superuser' access." when it tries to run scheduled tasks?

@anonymous-matomo-user
Copy link
Author

I just realised it seems to not be archiving any of the 20 sites I have on there either..
I've temporarily defined $PIWIK_SUPERUSER and $PIWIK_SUPERUSER_MD5_PASSWORD directly in the code and still no luck.
When it executes;

$TOKEN_AUTH= & $PHP_BIN -c $PHP_INI "$PIWIK_PATH" "--" "module=API&method=UsersManager.getTokenAuth&userLogin=$PIWIK_SUPERUSER&md5Password=$PIWIK_SUPERUSER_MD5_PASSWORD&format=php&serialize=0"

it returns a token, but something is wrong as it thinks the superuser isn't a superuser :-(

@mattab
Copy link
Member

mattab commented Jan 10, 2011

Are you sure about your super user token? when you execute this in the browser with the same token_auth as you use in the archive.sh, does it trigger archiving?

@robocoder
Copy link
Contributor

Probably unrelated, but the script should use the -q flag so that php-cgi doesn't emit the HTTP headers.

@robocoder
Copy link
Contributor

(In [3705]) refs #1959 - use -q flag in case php.exe is the cgi binary

@mattab
Copy link
Member

mattab commented Feb 17, 2011

Have you tried with the -q flags (as per previous comment) please let us know

@mattab
Copy link
Member

mattab commented Apr 28, 2011

no update for 2 months, assuming it is working...

@mattab
Copy link
Member

mattab commented Jan 31, 2014

In 916d8d6: Starting January 2014, this script is now deprecated. Please only use the standard archive.php script in your scheduled task setup. See documentation at: http://piwik.org/docs/setup-auto-archiving/ Refs #1959 #1411 #2848

@anonymous-matomo-user anonymous-matomo-user added this to the 1.x - Piwik 1.x milestone Jul 8, 2014
@mattab mattab added the wontfix label Aug 3, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Task Indicates an issue is neither a feature nor a bug and it's purely a "technical" change. wontfix If you can reproduce this issue, please reopen the issue or create a new one describing it.
Projects
None yet
Development

No branches or pull requests

3 participants