Originally posted by Chiru Raj:
But i need to take care of Accidental deletion of that file but in windows its safe if it is in the Registry
Yes, and when the hard drive fails, you either have to restore the registry from a backup - which can fail if the new drive configuration doesn't match OR you have to recreate the entire registry from scratch, which means finding all the application install disks, re-installing each and every one of the apps, adding the app updates and service packs, and generally spending about a week just to get basic system functionality back. Oh wait, I'm showing my age. Nowadays you also have to make the reinstalled apps phone home and register with the software vendor.
Or to say it another way - in Linux, if you delete a file, you lose the file. In Windows, if you corrupt the registry, you've lost the entire registry!
The registry was a good idea, and it served a very useful purpose back when FAT sector sized were very large and config files were very small. However, things have changed a lot, and the downsides of the registry have become apparent. Not only do you put all your eggs in one basket - that basket has a proprietary binary format. Linux/Unix config files are normally text files. They can be backed up and restored using ordinary archive utilities and they can be scanned and/or modified in bulk using ordinary text utilities.
I do, in fact, back up my /etc directory tree on a daily basis using a cron-scheduled tar job.
Back in the Windows world, some developers have gotten fed up with registry headaches and gone back to ini files. The registry has one advantage over ini - which is that you can build a hierarchy instead of just a flat option tree, but these days so do XML config files.