@anonymous-matomo-user opened this Issue on April 30th 2008

I'm testing piwik, (piwik 0.1.5, mysql 4.1.21, php 5.2.5, PDO Driver for MySQL 5.0.41),
and after a week running ok, it has showed this error in two plugins ("Pages" and "List of Keywords"), in the summary for a specific day, in just one site:
for example in plugin "Pages" (the other error is very similar):


Warning: gzuncompress() [function.gzuncompress]: data error in /piwik/modules/Archive/Single.php on line 246
Backtrace -->
#0 Piwik_ErrorHandler(2, gzuncompress() [data error, /piwik/modules/Archive/Single.php, 246, Array (name => Actions_actions,[=> blob,table => piwik_archive_blob_2008_04,[=> Zend_Db_Adapter_PdoMysql Object ( => mysql,[=> Array (host => localhost,[=> ****,password => *_*,[=> ***,tables_prefix => piwik_,[=> PDO_MYSQL,options => Array ([=> 0,autoQuoteIdentifiers => 1),[=> Array ()), => 2,[=> Zend_Db_Profiler Object ( => Array (),[=> , => ,[=> ), => PDO Object (),[=> 0, => 1),[value] => x??o$I?$???mn???{


And it continues on with a very very long binary chunk.

It occurs only in the site that has >5,000 visits per day, and just in one day.
I have other sites with less visits, and they run ok.

mysqlcheck says that there's no corrupted table.

Both plugins contains thousands of entries... couldn't be a way to limit their size? May be the size is not related, but it's enormous anyway.

Keywords: gzuncompress Single.php

@mattab commented on May 6th 2008 Member

Did it happen only once?

For your query of 'limit the size of the data' this is indeed a very important feature we are planning to implement: see #5456

@anonymous-matomo-user commented on May 6th 2008

No, it seems to happen every time the size of the data is too big (thousands of entries) in those two plugins ("Pages" and "List of Keywords"). (Though I haven't tried every plugin). As I said, the site with the problem has >5,000 visits/day...
If some day visits are lower, the plugins run ok, but if visits are big, the error appears.

I thought it could be related to the php gzuncompress function itself, but I used it with big data, and it compress and uncompress perfectly. May be something related to mysql, or the way the field is stored? If I could know the exact field from the DB in which data resides, I'd try to check it, but the table has thousands of entries, and I wasn't able to find which registry the php tries to read...


@mattab commented on May 9th 2008 Member

rsg, finally could reproduce the bug and it comes from the BLOB field limit to 2^16 characters, ie. 65535 bytes.
I changed the types to MEDIUMBLOB which will allow 16MB fields.

The new tables will be available for new users. For existing users, please use this query on your piwik_archive_blob* tables:

@mattab commented on May 9th 2008 Member

(In [470]) - refs #5623, fixing tables field types, limit is now MEDIUMBLOB to allow up to 16M values. Previous BLOB limit of 64K was not enough.

This Issue was closed on August 13th 2009
Powered by GitHub Issue Mirror