i overwrote initial slapd.conf, then removed slapd with "apt-get purge slapd", and reinstalled it.
initial slapd.conf didn't reappear.
what can i do to get it back?
upd: i need the initial one, not the one with my changes!
It depends which filesystem you were deleteing the file from, NTFS you can recover the file using ntfsprogs (apt-get install ntfsprogs) and then look for deleted files (ntfsundelete).
ext3, I am quite certain that you cannot recover files. This is an extract from ext3 FAQS:
Q: How can I recover (undelete) deleted files from my ext3 partition?
Actually, you can't! This is what one of the developers, Andreas Dilger, said about it:
In order to ensure that ext3 can safely resume an unlink after a crash, it actually zeros out the block pointers in the inode, whereas ext2 just marks these blocks as unused in the block bitmaps and marks the inode as "deleted" and leaves the block pointers alone.
Your only hope is to "grep" for parts of your files that have been deleted and hope for the best.
ok, i suspect that there is actually no default slapd.conf in newest 9.10 ubuntu package, that's why it doesn't restore it. must be the one from the old version.
it should create a new file based on your answer.