@wesleyscottrichards opened this Issue on January 5th 2015

Hi there,

we've got Piwik 2.3.0 for our university in use and the various departments have their own Piwik ID. Overall, we have about 100 000 pageviews per day. Archiving of data is done via the cron job runs once per hour.
In the individual departments, there are users with normal privileges to view the statistics. These have so far also create segments. But which were generated at runtime what the performance is heavily loaded.
I have now set in the config "enable_create_realtime_segments = 0".
Now normal user can't create any segments anymore. That is very unfortunate.
Why do I need Admin rights to create segments that are archived by the cronjob?

Is it a problem if I change the code in "plugins/SegmentEditor/api.php in something like this?

protected function checkAutoArchive($autoArchive, $idSite)
$autoArchive = (int)$autoArchive;
if ($autoArchive) {
$exception = new Exception("To prevent abuse, autoArchive=1 requires Super User or ontrollerAdmin access.";
if (empty($idSite)) {
if (!Piwik::hasUserSuperUserAccess()) {
throw $exception;
//else {
// if (!Piwik::isUserHasAdminAccess($idSite)) {
// throw $exception;
// }
// }
return $autoArchive;

Please excuse my English. I hope you understand what I mean.

Thank you in advance for your efforts.


@mattab commented on January 6th 2015 Member

Hi @wesleyscottrichards can you please upgrade to 2.10.0 ? the code looks already different as we fixed some issues there. see #6767 #6373 #5923 etc

This Issue was closed on January 6th 2015
Powered by GitHub Issue Mirror