Forum OpenACS Q&A: PostgreSQL lzText

Collapse
Posted by Roberto Mello on
Is PostgreSQL's lzText data type already working for real ? I saw it
on psql and created a row with that type and it worked.

    Is it working under the hood or just there as "coming up next" ?
Collapse
Posted by Don Baccus on
It works fine, I've been using it on the bulletin boards at http://birdnotes.net for about three weeks and we've had no problems.

I've been wanting to slide it into OpenACS 3.2.2 but have been waiting for PG 7.0 to become released for real, which happened on Monday.

If you want to do it, feel free!  With a 16KB blocksize, you get virtually unlimited bboard inserts (up to the 32KB size limit imposed by the browser for textareas).  I was going to replace all columns of both "text" and "varchar(4000)" with the lztext type, will just take a few minutes.

Collapse
Posted by Ken Chakiris on
Don:

How do you handle backing up the OpenACS system on birdnotes.net?  I want to get a system going myself for a nonprofit organization and I am wondering about the system admin details.

Collapse
Posted by Don Baccus on
I will SOON write up a document on this and on details about tuning Postgres, I promise.  Maybe on the airplane back home on Sunday.  Start a deluge of hate mail if I don't finish up in a week or two.

The sketchy answer is that I schedule a Tcl proc to run every night.  I did it in Tcl rather than cron because my sitewide admin page provides a link to force a backup at my request - this is nice if backups fail for some (my old server hardware was flakey and needed the occasional reboot).

The same proc also ftp's the resulting files to a couple of different locations.  Currently Irvine, CA and my home machine (the server's at an ISP in downtown Portland, OR).

Collapse
Posted by miguel sofer on
I did not find anything on 'lztext' in the 'Data Types - Character Types' section of the Postgres7.0 docs. What is it? Where can I find a description? What are the advantages?

Thanks

Miguel Sofer

Collapse
Posted by Don Baccus on
lzText is undocumented because it's probably going to disappear when this type is subsumed into the new large data types implementation.

The Postgres group has promised an invisible upgrade.  Jan Wieck (the first implementor to move to Great Bridge) did lzText some time ago, then took it out because it was felt his new large data types would be  much more useful AND (important) done for PG 7.0.

Alas, he didn't find the time to finish the new large data type implementation for PG 7.0.  A couple of folks (ummm, me, that is) convinced folks that lzText should go back in temporarily.  As a compromise it's not documented, but yet is safe to use because of the transparent upgrade path that will be provided for PG 7.1.  When PG 7.1 comes out, we'll want to change the datamodel for newcomers and rely on the upgrade path for us old hands.

Collapse
Posted by Don Baccus on
Ken asked me "how do you back up birdnotes.net"?  As promised, I've added a short section on this topic to the installation documentation for OpenACS.  You can grab it from the CVS tree.  Feel free to post questions about specifics that aren't clear in this forum (I'll clarify the documentation appropriately).