====== pkgsrc-2008Q2 ====== Released in summer 2008. Most notable change is that Ruby was updated to 1.8.7, which means only Rails 2.1.0 or newer will work, and PostgreSQL was bumped to 8.3 (with storage format not backwards compatible, see below). ===== Update gotchas ==== There are some updates that are known to fail, when updating to 2008Q2 using the pkg_chk based approach (see [[updating]]). ==== Ruby 1.8.7 ==== Some Rails apps (including Radiant CMS) won't work with Ruby 1.8.7. To downgrade Ruby, follow these steps. If you see any messages stating that there are dependencies, ignore them. These packages are forcefully removed as they will be replaced by the older version of Ruby, so no harm is done to those packages. 1. Download the necessary software. wget http://pkgsrc.joyent.com/2007Q4/All/ruby18-base-1.8.6.111.tgz wget http://pkgsrc.joyent.com/2007Q4/All/ruby-1.8.6.111.tgz wget http://pkgsrc.joyent.com/2008Q1/All/rubygems-1.1.1.tgz 2. Delete Ruby. pkg_delete -f ruby18-base pkg_delete -f ruby At this point, Ruby has been removed. 3. Reinstall Ruby (this time, 1.8.6). pkg_add ./ruby18-base-1.8.6.111.tgz pkg_add ./ruby-1.8.6.111.tgz 4. Reinstall gem. We're downgrading to an older version that supports 1.8.6. pkg_delete -f rubygems pkg_add ./rubygems-1.1.1.tgz 5. Create some symlinks to ensure that OpenSSL works with Ruby. This is probably a hack, and if anyone has a better way, please update this page. ln -s /opt/local/lib/libcrypto.so.0.9.8 /opt/local/lib/libcrypto.so.0.9.7 ln -s /opt/local/lib/libssl.so.0.9.8 /opt/local/lib/libssl.so.0.9.7 ==== PostgreSQL 8.3 ==== The postgresql82-client and postgresql82-server packages will still be reported as missing, because they are no longer provided in this package set release. Instead, PostgreSQL 8.3 is available. Beware though that the database storage format changed from 8.2 to 8.3, so you'll need to re-create all your databases. See the [[http://www.postgresql.org/docs/8.3/interactive/install-upgrading.html|official upgrade documentation]] for more. Before you run pkg_chk at all, you should back up all your databases: /opt/local/bin/pg_dumpall > dumpfile /usr/sbin/svcadm disable postgresql Make sure to have the dumpfile generated in a directory that has enough space left. (E.g. if you have a very large database set, using /tmp would be a bad choice.) Now run the pkg_chk part, and after it's done: mv /var/pgsql/data /var/pgsql/data82 /opt/local/sbin/pkg_add postgresql83 su - psql /opt/local/bin/initdb --pgdata=/var/pgsql/data --encoding=UTF8 --locale=en_US.UTF-8 --auth=password --pwprompt /usr/sbin/svcadm enable postgresql /usr/local/pgsql/bin/psql -d postgres -f dumpfile Specify your existing password for the 'postgres' user when asked for it in the initdb step (out of the box, it's the same one as for MySQL's root user). If you had any customizations to your pg_hba.conf or postgresql.conf files, you need to restore the changes before re-enabling PostgreSQL. ==== libevent ==== If updating from 2007Q4, this package changed its location from wip/libevent to devel/libevent. To replace it: /opt/local/sbin/pkg_delete libevent && /opt/local/sbin/pkg_add libevent If anything depends on the package, the removal will fail. Note which packages are the blockers (typically memcached), remove the package using pkg_add -r libevent, then re-add the depending packages (e.g. pkg_add memcached). ==== Apache mod_fcgid ==== Since this module came enabled out of the box on many Accelerators (even if not used really), it will complain about a missing config option that the newer version needs. If you see Apache go into maintenance right after the update, add this line to /opt/local/etc/httpd/includes/fcgid.conf: SharememPath /var/run/fcgidshm ==== Finishing up ==== Running ''pkg_chk -ub'' the second time should clear up anything outstanding.