LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-13-2020, 07:05 PM   #1
genese
Member
 
Registered: Feb 2006
Location: belgium
Posts: 66

Rep: Reputation: 16
systemd-tmpfiles : avoiding collisions


Hello All,

I need a temporary directory in /run.

I'm going to create a foo.conf file in /etc/tmpfiles.d with the following content

Code:
d /run/bar 0755 user group
How do I make sure that /run/bar is not defined in another .conf (in /usr/lib/tmpfiles.d or elsewhere) ?

Is there an alternative to grep ?

If one day I install a new package which defines /run/bar in its .conf, the conflict will be reported in the logs, but I must confess that I don't read the logs at each reboot.

So something will break (either my scripts or the package, I didn't read the doc enough to tell it), with possible loss of data or DOS.

Is there any naming convention that solves this problem ?

TIA for any help.
 
Old 02-15-2020, 06:39 AM   #2
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 13,722
Blog Entries: 9

Rep: Reputation: 3791Reputation: 3791Reputation: 3791Reputation: 3791Reputation: 3791Reputation: 3791Reputation: 3791Reputation: 3791Reputation: 3791Reputation: 3791Reputation: 3791
Does
Code:
man tmpfiles.d
offer any insights?
 
Old 02-18-2020, 01:26 AM   #3
MadeInGermany
Senior Member
 
Registered: Dec 2011
Location: Simplicity
Posts: 1,339

Rep: Reputation: 610Reputation: 610Reputation: 610Reputation: 610Reputation: 610Reputation: 610
No, the man page does not discuss conflicts.
This is a valid point.
In practice, the systemd-tmpfiles aborts all further activities when there is a duplicate.
And a duplicate might exist even in /etc/tmpfiles.d/systemd/system/ and (/usr)/lib/systemd/system/.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
systemd-tmpfiles --clean scryptkiddy Linux - Newbie 11 05-25-2016 07:32 PM
LXer: Avoiding systemd isn't hard LXer Syndicated Linux News 1 10-23-2014 11:06 AM
Boot Delay 30min: systemd-analyze blame systemd-tmpfiles-setup.service BGHolmes Fedora 0 07-27-2011 09:02 AM
Eth collisions w/ samba and how do you set duplex mode? system Linux - Networking 7 06-07-2002 10:48 AM
NIC Collisions Jase Linux - Networking 4 02-19-2002 06:25 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 01:28 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration