The current query focuses on RuntimeMaxSec but need not limit to that alone. A better guidance in a wider perspective is much appreciated. This configuration RuntimeMaxSec mentions the time unit as seconds in the name, but by experience and few other references, I had found the value of 5min to work fine.

All attempts to find a clear documentation on time units did not help, but something close was found here. Though its not exactly connected, but part of the documentation seems to apply to the original field in question.

Please clarify if there is any general documentation or guideline around this which helps with all possible time units and formatting.


See systemd.time:

Parsing Time Spans

When parsing, systemd will accept the same time span syntax. Separating spaces may be omitted. The following time units are understood:

  • usec, us, µs
  • msec, ms
  • seconds, second, sec, s
  • minutes, minute, min, m
  • hours, hour, hr, h
  • days, day, d
  • weeks, week, w
  • months, month, M (defined as 30.44 days)
  • years, year, y (defined as 365.25 days)

If no time unit is specified, generally seconds are assumed, but some exceptions exist and are marked as such. In a few cases "ns", "nsec" is accepted too, where the granularity of the time span permits this. Parsing is generally locale-independent, non-English names for the time units are not accepted.

  • Thanks a lot. That greatly helps removing all confusions. – Pavan Kumar Apr 28 at 9:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.