Slashdot Mirror


Oracle To Bring Dtrace To Linux

mvar writes "Dtrace co-author Adam Leventhal writes on his blog about Dtrace for Linux: 'Yesterday (October 4, 2011) Oracle made the surprising announcement that they would be porting some key Solaris features, DTrace and Zones, to Oracle Enterprise Linux. As one of the original authors, the news about DTrace was particularly interesting to me, so I started digging. Even among Oracle employees, there's uncertainty about what was announced. Ed Screven gave us just a couple of bullet points in his keynote; Sergio Leunissen, the product manager for OEL, didn't have further details in his OpenWorld talk beyond it being a beta of limited functionality; and the entire Solaris team seemed completely taken by surprise. Leunissen stated that only the kernel components of DTrace are part of the port. It's unclear whether that means just fbt or includes sdt and the related providers. It sounds certain, though, that it won't pass the DTrace test suite which is the deciding criterion between a DTrace port and some sort of work in progress.'"

17 of 155 comments (clear)

  1. Phasing out Solaris? by eln · · Score: 2, Insightful

    So, are they porting Solaris functionality to OEL as a precursor to phasing out Solaris entirely? It would suck to see Solaris go from a nostalgia point of view, but it never made much sense to me why one company would continue to develop two Unix-like operating systems.

    1. Re:Phasing out Solaris? by armanox · · Score: 2

      Hate to tell you this, but they killed OpenSolaris a long time ago.

      --
      I'm starting to think GNU is the problem with "GNU/Linux" these days.
    2. Re:Phasing out Solaris? by the+linux+geek · · Score: 3, Informative

      OEL for SPARC has already been announced.

    3. Re:Phasing out Solaris? by ToasterMonkey · · Score: 2

      Hate to tell you this, but they killed OpenSolaris a long time ago.

      ... as far as aspiring 3rd party Solaris contributors were concerned. For everyone else it was just renamed to Solaris 11 Express.

      They probably suddenly ended transparency of Solaris development because they intend to phase it out, port everything to Linux and give it away. /sarcasm

    4. Re:Phasing out Solaris? by MrNthDegree · · Score: 2

      Just some ideas that come to mind and show that actually Solaris isn't as innovative as the Linux camp...

      Linux kernel innovations which are more flexible than most alternatives:

      SELinux - label-based security which allows flexible controls over the privileges of objects and how they may interact with other labelled objects [Trusted Solaris]
      TOMOYO - pathname+history-based security which provides flexible controls over the privileges of processes and how they may interact with objects
      AppArmor - pathname based security with flexible controls over the privileges of processes and how they may interact with files/network
      cgroups - hierarchical scheduling, resource management customisable entirely by the user within software or through writing to files [Zone Resource Controls]
      Kernel Namespaces - flexible separation of networking, PID tables, IPC etc. called simply from within clone() [Jails / Zones]
      File Capabilities - labelling files with specific capabilities which would normally only be given to root - removing SETUID from a lot of files
      User Mode Linux - port of Linux to run in userland atop a Linux kernel, paravirtualization (Linode built their business upon this)
      Completely Fair Queuing (CFQ) - a decent method of prioritising I/O fairly, so that heavy I/O does not grind a desktop/server to a halt
      Completely Fair Scheduling (CFS) - a decent method of prioritising CPU fairly, so that heavy CPU load does not grind a desktop/server to a halt
      Kernel Mode Setting (KMS) - enables faster switching of terminals, simpler 2D acceleration and better security (Xorg no longer needs root) [Windows GDI]
      Full NX Support - helps reduce the risk of successful exploitation of buffer overflows [Windows DEP / OpenBSD W^X]
      Full ASLR Support / PIC / PIE - reduces risk of certain classes of exploit by randomising memory location of libraries
      NILFS2 - infinite snapshotting log-based filesystem, theoretically capable of tracking every change ever made to files

      GNU/Linux userland innovations:

      systemd - purely Linux-oriented solution for fast, parallelised initialisation of services
      AppArmor - simple way to lock down server/desktop processes interactively through a robust parser
      libvirt - abstraction layer to allow many different types of virtualisation to be used in a common way
      PolicyKit - secure method of enabling root processes to run without the risk of malicious X clients injecting commands
      PackageKit - abstraction layer for a common method of updating/installing/removing packages
      PulseAudio - low-latency abstraction layer for handling multiple audio systems, networking audio and multiplexing devices, with per-client volume controls
      firewalld - applications can make D-BUS requests to open inbound ports and PolicyKit handles allow/deny, along with any uPnP requests (if allowed)
      ABRT - automated bug reporting of most userland applications, sent to the distribution and/or the upstream developers [Windows Error Reporting]
      kerneloops - automated reporting of kernel oops errors to detect potential common bugs in the kernel without manual user interference [Windows Error Reporting]
      GCC SSP (ProPolice) - prevents buffer overflows in the stack through a canary value [Microsoft Visual Studio (C++) GS]

    5. Re:Phasing out Solaris? by Fished · · Score: 3, Insightful

      Yeah, Solaris has some pretty awesome features, but at the end of the day all that may be irrelevant in the face of Market Pressures. Sun for many years shot themselves in the foot by failing to deliver useful tools for things like patching/updating, mass installation of Solaris servers (yes, there is jumpstart/wanboot, but it is clearly deficient), and failing to deliver a decent native volume manager (ZFS) until Too Late, and then not having it support root filesystems until Way Too Late.

      The reality of Solaris is that there are all these features that look awesome in theory, until you actually have to implement them and discover the practical implications. Take Zones. Zone sounds great, in theory. But, ever tried to patch a server with zones? It's a nightmare. And heaven help you if you actually have a server with zones from multiple, different apps and you need to get outage windows from all the different app groups in order to patch. Or LDoms. Again, they sound awesome. That is, until you realize that there are no tools to manage migrations when a server goes down hard (the most common case for which you would want to do a migration!) So, you end up having to write a bunch of scripts to duplicate LDom xml files etc. to do this, because Sun/Oracle didn't really think through how their technology would be used in a real environment. I also use AIX virtualization technology, and it's much better, and VMWare (which is what we use for Linux servers) blows them both out of the water.

      Things like this are why a lot of major companies, including the one I work at, are leaving Solaris as fast as they can. The reality is that it takes twice as many SA's per server on Solaris as it does for any other platform, we have lower virtualization densities, and it therefore costs a lot more money to run. For the kind of money we're talking about, we can deal with a few echoes in the interface for SAN's.

      --
      "He who would learn astronomy, and other recondite arts, let him go elsewhere. " -- John Calvin, commenting on Genesis 1
  2. FreeBSD? by liquidhokie · · Score: 4, Informative

    If you want Dtrace and ZFS, just go with FreeBSD. You get pf and jails thrown in for the effort.

    1. Re:FreeBSD? by afabbro · · Score: 4, Interesting

      So why is it possible for FreeBSD to have dtrace/zfs and not Linux? I ask out of ignorance...

      (I am expecting the answer to be legal rather than technical/no one's gotten around to it)

      --
      Advice: on VPS providers
    2. Re:FreeBSD? by airencracken · · Score: 4, Insightful

      Because the CDDL (which dtrace and zfs are licensed under) is incompatible with the GPL, but not the BSD license.

      --
      Hell is other people - Jean-Paul Sartre
    3. Re:FreeBSD? by TheRaven64 · · Score: 3, Informative

      Linux is released under version 2 of the GNU General Public License. This imposes a few restrictions and says that the code may not be distributed linked to any code that imposes more restrictions, nor can any derived works impose any more restrictions than are present in the license.

      FreeBSD is released under the 2-clause BSD license, which says, basically, do what you want with this, just don't sue me if it doesn't work and don't claim you wrote it.

      OpenSolaris was released under the CDDL, which is generally less restrictive than the GPL (no restrictions on what you can link it to), but adds some anti-patent clauses that are not present in the GPL. Because these restrictions are not present in the GPL, the GPL prevents CDDL code from being linked against it. This means that if ZFS or DTrace were ever ported to Linux by anyone other than the copyright holder they would not be allowed to distribute Linux along with their port.

      In FreeBSD, ZFS and DTrace are optional kernel modules, so you can still build a system without them, but they are loadable if you are happy to accept the terms of the CDDL when you distribute FreeBSD. There's no technical reason why either couldn't be ported to any system (well, the Linux storage stack is a mess, so adding ZFS would be a bit harder, but it could be done), but few people are motivated to produce a port when they are not legally allowed to redistribute it.

      --
      I am TheRaven on Soylent News
  3. Great technology story! by bdgregg · · Score: 4, Interesting

    This is a great technology story - even if only for one version of Linux so far. DTrace will bring tremendous value for troubleshooting and performance analysis, and is a technology I use (almost) every day.

    For example, yesterday I had a CPU bound workload with an unexpected level of variation, and used DTrace to measure the effect of CPU thread affinity and interrupt activity on that workload. I used DTrace to pull the runtime along with other details: number of scheduling events for that thread, along with the CPUs that the thread ran on; also, for preemption, the pre-emptor thread (to see why) along with both its user-level and kernel stack traces; also the interrupt thread and device. I fairly quickly showed that the runtime variation was caused by network interface interrupts from an entirely different application. This analysis would take quite a lot longer without DTrace, and may be prohibitively difficult to complete.

    Many of my uses of DTrace are much more straightforward than that; including identifying file system latency for applications, application response time, and CPU dispatcher queue latency. I've listed many more examples in the DTrace book (http://www.dtracebook.com). It should be a great resource of ideas for those looking to use DTrace on Linux - since the hardest part for people has been knowing where to start, given the ability to see everything.

  4. Re:Bring ZFS to linux! by hjf · · Score: 3, Interesting

    And why do you want to keep the raid and LVM stack?

    If you're creating a filesystem and you can make it aware of its own backing storage (and adjust stuff like block size - cause you know, there are disks with 4K sectors now), and have it manage caching by itself (and thus, be aware of how much memory the has, and how much of it is actually RAM and not virtual), and have it check for redundancy and do online checks and repairs - which you realize it's just awesome if you ever try to do fsck on a 20TB filesystem (and because it knows how much data it's actually used, have it only check what's used, instead of blindly regenerating blank space for an array of disks). And variable strip size, and thin provisioning, CoW and free snapshots and clones, and a lot of other stuff ZFS does because it doesn't need to "respect its elders" LVM and md.

  5. Re:Too Late...WE DONT NEED IT...we got SystemTap by _merlin · · Score: 3, Insightful

    You obviously haven't had to use both in anger. SystemTap is another "me too" project like so many things on Linux, where the only people saying it's as good are the people who haven't used the product it's an imitation of. Oh, and then there's the RMS type who will say it's "better because freedom has value" or something to that effect. Doesn't help you when you're actually trying to tune an application for performance.

  6. Re:Bring ZFS to linux! by TheRaven64 · · Score: 2

    The worst thing about the first complaint is that ZFS actually does have very clean layering. At the bottom you have the storage pool allocator at the bottom is basically malloc() for persistent storage (equivalent to the block device layer, but with a more convenient interface), the data management unit sits on top of this and provides transactional I/O to the underlying storage, and the ZFS POSIX layer sits on top of this and provides POSIX filesystem semantics. You could replace the ZPL with something that provides things that look like raw block devices (ZVOLS - used for iSCSI shares, among other things), and you could also fairly easily add something that provided an SQL interface to storage, since the transactional support is all done a layer lower down the stack.

    The second complaint is really a matter of semantics. Scrubbing a ZFS partition provides a superset of the functionality of fsck. Not only does it validate and repair the metadata, it also validates and repairs the data on the disks. Most ZFS users don't need to run it, because all it really does is try to read every file on the disk - the underlying filesystem code performs the repairs automatically any time some read data fails the checksums.

    I think the real problem with ZFS is the name. Calling it a filesystem makes people mentally class it as something like UFS or ext2fs, when it's actually a complete storage stack.

    --
    I am TheRaven on Soylent News
  7. Re:Bring ZFS to linux! by TheRaven64 · · Score: 2

    OpenSolaris may be dead, but FreeBSD now ships with version 28 of ZFS, which includes nice things like deduplication. iXSystems, which sells storage appliances based on FreeBSD, is funding ongoing development work, so ZFS on FreeBSD is going to stay actively maintained irrespective of whether Oracle makes future versions of the code available. FreeBSD also got the ability to boot from ZFS before Solaris and integrates ZFS very nicely into the existing storage stack (it works as a GEOM consumer and provider, so you can easily do things like put a FAT partition in a ZVOL and have transactional I/O and deduplication on the filesystem used by a Windows 95 virtual machine).

    --
    I am TheRaven on Soylent News
  8. Re:Good news. by Morth · · Score: 2

    As long as the leave strace in place. Apple replaced ktrace with dtrace and I've been hating it ever since.
    It's not that dtrace is bad, it's just that they have different purposes, and dtruss has several problems ktrace/strace does not:

    • It's asynchronous. Meaning it won't output write(1, "foo\n", 4); next to the actual output of foo.
    • Sometimes stuff gets out of order, not sure why.
    • It'll only output pointer addresses, e.g. bind(3, 0x12345678, ...) instead of bind(3, {127.0.0.1, 8080}, ...)

    Ok, rant over.

  9. Available since 2008 by sgt+scrub · · Score: 2

    It has been available for Linux since 2008. 02-Aug-2008 Work in progress port of Sun's DTrace system for Linux. It is actively maintained. http://www.crisp.demon.co.uk/tools.html I don't see anything new to the table outside of keyboard, mouse, and framebuffer recording. I'm not sure a lot of Linux users would find that an attractive addition.

    Built-in instruments can track

            User events, such as keyboard keys pressed and mouse moves and clicks with exact time.
            CPU activity of processes and threads.
            Memory allocation and release, garbage collection and memory leaks.
            File reads, writes, locks.
            Network activity and traffic.
            Graphics and inner workings of OpenGL.

    --
    Having to work for a living is the root of all evil.