Rabu, 22 Juni 2011

Get Your Fresh Kernels from openSUSE and Test Linux 3.0!

The openSUSE kernel developers have recently announced that the kernel git trees have moved to kernel.opensuse.org/git, providing better reliability than gitorious. Gitorious had trouble with cloning the nearly 1GB repository sometimes, but the developers will keep syncing to gitorious so nothing should break. Moreover, kernel.opensuse.org offers an easy interface to install openSUSE kernels on a variety of openSUSE releases.


More things are planned for kernel.opensuse.org including the introduction LXR. cgit was already added during the writing of this article!


View the original article here

Github Has Surpassed Sourceforge and Google Code in Popularity

Github is now the most popular open source forge, having surpassed Sourceforge, Google Code and CodePlex in total number of commits for the period of January to May 2011, according to data released today by Black Duck Software. This should probably come as no surprise, but it's good to have data to backup assumptions.


During the period Black Duck examined, Github had 1,153,059 commits, Sourceforge had 624,989, Google Code and 287,901 and CodePlex had 49,839.


Black Duck also found that C++ and Java were the most popular languages for commits in these forges during this period of time.


Black Duck didn't look at language specific forges such as RubyForge, and it excluded shell, XML and assembler commits.


View the original article here

GPUs Demonstrate Potential for NASA Science Simulations

At NASA’s Goddard Space Flight Center, simulations of Earth and space phenomena are getting a boost from GPUs. Early results on a new GPU cluster at the NASA Center for Climate Simulation (NCCS) demonstrate potential for significant speedups versus conventional computer processors.


At NASA’s Goddard Space Flight Center, simulations of Earth and space phenomena are getting a boost from GPUs. Early results on a new GPU cluster at the NASA Center for Climate Simulation (NCCS) demonstrate potential for significant speedups versus conventional computer processors.


“GPUs offer a large number of streaming processing cores for performing calculations. For instance, the NCCS cluster’s 64 NVIDIA Tesla M2070 GPUs have 28,672 total cores, nearly as many cores as the rest of the Discover supercomputer. However, since GPUs only perform simple arithmetic, they must be connected to conventional CPUs for executing complex applications. “A GPU does not see the outside world, and one frequently must copy data from CPU to GPU and back again,” explained Tom Clune, Advanced Software and Technology Group (ASTG) lead in the Software Integration and Visualization Office (SIVO).”


View the original article here

Has Open Source Made Google’s Software Stack Obsolete?

Google has succeeded as much or perhaps more than any other technology company ever. They have accomplished all of this all the while being supporters of and with the support of the open source community. They are known for their corporate drive to have the best of everything as much...


Google has succeeded as much or perhaps more than any other technology company ever. They have accomplished all of this all the while being supporters of and with the support of the open source community. They are known for their corporate drive to have the best of everything as much as their corporate motto of "do no evil".  They have the best hardware, the best data centers, they hire the best people....


View the original article here

Hone Your Desktop Clipboards with Parcellite on Linux

If you're a normal desktop Linux user, it has probably been while since you thought about the X Window System. Modern distros let you configure your video card without ever touching xorg.conf, and by and large the window managers and GUI toolkits just work without getting in your way. But there is still one lingering pain point: the clipboard. Between most user apps, cut, copy and paste work without a hitch, but terminals, text editors like Emacs and Vim, and a few other stragglers refuse to cooperate. If that sounds familiar, consider checking out Parcellite.


Parcellite is a lightweight clipboard manager that sits unobtrusively in the top panel, but smooths over the rough spots of inter-app cut-and-paste behavior. The latest version is 1.0.2, which fixes a few bugs that slipped in after the recent 1.0 stable release. You can get source code packages on the project's download site, but there is a pretty good chance your distribution already packages it. Distro-provided packages might not include the latest release, simply due to how recent it is, however.


Whether or not it is worth installing from source depends on your exact needs. 1.0.x adds a few interesting features over the 0.9 series provided by most distros, such as the ability to search through Parcellite's clipboard history in as-you-type mode, and the ability to reposition where the clipboard history pop-up appears. Neither one of those is core functionality, but your mileage may vary. If you do build from source, Parcellite depends on basic GNOME stack libraries: GTK+, Pango, Cairo, etc.; nothing out of the ordinary.


