« Previous 1 2
Elephant Shed PostgreSQL appliance
Elephant in the Room
Enable Backups
One component I particularly like in the Elephant Shed appliance is pgBackRest, one of the most comprehensive backup solutions for PostgreSQL that bundles some of the most commonly used features, most notably the flexibility to take either full or incremental backups.
By default, the component is disabled, which is why clicking the Backup icon in the dashboard does not display a result on a fresh installation. To get started, you have to enable either the full or incremental backup toggle (i.e., Full Backup or Incr Backup ). For the first backup, click the Full Backup button, which takes you to the service's page in Cockpit. Here, click the Start button to make the backup. Depending on the size of your database, the process might take some time to complete; you can monitor its progress under the Service Logs section (Figure 4).
When the backup has been made, the process becomes inactive again, and you can switch back to the main page of the interface with the navigation bar at the top. Notice that the Full Backup toggle has been enabled, along with the Archiving toggle (Figure 5), which signals that the files from write-ahead logging (WAL) are also being backed up. Ideally you should archive the WAL files before taking the backups to ensure you can do point-in-time recovery. A particularly good feature is that the appliance is configured to activate the archiving option automatically when a backup is triggered.
Once you have made a full backup, you can then use the Incr Backup button to back up only the files that have changed between the last full backup and the current data. pgBackRest has a lot of configurable parameters to give you better control over the backups, including defining an automation schedule and a retention policy. However these parameters aren't exposed in the dashboard and can only be tweaked by editing the configuration file. The relevant configuration file options are mentioned in the Elephant Shed documentation [10].
Conclusion
You can now roam around the intuitive interface and peek inside the components, most of which are pre-configured with the bare minimum settings to be of use straight out of the box. For instance, Grafana ships with some dashboards pre-deployed to give you an overview of the underlying PostgreSQL server (Figure 6). Note, however, that this dashboard is read-only and if you need to make any modifications to its configuration, you have to save it under a different name. Moreover, Grafana offers a ton of other dashboards that you can easily grab from its website. Although the process is fairly intuitive, you can follow the official Grafana documentation to help you through the process.
Although Elephant Shed doesn't have much documentation beyond the bare essentials you need to get the appliance up and running, all the bundled components in the appliance have extensive documentation infrastructures of their own. All the tools are fairly intuitive to operate, but if you haven't used them before, you can follow the documentation on their respective websites to familiarize yourself.
Infos
- Elephant Shed: https://elephant-shed.io
- Prometheus: https://prometheus.io/docs/introduction/overview/
- Grafana: https://grafana.com/grafana/
- pgBadger: http://pgbadger.darold.net/
- pgBackRest: https://pgbackrest.org/user-guide.html
- pgAdmin4: https://www.pgadmin.org/docs/pgadmin4/latest/getting_started.html
- Cockpit: https://cockpit-project.org/
- Elephant Shed download: https://elephant-shed.io/#download
- "Managing and provisioning VMs" by Mayank Sharma, Linux Pro Magazine , issue 235, June 2020, pg. 22, https://www.linuxpromagazine.com/Issues/2020/235/Vagrant/(language)/eng-US
- Configuring pgBackRest: https://elephant-shed.io/doc/chapter/components.html#configuration #IE:
« Previous 1 2
Buy this article as PDF
(incl. VAT)
Buy ADMIN Magazine
Subscribe to our ADMIN Newsletters
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Most Popular
Support Our Work
ADMIN content is made possible with support from readers like you. Please consider contributing when you've found an article to be beneficial.