On Tue, Sep 08, 2009 at 08:52:23AM +0000, Jasen Betts wrote: > On 2009-09-08, Jia Chen <chen.1002@xxxxxxxxx> wrote: > > Now, I want to store PostgreSQL data on an external drive because I work > > both on my office machine and on my home machine a lot. This way, I can > > always bring my external drive to either location and work on data > > stored on the drive. > > start again and install from the source. > the ubuntu packge spreads the components of the postgres database about > putting some in /usr/bin, /usr/lib, /etc/postgres, /var/log, /var/lib and /etc I don't think you need to go that far. I'd just do an "initdb" somewhere on the removable disk and then start PG pointing at where the cluster was (i.e. postgres -D /media/disk/psqldata) and all should be good. I'd stay away from the official system startup scripts for PG. > you should install them all onto the removable drive instead. > it's not just the table data that is needed need for the database to work. Yup, the table data is very tied to the state of transactions and other "system level" information, you need to keep everything together unfortunately. This is the price of having transactions with ACID semantics. One other thing to note is that PG tends to change the on-disk format between "major" versions, where a major version is defined as the second digit changing. 8.3 and 8.2 are different major versions and have different on-disk formats, while 8.3.6 and 8.3.7 are not. -- Sam http://samason.me.uk/ -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general