At the heart of Parcellite's behavior is its ability to synchronize the two distinct X selection methods: the CLIPBOARD selection and the PRIMARY selection. In typical X fashion, the official designations for both are in all caps, so we'll use that format to distinguish them from generic usage of either term.


The PRIMARY selection is whatever is highlighted by the cursor; you often see this functionality when you highlight text in a terminal window using the mouse. Mouse-1 (the left button) starts the selection, Mouse-2 (the right button) ends it, and Mouse-3 (the middle button) inserts the selection. This old relic is still useful today because the keyboard shortcuts Control-C and Control-X are often captured by the shell and mapped to other functions if you type them inside a terminal window, but mouse clicks aren't.


In contrast, the CLIPBOARD selection is what is copied whenever you explicitly give a "copy" command to the current app — generally by Control-C or a button press, but potentially a different key combination. Yes, the world would be simpler if PRIMARY and CLIPBOARD were always the same, but that isn't going to happen any time soon.


You can launch Parcellite from the command line with parcellite —. The current version places a clipboard icon in the GNOME 2 panel's notification area; no word yet on an app-indicator for Unity or a GNOME Shell port. When in use the panel icon is essentially a system-wide clipboard menu: click it and you'll get a history of your copied items (25 entries long, by default), from which you can select whichever suits your fancy. The history is preserved across sessions, which is a nice touch.


Right-click on the icon to open the preferences dialog. The Behavior tab hold the important options. At the top, the "Clipboards" section has three checkboxes: one for "Use Copy" (which makes Parcellite watch CLIPBOARD), one for "Use Primary" (which watches PRIMARY), and one for "Synchronize clipboards (which keeps them in sync with each other). That is the core of the magic, of course, but the other options are worth looking at, too.


You can set how many history items to save — including none, in which case Parcellite just syncs CLIPBOARD and PRIMARY to whichever is most-recently-used — plus alter where the history list pops up (which honestly I have not discovered a use-case for). Another use case entirely is available in the "Miscellaneous" section, where you can have Parcellite copy only URLs to the history. That can be useful if you share a lot of links. Miscellaneous also lets you toggle on the search-as-you-type functionality, which can be good if you like to save a lengthy history.


Finally, the Display tab allows you to tweak a few display settings, such as the sort order (newest-to-oldest or vice versa), how many characters wide to make the history pop-up, and whether to truncate the beginning, middle, or end of selections that are too long.


If all you care about is freeing up the mental energy you used to expend keeping CLIPBOARD and PRIMARY straight in your mind, you're all set. But Parcellite has a few other tricks up its sleeve.


For one thing, despite the fact that the history menu shows you your actual selections, it also makes them all editable. That's not particularly handy if you're cutting and pasting in an email, but when you're writing something complex (code, an article, your new free software license), it can turn the clipboard into a handy saved-block-of-text storage system. Particularly when writing tutorials, I reuse lots of HTML fragments to mark up commands (imagine a long ifup command, littered with and tags). With Parcellite I can write the first one, copy it, then cut down the selection to just the generic portion and re-use it at will.


Parcellite also supports configuring "actions" (i.e., custom commands) that take the clipboard selection as an argument. The simplest example would be an action like wget %s -- the %s variable is replaced by the selection, so whenever you copy a URL, you can bring up Parcellite's actions menu and download it with one click. Users can also write actions to perform search-and-replace, dictionary lookup, or anything else. By default, Control-Alt-A opens the actions menu, but this is configurable.


Another nice touch is that Parcellite is usable from the command line. So if you have to SSH into your machine from a remote location, you can retrieve your clipboard history, or add to it. From a shell, you can type echo "http://some.url.youll/otherwise/forget" | parcellite and the URL will be added to your Parcellite selection history. Type parcellite -c to see your CLIPBOARD history, and parcellite -p to see your PRIMARY history (although naturally they will be the same if you sync them).


If you ask me, Parcellite's ability to unify the two main X selection methods is something that really ought to be built right into GNOME and the other desktop environments; it's just that useful, and I've never had occasion to want the two to be separate. On the other hand, I do use Emacs every day, and I really like having Emacs' slightly-different "kill" and "yank" behavior available when I'm writing. Owing to its heritage, Emacs is one of those programs that, like the terminal, has always exposed the difference between CLIPBOARD and PRIMARY.


