22
33Repository-backed installation commands for DocumentDB.
44
5- > This repository serves v1.0 -0.
5+ > This repository serves v1.2 -0.
66
77## Clean-host installer
88
@@ -13,9 +13,9 @@ curl -fsSLo documentdb-install.sh https://documentdb.io/install.sh &&
1313sudo sh documentdb-install.sh
1414```
1515
16- This installs v1.0 -0 from this repository on PostgreSQL 18; add ` --pg-major 17 `
16+ This installs v1.2 -0 from this repository on PostgreSQL 18; add ` --pg-major 17 `
1717for 17. On a host where DocumentDB is already set up, it only reports that instance's status
18- and doesn't upgrade it; to move an existing install to 1.0 , see
18+ and doesn't upgrade it; to move an existing install to 1.2 , see
1919[ Upgrading an existing install] ( #upgrading-an-existing-install ) .
2020
2121The site serves the ` install.sh ` attached to the release named in
@@ -225,7 +225,7 @@ Before using this anywhere but a private machine:
225225
226226``` bash
227227sudo documentdb-setup --status # gateway listener, service states, resolved paths
228- documentdb-gateway --version # DocumentDB version (1.0 .0)
228+ documentdb-gateway --version # DocumentDB version (1.2 .0)
229229dpkg -l | grep documentdb # or: rpm -qa | grep documentdb
230230```
231231
@@ -368,9 +368,11 @@ The current release publishes PostgreSQL 17 and 18. Install `documentdb-17` or
368368
369369## Upgrading an existing install
370370
371- Package installs from v0.116 or v0.117 upgrade in place to 1.0 . Move the entire stack
371+ Package installs from 1.0.0 upgrade in place to 1.2 . Move the entire stack
372372together; upgrading only ` postgresql-N-documentdb ` does not update the gateway, tools, common
373373payload, or ` documentdb-N ` . These steps use systemd; upgrading a host without it isn't covered here.
374+ There is no downgrade: an older release starts on the updated catalog, but some commands then fail,
375+ so back up the data directory first if you may need to go back.
374376On a package-managed private PostgreSQL 18 instance:
375377
376378> ** Warning:** A host that ran a 1.0 release candidate (RC1 or RC2) has no upgrade path. Use a
@@ -391,18 +393,17 @@ sudo dnf upgrade documentdb-18 postgresql18-documentdb \
391393 documentdb-common documentdb-gateway documentdb-postgresql-tools
392394```
393395
394- Upgrading the packages does not update the database catalog. The simplest way is to restart
395- PostgreSQL so it loads the new libraries, then re-run setup with the options you installed with.
396- Setup updates the extensions and then starts the gateway:
396+ Upgrading the packages does not update the database catalog. Re-run setup with the PostgreSQL
397+ major, plus any ` --data-dir ` or ` --pg-port ` you installed with. It restarts PostgreSQL once to
398+ load the new libraries, updates the extensions, and then starts the gateway:
397399
398400``` bash
399- sudo systemctl restart documentdb-postgresql@18.service &&
400- sudo documentdb-setup --pg-version 18 --use-new-postgres-instance --admin-user admin
401+ sudo documentdb-setup --pg-version 18 --yes
401402```
402403
403- Setup adds any missing ` shared_preload_libraries ` entries and updates the extensions, but only in
404- the ` postgres ` database. If your gateway uses another database, take the manual route below. It also asks for the admin password and sets it on the existing admin
405- user: enter the current password to keep it .
404+ Without ` --admin-user ` , setup asks for no password and keeps every admin user and password as
405+ they are. It adds any missing ` shared_preload_libraries ` entries and updates the extensions, but only in
406+ the ` postgres ` database. If your gateway uses another database, take the manual route below .
406407
407408To update by hand, or for every other database that has DocumentDB installed, first check that
408409the extended RUM library is preloaded:
@@ -411,7 +412,7 @@ the extended RUM library is preloaded:
411412sudo -u documentdb-local psql -h /run/documentdb-local/18/postgresql -p 9718 -d postgres -X -Atc " SHOW shared_preload_libraries;"
412413```
413414
414- If ` pg_documentdb_extended_rum ` is missing (possible on a 0.116 install ), add it before updating;
415+ If ` pg_documentdb_extended_rum ` is missing (possible on a host first set up with 0.116), add it before updating;
415416the update below would succeed without it, and index builds would fail later. If the gateway uses
416417` postgres ` , re-run setup as above. If it uses another database, add the library to
417418` shared_preload_libraries ` in the instance's ` postgresql.conf ` yourself: setup would point the
@@ -439,12 +440,11 @@ On a host with both PostgreSQL 17 and 18, `documentdb-common`, `documentdb-gatew
439440(` documentdb-gateway-local@17.service ` and ` @18.service ` ) before upgrading, then update each major.
440441
441442For an adopted PostgreSQL instance, setup never restarts PostgreSQL. Stop the gateway
442- (` documentdb-gateway-local@18.service ` ) before upgrading, restart the operator-managed PostgreSQL
443- service yourself, then re-run
444- ` documentdb-setup --pg-version 18 --target-postgres-instance 18/main --admin-user admin ` (with your cluster name); it
445- updates the extensions and then starts the gateway. If
446- setup has to change ` shared_preload_libraries ` , it exits without updating the extensions: restart
447- PostgreSQL and run it once more. By hand, use that instance's own ` psql ` connection.
443+ (` documentdb-gateway-local@18.service ` ) before upgrading, then run
444+ ` sudo documentdb-setup --target-postgres-instance 18/main --yes ` (with your cluster name). It
445+ prints the command that restarts your PostgreSQL service and the setup command to run after it,
446+ then exits without updating the extensions. Run both; the second run updates the extensions and
447+ starts the gateway. By hand, use that instance's own ` psql ` connection.
448448
449449Confirm afterwards with:
450450
@@ -479,17 +479,17 @@ published in the documentdb.io package repositories. Community builds are welcom
479479For example, after checking out the matching release tag, build an extension package with:
480480
481481``` bash
482- ./packaging/build_packages.sh --os deb12 --pg 16 --version 1.0 .0
482+ ./packaging/build_packages.sh --os deb12 --pg 16 --version 1.2 .0
483483```
484484
485- ` v1.0-0 ` and ` v1.0-RC2 ` are on the same commit, so pass ` --version ` ; without it the scripts can build RC-versioned packages . That command builds only ` postgresql-N-documentdb ` . A custom full-stack package set uses
485+ Without ` --version ` , the script takes the version from the checked-out release tag, or else from the control file; at ` v1.2-0 ` both give 1.2.0 . That command builds only ` postgresql-N-documentdb ` . A custom full-stack package set uses
486486three entry points:
487487
488488- ` packaging/build_packages.sh ` — PostgreSQL extension
489489- ` packaging/gateway/build_gateway_packages.sh ` — wire-protocol gateway
490490- ` packaging/build_extra_packages.sh ` — tools, common payload, ` documentdb-N ` , and meta package
491491
492- The [ v1.0 packaging guide] ( https://github.com/documentdb/documentdb/blob/v1.0 -0/packaging/README.md )
492+ The [ v1.2 packaging guide] ( https://github.com/documentdb/documentdb/blob/v1.2 -0/packaging/README.md )
493493documents their required arguments, version formats, prerequisites, and accepted targets.
494494PostgreSQL 15 remains extension-only for package-managed installs because the setup tools
495495require PostgreSQL 16 or newer.
@@ -504,9 +504,9 @@ they do not retain packages from older releases.
504504Examples:
505505
506506``` text
507- ubuntu24.04-documentdb_1.0 .0_all.deb
508- ubuntu24.04-postgresql-18-documentdb_1.0 -0_amd64.deb
509- rhel9-postgresql18-documentdb-1.0 .0-1.el9.x86_64.rpm
507+ ubuntu24.04-documentdb_1.2 .0_all.deb
508+ ubuntu24.04-postgresql-18-documentdb_1.2 -0_amd64.deb
509+ rhel9-postgresql18-documentdb-1.2 .0-1.el9.x86_64.rpm
510510```
511511
512512For a full stack, pass the five packages for the selected PostgreSQL major to one command:
0 commit comments