Re: [CentOS] systemd private tmp dirs

2015-04-16 Thread Dennis Jacobfeuerborn
On 16.04.2015 04:15, Les Mikesell wrote: On Wed, Apr 15, 2015 at 9:00 PM, John R Pierce pie...@hogranch.com wrote: On 4/15/2015 6:52 PM, Les Mikesell wrote: Mostly I'm interested in avoiding surprises and having code that isn't married to the weirdness of any particular version of any

Re: [CentOS] systemd private tmp dirs

2015-04-16 Thread Les Mikesell
On Thu, Apr 16, 2015 at 6:58 AM, Dennis Jacobfeuerborn denni...@conversis.de wrote: No, systemd actually remaps /tmp from apache - and apparently most other daemons - to private directories below /tmp with configs as shipped. The command line tool wrote the file to /tmp as expected. The

Re: [CentOS] systemd private tmp dirs

2015-04-16 Thread Les Mikesell
On Thu, Apr 16, 2015 at 9:25 AM, Matthew Miller mat...@mattdm.org wrote: On Thu, Apr 16, 2015 at 07:44:21AM -0500, Les Mikesell wrote: The issue here really isn't systemd or the PrivateTmp feature but the fact that some applications don't properly distinguish between temporary files and

Re: [CentOS] systemd private tmp dirs

2015-04-16 Thread Matthew Miller
On Thu, Apr 16, 2015 at 07:44:21AM -0500, Les Mikesell wrote: The issue here really isn't systemd or the PrivateTmp feature but the fact that some applications don't properly distinguish between temporary files and data files. Maybe, but if an application wants a private directory for

Re: [CentOS] systemd private tmp dirs

2015-04-16 Thread Matthew Miller
On Wed, Apr 15, 2015 at 08:52:16PM -0500, Les Mikesell wrote: Mostly I'm interested in avoiding surprises and having code that isn't married to the weirdness of any particular version of any particular distribution. And I found this to be pretty surprising, given that I That's always

[CentOS] systemd private tmp dirs

2015-04-15 Thread Les Mikesell
Is there a generic way that processes written to share files with (say) apache in /tmp can figure out that they are running on an OS with systemd and in that case, where the daemon in question thinks /tmp is? For example, twiki has a backup/restore add-in where the backup part is normally done

Re: [CentOS] systemd private tmp dirs

2015-04-15 Thread Matthew Miller
On Wed, Apr 15, 2015 at 05:31:52PM -0500, Les Mikesell wrote: Thanks - I can see how those would work once you understand what is broken on the target system and why, but is there a way that programs 'should' be written to run with/without systemd? That just happened to be the first thing

Re: [CentOS] systemd private tmp dirs

2015-04-15 Thread Les Mikesell
On Wed, Apr 15, 2015 at 5:01 PM, Matthew Miller mat...@mattdm.org wrote: On Wed, Apr 15, 2015 at 04:15:23PM -0500, Les Mikesell wrote: Why does this directory have to be /tmp rather than a specific directory belonging to twiki? Twiki is a perl web application run under apache. It doesn't

Re: [CentOS] systemd private tmp dirs

2015-04-15 Thread Matthew Miller
On Wed, Apr 15, 2015 at 04:15:23PM -0500, Les Mikesell wrote: Why does this directory have to be /tmp rather than a specific directory belonging to twiki? Twiki is a perl web application run under apache. It doesn't have its own uid. It doesn't 'have' to be anywhere in particular but that

Re: [CentOS] systemd private tmp dirs

2015-04-15 Thread Les Mikesell
On Wed, Apr 15, 2015 at 9:00 PM, John R Pierce pie...@hogranch.com wrote: On 4/15/2015 6:52 PM, Les Mikesell wrote: Mostly I'm interested in avoiding surprises and having code that isn't married to the weirdness of any particular version of any particular distribution. And I found this to be

Re: [CentOS] systemd private tmp dirs

2015-04-15 Thread John R Pierce
On 4/15/2015 6:52 PM, Les Mikesell wrote: Mostly I'm interested in avoiding surprises and having code that isn't married to the weirdness of any particular version of any particular distribution. And I found this to be pretty surprising, given that I could see the file in /tmp and could read

Re: [CentOS] systemd private tmp dirs

2015-04-15 Thread Les Mikesell
On Wed, Apr 15, 2015 at 6:48 PM, Matthew Miller mat...@mattdm.org wrote: On Wed, Apr 15, 2015 at 05:31:52PM -0500, Les Mikesell wrote: Thanks - I can see how those would work once you understand what is broken on the target system and why, but is there a way that programs 'should' be written

Re: [CentOS] systemd private tmp dirs

2015-04-15 Thread Matthew Miller
On Wed, Apr 15, 2015 at 03:55:34PM -0500, Les Mikesell wrote: Is there a generic way that processes written to share files with (say) apache in /tmp can figure out that they are running on an OS with systemd and in that case, where the daemon in question thinks /tmp is? For example, twiki

Re: [CentOS] systemd private tmp dirs

2015-04-15 Thread Les Mikesell
On Wed, Apr 15, 2015 at 4:07 PM, Matthew Miller mat...@mattdm.org wrote: On Wed, Apr 15, 2015 at 03:55:34PM -0500, Les Mikesell wrote: Is there a generic way that processes written to share files with (say) apache in /tmp can figure out that they are running on an OS with systemd and in that