Archive

Archive for the ‘Kernel / Internals’ Category

VirtualBox 3.1 released!

December 1st, 2009 No comments

Just when you thought you can start a new month without some new software, Sun has blessed the world with a ray of VirtualBox 3.1 goodness on us all! All hail the Sun. I’ve been using the Betas and trying out the spanking awesome Teleportation feature in VirtualBox 3.1. So lets take a bit of a look at the new grub.

Beam me up Scotty!

You know, people say the catch phrase thinking its from Star Trek, but did you know that it was never actually mentioned in any episode?

Teleportation or ‘Live Migration‘ in Xen/KVM  or vMotion in VMWare allows you to move a running virtual machine to another host without any downtime. Sun brings us this ‘Enterprise’ feature to VirtualBox. Whats even cooler, is that you can teleport your running VM on different host platforms (Windows -> OpenSolaris or Linux, vice versa) but not from one hardware set (Intel) to another (AMD) unless they both have the same instruction-sets. The transport layer for the teleportation is TCP/IP, so as long as the agreed port is open and accessible you can even teleport it through the tubes! (assuming you have a fast link like those pesky Dutch)

There are a few conditions and caveats as I’ve found. Firstly you must ensure (as you’d expect) the target VM has to have the exact same configuration as the source VM (same RAM, graphics memory, storage, CD/DVD images etc) the other thing is to be weary of the CPUs the host computer has. As long as its between the same generations (different clock speeds are OK) it should work (I tried between a QX6850 -> E6600 but QX6850->AMD X2 4600+ wasn’t so pretty!).

Once you’ve configured the target host to match the source host, time to ask VirtualBox to keep its eyes open for an incoming beam.

VBoxManage modifyvm [VirtualMachineName] --teleporter on --teleporterport [Port]

Then on the source host, send out the beams to initiate the teleportation:

VBoxManage controlvm [VirtualMachineName] teleport --host [TargetIP] --port [Port]

Give it some time to think and if you tried a localhost migration, it should migrate seamlessly :-)

Scotty doesn’t know

Scotty doesn’t know about the other little changes, but you will. The new VirtualBox has lots of refinements in the UI. For one, new icons for all the Guest operating systems. The settings window has had a make over and includes ‘optimal settings’ detection.

Windows 2003 VM in VirtualBox 3.1

Windows 2003 VM in VirtualBox 3.1

Here its telling me my Windows 2003 VM should have atleast 20Mb Video Memory assigned to it to work well in full-screen mode. Heading over to the Display options in VirtualBox 3.1 we find that the Video Memory selectors have got little indicators now, as well as the inclusion of 2D Video Acceleration.

Windows 2003 VM - VirtualBox 3.1 Display Settings

Windows 2003 VM - VirtualBox 3.1 Display Settings

Depending how ever many cores you have, it will highlight what you should set as the maximum number of cores available for your VirtualMachine as well as the recommended RAM allocation. This is what I see in my Intel QX6850 development workstation.

VirtualBox 3.1 System Processor Settings

VirtualBox 3.1 System Processor Settings

VirtualBox 3.1 - Motherboard Settings

VirtualBox 3.1 - Motherboard Settings

VirtualBox now also has experimental support for Extensible Firmware Interface (EFI) which will eventually replace the aging BIOS bootstrap (which is the default). Well known operating systems that boot via EFI include Windows Vista and Windows 7, Apple OS X and Fedora 11+.

The Storage controls in VirtualBox GUI has also had a bit of a make over. The options to select a disk and a controller have changed, CD/DVD drives can be attached to an arbitrary IDE controller too now!

VirtualBox 3.1 - Storage

VirtualBox 3.1 - Storage

The networking settings GUI in the new VirtualBox has change too, not only that but you can now configure the network interfaces whilst the guest is running – YAY!

VirtualBox 3.1 Network Settings

VirtualBox 3.1 Network Settings

