Online demo Privacy policy GoBD notes Blog

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
current:upgrade [2015/08/04 14:40]
sj created
current:upgrade [2019/04/29 21:47] (current)
sj
Line 5: Line 5:
  
 **Generic notes** **Generic notes**
 +
 +It's strongly recommended to backup your configs including piler.key, piler.conf, piler.pem, sphinx.conf and config-site.php before the upgrade.
  
 If you upgrade from older releases then you should apply all the intermediate changes, ie. when upgrading from 0.1.18 to 0.1.20 please apply both db-upgrade-0.18-vs-0.19.sql and db-upgrade-0.19-vs-0.20.sql sql scripts. If you upgrade from older releases then you should apply all the intermediate changes, ie. when upgrading from 0.1.18 to 0.1.20 please apply both db-upgrade-0.18-vs-0.19.sql and db-upgrade-0.19-vs-0.20.sql sql scripts.
Line 215: Line 217:
 </code> </code>
  
 +**from 1.1.1 to 1.2.0**
 +
 +There're some minor incompatibilities from 1.1.x to 1.2.0 you must be aware of.
 +Be sure to read RELEASE_NOTES file in the source directory describing the changes.
 +
 +The most important change is that I've moved all piler related configs to ${sysconfdir}/piler
 +directory (with the default options it's /usr/local/etc/piler).
 +
 +It means that whatever (piler related stuff) you had in /usr/local/etc, that must be moved to
 +/usr/local/etc/piler, eg. /usr/local/etc/piler.conf -> /usr/local/etc/piler/piler.conf, etc.
 +
 +I've decided to put the sphinx config file to  ${sysconfdir}/piler. Debian and Ubuntu ship
 +a sphinx package which enabled a periodic indexer --all cron job, which practically destroys
 +the sphinx indices, and despite both the install docs and the FAQ warn about it, many piler
 +users fell for this debian 'trick'.
 +
 +To match the new path, I've updated the rc.searchd file, and the indexer shell scripts as well.
 +
 +Execute the following sql script on the piler database:
 +
 +<code>
 +mysql -u piler -p piler < util/db-upgrade-1.1.0-vs-1.2.0.sql
 +</code>
 +
 +I recommend you to run pilerconf after the upgrade, and check if you get the values in piler.conf
 +back. If so, then the config files are at the proper new location.
 +
 +**from 1.2.0 to 1.3.0**
 +
 +Nothing extra is required.
 +
 +**from 1.3.0 to 1.3.5**
 +
 +The default mysql encoding has been changed from utf8 to utf8mb4. In mysql's terms 'utf8' is only a subset of the 4 byte range of the UTF-8 encoding. To provide full UTF-8 support mysql offers utf8mb4 encoding which is the default starting from 1.3.2. 
 +For new installations I recommend you to use the default (utf8mb4).
 +
 +When upgrading you may either convert your database and tables to utf8mb4 (see the discussion at https://bitbucket.org/jsuto/piler/issues/709/mysql_stmt_execute-error-incorrect-string and/or google the exact steps), or keep the current mysql settings.
 +
 +In the latter case be sure to set the following values:
 +
 +piler.conf:
 +<code>mysqlcharset=utf8</code>
 +
 +config-site.php:
 +<code>$config['DB_CHARSET'] = 'utf8';</code>
 +
 +sphinx.conf (for all sql_query_pre settings!):
 +<code>sql_query_pre = SET NAMES utf8</code>
 +
 +Perform the following sql statements:
 +
 +<code>
 +alter table sph_index change column `from` `from` tinyblob default null;
 +alter table metadata change column `from` `from` varchar(255) not null;
 +alter table metadata change column `fromdomain` `fromdomain` varchar(255) not null;
 +alter table metadata change column `message_id` `message_id` varchar(255) not null;
 +alter table attachment change column `name` `name` tinyblob default null;
 +alter table sph_index change column `body` `body` mediumblob default null;
 +alter table sph_index change column `subject` `subject` blob default null;
 +</code>
 +
 +And add the following jobs to piler's crontab:
 +
 +<code>
 +*/5 * * * * /usr/bin/find /var/piler/error -type f|wc -l > /var/piler/stat/error
 +3 * * * * /usr/local/libexec/piler/watch_sphinx_main_index.sh
 +</code>
  
Google Analytics Alternative