-
Notifications
You must be signed in to change notification settings - Fork 36
Increase PostgreSQL Database storage
kuanfandevops edited this page Oct 10, 2017
·
24 revisions
The current configuration is:
Storage:
postgresql: Bound to volume app-pv-152-1g 1 GiB
postgresql deployment configuration:
spec:
template:
spec:
volumes:
- name: postgresql-data
persistentVolumeClaim:
claimName: postgresql
containers:
volumeMounts:
- name: postgresql-data
mountPath: /var/lib/pgsql/data
Instructions to increase database storage:
step1: create a new storage for 5GiB
postgresql2: Bound to volume app-pv-???-1g 5 GiB
step2: update postgresql deployment configuration to mount current storage claim to postgresql-data-old and mount new storage claim to postgresql-data:
spec:
template:
spec:
volumes:
- name: postgresql-data
persistentVolumeClaim:
claimName: postgresql2
- name: postgresql-data-old
persistentVolumeClaim:
claimName: postgresql
containers:
volumeMounts:
- name: postgresql-data
mountPath: /var/lib/pgsql/data
- name: postgresql-data-old
mountPath: /var/lib/pgsql/data-old
step3: verify if a new deployment for postgresql has happened, manually trigger one if not
step4: login to pod and copy data under /var/lib/pgsql/data-old to /var/lib/pgsql/data
step5: update postgresql deployment configuration to remove postgresql-data-old:
spec:
template:
spec:
volumes:
- name: postgresql-data
persistentVolumeClaim:
claimName: postgresql2
containers:
volumeMounts:
- name: postgresql-data
mountPath: /var/lib/pgsql/data
step6: verify if a new deployment for postgresql has happened, manually trigger one if not
step7: verify if application works properly
further consideration: make sure a site maintenance page is displayed before we run the storage
- Working on GWELLS (full workflow from writing code to deploying to prod)
- Water terminologies
- Testing
- Swagger Documentation
- Restore a database backup manually
- (Archived) Manual Syncing of DEV to TEST to PROD
- (Archived) Setup GWells data migration for local dev test
- Update PostGres Oracle Foreign Data Wrapper image
- Increase PostgreSQL Database storage
- (Archived) Regular Corruption of the PostgreSQL DB
- (Archived) Recovering from a corrupt PostgreSQL Database