Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

A lot of unix config files in xx.d folders are prefixed by a number, like :

$ ls /etc/grub.d/
00_header        10_linux      30_os-prober      40_custom  
05_debian_theme  20_linux_xen  30_uefi-firmware  41_custom

Is there any convention on this number? What does it mean ?

Might just be to avoid name clashing but I'm curious if there's anything more.

share|improve this question
up vote 10 down vote accepted

It's a convention used both to keep filenames unique, and to control the order in which scripts get executed. In general, the xx.d directories are scanned by something doing the moral equivalent of for file in /etc/grub.d/*; do ... and the numeric prefixes give this an ordering other than alphabetical. There may be application-specific standards for what's a 4x_foo vs a 9x_foo but nothing consistent across all the xx.d directories.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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