Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×
Debian Operating Systems Software BSD

Debian Gets FreeBSD Kernel Support 425

mu22le writes "Today Debian gets one step closer to really becoming 'the universal operating system' by adding two architectures based on the FreeBSD kernel to the unstable archive. This does not mean that the Debian project is ditching the Linux kernel; Debian users will be able to choose which kernel they want to install (at least on on the i386 and amd64 architectures) and get more or less the same Debian operating system they are used to. This makes Debian the first distribution, and probably the first large OS, to support two completely different kernels at the same time."
This discussion has been archived. No new comments can be posted.

Debian Gets FreeBSD Kernel Support

Comments Filter:
  • But with FreeBSD doing Linux apps, and Debian able to run the FreeBSD kernel, things are getting kinda weird in UNIX-land.

    I think I need to lie down now.
    • by MichaelSmith ( 789609 ) on Sunday April 05, 2009 @05:50PM (#27469241) Homepage Journal
      Not to mention Android using the linux kernel with a netbsd userland. I guess google don't want to mess with GPLv3.
    • by thedrx ( 1139811 ) on Sunday April 05, 2009 @06:10PM (#27469385)
      "This makes Debian the first distribution, and probably the first large OS, to support two completely different kernels at the same time."

      Two kernels? At the same time? I'll be in my bunk.
    • by hedwards ( 940851 ) on Sunday April 05, 2009 @06:45PM (#27469659)

      Debian is dead. Netcraft confirms it.

    • Re: (Score:3, Funny)

      by TaoPhoenix ( 980487 )

      George Orwell on Operating Systems!

      "And there, Free BSD was doing Linux, and Debian Linux can run the BSD kernel, and lo, you could no longer tell them apart".

  • by MaskedKumquat ( 522312 ) on Sunday April 05, 2009 @05:46PM (#27469191)
    Gentoo managed to get this kind of setup working years ago, didn't they?
  • Given that Ubuntu is down stream from Debian, does this mean that I can run the FreeBSD kernel on my Ubuntu install now?

  • by Anonymous Coward on Sunday April 05, 2009 @05:48PM (#27469213)

    Gentoo has supported the FreeBSD kernel for a while now, afaik

  • or Debian GNU/FreeBSD or.....? Enquiring minds must know!
    • by larry bagina ( 561269 ) on Sunday April 05, 2009 @05:51PM (#27469253) Journal
      GNU/FreeBSD. FreeBSD kernel (and libc?) + GNU userland (instead of the BSD userland). There's no linux involved (except perhaps the linux syscall emulation)
      • GNU/FreeBSD. FreeBSD kernel (and libc?) + GNU userland (instead of the BSD userland). There's no linux involved (except perhaps the linux syscall emulation)

        So what is the part of the gnu userland that makes it important enough to use in the title of the OS? Compiler?

        • by Anonymous Coward on Sunday April 05, 2009 @06:02PM (#27469335)

          GNU C library

  • by iYk6 ( 1425255 ) on Sunday April 05, 2009 @05:49PM (#27469223)

    Debian has had an unofficial kfreebsd-i386 port for years. It is still an unofficial port.

  • when this image [cryptohax.com] was actually an on-topic response to a Slashdot story.
  • by CestusGW ( 814880 ) on Sunday April 05, 2009 @05:51PM (#27469245)
    It's one thing to sit and think about a beautiful system. To daydream wistfully about interfaces so well-thought that you can swap kernels and userland implementations without the world coming to an end. It's another thing entirely to see it happen with a full featured OS like Debian! Congrats are in order for the Debian team for tackling this and (apparently) going all the way.
  • for performance? (Score:3, Interesting)

    by bcrowell ( 177657 ) on Sunday April 05, 2009 @05:53PM (#27469271) Homepage

    TFA doesn't give much information. It would be interesting to know whether there are some practical reasons to want this. One possibility I can imagine is that if you have a particular task that you want a server to do, you could measure its performance with both kernels. If one is 10% faster than the other, you pick that one. Another possibility would be if you want to test your software to see if it's likely to be portable, or if it contains hidden linuxisms; however, I would expect most of the incompatibilities to be in things like shells and command-line utilities, not the kernel.

  • APT? (Score:3, Interesting)

    by fuzzyfuzzyfungus ( 1223518 ) on Sunday April 05, 2009 @05:53PM (#27469273) Journal
    What exactly does it mean to be running Debian with a FreeBSD kernel? Is it essentially just FreeBSD with APT and gnu userland instead of ports and bsd userland?
    • by CAIMLAS ( 41445 )

      It's hard to say. I imagine it might be possible to run the same userland on top of two separate kernels, but there are certain packages in addition to drivers would need to target specific kernels - namely, Xorg packages, I think. Other than that, as long as the packages are built on the same libraries, and the libraries work with either kernel (or more accurately, there'd be multiple library versions per OS) it should be pretty straight forward.

    • Re:APT? (Score:5, Insightful)

      by pablomme ( 1270790 ) on Sunday April 05, 2009 @06:18PM (#27469441)

      Is it essentially just FreeBSD with APT and gnu userland instead of ports and bsd userland?

      It's FreeBSD with the entire Debian userland. AND it's Debian with a FreeBSD kernel. Pretty much like a centaur is a man with a horse's body AND a horse with a human head.

      The best description depends on what part you focus on. To me it's Debian with a FreeBSD kernel.

      • Re: (Score:3, Funny)

        by Tokerat ( 150341 )

        Pretty much like a centaur is a man with a horse's body AND a horse with a human head.

        That's Two-Things-ism!

    • Re:APT? (Score:5, Funny)

      by glwtta ( 532858 ) on Sunday April 05, 2009 @06:34PM (#27469587) Homepage
      Is it essentially just FreeBSD with APT and gnu userland instead of ports and bsd userland?

      So they went from being the Linux with the best package manager to being the BSD with the worst package manager?
  • Some more info (Score:5, Informative)

    by Talla ( 95956 ) on Sunday April 05, 2009 @05:55PM (#27469287)

    Is available at http://www.debian.org/ports/kfreebsd-gnu/ [debian.org]

    There isn't much, but a little bit in the install notes.

  • This will also help application interoperability, as fa as such help is still needed...

  • by kasperd ( 592156 ) on Sunday April 05, 2009 @06:01PM (#27469325) Homepage Journal
    So can I install just one system and choose between the two kernels at boot time? Or do you have to make a completely different install with executables build separately for each kernel?
    • Re: (Score:3, Informative)

      It's probably an either/or proposition*, since the system calls and basic libraries aren't the same across the platforms.

      *FreeBSD has a kernel level Linux binary compatibility layer, so I guess with enough pain and suffering you could make things switchable, at least with userland stuff.

      • Re: (Score:3, Informative)

        by drinkypoo ( 153816 )

        Pain and suffering? You mean editing the linker config so that the compat libraries are loaded first?

      • by BitZtream ( 692029 ) on Sunday April 05, 2009 @07:34PM (#27470051)

        Disclaimer: I'm a FreeBSD fanboy.

        FreeBSD has no problem running Linux binaries, linux binary compatibility has been there for years, I used it to run linux binaries that hadn't yet been ported to FBSD yet in 97, I still run several Linux binaries on my FBSD servers.

        For things that don't directly interact with the kernel, FreeBSD will run Linux binaries fine, full syscall emulation is built in with practically 0 cost in most cases. You need the proper Linux libraries available for it all to work, but it will also run ibcs2 binaries so you can throw in SCO and such if you got a license for those libraries!

        All it does is emulate the syscall interface to the kernel. FreeBSD and Linux are almost spot on in the way these interfaces work so it can accomplish the task with very little overhead, in many cases its just as efficient as using the native FBSD syscalls. In other cases some structure and memory mangling goes on so it slows down a bit.

        FreeBSD is actually capable of running some Linux apps faster than the Linux kernel can. Of course thats simply because those apps happen to agree with the way FreeBSD does things under the hood a little better and not an indication of superior OS, as there are just as many apps that perform worse. As a general rule however, performance is practically identical as running it on a native Linux kernel.

        With all that in mind, theres no reason you couldn't switch at boot time if your entire userland was made for the Linux kernel. There would need to be certain parts left as native code such as initd and the like, but you're really just talking about holding duplicate copies of what FBSD stores in /sbin and /bin. Probably just a simple matter of modifing the FBSD kernel and /bin /sbin apps to expect to work from /freebsd/boot,/freebsd/bin,/freebsd/sbin.

        Doesn't Linux have this sort of thing? I haven't used Linux in years, I just kind of assumed it did something like this as well. Maybe not for FBSD so much, but I'd expect some ibsc2 support at least.

        Finally, doesn't seem like theres much of a point really. FreeBSD is typically considered 'more secure' and has the fastest IP stack on the planet out of the box, but security is mostly a property of userland, kernel level exploits are rather rare now days, its usually a dumb app running with elevated privs that causes the problem so if you're using a Linux userland you aren't gaining that bit (real or imaginary). Linux isn't exactly slow when it comes to networking so unless you're trying to squeeze every last drop out of some hardware that doesn't seem to make it worth the while, might as well stick with what you know and what you know works for you. Just seems silly.

        • by Nevyn ( 5505 ) * on Sunday April 05, 2009 @09:52PM (#27471223) Homepage Journal

          FreeBSD has no problem running Linux binaries, linux binary compatibility has been there for years, I used it to run linux binaries that hadn't yet been ported to FBSD yet in 97, I still run several Linux binaries on my FBSD servers.

          Does this actually work 100%? How?

          And, yes, I understand you can do syscall emulation. But what about what happens behind the interfaces. For instance I find it hard to believe that TCP_CORK/mremap/epoll/etc. "works" when FreeBSD has refused (decided not to, whatever) to natively support it for years now. AFAIK FBSD doesn't have splice()/tee()/etc. either ... do they hack some of this in userspace?

          But even that seems like the easy stuff, what does FBSD do when I open("/proc/*") and start parsing stuff? What about closing sockets that are only referenced in the poll() call of another thread? Anything that hits the drivers "deeply" like X, pulseaudio, etc. seems like it'd be impossible to support. SELinux is just not going to work, probably dito. somewhat releated stuff like the audit interface / netlink (maybe that classifies as "deep" driver knowledge though).

          Then there's the really crazy stuff where you have the same interfaces natively but they operate subtley differently in weird corner cases, DJB has a page on some stuff [cr.yp.to], but I doubt anyone sane enough to have commit privs. knows all of these (if anyone at all does).

          • Re: (Score:3, Informative)

            by MattBurke ( 58682 )

            > Does this actually work 100%? How?
            No. The only reason I run Debian on my desktop instead of FreeBSD is because I need to use VMWare, which hasn't run under the Linux compat stuff since VMWare Workstation 3, but given that it *did* work once is a bit of a tribute to its completeness.

            I spent several years running an extremely busy yet stable Counter-Strike server under Linux compat, which performed significantly better (lower latency, less CPU load) than when running Linux natively on the same hardware.

          • Re: (Score:3, Interesting)

            by synthespian ( 563437 )

            Yes, Linux binary emulation actually works. A couple of years ago, the usual Linux ABI breakage - of which they are very proud of - made me unable to use Maple 8 (for which you have to buy an expensive license) on Ubuntu.

            I installed FreeBSD and the Linux emulation layer, tweaked some stuff on the Maple side (basically, some scripts) and there you go - Maple ran on FreeBSD with the Linux emulation layer, while it refused to run on Linux itself, whcih it had done, just a release earlier (i.e., a couple of mon

  • Boring... (Score:5, Funny)

    by __aaclcg7560 ( 824291 ) on Sunday April 05, 2009 @06:23PM (#27469485)
    I'm waiting for Windows kernel support to be added. I prefer blue screens over seg faults. :P
  • by gmhowell ( 26755 ) * <gmhowell@gmail.com> on Sunday April 05, 2009 @06:27PM (#27469519) Homepage Journal

    Does this mean Netcraft no longer confirms it?

  • by Idimmu Xul ( 204345 ) on Sunday April 05, 2009 @06:31PM (#27469557) Homepage Journal

    ZFS, woohoooooooooooooooooooooo!!!!!!!!!!

  • by ivoras ( 455934 ) <ivoras&fer,hr> on Sunday April 05, 2009 @07:07PM (#27469843) Homepage

    There are at least two things that need consideration here, in a sort-of general aspect:

    • Sure, you can replace tools like 'ls' and 'rmdir' with GNU equivalents, and BSDs already use gcc so it's not that hard to get it going, but BSDs are also full of utilities that are tightly integrated with the kernel. Trivial examples: you can't replace GEOM utilities with md* utilities - they simply cover different things (here's a simple example of what GEOM can do [sharanet.org]). Utilities like "top" and "netstat" operate on completely different data structures. The Linux "free" utility, for example, cannot have an equivalent in FreeBSD with exactly the same output because the interpretation of what is "free" memory is different.
    • FreeBSD can execute Linux binaries natively. This means exactly what it says, within reason. Pick up a "ls" binary from any Linux distribution (actually, pick an older one that doesn't use fancy new 2.6 features - 2.6 will only be supported in full in 8.x), copy it and the libraries it needs to a FreeBSD system with Linux ABI enabled and simply run it. You can, in fact, run a completely Linux userland, except for the administrative utilities. With some effort (because nobody made it automated yet) you can run Debian under FreeBSD natively, packages and all. (explanation: it's simply a matter of remapping Linux syscalls to FreeBSD syscalls; for example: Linux's open() to FreeBSD open(), etc. with no visible performance impact - people are running Oracle this way, though completely unsupported of course)

    There's little documentation about the Debian project but it doesn't say which route they've chosen, and what about possible issues with it (mostly: admin utilities).

    And besides, a very large number of BSD users will agree that its userland is what's most important - the consistency of development and behaviour, the ease of administration. The kernel features are just icing on the cake :)

  • Hurd too.. (Score:5, Informative)

    by Amazing Quantum Man ( 458715 ) on Sunday April 05, 2009 @07:17PM (#27469909) Homepage
  • What's the point? (Score:4, Insightful)

    by bonch ( 38532 ) on Sunday April 05, 2009 @07:53PM (#27470193)

    Why not just run FreeBSD with a real BSD userland and ports system? I'm just curious why you would use a BSD kernel but keep a Debian userland when it would probably be more reliable to just use FreeBSD's userland too.

    • Re: (Score:3, Informative)

      by micheas ( 231635 )

      Because if you want to run anything besides sendmail you are stuck with the ports that occasionally have the quality control of "if it compiles ship it", especially if you head of the beaten tracks and try obscure ports like php and samba.

      Debian has its short comings, but if you like FreeBSD because it is integrated, you should find that Debian is even more integrated.

      FreeBSD tends to have the source readily available and builds without any black magic to hold together a billion dependencies, so it is a mor

In the long run, every program becomes rococco, and then rubble. -- Alan Perlis

Working...