From owner-freebsd-emulation Fri Oct 10 14:31:49 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id OAA11243 for emulation-outgoing; Fri, 10 Oct 1997 14:31:49 -0700 (PDT) (envelope-from owner-freebsd-emulation) Received: from usr08.primenet.com (tlambert@usr08.primenet.com [206.165.6.208]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id OAA11227; Fri, 10 Oct 1997 14:31:44 -0700 (PDT) (envelope-from tlambert@usr08.primenet.com) Received: (from tlambert@localhost) by usr08.primenet.com (8.8.5/8.8.5) id OAA13249; Fri, 10 Oct 1997 14:31:13 -0700 (MST) From: Terry Lambert Message-Id: <199710102131.OAA13249@usr08.primenet.com> Subject: Re: LINUX emulation and uname(3). To: rivers@dignus.com (Thomas David Rivers) Date: Fri, 10 Oct 1997 21:31:13 +0000 (GMT) Cc: jlemon@americantv.com, rivers@dignus.com, cracauer@cons.org, freebsd-emulation@freefall.FreeBSD.org, freebsd-hackers@freefall.FreeBSD.org In-Reply-To: <199710101218.IAA08913@lakes.dignus.com> from "Thomas David Rivers" at Oct 10, 97 08:18:06 am X-Mailer: ELM [version 2.4 PL23] Content-Type: text Sender: owner-freebsd-emulation@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > > The Linux uname() call currently reports the FreeBSD info. I suppose > > that this could be made into a sysctl if it really becomes a nuisance? > > (see sys/i386/linux/linux_misc.c:linux_newuname for the implementation) > > Well - it was a nuisance in this case, as I was unable to run the > particular Linux program I wanted to run... > > And, of course, you are right... I got a small program that simply > calls uname() on Linux and ran it on FreeBSD - it reported the FreeBSD > info... > > However, after reporting what I was doing, the company sent me a new > license key (with the idea that "FreeBSD" would be returned in the utsname > fields), which worked... > > It's just a bother for the various companies, and it means that our claim > of being able to run Linux binaries isn't as complete as we may have wanted. > > Maybe a sysctl, so people could taylor it, is the right thing to do. > In any event, I think a uname() call under Linux emulation should claim > to be "Linux" and not "FreeBSD". So, the default should be "Linux"... I *STRONGLY* disagree! Putting aside for the moment the fact that the utsname is a silly thing to include in a licensing scheme on an OS where you can make it say whatever you want it to (you can even do it on Solaris/UnixWare, since you can load a loadable driver, and as part of the "init", overwrite the sysent[] table entry with a pointer to your replacement function). The reason the Linux uname reports FreeBSD instead of Linux information is *precisely* to trigger fixes exactly like the one you got. You now have added a "FreeBSD" tally mark instead of a "Linux" tally mark at that company. Initially, it was done because of the Linux NetScape reporting "Linux" to the HTTP servers on the other end of the line, when in fact it was running on FreeBSD. If you want accurate demographics for FreeBSD systems, then this type of thing needs to stick out. That said, I'm not terribly opposed to a sysctl() that would let you hammer it down, but it should *definitely* remain the way it is for the default, and hammering should be a last resort. I'm somewhat opposed to a sysctl(), only because it's too easy to avoid providing correct demographics to companies that should *know* that their products are being used on FreeBSD before the next release is ported to various platforms. Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.