Re: ext2 problem

From: Oliver Fromme <olli(at)lurza.secnetix.de>
Date: Tue, 20 Apr 2004 12:53:07 +0200 (CEST)

torben friese <contact(at)derfriese.com> wrote:
> bash-2.05b# mount_ext2fs /dev/ad4s5 /data/data4/
> mount_ext2fs: /dev/ad4s5: No such file or directory

(BTW, man schreibt besser »mount -t ext2fs ...«, das sollte
aber hier nicht das Problem sein. Auch der abschließende
Slash hinter »data4« gehört da eigentlich nicht hin.)

Bist Du sicher, daß die Slice überhaupt stimmt, d.h. daß
auf ad4s5 ein ext2-Dateisystem ist? Denk daran, daß die
Numerierung der Partitionen unter BSD anders ist als unter
Linux. »ad4s5« ist (in DOS-Terminologie) das erste logi-
sche Laufwerk in der erweiterten Partition auf ad4.

> ich hab aber grad auch irgendwo gelesen das ext2 nicht unterstuezt wird
> ..was ich mir nicht wirklich vorstellen kann

Doch, wird unterstützt (mit gewissen Einschränkungen, die
man in LINT nachlesen kann). Allerdings ist es im GENERIC-
Kernel nicht drin, und es gibt auch kein ladbares Kernel-
Modul dafür, d.h. Du müßtest zunächst einen Kernel compi-
lieren, der »options EXT2FS« enthält (siehe LINT). Wenn
Du sonst weiter nichts brauchst, genügt es, wenn Du Dir
die Konfiguration für den GENERIC-Kernel kopierst und diese
eine Option noch drunten dranpappst. Dann die Standardpro-
zedur zum Bauen eines neuen Kernels ... steht alles im
Handbook; ist ganz einfach.

> bash-2.05b# e2fsck /dev/ad4s5
> e2fsck 1.32 (09-Nov-2002)
> The filesystem size (according to the superblock) is 33554414 blocks
> The physical size of the device is 0 blocks
> Either the superblock or the partition table is likely to be corrupt!

Das klingt so, als wenn /dev/ad4s5 nicht die richtige Slice
ist. (Soviel ich weiß, ist das e2fsck-Tool autark und be-
nötigt keinen ext2fs-Support im Kernel.)

Versuch doch mal ein »fdisk /dev/ad4«. Das zeigt die Bele-
gung der vier Slice-Slots an. Einer davon sollte als »Ex-
tenden Partition« bezeichnet sein -- auf den kann man wie-
derum fdisk anwenden und sich so durchhangeln.

Wenn ich mal kurz spekulieren darf: Wenn Deine Platte eine
primätre Partition und sonst nur noch logische Laufwerke
enthält, und die gesuchte Partition ist die fünfte, dann
wäre /dev/ad4s8 das richtige Device. Aber Du kannst ja
einfach mal ab ad4s6 aufsteigend durchprobieren (sicher-
heitshalber nur read-only mounten, d.h. »-o ro« beim mount-
Befehl). Ggf. mußt Du dazu unter /dev noch ein paar Devi-
ces mit MAKEDEV anlegen, wenn die noch nicht da sind.

Gruß
   Olli

-- 
Oliver Fromme, secnetix GmbH & Co KG, Oettingenstr. 2, 80538 München
Any opinions expressed in this message may be personal to the author
and may not necessarily reflect the opinions of secnetix in any way.
"... there are two ways of constructing a software design:  One way
is to make it so simple that there are _obviously_ no deficiencies and
the other way is to make it so complicated that there are no _obvious_
deficiencies."        -- C.A.R. Hoare, ACM Turing Award Lecture, 1980
To Unsubscribe: send mail to majordomo(at)de.FreeBSD.org
with "unsubscribe de-bsd-questions" in the body of the message
Received on Tue 20 Apr 2004 - 12:53:50 CEST

search this site