Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 5 Oct 1997 12:43:43 -0500 (CDT)
From:      "Matthew D. Fuller" <fullermd@shell.futuresouth.com>
To:        Jon Saenz <jsaenz@netflow.es>
Cc:        freebsd-questions@FreeBSD.ORG
Subject:   Re: read-only root filesystem... = disaster?
Message-ID:  <Pine.BSF.3.96.971005123514.4930B-100000@shell.futuresouth.com>
In-Reply-To: <19971005111731334.AAA201@jon>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 5 Oct 1997, Jon Saenz wrote:

> Hello, there.
> 
> My root filesystem filled up yesterday {or | and } I had some problems with
> permissions in /dev directory when trying to make my ZIP disk available to
> all users to mount and unmount it. I don't exactly know which is the cause
> of the problem, but my system (FreeBSD 2.2.2) doesn't boot now.
> 
> After trying some solutions like mounting a minimal 2.2.1 distribution in a
> SCSI ZIP disc, removing the extra space in the root filesystem, making a
> Custom installation and Commiting the disklabels/distributions to the hard
> disk (extracting just a XF86 server which I don't need for my hardware) and
> some other actions, I have reached to the following status.
> a) My system refuses to boot.
> b) I only have the 2.2.1 CD-ROM distribution, because the 2.2.2 CD-ROM
> distribution was not mine :-(.
.....

> fstab: /etc/fstab:0: Permission denied. # Here start the problems... #
> mount can't find fstab entry for /. # /etc/fstab HAS a / entry! I can cat
> /etc/fstab and it is there!#
> Filesystem mount failed, startup aborted
> Enter pathname of shell or RETURN for sh:
> 
> When typing RETURN, sh starts and when I type df, I get the following
> answer:
> 
> Filesystem	512-blocks	Used	Avail	Capacity	Mounted on
> root_device 	67742		25762	36562	41%		/
> 
> I am NOT allowed to:
> 1. edit files
> 2. sh MAKEDEV
> 3. mounting other disks
> 4. writing disklabel files to root filesystem
> nor .... writing any single bit to the disk, because the answer is always
> the same:
Well, you can try checking the permissions on /etc/fstab; they could be
set to, say, mode 000, and you could still cat it as root.  The filesystem
will of course be mounted read-only, because it's not set as clean.
You'll need to fsck /, then mount / to get it read/write; then you can do
all that stuff.  If that fails, then you might have to do what I did a
week ago; I could no longer access my / partition because of a  few
complications of my BIOS resetting, and I wanted to save as much as I
could.  I have a 100 MB /, 128 MB swap, and ~800 MB /usr on my first disk,
and 128 MB swap, ~1900 MB /home on my second disk.  I did a install of bin
and DES, over PPP, and I told it that the only thing it could use was what
used to be my /; don't even TOUCH the partition entriess for the other
partitions.  Did the install, booted up, checked to make sure I could
remount my old /usr and /home (on /mnt/{usr|home}), edited my /etc/fstab
file to include them, and Voila!  It's working so far, and I don't see why
this mightn't help you at least a bit.  Now, if you want to recover files
in your / partition...   Try the fsck'ing, check the permissions, and
pray.


> Is there any possibility to recover these files under the previously quoted
> constraints? Which?
> 
> Thanks in advance!
> 
> ***************************************************************
> * Jon Saenz                       |jsaenz@netflow.es          *
> * Barrio de la Cruz 5, 3D         |jsaenz@lcpxbi.wm.lc.ehu.es *
> * 48006 - Bilbao                  |wdpsaagj@lg.ehu.es         *
> ***************************************************************

Hope it helps!!

*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
|  FreeBSD; the way computers were meant to be    |
*    FreeBSD: turning PCs into workstations       *
| Windows: turning workstations into typewriters  |
* fullermd@futuresouth.com   :-}  MAtthew Fuller  *
|   http://keystone.westminster.edu/~fullermd     |
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.96.971005123514.4930B-100000>