Mount /tmp in /mnt on EC2
- by Claudio Poli
I was wondering what is the best way to mount the /tmp endpoint in the ephemeral storage /mnt on an EC2 instance and give the ubuntu user default write permissions.
Some suggest editing /etc/rc.local this way:
mkdir -p /mnt/tmp && mount --bind -o nobootwait /mnt/tmp /tmp
However that doesn't work for me.
I tried editing the fstab:
/dev/xvdb /tmp auto defaults,nobootwait,comment=cloudconfig 0 2
and giving it a umask=0777, however it doesn't work because of cloudconfig.
I'm using Ubuntu 12.04.