On an Ubuntu 14.04 system I had to enlarge the /tmp folder, and instead of resizing partitions I unmounted the partition mounted to /tmp and created a new file mounted to /tmp, following the instructions here.I changed the permissions to this new /tmp folder to 1777, but I get some permissions issue - when I compile some c++/cuda code from Python (using Codepy, creating a shared object), I get the following error when (within the compilation code) the shared object is loaded (compilation is done into subfolder of /tmp):failed to map segment from shared object: Operation not permittedI have a similar machine (it was a clone) where this does not happen, so I guess it has something to do with the /tmp folder.Any idea?
Problem with the permissions of newly created /tmp
ubuntu;permissions;filesystems;python;dynamic linking
That guide is not the best to follow.Instead, mount your /tmp as tmpfs and reap the benefits of much faster compiling, and faster /tmp usage for other things.tmpfs is an in-memory filesystem which is very well suited for /tmp usage.It also reduces hard drive writes which can be a bit useful for the paranoid folks who don't want to write to their SSDs often.To accomplsih this, unmount /tmp and undo everything you did that guide.mount -t tmpfs temp /tmp -o size=4G,nosuid,nodevNote that size=4G can and should be changed depending on how much memory your system has. I use 1/4th of my total system memory. You can check with the command free for memory total and usages.Note that the 3rd argument, temp in the command above can actually be anything you want. Make it something more descriptive if you want, but it must be a single argument so if you use spaces, encase it in quotes.