2 edited body
source | link

It's failing when trying to run the old bin files because it's missing a dependency. You're going to need to install its dependencies, install 8.4 on the new server for this task, or spin up a VM with 8.4 installed, copy the files to the VM, do what it takes to start the 8.4 instance on the VM (which means that postgres will need to know where the default data directory is). From there, I'd do a pg_dump on the database(s) in question and then restore them to the new server. That would probably give you the cleanest environment.

So, here are what I see as your options:

Using pg_upgrade

On The New Server (pg_upgrade)

  1. Install PostgreSQL 8.4 dependencies and hope that your copied binaries work. If they don't, then you may need to just remove these copied binaries and install 8.4 from apt.
  2. Attempt to start the service /tmp/postgres-bin.old/postgresql/8.4/bin/pg_ctl start -D /tmp/postgres.old/main/
  3. If that works, stop the service /tmp/postgres-bin.old/postgresql/8.4/bin/pg_ctl stop -D /tmp/postgres.old/main/
  4. Now try your pg_upgrade script

Without Using pg_upgrade

  1. Create a VM or use an old, decommed server and install postgresql 8.14
  2. Initialize your server using initdb (or pg_createcluster)
  3. Copy your backed up data over that which was just created
  4. Start postgresql
  5. Backup the data using pg_dump
  6. Copy the dump file to the "new server"
  7. Restore to a new database on the new server

It's failing when trying to run the old bin files because it's missing a dependency. You're going to need to install its dependencies, install 8.4 on the new server for this task, or spin up a VM with 8.4 installed, copy the files to the VM, do what it takes to start the 8.4 instance on the VM (which means that postgres will need to know where the default data directory is). From there, I'd do a pg_dump on the database(s) in question and then restore them to the new server. That would probably give you the cleanest environment.

So, here are what I see as your options:

Using pg_upgrade

On The New Server (pg_upgrade)

  1. Install PostgreSQL 8.4 dependencies and hope that your copied binaries work. If they don't, then you may need to just remove these copied binaries and install 8.4 from apt.
  2. Attempt to start the service /tmp/postgres-bin.old/postgresql/8.4/bin/pg_ctl start -D /tmp/postgres.old/main/
  3. If that works, stop the service /tmp/postgres-bin.old/postgresql/8.4/bin/pg_ctl stop -D /tmp/postgres.old/main/
  4. Now try your pg_upgrade script

Without Using pg_upgrade

  1. Create a VM or use an old, decommed server and install postgresql 8.1
  2. Initialize your server using initdb (or pg_createcluster)
  3. Copy your backed up data over that which was just created
  4. Start postgresql
  5. Backup the data using pg_dump
  6. Copy the dump file to the "new server"
  7. Restore to a new database on the new server

It's failing when trying to run the old bin files because it's missing a dependency. You're going to need to install its dependencies, install 8.4 on the new server for this task, or spin up a VM with 8.4 installed, copy the files to the VM, do what it takes to start the 8.4 instance on the VM (which means that postgres will need to know where the default data directory is). From there, I'd do a pg_dump on the database(s) in question and then restore them to the new server. That would probably give you the cleanest environment.

So, here are what I see as your options:

Using pg_upgrade

On The New Server (pg_upgrade)

  1. Install PostgreSQL 8.4 dependencies and hope that your copied binaries work. If they don't, then you may need to just remove these copied binaries and install 8.4 from apt.
  2. Attempt to start the service /tmp/postgres-bin.old/postgresql/8.4/bin/pg_ctl start -D /tmp/postgres.old/main/
  3. If that works, stop the service /tmp/postgres-bin.old/postgresql/8.4/bin/pg_ctl stop -D /tmp/postgres.old/main/
  4. Now try your pg_upgrade script

Without Using pg_upgrade

  1. Create a VM or use an old, decommed server and install postgresql 8.4
  2. Initialize your server using initdb (or pg_createcluster)
  3. Copy your backed up data over that which was just created
  4. Start postgresql
  5. Backup the data using pg_dump
  6. Copy the dump file to the "new server"
  7. Restore to a new database on the new server
1
source | link

It's failing when trying to run the old bin files because it's missing a dependency. You're going to need to install its dependencies, install 8.4 on the new server for this task, or spin up a VM with 8.4 installed, copy the files to the VM, do what it takes to start the 8.4 instance on the VM (which means that postgres will need to know where the default data directory is). From there, I'd do a pg_dump on the database(s) in question and then restore them to the new server. That would probably give you the cleanest environment.

So, here are what I see as your options:

Using pg_upgrade

On The New Server (pg_upgrade)

  1. Install PostgreSQL 8.4 dependencies and hope that your copied binaries work. If they don't, then you may need to just remove these copied binaries and install 8.4 from apt.
  2. Attempt to start the service /tmp/postgres-bin.old/postgresql/8.4/bin/pg_ctl start -D /tmp/postgres.old/main/
  3. If that works, stop the service /tmp/postgres-bin.old/postgresql/8.4/bin/pg_ctl stop -D /tmp/postgres.old/main/
  4. Now try your pg_upgrade script

Without Using pg_upgrade

  1. Create a VM or use an old, decommed server and install postgresql 8.1
  2. Initialize your server using initdb (or pg_createcluster)
  3. Copy your backed up data over that which was just created
  4. Start postgresql
  5. Backup the data using pg_dump
  6. Copy the dump file to the "new server"
  7. Restore to a new database on the new server