Snapshots are a lot more flexible in this release (much like VMWare’s snapshot feature). Previously you can only restore from the last created snapshot, now any arbitrary snapshot can be restored too or branched off.

For those who use OpenSolaris (like yours truely!) the rewritten USB support (still experimental btw!) should mean we can interact with our USB devices in Solaris Nevada 124 or higher now – I’m running 127 and have USB devices appearing in my VMs.

If those don’t give you any indication on to the pure awesomeness of this release, there was a significant performance improvement for APE & AMD64 guests (VT-x/AMD-V) which will be quite noticeable from what I’ve been told by a college.

As Barack Obama said, tis time for a change..log.

He didn’t say that, I just reused 36 Mafia’s Lolli Lolli. The entire change log appears below from the website.

VirtualBox 3.1.0 (released 2009-11-30)

This version is a major update. The following major new features were added:

  • Teleportation (aka live migration); migrate a live VM session from one host to another (see the manual for more information)
  • VM states can now be restored from arbitrary snapshots instead of only the last one, and new snapshots can be taken from other snapshots as well (“branched snapshots”; see the manual for more information)
  • 2D video acceleration for Windows guests; use the host video hardware for overlay stretching and color conversion (see the manual for more information)
  • More flexible storage attachments: CD/DVD drives can be attached to an arbitrary IDE controller, and there can be more than one such drive (the manual for more information)
  • The network attachment type can be changed while a VM is running
  • Complete rewrite of experimental USB support for OpenSolaris hosts making use of the latest USB enhancements in Solaris Nevada 124 and higher
  • Significant performance improvements for PAE and AMD64 guests (VT-x and AMD-V only; normal (non-nested) paging)
  • Experimental support for EFI (Extensible Firmware Interface; see the manual for more information)
  • Support for paravirtualized network adapters (virtio-net; see the manual for more information)

