Hello all,
Any idea how I can setup a per-user tmp directory? E.g. USER1 has /tmp -> /tmp/USER1, /var/tmp -> /var/tmp/USER1. USER2 has /tmp -> /tmp/USER2, /var/tmp -> /var/tmp/USER2. etc.
In short, I want each user to have a private /tmp, and /var/tmp - without having to resort to using virtualized/jailed environment.
- Gilboa
On Mon, Sep 01, 2008 at 15:37:18 +0300, Gilboa Davara gilboad@gmail.com wrote:
Hello all,
Any idea how I can setup a per-user tmp directory? E.g. USER1 has /tmp -> /tmp/USER1, /var/tmp -> /var/tmp/USER1. USER2 has /tmp -> /tmp/USER2, /var/tmp -> /var/tmp/USER2. etc.
In short, I want each user to have a private /tmp, and /var/tmp - without having to resort to using virtualized/jailed environment.
Another approach is polyinstantiation. See: http://www.ibm.com/developerworks/linux/library/l-polyinstantiation/?ca=dgr-...
On Mon, 2008-09-01 at 09:30 -0500, Bruno Wolff III wrote:
On Mon, Sep 01, 2008 at 15:37:18 +0300, Gilboa Davara gilboad@gmail.com wrote:
Hello all,
Any idea how I can setup a per-user tmp directory? E.g. USER1 has /tmp -> /tmp/USER1, /var/tmp -> /var/tmp/USER1. USER2 has /tmp -> /tmp/USER2, /var/tmp -> /var/tmp/USER2. etc.
In short, I want each user to have a private /tmp, and /var/tmp - without having to resort to using virtualized/jailed environment.
Another approach is polyinstantiation. See: http://www.ibm.com/developerworks/linux/library/l-polyinstantiation/?ca=dgr-...
Interesting read. Thanks.
- Gilboa
Gilboa Davara wrote:
Hello all,
Any idea how I can setup a per-user tmp directory? E.g. USER1 has /tmp -> /tmp/USER1, /var/tmp -> /var/tmp/USER1. USER2 has /tmp -> /tmp/USER2, /var/tmp -> /var/tmp/USER2. etc.
In short, I want each user to have a private /tmp, and /var/tmp - without having to resort to using virtualized/jailed environment.
- Gilboa
One thing I have done is create a tmp directory in each user's home directory, and then set the TMP variable to point to it. You will also want to add the tmp directory to /etc/skel so new users get it created for them automatically. (I added "TMP=$HOME/tmp" and added TMP to the export list in .bashprofile, but you could also add files to /etc/profile.d to cover both the c and sh shell variants.
OH yes, the /tmp directory does limit what other users can do to your files in /tmp.
Mikkel