Skip to content

Instantly share code, notes, and snippets.

View obabawale's full-sized avatar
🎯
Focusing

Olalekan Babawale obabawale

🎯
Focusing
View GitHub Profile
@obabawale
obabawale / install-postgres-10-ubuntu.md
Created March 22, 2018 09:15 — forked from alistairewj/install-postgres-10-ubuntu.md
Install PostgreSQL 10 on Ubuntu

Install PostgreSQL 10 on Ubuntu

This is a quick guide to install PostgreSQL 10 - tested on Ubuntu 16.04 but likely can be used for Ubuntu 14.04 and 17.04 as well, with one minor modification detailed below.

(Optional) Uninstall other versions of postgres

To make life simple, remove all other versions of Postgres. Obviously not required, but again, makes life simple.

dpkg -l | grep postgres
1. Change to the oracle virtualbox directory where you can run VBoxManage command
cd "C:\Program Files\Oracle\VirtualBox"
2. Clone the .vmdk file to a new .vdi file
VBoxManage clonehd "C:\Users\Somebody\VirtualBox VMs\Windows7\windows7.vmdk" "C:\Users\Somebody\VirtualBox VMs\Windows7\windows7.vdi" --format vdi
3. Run the next command to expand the cloned vdi disk. For instance, to expand to 50GB, do:
VBoxManage modifyhd "C:\Users\Somebody\VirtualBox VMs\Windows7\windows7.vdi" --resize 51200
4. In case you want convert to the .vmdk format, clone the new .vdi disk to .vmdk
@obabawale
obabawale / upgrade-postgres-9.3-to-9.5.md
Last active August 17, 2017 13:24 — forked from johanndt/upgrade-postgres-9.3-to-9.5.md
Upgrading PostgreSQL from 9.3 to 9.5 on Ubuntu

TL;DR

Install Postgres 9.5, and then:

sudo pg_dropcluster 9.5 main --stop
sudo pg_upgradecluster 9.3 main
sudo pg_dropcluster 9.3 main