Nokia N900: First Look at Linux Journal

Nokia N900: First Look | Linux Journal.

The Nokia N900 has just started shipping and there are already a number of reviews of the device out on the net. I’ve had the opportunity evaluate a pre-release N900 for a few weeks now, and while you can expect a full review in an upcoming issue of Linux Journal, I wanted to give you a quick look into what the N900 is like from the perspective of your average Linux geek. If you’ve read any of my previous articles in Linux Journal, you’ll know that I’m a vim-using, mutt-loving sysadmin who spends a lot of time on the command line, so hopefully I can provide a unique perspective on this device.

screenshot01

Read entire article at Linux Journal: Nokia N900: First Look | Linux Journal.

Tags: ,

FreeBSD will be an official option for Debian Squeeze

from debian.org

Debian pushes development of kFreeBSD port

October 7th, 2009

The Debian Release Team is pleased to announce that it sees the port of the Debian system to the FreeBSD kernel fit to be handled equal with the other release ports. The upcoming release codenamed ‘Squeeze’ is planned to be the first Debian distribution to be released with Linux and FreeBSD kernels.

The kFreeBSD architectures for the AMD64/Intel EM64T and i386 processor architectures are now release architectures. Severe bugs on these architectures will be considered release critical the same way as bugs on other architectures like armel or i386 are. If a particular package does not build or work properly on such an architecture this problem is considered release-critical.

Debian’s main motivation for the inclusion of the FreeBSD kernel into the official release process is the opportunity to offer to its users a broader choice of kernels and also include a kernel that provides features such as jails, the OpenBSD Packet Filter and support for NDIS drivers in the mainline kernel with full support.

How To Tune Swap Settings on Linux

I started out with FreeBSD. I love FreeBSD, and all the BSDs, however in the workplace, Linux is much more common as a server platform. No, I am not including Mac OS X as a BSD.  I do not hold Apple in a very high regard, that is just my opinion, you must draw your own conclusions. Please use the dry erase markers on the white board. That way it’s easier to change your mind in the future,

Back to my point.

Several years ago, when the 2.4 kernel was all the rage. I noticed that Linux did not behave like FreeBSD in regards to swapping to the disk. FreeBSD would swap when available RAM was in short supply. Linux however, seemed to swap to disk,  just for the sake of swapping. It always seemed silly to me, and definitely a hit to performance.

Even with the 2.6 kernel, and all it’s wonder, default swap settings are fairly liberal in my opinion. The good news is, vm.swappiness can be adjusted via the proc filesystem.

Echoing values into /proc/sys/vm/swappiness works, but we are no longer savages hurling values into proc files in the wilderness . Modern Linux types are refined, disciplined. We use sysctl, and /etc/sysctl.conf, (so as to retain settings when we reboot).

If you have gigs upon gigs of ram, why would you want to swap data to the disk? Remember good people,

it’s all about I/O.

Here’s how to do it.

First, check your current settings.


debian:~# sysctl vm.swappiness
vm.swappiness = 60

The scale is from 0 to 100,
0 being the least swappy,
and 100 being the swappiest. 

I am showing you how to adjust the settings,

I am not making any recommendations as to

what those settings should be.


Me, I don’t want swap anymore than I absolutely have to swap.

I’m going to set my vm.swappiness to a lower value, 10.


debian:~# sysctl -w vm.swappiness=10
vm.swappiness = 10

The new value will not persist during a reboot.

If you want it to persist,
add this line to your /etc/sysctl.conf 

vm.swappiness = 10


Here's some more information regarding vm.swappiness. 


Linux: VM Swappiness Autoregulation

swapping and the value of /proc/sys/vm/swappiness

Linux performance tuning - /proc/sys/vm/swappiness
 

Adrian Thiele

Tags:

Hulu Desktop For Linux

Hulu has released a version of the Hulu Desktop for Linux. It is currently released for Fedora and Ubuntu officially. The Ubuntu 32-bit installer worked perfectly fine when installed on Debian Lenny.

Download Hulu Desktop 32-bit (.deb)

Download Hulu Desktop 64-bit (.deb)

Download Hulu Desktop 32-bit (.rpm)

Download Hulu Desktop 64-bit (.rpm)

from Hulu’s Website

Which Linux distributions does Hulu Desktop support?
Hulu Desktop for Linux is currently built on Fedora 11 and Ubuntu 9.04. The packages should also work on any Linux distribution with glib2.16 (such as Ubuntu 8.04+ and Fedora 9+). Other configurations have not been tested.

Will you be supporting other Linux distributions?
Over time we hope to expand the set of supported Linux distributions. You can let us know your preference by posting on the Hulu Desktop discussion forum.

Does Hulu Desktop for Linux require Flash?
Yes, you must have Adobe Flash Player 9.0.124 or higher installed. If you can load and watch videos on Hulu.com, you should be able to use Hulu Desktop for Linux.

What libraries are required to run Hulu Desktop?
Hulu Desktop depends on the following libraries or packages, although they should be pre-installed with the supported distributions:

  • GTK+ 2.12 or higher
  • GLib 2.16 or higher
  • LIRC 0.8.2 or higher (required for remote control functionality)

Can I use a remote control with Hulu Desktop Linux?
Hulu Desktop for Linux supports input from hundreds of infrared remote controls using the LIRC open source package. You can download LIRC and receive general configuration information from http://www.lirc.org, as well as browse a list of supported remote controls. Hulu Desktop for Linux requires that lircd be run with the -r (–release) switch.

You can also configure Hulu Desktop’s LIRC hardware interface, key mappings, and more by modifying the remote section of ~/.huludesktop. For more information, refer to /usr/share/doc/huludesktop/README.

Tags:

How to write a command line Twitter client in C using libcurl on Debian.

I’ve been playing around with Twitter lately, so naturally I took a look at the Twitter api. Several of the examples are done with curl. For those of you who haven’t looked into the Twitter api, it’s just simple HTTP commands.

To do a status update on Twitter,  you do an HTTP post with your username and password, along with the status parameter. This is an easy task using libcurl.

To get started, you need to have gcc and libcurl installed.

apt-get install gcc libcurl3

Here is the example for an HTTP post from the libcurl website.

I used that as my template.

Here is the code:

#include <stdio.h>
#include <curl/curl.h>
#include <string.h> /* Need this header for strcat */

char mesg[140]; /*140 for the tweet */
char status[149]=”status=”;


int main(void)
{

fgets(mesg,140,stdin);
strcat(status,mesg);

CURL *curl;
CURLcode res;

curl = curl_easy_init();

if(curl) {

curl_easy_setopt(curl, CURLOPT_URL, “http://user:pass@twitter.com/statuses/update.json”);  /*build the url with the username and password */

curl_easy_setopt(curl, CURLOPT_POSTFIELDS, status);

res = curl_easy_perform(curl);

curl_easy_cleanup(curl);

}

return 0;
}

That’s all there is to it.

compile with: gcc -lcurl twitter-post.c -o twitter-post

run it:

at@debian:~$ ./twitter-post

this is my status update

Twitter will return a nice blob of JSON information

to let you know it succeeded

Adrian Thiele