You can use Parcellite with Emacs naively to keep the program's kill-ring synchronized with the system-wide clipboard, but if you're a heavy Emacser, you may want some more flexibility. For that, EmacsWiki.org has a nice summary of the copy-and-paste options and how they affect Emacs's interaction with the system clipboard -- and thus, with Parcellite.


Personally, I've never been unlucky enough to have to use Vim, but if that lot does befall you, I would recommend looking at the corresponding page on the Vim wiki for a detailed look at that application's copy and paste behavior. It, like Emacs, has different expectations of CLIPBOARD and PRIMARY, which can lead to conflicts if you're not careful.


These days, most other common applications with sync with Parcellite without incident, but if you do find another one with its own brand of clipboard behavior, be sure to share it. Parcellite is under active development again (after a few years off following the 0.9 series), so your feedback could improve the app and help out some other user at the same time.


View the original article here

Selasa, 21 Juni 2011

How to Build a Distributed Monitoring Solution with Nagios

With Nagios, the leading open source infrastructure monitoring application, you can monitor your whole enterprise by using a distributed monitoring scheme in which local slave instances of Nagios perform monitoring tasks and report the results back to a single master. You manage all configuration, notification, and reporting from the master, while the slaves do all the work.


This design takes advantage of Nagios’s ability to utilize passive checks – that is, external applications or processes that send results back to Nagios. In a distributed configuration, these external applications are other instances of Nagios.


View the original article here

Install and Configure OpenVPN Server on Linux

The VPN is very often critical to working within a company. With working from home being such a popular draw to many industries, it is still necessary to be able to access company folders and hardware that exists within the LAN. When outside of that LAN, one of the best ways to gain that access is with the help of a VPN. Many VPN solutions are costly, and/or challenging to set up and manage. Fortunately, for the open source/Linux community, there is a solution that is actually quite simple to set up, configure, and manage. OpenVPN is that solution and here you will learn how to set up the server end of that system.


The VPN is very often critical to working within a company. With working from home being such a popular draw to many industries, it is still necessary to be able to access company folders and hardware that exists within the LAN. When outside of that LAN, one of the best ways to gain that access is with the help of a VPN. Many VPN solutions are costly, and/or challenging to set up and manage. Fortunately, for the open source/Linux community, there is a solution that is actually quite simple to set up, configure, and manage. OpenVPN is that solution and here you will learn how to set up the server end of that system.


I will be setting OpenVPN up on a Ubuntu 11.04, using Public Key Infrastructure with a bridged Ethernet interface. This setup allows for the quickest route to getting OpenVPN up and running, while maintaining a modicum of security.


The first step (outside of having the operating system installed) is to install the necessary packages. Since I will installing on Ubunutu, the installation is fairly straightforward:

Open up a terminal window.Run sudo apt-get install openvpn to install the OpenVPN package.Type the sudo password and hit Enter.Accept any dependencies.

There is only one package left to install — the package that allows the enabling of bridged networking. Setting up the bridge is simple, once you know how. But before the interface can be configured to handle bridged networking, a single package must be installed. Do the following:

Install the necessary package with the command sudo apt-get install bridge-utils.Edit the /etc/network/interfaces file to reflect the necessary changes (see below).Restart networking with the command sudo /etc/init.d/networking restart .

Open up the /etc/network/interfaces file and make the necessary that apply to your networking interface, based on the sample below:

auto loiface lo inet loopbackauto br0iface br0 inet static address 192.168.100.10 network 192.168.100.0 netmask 255.255.255.0 broadcast 192.168.100.255 gateway 192.168.100.1 bridge_ports eth0 bridge_fd 9 bridge_hello 2 bridge_maxage 12 bridge_stp off

Make sure to configure the bridge section (shown above) to match the correct information for your network. Save that file and restart networking. Now it's time to start configuring the VPN server.


The OpenVPN server will rely on certificate authority for security. Those certificates must first be created and then placed in the proper directories. To do this, follow these steps:

