Monthly Archives: May 2009

Qmail Autoresponder

Installation get it from http://untroubled.org/qmail-autoresponder/ untar the tarball  $ make  # ./installer  # ./instshow  # vi /etc/vmailmgr/vdeliver-postdeliver And make sure it contains:  #!/bin/sh  if test -s $MAILDIR/autoresponse/message.txt  then    qmail-autoresponder $MAILDIR/autoresponse/message.txt $MAILDIR/autoresponse  fi Then  # /etc/vmailmgr/vdeliver-predeliver and make sure it … Continue reading

Posted in AIX, Hosting Support, Linux, OpenBSD | Tagged | Leave a comment

How to change ownership of a PostgreSQL database

To change the owner of a database we have found this solution: UPDATE pg_database SET datdba=(SELECT usesysid FROM pg_shadow WHERE usename=’new_owner’) WHERE datname=’db_name’; http://archives.postgresql.org/pgsql-admin/2003-07/msg00301.php * From: Tom Lane * To: Devrim GUNDUZ * Subject: Re: changing ownership of db * … Continue reading

Posted in Cloud Computing, Data Warehouse, Dedicated Servers, Linux, Managed Hosting | Tagged | Leave a comment

PostreSQL Upgrade Process

First you need to change permissions on the localhost to trust: # cd /var/lib/pgsql/data # vi pg_hba.conf Change the autorization/authentication for the line that starts with “local” to trust: local all trust And prevent clients to access the database by … Continue reading

Posted in Cloud Computing, Data Warehouse, Dedicated Servers, Linux, Managed Hosting | Tagged | Leave a comment

Rebuild Postgres for specific platform

# rpm -i postgres-[version number].src.rpm # rpmbuild -bb –target i686 /usr/src/redhat/SPECS/postgresql.spec If you get a problem with unpackaged files, use the following trick: vi /usr/lib/rpm/macros An modify some of the lines as follows: # # Script gets packaged file list … Continue reading

Posted in AIX, Cloud Computing, Data Warehouse, Dedicated Servers, Linux, Mac OS X, Managed Hosting, OpenBSD, Windows | Tagged | Leave a comment

PHP after upgrading to 4.3.10 displays errors: "Warning: Illegal offset type in…"

I found this solution originally on Kreny’s Blog Troubleshooting for “Warning: Illegal offset type in …” in PHP Posted by kreny at December 17, 2004 02:08 AM System Environment: Red Hat 9.0 + Apache 2.0.52 + PHP 4.3.10 + Zend … Continue reading

Posted in Linux | Tagged | Leave a comment

How to avoid the phpBB worm with Apache Rewrite Engine

This solution was suggested by Raymond Dijkxhoorn on BugTraq: If you cannot fix it (virtual servers) fast for all your clients you could also try with something like this: RewriteEngine On RewriteCond %{QUERY_STRING} ^(.*)echr(.*) [OR] RewriteCond %{QUERY_STRING} ^(.*)esystem(.*) RewriteRule ^.*$ … Continue reading

Posted in PHP | Tagged , | Leave a comment

How to validate emails using PHP

Complete and thorough php email validation and php email verification can be found at PHPClasses.org: Email Validation: <<This is a PHP class that attempts to validate a given e-mail address at three levels: matching the address against a RFC compliant … Continue reading

Posted in PHP | Tagged | Leave a comment

How to create an MD5 password in java or Tomcat

To create an MD5 password at the prompt, assuming you have tomcat installed in /usr/local/tomcat, type $ export TOMCAT=”/usr/local/tomcat” $ java -cp “$TOMCAT/server/lib/catalina.jar:/usr/share/java/jmxri.jar:$TOMCAT/bin/commons-logging-api.jar” \ org.apache.catalina.realm.RealmBase -a md5 [secret] by replacing “[secret]” with the password. Some systems have a working digest.sh … Continue reading

Posted in Java | Tagged , , | Leave a comment

Problems starting Java

If running a legacy java app on a newer RH or RHEL system, youget: Error occurred during initialization of VM Unable to load native library: …/libjava.so: symbol __libc_wait, version GLIBC_2.0 not defined in file libc.so.6 with link time reference This … Continue reading

Posted in Java | Tagged , , | Leave a comment

How to remove a passphrase from an SSL cert key

Here are the steps to remove a pass phrase from a cert key. This solution was originally discovered on the modssl website: cp server.key server.key.org openssl rsa -in server.key.org -out server.key Make sure the key is readable by root only, … Continue reading

Posted in Dedicated Servers, Hosting Support, Managed Hosting | Tagged , , | Leave a comment