- Más nuevo
- Más votos
- Más comentarios
Hello, it's a best practice that you separate OS disk from your App files or DB binaries, so here's what I think about your design:
For setting a root limit, you can use quota
command, I didn't try it except ZFS with Solaris .However, it is generally not recommended to set a root limit as this may cause issues with the system's performance and stability.
To automatically store new data on the attached EBS volumes, you can use LVM to create a logical volume that spans across all the EBS volumes and use it as PostgreSQL data directory (You will need to change your DB configuration file with new directory). Check this document https://www.redhat.com/sysadmin/lvm-vs-partitioning and https://www.digitalocean.com/community/tutorials/how-to-move-a-postgresql-data-directory-to-a-new-location-on-ubuntu-16-04
To mount the EBS volumes use the mount
command to mount the EBS volumes to specific directories. For example, to mount the EBS volume at /dev/xvdf
to the /data/db1
directory, you can use the following command:
sudo mount /dev/xvdf /data/db1
It is important to make sure that the mount point directories
And don't forgot about permissions, newly created directory should allow PostgreSQL process access the data inside it.
Contenido relevante
- OFICIAL DE AWSActualizada hace un año
- OFICIAL DE AWSActualizada hace 2 años
- OFICIAL DE AWSActualizada hace 3 años
- OFICIAL DE AWSActualizada hace 2 años
Thanks for the answer. I tried this but data gets stores in particular directory only which I am giving the path say /dev/xvdf /data/db1. Is there a way how the data can automatically go to the next EBS volumes? Should I need to multi attach the volumes?