Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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

I have a broken file system on my debian server and I'm not really expert on this OS, could anyone help me out?

I encountered several errors on my website hosted on debian, caused by accidentally change of permission to var directory.

Somebody advised me to fsck using the rescue cd and not to fsck using a mounted filesystem.

Could anyone give me a detailed instructions on how to do so and what tools (opensource) to use?

share|improve this question

migrated from Nov 18 '12 at 17:20

This question came from our site for professional and enthusiast programmers.

Install Debian on your local (laptop and desktop) machine, and take hours to read material on, and to experiment with, your Debian/Linux system thru the command line. – Basile Starynkevitch Nov 12 '12 at 7:41
To use fsck from a rescue cd, you boot into the cd and then run 'fsck /dev/<id>' where <id> is the identifier of your hard drive. You can find this by using 'fdisk -l': your hard drive will be sdaX or hdaX, formatted with a linux filesystem type (ext3/ext4 probably). If there are multiple entries matching this, do 'ls /dev/<id>' on each to list the contents. You're looking for the one containing /var. – jam Nov 12 '12 at 10:51

I don't think fsck will fix permission issues. But if the filesystem is damaged, and you need to fsck the root filesystem, you can do it on next boot.

Simply login as root:

su -

Tell the system to run fsck on the root partition on next boot

touch /forcefsck

and reboot the system.

share|improve this answer

Your Answer


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