Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 16 Sep 2005 17:46:53 +0300
From:      Peter Pentchev <roam@ringlet.net>
To:        Daniel O'Connor <doconnor@gsoft.com.au>
Cc:        Daniel Eischen <deischen@freebsd.org>, freebsd-hackers@freebsd.org, Wouter van Rooij <aentgood@gmail.com>
Subject:   Re: ELF binary type "0" not known.
Message-ID:  <20050916144653.GG2813@straylight.m.ringlet.net>
In-Reply-To: <200509162357.22204.doconnor@gsoft.com.au>
References:  <Pine.GSO.4.43.0509161008460.17155-100000@sea.ntplx.net> <200509162357.22204.doconnor@gsoft.com.au>

next in thread | previous in thread | raw e-mail | index | archive | help

--+sHJum3is6Tsg7/J
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Fri, Sep 16, 2005 at 11:57:21PM +0930, Daniel O'Connor wrote:
> On Friday 16 September 2005 23:42, Daniel Eischen wrote:
> > > I'd be *very* suprised..
> > > I expect he just downloaded an RPM from somewhere..
> >
> > It's probably just not having linux.ko/linprocfs.ko loaded.
> >
> >   $ kldstat
> >   Id Refs Address    Size     Name
> >    1    1 0xc0400000 498518   kernel
> >   $ /usr/compat/linux/bin/ls
> >   ELF binary type "0" not known.
> >
> >   $ sudo kldload linux.ko
> >   $ kldstat
> >   Id Refs Address    Size     Name
> >    1    5 0xc0400000 498518   kernel
> >    2    1 0xc2a1a000 16000    linux.ko
> >   $ /usr/compat/linux/bin/ls /bin
> >   basename  chgrp  cp    echo   fgrep  ls     mv    rm     setserial  s=
tty=20
> >  true bash      chmod  date  egrep  grep   mkdir  nice  rmdir  sh      =
 =20
> > sync   uname bash2     chown  dd    false  ln     mknod  pwd   rpm    s=
leep
> >      touch
>=20
> Wow that's weird..
> I wonder why that happens?

What is weird?  The fact that if linux.ko is not loaded, the kernel
does not know what to do with an unknown ELF binary type? :)

What I find weird is the fact that as soon as linux.ko is loaded,
the kernel "learns" to treat type 0 binaries as type 3; but this is
probably because Daniel Eischen has at some earlier time set
the kern.fallback_elf_brand sysctl to 3.

G'luck,
Peter

--=20
Peter Pentchev	roam@ringlet.net    roam@cnsys.bg    roam@FreeBSD.org
PGP key:	http://people.FreeBSD.org/~roam/roam.key.asc
Key fingerprint	FDBA FD79 C26F 3C51 C95E  DF9E ED18 B68D 1619 4553
This sentence is false.

--+sHJum3is6Tsg7/J
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (FreeBSD)

iD8DBQFDKtrd7Ri2jRYZRVMRAsQrAJ9jtEEiPG7MwKGEyCkgQnP0JyPWFACeNsiC
ajxDf1NeSTlMapnV5Wf76HM=
=v7jD
-----END PGP SIGNATURE-----

--+sHJum3is6Tsg7/J--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050916144653.GG2813>