Create a new directory with the command sudo mkdir /etc/openvpn/easy-rsa/.Copy the necessary files with the command sudo cp -r /usr/share/doc/openvpn/examples/easy-rsa/2.0/* /etc/openvpn/easy-rsa/.Change the ownership of the newly copied directory with the command sudo chown -R $USER /etc/openvpn/easy-rsa/.Edit the file /etc/openvpn/easy-rsa/vars and change the variables listed below.

The variables to edit are:

export KEY_COUNTRY="US"export KEY_PROVINCE="KY"export KEY_CITY="Louisville"export KEY_ORG="Monkeypantz"export KEY_EMAIL=" This e-mail address is being protected from spambots. You need JavaScript enabled to view it "

Once the file has been edited and saved, we'll run several commands must be entered in order to create the certificates:

cd /etc/openvpn/easy-rsa/source vars./clean-all./build-dh./pkitool --initca./pkitool --server servercd keyssudo openvpn --genkey --secret ta.keysudo cp server.crt server.key ca.crt dh1024.pem ta.key /etc/openvpn/

The clients will need to have certificates in order to authenticate to the server. To create these certificates, do the following:

cd /etc/openvpn/easy-rsa/source vars./pkitool hostname

Here the hostname is the actual hostname of the machine that will be connecting to the VPN.


Now, certificates will have to be created for each host needing to connecting to the VPN. Once the certificates have been created, they will need to be copied to the respective clients. The files that must be copied are:

/etc/openvpn/ca.crt/etc/openvpn/ta.key/etc/openvpn/easy-rsa/keys/hostname.crt (Where hostname is the hostname of the client)./etc/openvpn/easy-rsa/keys/hostname.key (Where hostname is the hostname of the client).

Copy the above using a secure method, making sure they are copied to the /etc/openvpn directory.


It is time to configure the actual VPN server. The first step is to copy a sample configuration file to work with. This is done with the command sudo cp /usr/share/doc/openvpn/examples/sample-config-files/server.conf.gz /etc/openvpn/. Now decompress the server.conf.gz file with the command sudo gzip -d /etc/openvpn/server.conf.gz. The configuration options to edit are in this file. Open server.conf up in a text editor (with administrative privileges) and edit the following options:

local 192.168.100.10dev tap0up "/etc/openvpn/up.sh br0"down "/etc/openvpn/down.sh br0"server-bridge 192.168.100.101 255.255.255.0 192.168.100.105 192.168.100.200push "route 192.168.100.1 255.255.255.0"push "dhcp-option DNS 192.168.100.201"push "dhcp-option DOMAIN example.com"tls-auth ta.key 0 # This file is secretuser nobodygroup nogroup

If you're unsure of any of the options, here:

The local address is the IP address of the bridged interface.The server-bridge is needed in the case of a bridged interface.The server will push out the IP address range of 192.168.100.105-200 to clients.The push directives are options sent to clients.

Before the VPN is started (or restarted) a couple of scripts will be necessary to add the tap interface to the bridge (If bridged networking is not being used, these scripts are not necessary.) These scripts will then be used by the executable for OpenVPN. The scripts are /etc/openvpn/up.sh and /etc/openvpn/down.sh.

#!/bin/sh#This is /etc/openvpn/up.shBR=$1DEV=$2MTU=$3/sbin/ifconfig $DEV mtu $MTU promisc up/usr/sbin/brctl addif $BR $DEV#!/bin/sh#This is/etc/openvpn/down.shBR=$1DEV=$2/usr/sbin/brctl delif $BR $DEV/sbin/ifconfig $DEV down

Both of the scripts will need to be executable, which is done with the chmod command:

sudo chmod 755 /etc/openvpn/down.shsudo chmod 755 /etc/openvpn/up.sh

Finally, restart OpenVPN with the command sudo /etc/init.d/openvpn restart. The VPN server is now ready to accept connections from clients (the topic of my next tutorial.)


One thing that is a must for a VPN is that the machine hosting the VPN has to be accessible to the outside world — assuming users are coming in from the outside world. This can be done by either giving the server an external IP address or by routing traffic from the outside in with NAT rules (which can be accomplished in various ways). It will also be critical to employ best security practices (especially if the server has an external IP address) to prevent any unwanted traffic or users from getting into the server.


View the original article here