Bad file descriptor

Polytropon freebsd at edvax.de
Fri Apr 18 17:57:21 UTC 2014


On Fri, 18 Apr 2014 15:27:53 +0000 (UTC), Walter Hurry wrote:
> FreeBSD 9.2-RELEASE
> 
> I have a handful of files in a subdirectory of /usr/ports/multimedia/
> gstreamer/work, which show up as 'Bad file descriptor'. It appears that I 
> am unable to delete them.

This sounds familiar - like file system corruption.



> /usr/ports is on my root partition/slice, which is ufs with journalling.
> 
> On rebooting, it says the partition/slice is clean, so checking is 
> skipped.

A check should be forced anyway. Use "fsck -f" to do so.



> I gather that the way to fix this is to run fsck with the -f option. Is 
> this correct? If so, how do I get / unmounted? Or is there a way to force 
> a check on reboot before mounting?

The easiest way is to boot from optical media (CD or DVD #1)
or USB stick. It _may_ be possible to boot into single user
mode (use "boot -s" after reboot) where / is mounted r/o.
There is no way to unmount / while the system is running,
even in single user mode this is problematic, so a second
(live) system seems to be the safest way.



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...


More information about the freebsd-questions mailing list