In addition, the following items were fixed and/or added:

  • VMM: guest SMP fixes for certain rare cases
  • GUI: snapshots include a screenshot
  • GUI: locked storage media can be unmounted by force
  • GUI: the a log window grabbed all key events from other GUI windows (bug #5291)
  • GUI: allow to disable USB filters (bug #5426)
  • GUI: improved memory slider in the VM settings
  • GUI: the VirtualBox website couldn’t be opened from the help menu (bug #4559)
  • 3D support: major performance improvement in VBO processing
  • 3D support: added GL_EXT_framebuffer_object, GL_EXT_compiled_vertex_array support
  • 3D support: fixed crashes in FarCry, SecondLife, Call of Duty, Unreal Tournament, Eve Online (bugs #2801, #2791)
  • 3D support: fixed graphics corruption in World of Warcraft (#2816)
  • 3D support: fixed Final frame of Compiz animation not updated to the screen (#4653)
  • 3D support: fixed incorrect rendering of non ARGB textures under compiz
  • iSCSI: support iSCSI targets with more than 2TiB capacity
  • VRDP: fixed occasional VRDP server crash (bug #5424)
  • Network: fixed the E1000 emulation for QNX (and probably other) guests (bug #3206)
  • NAT: added host resolver DNS proxy (see the manual for more information)
  • VMDK: fixed incorrectly rejected big images split into 2G pieces (bug #5523, #2787)
  • VMDK: fixed compatibility issue with fixed or raw disk VMDK files (bug #2723)
  • VHD: fixed incompatibility with Hyper-V
  • Support for Parallels version 2 disk image (HDD) files; see the manual for more information
  • OVF: create manifest files on export and verify the content of an optional manifest file on import
  • OVF: fixed memory setting during import (bug #4188)
  • Mouse device: now five buttons are passed to the guest (bug #3773)
  • VBoxHeadless: fixed loss of saved state when VM fails to start
  • VBoxSDL: fixed crash during shutdown (Windows hosts only)
  • X11 based hosts: allow the user to specify their own scan code layout (bug #2302)
  • Mac OS X hosts: don’t auto show the menu and dock in fullscreen (bug #4866)
  • Mac OS X hosts (64 bit): don’t interpret mouse wheel events as left click (bug #5049)
  • Mac OS X hosts: fixed a VM abort during shutdown under certain conditions
  • Solaris hosts: combined the kernel interface package into the VirtualBox main package
  • Solaris hosts: support for OpenSolaris Boomer architecture (with OSS audio backend).
  • Shared folders: VBOXSVR is visible in Network folder (Windows guests, bug #4842)
  • Shared folders: performance improvements (Windows guests, bug #1728)
  • Windows, Linux and Solaris Additions: added balloon tip notifier if VirtualBox host version was updated and Additions are out of date
  • Solaris guests: fixed keyboard emulation (bug #1589)
  • Solaris Additions: fixed as_pagelock() failed errors affecting guest properties (bug #5337)
  • Windows Additions: added automatic logon support for Windows Vista and Windows 7
  • Windows Additions: improved file version lookup for guest OS information
  • Windows Additions: fixed runtime OS detection on Windows 7 for session information
  • Windows Additions: fixed crash in seamless mode (contributed by Huihong Luo)
  • Linux Additions: added support for uninstalling the Linux Guest Additions (bug #4039)
  • Linux guest shared folders: allow mounting a shared folder if a file of the same name as the folder exists in the current directory (bug #928)
  • SDK: added object-oriented web service bindings for PHP5

Overall this is a solid new release from Sun – unsure about its stability as I’ve only been running a few VMs (Windows 2003, CentOS and Fedora 12) for about 10-12hrs. Nothing bad as yet.

Download from the VirtualBox site:

  • VirtualBox 3.1.0 for Windows hosts x86/amd64
  • VirtualBox 3.1.0 for Solaris and OpenSolaris hosts x86/amd64

Enjoy!

[Post to Twitter] 

  • Share/Save/Bookmark

Google releases ChromeOS

November 20th, 2009 No comments

Google just released information and a presentation (below) about ChromeOS.

Wow, you can take a peek at the source as well. I’m not sure if its just a very tweaked minimalistic Linux Kernel with a Chrome Window Manager or what, but like they did with Chrome, this is definitely a Think Different product. Take a look at a visual tour of the ChromeOS.

I don’t think this will replace your traditional desktop completely (I still like to have my stuff with me rather than hosted somewhere!) but what happens to devices, peripherals etc, development environments (Imagine running Visual Studio over the intertubes on ADSL!) etc.

But one things for sure, it takes the idea of Operating Systems and how you view your operating system to a different level. All those tabs you see in Chrome now, are virtual desktop like instances in ChromeOS. More info can be got from the PCWorld article on ChromeOS.

[Post to Twitter] 

  • Share/Save/Bookmark

Windows 7 NetBIOS Kernel Crash, 1997 all over again :(

November 12th, 2009 No comments

Looks like Windows 7 is vulnerable to an SMB remote exploit.

Unfortunatly this SMB2 security issue is specificaly due to a MS patch, for another SMB2.0 security issue:
KB942624 (MS07-063)
Installing only this specific update on Vista SP0 create the following issue:

SRV2.SYS fails to handle malformed SMB headers for the NEGOTIATE PROTOCOL REQUEST functionnality.
The NEGOTIATE PROTOCOL REQUEST is the first SMB query a client send to a SMB server, and it’s used to identify the SMB dialect that will be used for futher communication.

Reminds me of the days of WinNuke.

[Post to Twitter] 

  • Share/Save/Bookmark

Next generation Linux file-systems

November 5th, 2009 No comments

If you’ve been reading this blog a couple of things are clear, I don’t like Apple much and I have a soft spot for file-systems. An article was posted on the IBM DeveloperWorks site that covers two file systems; NiLFS(2) and exofs that has some great information about these two beasts.

Linux® continues to innovate in the area of file systems. It supports the largest variety of file systems of any operating system. It also provides cutting-edge file system technology. Two new file systems that are making their way into Linux include the NiLFS(2) log-structured file system and the exofs object-based storage system. Discover the purpose behind these two new file systems and the advantages that they bring.

Read the full article on the Next-generation linux filesystems, there was an article on LWN.net a few years back discussing the (then emerging) Btrfs and NiLFS and how things may pan out. I’m quite happy and content with ZFS but in either case it’ll be interesting to see how all three go.

[Post to Twitter] 

  • Share/Save/Bookmark

Ubuntu 9.10 & Mozilla Firefox 3.6 Beta 1!

November 1st, 2009 No comments

Unless you’ve been living under a rock (or near a very large one in the middle of no where) Canonical released the eagerly awaited Ubuntu 9.10 Karmic Koala on Friday. This is probably one of the biggest and coolest release of Ubuntu yet! Make sure you try the Server edition and setup an EC2 private cloud for tinkering – Cloud is where its at! But thanks to Mark Wolfe make sure you see this blog post about some things to do after installing.

Get it from the main download server or from iinet or internode mirrors if your in Australia.

Then there’s Mozilla who released Firefox 3.6 Beta 1 recently too – based on Gecko 1.9.2, download a copy and try it out, its got Windows 7 integration and CTRL+TAB previews which are finally in!

If that wasn’t enough I finally turned 25 today, quarter of a century. Its nice to have a birthday on a weekend – especially a long weekend!

[Post to Twitter] 

  • Share/Save/Bookmark

Redhat 5.4 released, CentOS 5.4 is coming soon!

September 3rd, 2009 No comments

If you haven’t heard already, Redhat has released the eagerly anticipated 5.4 release of Redhat Enterprise Linux at their Redhat Summit in Chicago. As expected, Redhat looks to have moved from using Xen as their favoured virtualisation hypervisor to using KVM (which is an integral part of the Linux Kernel). All this will eventually go into RHEV.

All the changes in this release are documented in the  Release Notes, unfortunately Ext4 is still not considered usable in this release (they’re targetting for RHEL6 possibly).

So what of the RHEL clone CentOS? Possibly a 2-4 week delay it seems. WOO! In the meantime, upgrading from 5.3 is easy peasy.

[Post to Twitter] 

  • Share/Save/Bookmark

Boffins get 1,000,000 Linux Kernels running as virtual machines!

August 4th, 2009 No comments

Thats right, that wasn’t a typo. Some crazy boffins at Sandia National Laboratories in Livermore, have run more than a million Linux kernels as virtual machines out of which 20,000 can be run simultaneously! Why on earth would they attempt such feats?

Prehaps this XKCD may jog your memory

XKCD: Networking

Yep, just about:

The technique will allow them to effectively observe behaviour found in malicious botnets, or networks of infected machines that can operate on the scale of a million nodes.

Insane!

[Post to Twitter] 

  • Share/Save/Bookmark

Linux Btrfs: A short history of btrfs

August 2nd, 2009 No comments

Valerie Aurora (such a cool name!) takes a look into the history of Btrfs, well written and easy to follow.

[Post to Twitter] 

  • Share/Save/Bookmark

Time flies: VirtualBox 3.0 final is out!

July 1st, 2009 No comments

It only feels like last week that I mentioned the beta release of VirtualBox 3.0, Sun has released the final version of the much anticipated v3.0!

As mentioned earlier, this release is super exciting for the simple fact that it has SMP support – a maximum of 32 virtual CPUs (but relax, you shouldn’t assign more than what you can afford – or the number of cores you have!). VMWare still only supports a maximum of 2 virtual-cpus (this _may_ change in VMWare 7.0!), another feat is the hardware 3D (Direct3D/OpenGL)  support for guests.

This version is a major update. The following major new features were added:

  • Guest SMP with up to 32 virtual CPUs (VT-x and AMD-V only; see chapter 3.7.2.2 of the user manual)
  • Windows guests: ability to use Direct3D 8/9 applications / games (experimental; see chapter 4.8 of the user manual)
  • Support for OpenGL 2.0 for Windows, Linux and Solaris guests

In addition, the following items were ?xed and/or added:

  • Solaris hosts: allow suspend/resume on the host when a VM is running (bug #3826)
  • Solaris hosts: loosen the restriction for contiguous physical memory under certain conditions
  • Mac OS X hosts: ?xed guest PAE
  • Linux hosts: kernel module compile ?xes for 2.6.31 (bug #4264)
  • VMM: ?xed occasional guru meditation when loading a saved state (VT-x only)
  • VMM: eliminated IO-APIC overhead with 32 bits guests (VT-x only, some Intel CPUs don’t support this feature (most do); bug #638)
  • VMM: ?xed 64 bits CentOS guest hangs during early boot (AMD-V only; bug #3927)
  • VMM: performance improvements for certain PAE guests (e.g. Linux 2.6.29+ kernels)
  • VMM: some Windows guests detected a completely wrong CPU frequency (bug #2227)
  • VMM: ?xed hanging and unkillable VM processes (bug #4040)
  • VMM: ?xed random infrequent guest crashes due to XMM state corruption (Win64 hosts only)
  • VMM: performance improvements for network I/O (VT-x/AMD-V only)
  • GUI: added mini toolbar for fullscreen and seamless mode (Thanks to Huihong Luo)
  • GUI: redesigned settings dialogs
  • GUI: allow to create/remove more than one host-only network adapters (non Windows hosts)
  • GUI: display estimated time for long running operations (e.g. OVF import/export)
  • GUI: ?xed rare hangs when open the OVF import/export wizards (bug #4157)
  • 3D support: ?xed VM crashes for client applications using incorrect OpenGL states
  • 3D support: ?xed memory corruption when querying for supported texture compression formats
  • 3D support: ?xed incorrect rendering of glDrawRangeElements
  • 3D support: ?xed memory leak when using VBOs
  • 3D support: ?xed glew library detection
  • 3D support: ?xed random textures corruption
  • VRDP: support Windows 7 RDP client
  • Networking: ?xed another problem with TX checksum of?oading with Linux kernels up to version 2.6.18
  • NAT: ?xed “open ports on virtual router 10.0.2.2 – 513, 514” (forum)
  • NAT: allow to con?gure socket and internal parameters
  • NAT: allow to bind sockets to speci?c interface
  • PXE boot: signi?cant performance increase (VT-x/AMD-V only)
  • VHD: properly write empty sectors when cloning of VHD images (bug #4080)
  • VHD: ?xed crash when discarding snapshots of a VHD image
  • VHD: ?xed access beyond the block bitmap which could lead to arbitrary crashes
  • VBoxManage: ?xed incorrect partition table processing when creating VMDK ?les giving raw partition access (bug #3510)
  • VBoxManage: support cloning to existing image ?le
  • OVF: several OVF 1.0 compatibility ?xes
  • OVF: ?xed exporting of disk images when multiple virtual machines are exported at once
  • Virtual mouse device: eliminated micro-movements of the virtual mouse which were confusing some applications (bug #3782)
  • Shared Folders: sometimes a ?le was created using the wrong permissions (2.2.0 regression; bug #3785)
  • Shared Folders: allow to change ?le attributes from Linux guests and use the correct ?le mode when creating ?les
  • Shared Folders: some content was incorrectly written under certain conditions (bug #1187)
  • Shared Folders: ?xed incorrect ?le timestamps, when using Windows guest on a Linux host (bug #3404)
  • X11 clipboard: ?x duplicate end of lines (bug #4270)
  • X11 guests: a number of shared clipboard ?xes
  • Linux guests: Guest Additions support for SUSE Linux Enterprise Desktop 11
  • Linux guests: new daemon vboxadd-service to handle time synchronization and guest property lookup
  • Linux guests: implemented guest properties (OS info, logged in users, basic network information)
  • Windows host installer: VirtualBox Python API can now be installed automatically (requires Python and Win32 Extensions installed)
  • USB: Support for high-speed isochronous endpoints has been added. In addition, read-ahead buffering is performed for input endpoints (currently Linux hosts only). This should allow additional devices to work, notably webcams (bug #242).
  • USB: ?xed error handling for some USB dongles
  • Web service: ?xed inability to handle NULL pointers for object arguments, which are valid values for a lot of APIs, in both the raw and the object-oriented web service.
  • Web service: object-oriented bindings for JAX-WS did not exhibit interface inheritance correctly, ?xed
  • Web service: added support for IDisplay and IGuest interfaces, which were previously unavailable
  • Registration dialog uses Sun Online accounts now

Why keep reading, upgrade dammit!

  • VirtualBox 3.0.0 for Windows hosts x86/amd64
  • VirtualBox 3.0.0 for Solaris and OpenSolaris hosts x86/amd64
  • VirtualBox 3.0.0 Software Developer Kit (SDK) All platforms (registration required)

Enjoy, see the manual online too!

[Post to Twitter] 

  • Share/Save/Bookmark

Linus releases Linux 2.6.30

June 11th, 2009 No comments

Linus has released 2.6.30 of the kernel, list of changes are available in the Linux Kernel Newbies guide.

This version adds the log-structured NILFS2 filesystem, a filesystem for object-based storage devices, a caching layer for local caching of NFS data, the RDS protocol which delivers high-performance reliable connections between the servers of a cluster, a distributed networking filesystem (POHMELFS), automatic flushing of files on renames/truncates in ext3, ext4 and btrfs, preliminary support for the 802.11w drafts, support for the Microblaze architecture, the Tomoyo security module, DRM support for the Radeon R6xx/R7xx graphic cards, asynchronous scanning of devices and partitions for faster bootup, MD support for switching between raid5/6 modes, the preadv/pwritev syscalls, several new drivers and many other small improvements.

One interesting change (amongst the many) is that we have this new feature called Fastboot. Essentially, when we boot right now, there is significant cycles wasted waiting for the device probing to complete. From Johnathan Corbet’s article on LWN:

There are many aspects to the job of making a system boot quickly. Some of the lowest-hanging fruit can be found in the area of device probing. Figuring out what hardware exists on the system tends to be a slow task at best; if it involves physical actions (such as spinning up a disk) it gets even worse. Kernel developers have long understood that they could gain a lot of time if this device probing could, at least, be done in a parallel manner: while the kernel is waiting for one device to respond, it can be talking to another. Attempts at parallelizing this work over the years have foundered, though. Problems with device ordering, concurrent access, and more have adversely affected system stability, with the inevitable result that the parallel code is taken back out. So early system initialization remains almost entirely sequential.

This new release attempts to address this problem.

Arjan hopes to succeed where others have failed by (1) taking a carefully-controlled approach to parallelization which doesn’t try to parallelize everything at once, and (2) an API which attempts to hide the effects of parallelization (other than improved speed) from the rest of the system. For (1), Arjan has limited himself to making parts of the SCSI and libata subsystems asynchronous, without addressing much of the rest of the system. The API work ensures that device registration happens in the same order is it would in a strictly sequential system. That eliminates the irritating problems which result when one’s hardware changes names from one boot to the next.

How well it does it, I guess we’ll have to wait and see. But here’s a bit of a tidbit in the kernel for the new Microblaze implementation.

void __init setup_cpuinfo(void)
{
struct device_node *cpu = NULL;

cpu = (struct device_node *) of_find_node_by_type(NULL, "cpu");
if (!cpu)
printk(KERN_ERR "You don't have cpu!!!\n");

printk(KERN_INFO "%s: initialising\n", __func__);

DUDE, You dont’ have cpu!!!

[Post to Twitter] 

  • Share/Save/Bookmark