9

Suppose one deleted the following files.

/etc/init.d/.depend.boot
/etc/init.d/.depend.start
/etc/init.d/.depend.stop

How to regenerate them?

Gilles 'SO- stop being evil'
  • 807,993
  • 194
  • 1,674
  • 2,175
adrelanos
  • 1,786
  • 7
  • 29
  • 56

2 Answers2

10

Good question. The only reference I've found to those files is in man insserv:

   /etc/init.d/.depend.boot,
   /etc/init.d/.depend.start,
   /etc/init.d/.depend.stop
          The make(1) like dependency files produced by  insserv  for  booting,
          starting, and stopping with the help of startpar(8).

And in fact, running just plain insserv touches their modification time. So try that and see if it rebuilds them.

As a tip, when you are tempted to delete something like this for whatever reason, move them to a temporary trash directory instead.

goldilocks
  • 86,451
  • 30
  • 200
  • 258
0

find the package it come from and excecute something like :

dpkg --reinstall package name

or

dpkg-reconfigure package name

I'm not sure but that how I would do.
To find what package create what file you can use:

dpkg --search .depend.start

Thos file seems to be generated by the package insserv so command line according to this blog and the man page:

dpkg-reconfigure insserv 

Should fix the problem, but BE CAREFULL THIS CAN BREAK THE BOOT SEQUENCE

Kiwy
  • 9,415
  • 13
  • 49
  • 79
  • 2
    They are not associated with any package on my Debian system. – Joseph R. Nov 28 '13 at 13:45
  • 2
    Isn't it obvious that those files are system-wise not package-wise? This simply _cannot_ work, as I understand it, they contain information from _many packages_! – yo' Nov 28 '13 at 14:03
  • @tohecz This is obvious that those script came from somthing and more likely a package as they are not on my debian and more over when I read those kind of thing http://www.goatpr0n.de/blog/2008/04/09.speed.up.debian.boot.process.using.start.par – Kiwy Nov 28 '13 at 14:10
  • @JosephR. do you have them install ? – Kiwy Nov 28 '13 at 14:15
  • 1
    I'm inclined to agree with @tohecz on this. These scripts are generated based on the services you have installed. They do not depend on a single package. – Joseph R. Nov 28 '13 at 14:18
  • I don't think you have to re-install / re-configure `insserv`, you just have to run it (see my answer). – goldilocks Nov 28 '13 at 14:32
  • @goldilocks yes in fact it should be OK too – Kiwy Nov 28 '13 at 14:33
  • There is no such `dpkg --reinstall` option. – adrelanos Nov 28 '13 at 22:26