100
www.linuxuser.co.uk EBEN UPTON FOR THE GNU GENERATION THE MONTHLY MAGAZINE ALSO INSIDE » CuBox reviewed » Beating Microsoft at its own game » Fedora 18 reviewed EXCLUSIVE INTERVIEW Find and prevent attacks on your network the open source way The ultimate desktop in your pocket Master networking’s darkest art in easy steps Secure your network Live distro super-test Linux genealogy Map out your family tree with Gramps 20 + pages of reviews RAS PI Revealed: Incredible things you can do with the $25 PC Raspberry Pi VPN The latest details revealed in full The Ubuntu Phone Wine for developers How advanced users can harness the power of Wine RASPBERRY PI 10 AMAZING PROJECTS BIRTHDAY SPECIAL Eben Upton Interview ISSUE 123

Linux User & Developer - Bpfine

  • Upload
    russo

  • View
    85

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Linux User & Developer - Bpfine

www.linuxuser.co.uk

EBEN UPTON

FOR THE GNU GENERATIONTHE MONTHLY MAGAZINE

ALSO INSIDE » CuBox reviewed

» Beating Microsoft at its own game

» Fedora 18 reviewed

EXCLUSIVEINTERVIEW

Find and prevent attacks on your network the open source way

The ultimate desktop in your pocket

Master networking’s darkest art in easy steps

Secure your network

Live distro super-test

Linux genealogyMap out your family tree with Gramps

20+ pages of reviews

RAS PI

Revealed: Incredible things you can do with the $25 PC

Raspberry Pi VPN

The latest details revealed in full

The Ubuntu Phone

Wine for developersHow advanced users can harness the power of Wine

RASPBERRY PI10 AMAZING

PROJECTS

The Ubuntu Phone

BIRTHDAYSPECIAL

Eben Upton Interview

ISSUE 123

001_LUD_123_NOSPINE.indd 1 29/01/2013 15:16

Page 2: Linux User & Developer - Bpfine

Get your FREE evaluation copy at http://www.aspose.com

CONVERT PRINT CREATE MODIFY & COMBINE

Aspose.Email

Aspose.Slides

Aspose.Pdf

Aspose.Cells

Aspose.BarCode

Aspose.Words

FILES

MANAGE

Full pg.indd 1 22/01/2013 10:01

Page 3: Linux User & Developer - Bpfine

Gareth Halfacree has been breaking, fi xing, tinkering and voiding warranties on electrical items for many years, without once receiving a fatal electric shock. This issue Gareth brings us his thoughts on the latest mini-PC to hit the market - the CuBox. See what he thinks on pages 68-69.

Kunal Deo is a veteran open source developer leading multiple open source projects. He is also a KDE developer and has contributed to many projects including KDE-Solaris, Belenix and Openmoko. This month Kunal shows us how advanced users and developers can leverage Wine (pages 56-59).

Liam Fraser is the creator of the hugely popular RaspberryPiTutorials YouTube series and is a Linux server admin for the Raspberry Pi Foundation. This month Liam delves into the dark art of VPN to show how the Raspberry Pi can be used to create a viable virtual private network. Follow along on pages 52-55.

Joey Bernard has been using Linux at home for almost 20 years and he’s now getting paid for it as a computational research consultant with ACEnet. This month Joey shows us how to create a family tree using open source software in his geneology with Linux tutorial (pages 32-35).

Rory MacDonald is our resident open

source reporter with a keen nose for a story and a good eye for detail. In the news starting on page 6 this month, Rory brings us up to speed on the latest developments in mobile technology and discovers that CES has lost out on this year’s big announcements to MWC.

Rob Zwetsloot studied aerospace engineering at university, using Python to model complex simulations in class while configuring Linux HTPCs at home. In this issue Rob reveals Canonical’s latest plans with his special news report on the Ubuntu Phone (pages 6-7) among other things.

Issue 1233

Your

team

of L

inux

expe

rts…

Get in touch with the team:[email protected]

Welcometo issue 123 of Linux User & Developer

Welcome to the latest edition of Linux User & Developer, the UK and America’s favourite high-end open source and Linux magazine.

This issue we’re celebrating the fi rst birthday of the Raspberry Pi in grand style with two very special features and another excellent ‘how-to’ article from the Raspberry Pi Foundation’s own Liam Fraser.

Our fi rst special feature required us to gather together three key members of the Raspberry Pi Foundation for tea, a slice of birthday cake and a whole host of questions. In our exclusive interview starting on page 46, Eben, Liz and Pete take time out of their packed schedules to tell us all about the fi rst year on sale and what we can expect in the future.

Our second birthday treat is a huge 12-page exposé of the very best projects Raspberry Pi enthusiasts have created. It’s quite incredible what can be achieved with a £25 computer and a bit of imagination – see pages 18-29 to fi nd our favourites.

We’ve already started compiling our top-picks for the next ten amazing Raspberry Pi projects, so if you’ve got an amazing idea and have been waiting for an excuse to put it into action, get in touch with the magazine and let us know!

Enjoy the issue…

Russell Barnes, Editor

Buy online

Get Linux User

for £4.19 per issue

Page 30

» Fedora 18 reviewed» Eben Upton exclusive» 10 amazing RasPi projects» The Ubuntu Phone revealed

This issue

Visit us online for more news, opinion, tutorials and reviews:

www.linuxuser.co.uk

003_LUD_123 PK.indd 3 25/01/2013 17:43

Page 4: Linux User & Developer - Bpfine

Contents

Join us online for more Linux news, opinion and reviews www.linuxuser.co.uk

www.linuxuser.co.uk4

06 News The biggest stories from the

open source world

12 OpinionsThe latest from your favourite free software columnists

94 Letters Your views on the magazine

and the open source scene

OpenSource

96 Cover disc The very latest distros on one DVD

On your free disc

Fuduntu 2013.1Knoppix 7.0.5Parted MagicFedora 18

Tutorials32 Genealogy with Gramps Track your family history with open source

36 Install Cinnamon on your distro Add this exciting new desktop experience to your favourite distribution

40 Protect your network with Snort Spot attacks and protect your network

Developer tutorialsFeatures18 10 amazing Raspberry Pi projects Incredible things you can do with a $25 computer!

46 RasPi Foundation exclusive interview We celebrate the occasion with Eben, Pete and Liz

60 Kolab: David & Goliath Can Kolab beat the likes of Microsoft at their own game?

72 Live distro super-test Four of the best fi ght it out

86 Q & AYour problems solved!

FEATURE

46 Celebrating the life of PiWe sit down with three core members of the Raspberry Pi Foundation to celebrate the first year on sale and to find out what 2013 has in store

52 Create a VPN with the RasPi Master the mysterious art of virtual private

networks with the aid of the Raspberry Pi

56 Wine for Developers Build and run Windows apps sans

Microsoft Tax

Reviews

18. Revealed: Incredible things you can do with the $25 PC

10 amazing Raspberry Pi projects

Subscribe today!

30 Save at least 30% on the shop price. US customers can subscribe via page 84

66 HTC One X+HTC updates its flagship smartphone for 2013

68 SolidRun CuBoxAnother tiny-PC contender

70 Samsung Galaxy Ace 2The market leader takes another shot at budget handsets

72 Live distro super-testThe latest live distros fight to earn space on your USB stick

78 Fedora 18The Spherical Cow has finally entered the field!

80 Pear Linux 6.1We put the squeeze on thelatest Pear build to see if it’s ripe

82 Fuduntu 2013.1 A fun and functional desktop for everyday use

004_LUD_123 PK.indd 4 25/01/2013 18:51

Page 5: Linux User & Developer - Bpfine

fullpg.indd 1 23/01/2013 15:47

Page 6: Linux User & Developer - Bpfine

www.linuxuser.co.uk6

the Android Board Support Package, effectively allowing the OS to run on any current Android hardware with very little modifi cations needed. To begin with, entry-level phones for the OS will need mid- to high-range specs, with a dual-core CPU and plenty of RAM recommended. However, within a few years the plan is to optimise it for even the most low-powered phones. At the highest end, Ubuntu for Phones also includes the full Ubuntu desktop, accessible via docking similar to the Ubuntu for Android implementation; however, it’s recommended to use a quad-core CPU for this.

Shuttleworth was keen to show off the way Ubuntu for Phones works, with its fairly unique interface based on the phone’s edges. Swiping

On the fi rst working day of the year, Linux User & Developer attended a conference at Canonical HQ, where a top secret Ubuntu product would be shown off for the very fi rst time. The rumour mill had been churning over the Christmas holiday period as to what we’d be seeing, and needless to say when Mark Shuttleworth revealed the Ubuntu Phone, it was not totally unexpected. Taking a special Galaxy Nexus from his jacket pocket loaded with Ubuntu for Phones, he then proceeded to give us a fi rst look at what is essentially a full Ubuntu OS for smartphones.

Although the Galaxy Nexus is test hardware for now, it’s indicative of the functionality Ubuntu for Phones will have. It currently uses

Ubuntu for Android evolves into a full phone OS

SUPERPHONE INCLUDING DESKTOPFor a high-end smartphone that docks as a portable desktop, you’ll need:

CPU: Quad-core Cortex-A9 or Intel AtomMemory: 1GBInternal fl ash storage: 32GBMulti-touch: YesDesktop: Yes

SwipeEach edge of the phone has a specifi c use. Here’s what happens when you swipe from the top…

All the icons on the top bar represent accessible system settings, such as Wi-Fi, mobile network, battery settings and even message notifi cations. All you need to do is touch the one you wish to access.

Pull down the bar with your fi nger part of the way to get a description of what the icon means. You can swipe left to right from here to move between the different icons on the bar if you need to.

When you want to access the particular setting or notifi cation, pull down the rest of the bar right over the running app, similar to Android notifi cations. This allows you to change system settings without going to a whole different menu.

THE SPECSENTRY-LEVEL SMARTPHONEFor a solid competitor to today’s smartphone, you’ll need:

CPU: Dual-core Cortex-A9Memory: 512MB-1GBInternal fl ash storage: 4-8GBMulti-touch: YesDesktop: No

■ High-end phones like the Galaxy S III can run the desktop

■ The Galaxy S II meets the minimum specs

The Ubuntu phone06 News | 12 Opinion | 94 Letters

006-007_LUD_123 PK.indd 6 25/01/2013 18:07

Page 7: Linux User & Developer - Bpfine

■ Mark Shuttleworth believes in the vision of one OS for all your devices

ANDROID

www.linuxuser.co.uk7

Ubuntu for AndroidWhat’s going on with the Android dock?Canonical released Ubuntu for Android to little fanfare late last year – and it plans to support it outside of Ubuntu for Phones. Making its debut last year at CES 2012, the original image we saw allowed you to access the Android phone through an emulation window – this has now been mostly removed, as Ubuntu for Android can access the full telephony stack of more Android phones now, allowing you to call and text from a dedicated

app on the desktop. It still contains the ability to retrieve data from the Android portion, such as contacts, documents and photos. There is unfortunately no phone or network provider that uses it just yet – however, 2011 and 2012 saw a few failures in terms of phone-powered desktop experiences, and we’re only just seeing the advent of smartphones powerful enough to provide a seamless experience.

from the left edge brings out the Unity app bar, where you can place some of your favourite apps and then also access the full home screen. Swiping from the right edge allows you to go back through all the apps you’ve been using, and swiping up from the bottom brings up the app-specifi c controls. Swiping down from the top allows quick access to system settings for time, volume, networking, messaging, battery etc – each can be modifi ed without leaving the current screen, as well.

On the Galaxy Nexus the interface was fairly slick and responsive. The edge gestures worked well – although trying to select items in the corners was sometimes a little tricky, but it is still in development.

App development wise, Canonical says it has been working closely with some of the major smartphone app developers for native Twitter, Facebook and other popular apps to be ready for Ubuntu phones. Shuttleworth reiterated that the OS was more open than any other current mobile OS, and that development of apps and tools would be much easier using the Ubuntu framework.

There are no current release plans for an Ubuntu Phone, and while talks are underway with networks and manufacturers, no deal has been reached as of yet. Images for Ubuntu for Phones are going to be released to the public sometime in February, though, so those with decent Android phones will be able to give it a try.

v2

Lean smartphones

Estimated OS stretch by 2016

< >v3 v4

Mid-range smartphones High-end smartphones Superphones

allowing you to call and text from a dedicated seamless experience.

from the left edge brings out the Unity app bar, where you can place some of your favourite apps and then also access the full home screen. Swiping from the right edge allows you to go back through all the apps you’ve been using, and swiping up from the bottom brings up the app-specifi c controls. Swiping down from the top allows quick access to system settings for time, volume, networking, messaging, battery etc – each can be modifi ed

The latest in the Linux communityNews

OPEN SOURCE

06 News | 12 Opinion | 94 Letters

006-007_LUD_123 PK.indd 7 25/01/2013 17:05

Page 8: Linux User & Developer - Bpfine

When it comes to new, market-ready smartphones and mobile devices, this year’s CES was widely seen as a disappointment. What the trade show has revealed, however, is a serious selection of the latest mobile processors that will be found at the core of the devices we eventually see at Mobile World Congress (MWC) on 25-28 February.

Nvidia announced its successor to the Tegra 3 chipset, used in 2012’s most successful high-end Android devices, such as the Nexus 7. Billed as the world’s fastest mobile processor, the

www.linuxuser.co.uk8

■ The Tizen OS is gaining momentum

■ The Tegra 4 offers blistering mobile power

New processors reveal what we can expect

Ubuntu Mobile is not the only new game in town – Tizen looks set to grow in 2013

pioneers the LiMo Foundation. The project took the groups’ existing investments into MeeGo Linux and several other mobile Linux variants and redeveloped these into an even more sophisticated and up-to-date mobile platform. With a heavy focus on open HTML5-based applications, Tizen has been making signifi cant inroads into both the IVI and smartphone markets. However, Samsung is the fi rst major manufacturer to confi rm plans for smartphones built on the new platform.

With Samsung’s current smartphone success built on Android, it is no secret that the company has been looking for alternatives that would allow it to hedge its bets against overdependence on the Google-dominated platform. Google’s decision to buy Motorola

While the loudest noise on the Linux front came from the new Ubuntu Mobile distro (see page 6), it was not the only signifi cant mobile Linux development at CES.

Samsung let slip that 2013 will see it launching a new range of phones built on the Tizen OS. Tizen was developed by the Linux Foundation and mobile Linux

MOBILE

Your source of Linux news and viewsOpenSourceContact us…Register and post your comments…www.linuxuser.co.uk/forum/

Email us directly…[email protected] us directly…[email protected]

last year will almost certainly have added extra impetus to Samsung’s search.

Samsung, a key founder member of the former LiMo Foundation, had been working on Bada, its own mobile Linux distro. But with limited uptake of Bada, much of this work was subsequently rolled into Tizen.

The vision of Tizen – to provide a Google-free, unifi ed platform running across phones, cars, home entertainment and broader smart devices – is compelling. With other Tizen Foundation members including Intel, Huawei, NEC, Panasonic and some of the world’s largest mobile carriers, this vision is looking increasingly viable as a new force across the consumer electronics industry.

Offi cial details of Samsung’s Tizen-phone plans have yet to emerge. However, early reports on the Japanese Daily Yomiuri Online news site were confi rmed at CES, when a Samsung spokesperson told CNET reporters that the company plans “to unveil competitive Tizen devices within this year.”

Mobile World Congress steals device launches

TIZEN

Tizen set to rival Android

Tegra 4 combines an eye-watering 72 custom GeForce GPU cores (six times the graphics processing power of the Tegra 3) with the fi rst quad-core implementation of ARM’s newest Cortex A-15 CPU and a second-generation battery saver core for less intensive tasks.

As with most of the new high-end chips announced at the show, the Tegra 4 can deliver 4K Ultra HD video. However, 4G mobile support requires an additional chipset. Importantly, given the criticisms of the Tegra 3, Nvidia also claimed that the new processor consumes up to 45 per cent less power than its predecessor “in common use cases” and enables up to 14 hours of HD video playback on phones.

Meanwhile, Qualcomm announced its quad-core Snapdragon 800, with a 75 per cent performance increase on the S4 Pro. It will be based on four of Qualcomm’s own Krait 400 CPU cores, which can be clocked at up to 2.3GHz each. Graphics will be delivered by an Adreno 330 GPU, which doubles the power available on

the S4 Pro. The Snapdragon 800 also supports 4G on the chip, which will reduce costs for device manufacturers. The inclusion of a dual image signal processor to allow the capture of 3D images and standard resolution video also gives the Snapdragon an added edge.

Although many of Samsung’s 2012 phones featured Qualcomm processors, the fi rm has been working on updating its own Exynos range. The Exynos 5 ‘Octa’ unveiled at CES offers an eight-core design, based on ARM’s big.LITTLE architecture. It uses four low-power ARM Cortex-A7 cores for less CPU-intensive tasks and four Cortex-A15s to handle heavy loads. The intention is to reduce power consumption, with Samsung claiming a 70 per cent increase in battery life for the dual-core Exynos 5.

Finally, Intel, whose Atom x86-based chips have been rivalling ARM in 2012, announced that devices based on the ‘Bay-Trail’ quad-core Atom chip are scheduled to hit the shelves towards the end of 2013.

■ A new Snapdragon

008-011_LUD_123 PK.indd 8 25/01/2013 17:10

Page 9: Linux User & Developer - Bpfine

www.linuxuser.co.uk9 www.linuxuser.co.uk9

Linux calendar

21 F

eb 2

013 Android Magazine –

issue 22 » www.littlegreenrobot.co.ukAndroid Magazine, our best and only print source for everything Android, is coming out today. Check out what’s in store over on page 64.

SCALE 11x » Hilton Los Angeles International

Airport, Los Angeles, CA» USA» www.socallinuxexpo.org/

scale11xThe 11th annual Southern California Linux Expo is the fi rst Linux and open source software expo this year in North America, and will be host to more than 100 exhibitors and 70 speakers.

Linux User & Developer – issue 124 » www.linuxuser.co.ukThe next issue of Linux User will be out today – fi nd out what will be in issue 124 on page 98…

22-2

4 Fe

b 20

13

Online retail giant Amazon is currently putting different variants of the Google Chromebook at the top of its hourly updated listings of the bestselling notebooks in the UK and the US. At the time of writing, Samsung’s 11-inch offering is in the number-one position for US sales, while the Acer C7 Chromebook is sitting

Xi3, a fi rm formed as a Kickstarter project to create small, modular Linux-based PCs, caused a stir at CES amid rumours that the company’s new Piston PC was, in fact, a pre-release version of Valve’s upcoming Steambox gaming console. Xi3 has taken investment from Valve and executives said they have been

PyCon 2013 » Santa Clara Convention Center,

Santa Clara, CA » USA » https://us.pycon.org/2013/The largest annual gathering for the Python community, PyCon is a diverse conference dedicated to providing an enjoyable experience for everyone who attends. Tutorials, talks, summits and open spaces are available at the conference.

14 M

arch

201

313

-21

Mar

ch 2

013

Samsung model top in US

Based on Xi3 Piston PC

The latest in the Linux communityNews

OPEN SOURCE

HARDWARE

HARDWARE

Google has tasked Lior Ron, ex-chief technology offi cer of the Israeli Army Intelligence, to head up the team to develop a new Android super-phone, according to reports in The Wall Street Journal. The ‘X-Phone’ is part of a plan for Google to increase the profi tability of its Motorola Mobility unit and claw back a share of the smartphone hardware market now dominated by Samsung and Apple.

When Google fi rst bought Motorola Mobility last year, the company carefully stage-managed the deal. The focus was placed on

Ex-CTO of Israeli military to head up developmentMotorola’s patent portfolio as the chief reason for the acquisition. Google initially played down any talk of the company creating its own in-house, end-to-end, Android ecosystem.

“Google remains fi rmly committed to Android as an open platform and a vibrant open source community,” Andy Rubin, Google’s senior vice president of mobile, commented at the time. “We will continue to work with all of our valued Android partners to develop and distribute innovative Android-powered devices.”

Since then, Google has avoided any sign of favouritism to Motorola. The ‘Nexus’ branded contract to premiere the latest version of Android has been awarded to a string of other hardware vendors in the Android ecosystem. However, the appointment of a heavy hitter such as Ron to head up its in-house hardware development will undoubtedly strike fear into the hearts of an already paranoid Android hardware community.■ X marks the spot for a new Google phone

MOBILE

Google plans new ‘X-Phone’

Chromebook tops the charts

Steambox is confirmed

■ Samsung’s 11-inch Chromebook

■ Piston PC

at the number-two spot in the UK. Although the Windows 8-powered Acer Aspire E1 currently holds the top spot in the UK, Windows has been knocked into third place by the 13-inch Apple MacBook Pro in the US. It certainly seems that Microsoft’s one-time dominance of computer hardware is now in question.

working together to optimise the Piston PC for running Steam on Linux. However, Valve founder Gabe Newell fi nally laid all speculation to rest after the show. “We’ll come out with our own,” Newell told reporters at The Verge, “and we’ll sell it to consumers by ourselves.”

008-011_LUD_123 PK.indd 9 25/01/2013 17:10

Page 10: Linux User & Developer - Bpfine

Your source of Linux news and viewsOpenSourceContact us…Register and post your comments…www.linuxuser.co.uk/forum/

Email us directly… [email protected]

www.linuxuser.co.uk10

Linux, customised with the project’s own Sugar user interface.

The Tablet’s new XO Learning interface is an Android-compatible software suite for child-centric learning. The interface was developed by OLPC together with Yves Behar’s fuseproject and Common Sense Media, a non-profit organisation dedicated to helping parents and teachers make informed decisions about media.

“OLPCA and Common Sense Media share the same vision of a world in which all kids have access to the limitless learning opportunities that technology provides,” OLPC commented in the official launch announcement. “Every child has dreams, and XO Learning directs the child’s passion, creativity and energy for these dreams into a new user interface that has 12 dreams. Such dreams include ‘I want to be’ an artist, a musician and a scientist. Each dream features a rich learning experience and applications, books, games and videos that allow children ages 3 to 12 to naturally explore their dreams and learn at the same time.”

XO Learning provides a full range of parental controls and user IDs for up to three children, plus a dashboard where the child or the parent can review usage, types of content and the skills

Less cutting-edge, more at the cuddly edge of Linux, the One Laptop Per Child (OLPC) association was also showing off its latest wares at this year’s CES. OLPC suffered a bumpy ride into the world of tablets, shelving initial plans for the XO 3.0 device. However, with the new XO Learning Tablet and XO 4.0 Touch, the project seems to have found its feed again.

The XO 4.0 Touch is the fourth generation of OLPC’s now iconic green and white notebook aimed at providing a modern education to children through a rugged, low-cost, connected computing device. It features a robust swiveling Neonode touch screen to convert between notebook and tablet mode. The processor has been updated to a 1GHz Marvell Armada multicore ARM processor with hybrid-SMP technology. Memory and storage have been left as flexible as possible, with the option for either 1 or 2GB of DDR RAM, 4 or 8GB of drop-proof NAND flash storage, internal microSD and a full-size external SD slot.

The XO 4.0 is designed with a focus on power efficiency in order to cope with the erratic electricity supplies in the developing nations where OLPC predominantly operates. However, running a customised version of Fedora 18, the device still delivers sterling performance and the new touch screen is usable in an unlit classroom or in direct sunlight.

OLPC’s first pure touch device, the XO Learning Tablet, offers even more poke with a dual-core 1.6GHz processor and 1GB of RAM (for full specs, see below right). The XO Learning Tablet also marks a change for OLPC, as it is the project’s first Android-based device. To date, the XO notebook range has run Fedora

Two new low-cost learning devices, both with touch screens

hardwarE

the child is developing. Current content partners include Sesame Street, MyCityWay and Little Pim, and OLPCA is currently in negotiations with many more of the world’s leading companies to provide unique experiences in time for the product’s expected launch in May 2013.

In contrast to the traditional XO models which were always hard to come by in the Western world, the XO Learning Tablet is intended for truly global use and is likely to be made available through high-street retailers. We will keep you updated.

OLPC previews new touch devices at CESn The OLPC XO

4.0 Touch

n OLPC XO Learning Tablet – scheduled for widespread release in May 2013

display size 7.0-inch Processor 1.6Ghz dual-core raM 1GB wi-Fi SDIO 802.11b/g/n Screen resolution 1024x600 pixels Free apps 100 preloaded Parental control Built-in Storage 8GB Battery 3,800mA I/O microSD, HDMI, micro-USB, stereo headset Cameras 1.3MP 720 HD (front); 2.0MP (rear)

Vivitar licensed XO Learning TabletTechnical specs

008-011_LUD_123 PK.indd 10 25/01/2013 17:10

Page 11: Linux User & Developer - Bpfine

The latest in the Linux communityNews

OPEN SOURCE

Online fi lm and TV provider Netfl ix aims to strengthen its position in the open source community by holding an Open House event at its Los Gatos offi ces in California. In the past year, the fi rm has released 16 of its core infrastructure components as open source projects on GitHub (http://netfl ix.github.com). These releases have included its Asgard cloud management tool, Eureka load balancing software and the Simian Monkey suite of cloud network and cloud infrastructure testing tools.

The Netfl ixOSS Open House event will provide a showcase for the company’s existing GitHub releases and the opportunity to “deep-dive” into

the technologies with their core developers. In addition, Netfl ix is promising more new releases.

Despite several requests to the event’s organisers, we have yet to determine if the Open House will be streamed live (given Netfl ix’s business, we’d expect it to be). However, it will almost certainly develop interest and activity around some of the more useful open source technologies to have been released last year.

It is also worth noting that Netfl ix is clearly not releasing new tools and holding this type of event simply to be friendly to its new open source community: the company is clearly looking to attract new developer talent.

In case you missed it, Linux User magazine is available to read on any digital format thanks to the excellent digital editions super-site, www.greatdigitalmags.com.

The site brings together Linux User’s offerings on Zinio and Newsstand, allowing you to enjoy your favourite mag on your Mac, PC, iPad, Android and a host of other devices.

There are some incredible subscription incentives up for grabs too – not just for Linux User but for all Imagine Publishing titles.

To fi nd these amazing deals, point your web browser at www.greatdigitalmags.com, where you can fi nd links to back issues, subscriptions and more, across almost every platform. It’s all available in just one place, and there are massive savings to be had!

Grab Linux User digitally at greatdigitalmags.com

OPEN SOURCE

■ Netflix is wooing open source developers

Open source developers invited to showcase event

NetflixOSS Open House promises new insights

008-011_LUD_123 PK.indd 11 25/01/2013 17:10

Page 12: Linux User & Developer - Bpfine

www.linuxuser.co.uk12

Your source of Linux news and viewsOpenSource

Jon Masters summarises the latest happenings in the Linux kernel community, including the closing of the development ‘merge window’ for the 3.8 kernel

Jon MastersTHE KERNEL COLUMN

Linus Torvalds closed the 3.8 kernel ‘merge window’ (the period of time during which disruptive changes are allowed into the kernel, and are then stabilised before fi nal release) just prior to the Christmas holiday. In his announcement of the fi rst 3.8 ‘release candidate’, Linus said, “The longest night of the year is upon us (and by ‘us’ I mean mainly people in the same time zone and hemisphere as I am. Because I’m too self-centred to care about anybody else), and what better thing to do than get yourself some nice mulled wine, sit back, relax, and play with the most recent RC kernel?” Some readers might question whether this is truly the most relaxing course of action, but nobody can fault Linus for trying to motivate developers to spend some holiday time testing code.

The 3.8 merge window was, according to Linus himself, the biggest merge window in the 3.x kernel series so far (in terms of raw number of changes going into the kernel codebase). It will contain a number of new and exciting features. Two that interest this author in particular are the support for transparent huge zero pages, and newly added support for the AllWinner ‘A1X’ series of system-on-chip ARM processors. The latter are very popular, inexpensive and more capable (in terms of

compute) bigger brothers than the chip used in the Raspberry Pi, while being used in systems of similar price. It is possible, for example, to purchase one of the popular ‘MK802’ plug-in TV dongles built using the AllWinner A10 CPU for $35. That yields a full ARM-based Linux system running at 1GHz, with 1GB RAM, USB, Wi-Fi, an SD card interface and full HDMI output. Even more capable systems of a similar price point are appearing all the time, so the A1X will remain popular.

Transparent zero huge pages are another 3.8 kernel feature that will be popular with users, although if the feature is working correctly, users who use it may never realise that it is even there. Huge pages are a hardware feature of modern CPUs in which the built-in CPU virtual memory translation caches, known as TLBs (translation lookaside buffers), support both the conventional smallest unit of virtual memory page size of (typically) 4KB, as well as a much larger ‘huge’ page of 2 or 4MB or more. This is useful because the CPU has only a limited number of these much faster TLB caches that it uses to store previously looked-up (translated) virtual memory mappings from addresses used by applications to those of the underlying hardware. By using huge pages, the hardware can keep more translations cached and improve performance. But, there is a performance catch to using huge pages.

Historically, huge pages had to be manually assigned, but support for ‘transparent’ or automatic huge pages was added to the kernel some time ago and has been present in distributions for a number of releases. With the introduction of transparent huge pages came the unintended side effect that some systems would actually waste memory in the process. This is because when allocating conventional

Jon Masters is a Linux kernel hacker who has been working on Linux for almost 17 years, since he fi rst attended university at the age of 13. Jon lives in Cambridge, Massachusetts, and works for a large enterprise Linux vendor. He publishes a daily Linux kernel mailing list summary at kernelpodcast.org

012-013_LUD_123_OPINION PK.indd 12 25/01/2013 17:11

Page 13: Linux User & Developer - Bpfine

www.linuxuser.co.uk13

The kernel column – Jon MastersOpinion

open source

pages, the kernel has the option of using the ‘zero’ page, a special page that is read-only and full of zeros. When applications attempt to write to it, a process known as copy-on-write actually allocates and sets up the real page entries in the kernel. The transparent huge pages code did not have a similar concept, so applications mapping large amounts of contiguous memory might have a large number of huge pages filled with zeros allocated that were never used. Linux 3.8 addresses this situation by sharing a ‘huge’ zero page, similar to the regular zero page.

During the merge window, some changes to the Video4Linux (V4L) code were merged that broke a user-space application (PulseAudio) by altering the return codes passed by a system call. Linus got particularly angry about this, telling the kernel developer concerned to “SHUT THE F*** UP!” when responding to protests that the user-space application was doing something wrong. Linus reminded everyone of longstanding policy by saying, “[If]a change results in user programs breaking, it’s a bug in the kernel. We never EVER blame the user programs. How hard can this be to understand?” Strong responses aside, there is established history of never questioning even the weirdest of application behaviour, always endeavouring to retain compatibility. The patch in question was reverted by Linus and an alternative reworked.

With the merge window closed, development has returned to a combination of new patch development and refinement of the existing 3.8 release candidates, which are several weeks in as of this writing. There are typically seven or eight release candidate kernels (spread over several months’ duration) for a typical kernel, meaning that we can expect 3.8 final sometime in February.

ongoing developmentThis past month saw an interesting series of conversations around hash collisions in next-generation file systems. Many modern file systems use a hash-based approach to store the names of individual filename entries within normal directories. A given name, such as ‘passwd’ (as in /etc/passwd) is passed through a hashing algorithm which generates a finite number of possible numeric values. This value

is then used internally within the file system to determine where in the ‘data structure’ within the file-system metadata the given entry will be stored. If multiple files hash to the same location, a list is created. Such lists (buckets) are not typically very large because the hashing algorithm does a good job at keeping hash ‘collisions’ to a minimum. Sometimes, however, these lists can be artificially enlarged by creating special file-system entries that are known to generate collisions. This is what Pascal Junod blogged about in December. He raised a number of known issues with Btrfs and discovered a new bug in the code, which Chris Mason (the author) has now posted a patch intended to address the concern.

A lot of memory (virtual and otherwise) work is ongoing. Minchan Kim has continued working on support for volatile memory mappings. Using special parameters, applications can explicitly mark regions of memory as being volatile (the kernel is allowed to trash them at will), and unmark them as volatile when they are needed again. The application is able to determine whether the volatile memory was actually destroyed in the meantime. Related work includes a user-space memory shrinker from Anton Vorontsov, which allows applications to use a mempressure cgroup to register reclaimable chunks. When the system is low on memory, the application will be asked to reclaim a number of chunks. It will then

“Transparent zero huge pages are a 3.8 feature that will be popular”

update the kernel as to what was reclaimed. Both this and the volatile work are useful, for example, in applications that retain large caches (eg of webpage content) that can easily be regenerated.

Linux 3.7 introduced support for ARM’s new ‘AArch64’ 64-bit ARM architecture. Previous kernel cycles have sometimes introduced more than one new architecture. Although it seems as if this won’t be the case for 3.8, it does look like 3.9 could have two new architectures. James Hogan posted pretty comprehensive support for Imagination’s ‘Meta’ processor cores (hybrid CPU/DSP cores capable of running multiple RTOSs and regular kernels on hardware threads at the same time), while Vineet Gupta reworded the older 3.2 kernel support for Synopsys’s ARC processors to bring it up to date. The latter is interesting because it is intended to be a highly configurable and extensible processor architecture. Those implementing the (licensable) ARC processor can customise the number of instructions, registers and many other features, in a manner described online as being “like Lego blocks”.

Finally this month, a number of kernel developers have been considering putting the ‘Kernel Hacking’ menu options within the kernel Kconfig “on a diet”. Dave Hansen, as well as other developers, consider that 120 possible options is now too large and that a number of these should be removed, or split out. In particular, Dave posted a cleanup patch to move ‘debugfs’ out into the file-systems menu.

n Linus Torvalds

encouraged developers to play with

the latest RC kernel over

the holidays

CC.

GFD

L. P

erm

issi

on o

f Mar

tin S

trei

cher

, Edi

tor-

in-C

hief

, LIN

UXM

AG.c

om

012-013_LUD_123_OPINION PK.indd 13 25/01/2013 17:11

Page 14: Linux User & Developer - Bpfine

the open source column

www.linuxuser.co.uk14

Your source of linux news and viewsopensource

Simon ponders the continued explosion in the sales of tablet devices, and wonders how it can all be turned to good

the tablet the industry needs?

simon Brew is a technology writer and editor, working across the Linux, Windows and Mac OS X platforms

Given that the general impression given of the British retail sector in particular post-christmas was one of doom and gloom, with several major chains facing well-documented problems, closer inspection revealed some interesting upward trends in the midst of the figures. And technology, not for the first time, was adding some of the fuel.

Appreciating that there were many contributory factors, the numbers for high-street electrical giant Currys were surprisingly impressive. In line with similar chains in other countries, Currys has spent money making its stores bigger, consolidating its brands under one (very big) roof. I went in one just before Christmas and, truthfully, couldn’t leave fast enough. The PC World segment of the business seems to exist to try to sell us copies

n Apple is no longer getting it all its own way in the

tablet market

of Windows 8 (which I suspect will continue to cause Microsoft as many problems as it resolves), and listening to a salesperson try and sell anti-virus software to someone buying a tablet computer called for rarely seen levels of restraint. The methodology of old remains the same, it seems, even if the products themselves gradually changed.

Two things have buoyed Currys, however. The first is the demise of another big British chain, Comet, which inevitably brought fresh footfall into the market.

But the other, and less UK-specific factor is the staggering, ongoing success of tablet computers. Tablets are now heavily mainstream, as well as filling in niches in the market that a full computer can’t do. Take the rise in educational and child-targeted tablet computers, for instance. Granted, this is usually a cheap Android-powered model that’s had a few apps clustered together on it. But there’s potential here to push the hardware itself into affordable, interesting places, and the low price that’s been asked for such devices suggests that there’s headroom to do more.

What’s particularly interesting about the tablet market too is that Apple no longer appears to be having things its own way, and that’s been crucial to the relaxing of the sector as a whole. Samsung and its Galaxy line is at the top end of Apple’s rivals, and Google’s Nexus line continues to thrive. Sadly, it looks as if Amazon’s less-friendly-than-it-looks Kindle Fire has been making serious headway, though, which is a worry. As those who have used the Kindle Fire extensively can testify, it’s a tablet that exists to get you closer to Amazon’s products and

services above all else. It adds little to nothing to the open source community at all.

But it doesn’t have to be like that. Convincing the mass market to adopt an open source operating system for a desktop PC or laptop was always going to be a proverbial uphill struggle, but there’s a different set of parameters now. While Windows 8 continues to try to win people over, the truth that Microsoft is facing is that, for the first time in a generation, there’s change on a software as well as a hardware level.

Sadly, by allowing the likes of Amazon to seize that, there’s an argument that some opportunities have been lost already. But the taking for granted of a touch-screen interface means that there’s space here for something of note in the retail sector to develop; for devices that work on a genuine framework of open source software, to offer genuine choice.

Remember the days when Dell first introduced its laptop customisation purchase screen that seemed intent on selling you as much as it possibly could? Well, that might just be inverted now. Instead, software becomes the choice. Given that most hardware in the sector is created equal, we’re at a stage where end users can, instead of quibbling over memory and storage space, focus on application and what they actually want a device for.

Currys is unlikely to be interested in that any time soon. But by continuing to fuel the tablet explosion, the retailer may yet have a helping hand in bringing to the fore a more interesting way of computing.

014_LUD_123 PK.indd 14 25/01/2013 17:13

Page 15: Linux User & Developer - Bpfine

www.linuxuser.co.uk15

The free software columnOpinion

open source

the Free soFtware column

Igor stravinsky once said that “a good composer does not imitate; he steals”, and ts eliot once said “immature poets imitate; mature poets steal.” even the idea that good art embraces the work of other good artists is not unique or original.

Good art is often a synthesis of thoughts and methodologies that have been poached and recycled from other sources. Very little is entirely new or original, and this understanding is equally true of other aspects of our lives. Ideas are cumulative and depend upon the evolution of techniques, observation and criticism, so it isn’t entirely surprising that inventions and discoveries are often made simultaneously by different people in different locations. It is still a matter of argument, for instance, whether the electric light bulb was invented by Joseph Swan or Thomas Edison, or the telephone by Elisha Gray or Alexander Graham Bell…

The style and design of the prevailing art and everyday items of our lives reflect the zeitgeist and are a refinement and an assimilation of the judgement of their times. Everybody copies everybody else, and style is not a patentable

Android phones are no more a ‘rip-off’ of the iPhone than the iPhone is a rip-off of earlier mobile phones and technology, argues Richard Hillesley…

apple scruffs

idea. So the cars of any era, however different they might have seemed in their time, look like other cars of that era – and the same can be said of, say, furniture, graffiti, clothes, hairstyles and mobile computer devices. A mobile phone is based on any number of software and hardware technologies developed by individuals and firms such as Nokia, Samsung and Motorola over a period of 30 years, but a modern phone looks very different to one of 30 years ago.

A mobile phone has some basic requirements. It has to be portable and fit in your pocket, preferably with smooth edges so that it doesn’t catch on the threads of your jacket or shirt. It has to be able to scan the web and talk to other phones. Sometimes we expect a little bit more, but the basic technology and appearance, albeit refined and improved, remains the same, and owes everything to 30 years of research and development by any number of companies and individuals who wormed away at the idea of touch screens and mobile communications, sometimes making breakthroughs and sometimes encountering failure.

The commercial breakthrough of the smartphone is dated to the launch of the iPhone in 2006, but the ideas and technology it embraced did not slip, clean and new, out of Apple’s ownership of one particular part of the ether. Apple was not alone in recognising that the mobile phone had a significant future, but had the advantage of being an outsider to the business, able to take a dispassionate view of the possibilities. Apple synthesised the best aspects of existing mobile phone technologies and smartphones, and added the marketing potential of the idea behind iTunes to make an iPhone out of an iPod – a phone that doubled as an iPod and a web device, and gave access to the Apple store. Marketing and the inertia of the competition did the rest.

The iPhone was the best mobile phone of its time, used the best hardware, and relied

richard hillesley writes about art, music, digital rights, Linux and free software for a variety of publications

on clean design and usability principles. Apple made all the right decisions, sidestepped the competition and still holds a significant share of the market – but very few of the constituent parts of the iPhone were really unique or original. Competitors adopted Android, which had been under development since 2003, offered all the advantages of the iPhone and cost significantly less.

The justification for Apple’s subsequent righteous war against the Androids is the tendentious claim that Android is a ‘rip-off’ of the iPhone and “a stolen product”. The primary contention is that Samsung and Android have ripped off Apple’s style and look and feel, but Android is no more stolen from the iPhone than the iPhone is a ‘rip-off’ of the pioneering work of the likes of Motorola, Nokia and Samsung itself.

The instrument for Apple’s war has been the acquiescence of the United States Patent and Trademark Office (USPTO) and the US courts, ownership of scores of debatable utility and design patents, and its claims against Samsung and others of ‘trade dress infringement’. The good news in recent months is that some of these entitlements, such as Apple’s patent entitled ‘Touch screen device, method, and graphical user interface for determining commands by applying heuristics’ (bit.ly/TPWeEw) and ‘the rubber band patent’ (ars.to/SmJ6pP) have come up for review and been found wanting by the USPTO. The bad news is that Apple still has a vast portfolio of debatable patents to draw upon.

Patents are not a defence of the rights of the innovator, but a weapon against competition and invention and the rights of the user. Android is no more a ‘rip-off’ or ‘stolen product’ than the iPhone itself, or the music of Stravinsky or poetry of Eliot.

015_LUD_123 PK.indd 15 25/01/2013 17:13

Page 16: Linux User & Developer - Bpfine

6 MONTHS

FREE!CELEBRATE

DOMAINS | E-MAIL | WEB HOSTING | eCOMMERCE | SERVERS

* 12 month minimum contract term applies. Visit www.1and1.co.uk for full offer details, terms and conditions. Prices exclude VAT.

This year at 1&1, we’re celebrating our 25th anniversary! In honour of this occasion, we‘re making it even easier for you to benefi t from our knowledge and experience, with 6 months free on all our web hosting packages!

Over the past 25 years, 1&1 has grown to become one of the world’s leading web hosts. Today, with more than 11 million customer contracts, £2 billion in annual turnover, 5000 employees and 5 high-performance data centres, 1&1 provides superior web hosting to support your business.

Share in our success and take advantage of our anniversary offers!

SHARE OUR SUCCESS

Plus: secure your ideal domain now from just £0.99!*

1and1.co.ukCall 0844 335 1211 or buy online

* 12 month minimum contract term applies. Visit www.1and1.co.uk for full offer details, terms and conditions. Prices exclude VAT.

1&1 Starter 1&1 Standard 1&1 Unlimited 1&1 Business5 GB Webspace 50 GB Webspace Unlimited Webspace Unlimited Webspace1 MySQL 5 Database (1 GB each)

10 MySQL 5 Databases (1 GB each)

100 MySQL 5 Databases (1 GB each)

Unlimited MySQL 5 Databases (1 GB each)

1000 e-mail accounts (2GB) 3000 e-mail accounts (2GB) 5000 e-mail accounts (2GB) Unlimited e-mail accounts (2GB)

– – 1 domain included. Choose from .co.uk, .me.uk or .org.uk

1 domain included. Choose from .co.uk, .me.uk or .org.uk

PHP 5.4, PHPDev, Zend Framework PHP 5.4, PHPDev, Zend Framework, Perl, Python, Ruby, SSI

PHP 5.4, PHPDev, Zend Framework, Perl, Python, Ruby, SSI

PHP 5.4, PHPDev, Zend Framework, Perl, Python, Ruby, SSI

Unlimited Traffi c

1&1 Click & Build Applications: WordPress, Joomla!®, Drupal™ and more

1&1 Security: Geo-redundancy and Webspace Recovery

24/7 phone and e-mail support

6MONTHS

FREE

24/7 phone and e-mail support

6MONTHS

FREE

24/7 phone and e-mail support24/7 phone and e-mail support

6MONTHS

FREE6MONTHS

FREE

£9.99per month*£9.99per month*

£4.99per month*

£4.99per month*

£6.99per month*

£6.99per month*

£2.49per month*

£2.49per month*

OFFERS END 28/02/13

DPS.indd 1 22/01/2013 10:33

Page 17: Linux User & Developer - Bpfine

6 MONTHS

FREE!CELEBRATE

DOMAINS | E-MAIL | WEB HOSTING | eCOMMERCE | SERVERS

* 12 month minimum contract term applies. Visit www.1and1.co.uk for full offer details, terms and conditions. Prices exclude VAT.

This year at 1&1, we’re celebrating our 25th anniversary! In honour of this occasion, we‘re making it even easier for you to benefi t from our knowledge and experience, with 6 months free on all our web hosting packages!

Over the past 25 years, 1&1 has grown to become one of the world’s leading web hosts. Today, with more than 11 million customer contracts, £2 billion in annual turnover, 5000 employees and 5 high-performance data centres, 1&1 provides superior web hosting to support your business.

Share in our success and take advantage of our anniversary offers!

SHARE OUR SUCCESS

Plus: secure your ideal domain now from just £0.99!*

1and1.co.ukCall 0844 335 1211 or buy online

* 12 month minimum contract term applies. Visit www.1and1.co.uk for full offer details, terms and conditions. Prices exclude VAT.

1&1 Starter 1&1 Standard 1&1 Unlimited 1&1 Business5 GB Webspace 50 GB Webspace Unlimited Webspace Unlimited Webspace1 MySQL 5 Database (1 GB each)

10 MySQL 5 Databases (1 GB each)

100 MySQL 5 Databases (1 GB each)

Unlimited MySQL 5 Databases (1 GB each)

1000 e-mail accounts (2GB) 3000 e-mail accounts (2GB) 5000 e-mail accounts (2GB) Unlimited e-mail accounts (2GB)

– – 1 domain included. Choose from .co.uk, .me.uk or .org.uk

1 domain included. Choose from .co.uk, .me.uk or .org.uk

PHP 5.4, PHPDev, Zend Framework PHP 5.4, PHPDev, Zend Framework, Perl, Python, Ruby, SSI

PHP 5.4, PHPDev, Zend Framework, Perl, Python, Ruby, SSI

PHP 5.4, PHPDev, Zend Framework, Perl, Python, Ruby, SSI

Unlimited Traffi c

1&1 Click & Build Applications: WordPress, Joomla!®, Drupal™ and more

1&1 Security: Geo-redundancy and Webspace Recovery

24/7 phone and e-mail support

6MONTHS

FREE

24/7 phone and e-mail support

6MONTHS

FREE

24/7 phone and e-mail support24/7 phone and e-mail support

6MONTHS

FREE6MONTHS

FREE

£9.99per month*£9.99per month*

£4.99per month*

£4.99per month*

£6.99per month*

£6.99per month*

£2.49per month*

£2.49per month*

OFFERS END 28/02/13

DPS.indd 2 22/01/2013 10:33

Page 18: Linux User & Developer - Bpfine

TEN AMAZING RASPBERRY PI

PROJECTSThe £25 computer is celebrating its fi rst anniversary – here’s to a year’s worth of

magnifi cent, unique and exciting achievements

www.linuxuser.co.uk18

Feature 10 amazing Raspberry Pi projects

As portable computing goes, the Raspberry Pi could hardly be bettered. Small enough to slip inside a pocket, it can go anywhere and everywhere with you. Yet to use the Pi as a standard

Linux machine kind of misses the point – or, at the very least, the opportunities afforded by this small-form-factor, high-spec wonder.

Over the past year, this inexpensive machine, produced as an educational plaything, has taken centre stage for a

whole host of projects. Some have satisfi ed a craving for fun; others for exploration and indulgence. More still have satisfi ed the current trend for performing real-world tasks at the lowest possible price. The Pi is the recession buster with the potential to empower a future generation (as one schoolboy emphatically showed).

Here we present ten of those projects. Each of them, we believe, encapsulates all that is good about the Pi, making great use of two things: the machine itself, with its tiny credit card size; but above all, the bold

imagination of the creators. And the balls to keep going to realise those dreams, of course, but that would be three things.

Over the next few pages, the creators of these projects talk us through their projects. You will fi nd the majority of the source code on our cover disc and we'll also tell you where you can fi nd tutorial instructions, where available, to allow you to replicate them. But more than all of this, we hope it provides you with inspiration for your own projects. You never know – you may see your creation here in a year's time.

018-029_LUD_123 PK.indd 18 25/01/2013 17:15

Page 19: Linux User & Developer - Bpfine

www.linuxuser.co.uk19

Top Raspberry Pi projects to amaze and inspire10 amazing Raspberry Pi projects

feature

rasPi 1st birthdaysPecial

018-029_LUD_123 PK.indd 19 25/01/2013 17:15

Page 20: Linux User & Developer - Bpfine

www.linuxuser.co.uk20

Feature 10 amazing Raspberry Pi projects

The Raspberry Pi SupercomputerTake some Lego and 64 Pis for a delicious slice of processing power

Since the ultimate aim of the Raspberry Pi is to encourage children to experiment with computers and understand their inner joy, the supercomputer project built by computational engineers at the University of Southampton could not be a better example of the magical things being done with this miniature marvel.

The creation by Professor Simon Cox and his team cost less than £2,500 to build, excluding the switches, but it also had a special ingredient: Prof Cox’s six-year-old son, James.

It was while playing around with a Pi with his son that the supercomputer expert decided it would be an interesting experiment to buy 64 of the machines and produce something rather spectacular. And it was the young boy who provided specialist support on Lego and system testing, providing an eye-catching aspect to the entire project.

Maker profile: Prof Simon CoxSimon Cox is professor of Computational Methods at the University of Southampton. His research is about applying and developing high-performance computing and big data to tackle problems in science and engineering. The university of has a powerful 12,000-core intel-based supercomputer which cost millions of pounds.

With 64 raspberry pis and more than 1,000

pieces of lego, this is a supercomputer in more ways than one

it has 192W total electric power draw, ~4 Gflops of CpU power and ~1500 Gflops of GpU graphics

compute power

There is 1TB of Class 10 SD card memory on

iridis-pi, which is named after the University of

Southampton’s 12,000-core iridis supercomputer

The supercomputer runs raspbian oS, which is based on

Debian and optimised for raspberry pi

018-029_LUD_123 PK.indd 20 25/01/2013 17:15

Page 21: Linux User & Developer - Bpfine

www.linuxuser.co.uk21

Top Raspberry Pi projects to amaze and inspire10 amazing Raspberry Pi projects

■ The project started when Prof Simon Cox and his son, James, began to play with a Pi

■ Since the drivers for the Pi's video card are open source, the potential to use that video chip for processing opens up 24 gigafl ops of general-purpose computer performance

■ Lego features highly in the project, but so does research. Although the supercomputer uses an ordinary downloadable system image from the Raspberry Pi website, the performance and various other parts of the fi rmware and drivers have been improved by a factor of 50 or more

TRY IT YOURSELFThe Kit:• 64 Raspberry Pis Model B/256MB = £1,475.20• 64 Kingston Ultimate X 16GB Class 10 (SD10G2/16GB) = £622.72

• 64 metres of CAT 5E (misc colours) = £90.88• 64 micro-USB power supply adaptors, UK, 1.2A = £244.48

The Knowhow: www.soton.ac.uk/~sjc/raspberrypi

Plus items that were in the lab:• 3 Netgear ProSafe 24-port smart switches with PoE / 192W total 4 SFP (GS724TP) = £269.99 each

• DrayTek Vigor 2820N router• Keyboard• Monitor• Mouse• HDMI-to-monitor cable• 3 CAT 5E cables to connect the switches together

“The thing about the Raspberry Pi is that suddenly things can be done that come within the budget of a school so you could actually have term-long projects and a whole class involved”

Running off a single 13 amp mains socket and using MPI to communicate between nodes using Ethernet, it offers a staggering amount of power when you consider the low cost.

Prof Cox had been impressed straight away by how great the Pi was for playing around with electronics using the GPIO connectors. “The fact you could turn LEDs on and off and

link a little Python computer program to a bar graph LED caught the imagination of myself and my son who built a Lego case for it,” he tells us.

So he waited for a large supply of Pis to became available. “We then had to decide on the network switches. My background researching supercomputers and IT meant I knew you could spend a lot of money on switches. We begged, stole and borrowed some old switches that were being decommissioned from our computing service, which meant we could link them together. I got some power over Ethernet switches from another project I was working on.”

James used his design skills to build the racking out of little plastic bricks before testing it using Python and Scratch. But one of the most time-consuming processes was getting all of the images set up. Prof Cox found it was one thing to download one image on to one SD card, but quite another doing 64 of them.

“The Pi, for the fi rst time, has meant you can assemble a supercomputer for a couple of thousand of pounds. And if you take just four of the units, suddenly you are at £100 and that means that large-scale supercomputing, or the principle of it, can be seen in schools. That's very special.”

FEATURE

RasPi 1st BIRTHDAYSPECIAL

018-029_LUD_123 PK.indd 21 25/01/2013 17:15

Page 22: Linux User & Developer - Bpfine

Feature 10 amazing Raspberry Pi projects

Games have often been said to be a key driver of technology and so we were extremely excited to see the Picade project when it emerged on Kickstarter. Created by Jonathan Williamson and Paul Beech, it looks like a mini, retro-style cabinet and comes in kit form. All people need is a screwdriver, a pair of pliers and an hour of time to put it together.

“The idea had been in our heads for a while,” says Jonathan. “Paul and I have been through a number of startups and we had frequently seen a JAMMA cabinet in the office. It seemed the thing to have. We thought that only people with too much money or time on their hands were getting enjoyment out of them, so we decided it would be good to build one ourselves.”

The pair have been interested in technology for a long time and the Picade has been an accumulation of knowledge. From reading about joysticks to monitors, all of those ideas have come together. “We’ve also benefited from Kickstarter and globalisation,” says Paul. “Having the Pi was amazing.”

As if to underline just how the project has turned heads, Ian Stewart, the founder of Sheffield’s Gremlin Graphics – a games

n Ian Stewart from Gremlin Graphics stepped forward and allowed his old games to be available on the Picade

Picade arcade cabinetNo need to stand around in arcades – bring the action to your home

Maker profile: Jonathan Williamson and Paul Beechpaul is a designer, hacker and maker. He designed the raspberry pi logo and is the brand and design lead for the foundation. Jon is a software guy and electronics hobbyist. He is the co-founder and technical lead for Netcopy (a digital archiving solution).

www.linuxuser.co.uk22

“There are those little specialist niche markets. The raspberry pi lets you do things which were previously very expensive if you are prepared to get your hands dirty and hack a bit”

018-029_LUD_123 PK.indd 22 25/01/2013 17:15

Page 23: Linux User & Developer - Bpfine

developer big in the Eighties and early Nineties – has allowed the use of the fi rm’s old-school games. “This means we can provide a games machine that can be used straight away,” says Paul. “And when you look at the Pi Store, the Picade suddenly becomes a great way to play legal games.”

Jonathan is excited about the future. “It’s the 3D games which I am loving,” he enthuses. “It will show off the Pi as a great gaming machine.” However, there have been some problems encountered by the pair. “Screens,” says Paul. “There are tons of models out there and some of these are 3mm in width. You can’t believe how thin they are. We had to look at how easy they are to mount, and separating wheat from the chaff. There is always a delay in stock too and we have to get on with other stuff while waiting for things to appear. Trying to get quality parts on time is diffi cult. A lot of components have to come from the East, such as arcade joysticks. But it’s been brilliant to work on.”

TRY IT YOURSELFThe Kit:• Cabinet panels and fasteners • LCD panel mount with protective overlay • LCD panel and driver board with inputs (at least 8” for the Picade Mini and 12” for the Picade) • Amplifi er and speakers • 3.5mm stereo panel-mounted headphone socket • Panel-mounted video input socket (allows you to use your Picade as a second display for your computer or laptop)

• A proper arcade stick • Illuminated microswitch arcade buttons (at least 4 on the Picade Mini and 6 on the Picade) • All other required components and cablesThe Knowhow: www.kickstarter.com/projects/pimoroni/picade-the-arcade-cabinet-kit-for-your-raspberry-p

Getting a quality screen was important for Jon

and Paul. Delays in stock caused problems

Finding quality parts was hard. A lot of

components had to come from the Far East

Both Paul and Jon have accumulated knowledge

of items from joysticks to monitors following years of reading and research

The creators noticed lots of startups had JAMMA cabinets in the break room and

associated them with people with a lot of

money. Picade opens up cabinets to the masses

■ Jon and Paul say the exciting stuff with

the Pi is 3D and new games like Minecraft

www.linuxuser.co.uk23

■ There is no profi t margin on this project. It is something the pair just wanted to build

Top Raspberry Pi projects to amaze and inspire10 amazing Raspberry Pi projects

FEATURE

RasPi 1st BIRTHDAYSPECIAL

018-029_LUD_123 PK.indd 23 25/01/2013 17:15

Page 24: Linux User & Developer - Bpfine

Feature 10 amazing Raspberry Pi projects

Very often what you didn’t have in your childhood inspires you in adulthood. That was the case with the Lego remote-controlled car created by Tom Rees using the Raspberry Pi. Having always wanted a remote-controlled car when he was young, the desire never left him.

And thanks to the power of the Pi, he was also able to go one better. Rather than build something controlled on a long tether to a computer or via Wi-Fi from a laptop, Tom could integrate the computer into the car itself. This means it became a ‘real’ remote-controlled car comprising just the vehicle and the controller.

The original plan was to build an RC Lego DeLorean, but all he could produce was an ugly white box. He then came up with different prototypes, most of which looked nothing like a car and were essentially motors, servos and LEDs attached to Technic towers. “I remember the very fi rst thing I built was a pair of LEDs which were turned on and off by the Xbox controller,” he says. “It’s important to begin

Lego remote- controlled carA Pi-powered self-contained remote-controlled car guided by an Xbox controller

with the simplest possible proof-of-concept to show all parts of the system working.”

To even begin to prototype, jumper wires, breadboards, a multimeter and lots of batteries were needed, plus a selection of resistors, capacitors, LEDs and a soldering iron. Once Tom had all the necessary supplies, he just decided to dive in. He learned as he went along.

“I had plenty of disasters,” he admits. “The cheap inductors I used in the 5V power regulator

“I think the thing that has really encouraged me is if you actually look at the number of these things where the Pi is a tool, it is not the Pi that is really the hit, it is the thing around it that is really the piece of inventive genius”

MAKER: TOM REES

■ Extra electronics are needed on top of the Lego and the Raspberry Pi. The Cobbler breakout kit from Adafruit broke out the power, GPIO, I2C and SPI pins from the 26-pin header onto a solderless breadboard

■ The car is controlled via a wireless Xbox 360 controller. Software on the Pi translates the controller buttons into motor speed, motor direction and steering rotation

■ All the hardware lives on the car. There is no need for a laptop issuing commands over Wi-Fi. This is the simple chassis

kept catching fi re because the Pi consumes so much current. Smoke pouring out of the Lego Technic holes is pretty terrifying.”

Trickiest of all was powering the electronics aboard the car. “The Raspberry Pi has strict tolerances on its 5V input, and it will consume well over 1 amp when the Microsoft USB peripheral is attached,” he says. But he is more than pleased with the result.

“Most stunning has been the reaction to this project. I knew I wanted to do something original with my Pi, to push the envelope very slightly, and be a little more imaginative than another ‘internet-controlled LEDs’ project. It’s seen a great reaction and I’m very pleased to see some projects inspired by this one.”

Lego remote- controlled carLego remote- controlled carLego remote- TOM REES

Tom suffered dodgy 5V regulators

and overloaded components. He

also found that the cheap micro-USB

cable going into the Pi could barely carry half an amp and had

to be replaced

The steering is controlled via a high-

torque 180-degree TowerPro servo and a Lego gear is attached

with superglue

www.linuxuser.co.uk24

Although Tom says he could go on for years

building larger and more complex vehicles with increased power,

four-wheel drive, weaponry, cameras, caterpillar treads, he is keen to invent

something new

Tom wanted a simple and robust chassis design, so Technic

clip joints and axles are used through

everything. Servos and motors need

to be held together tightly and two

motors are required

018-029_LUD_123 PK.indd 24 25/01/2013 17:16

Page 25: Linux User & Developer - Bpfine

There is seldom a more stunning effect than light painting. It uses long exposure times with lights in motion to produce amazing images. When Phil Burgess wanted to produce a machine that could create effective artistic images, he had a hunch that the Raspberry Pi would be able to streamline the process, not least because of the memory it could provide for the project.

The concept had been stewing for months, but no existing device made for a really satisfactory solution, Phil says, and by that he meant something that could be shared and easily built by others. The open source electronic prototyping platform Arduino was considered and Phil says it could handle the core task but it requires a ton of

Light painting with the PiArtistic images that simply astound are possible with the power of Pi

preprocessing and staging of the image data in fl ash storage. The Pi could handle this – and because it is inexpensive, it got over the worry of getting it damaged.

“So far we have created the prototype,” Phil tells us. “The next version will be smaller and lighter with a proper battery pack. At the time I was just scrambling among parts in the garage and relied on an enormous camping inverter to quickly solve the problem at hand.” Things went well too. “All the hardware and software was amazingly co-operative and everything fell into place,” Phil adds.

The trickiest part of the project was the documentation. “Explaining things as concisely as possible, cleaning up the code to be presentable, providing clear diagrams and such is always hard,” comments Phil. “Good documentation can elevate even a modest project into something desirable, but no

■ An Arduino could handle the core task, but required a ton of preprocessing and staging of the image data in fl ash storage. Another thought by Phil was to use his laptop and FTDI chip, but that machine is rather precious to him and he was not eager to strap it on a bike. The Pi was a middle ground – the horsepower and programming ease of the laptop, but the throwaway inexpensive nature of it. As you can see, the results are astounding.

■ Phil just scrambled among parts in the garage and relied on an enormous camping inverter to get these effects

■ The bike. Other than having the basic concept already, there was no planning: Phil just went straight into implementation, which took about two days

MAKER PROFILE: PHIL BURGESS

A Californian living in the San Francisco Bay area, Phil Burgess’s roots in art and technology go back many decades.

The light painting demo is the latest in a progression of LED projects inspired by artist/engineer Bill Bell in the 1980s. Today Phil develops kits and tutorials for Adafruit Industries, a fi rm at the centre of the open source and ‘maker’ movements.

TRY IT YOURSELFThe Kit:• Raspberry Pi = £25• Adafruit Pi Cobbler breakout kit = $7.95• Digital RGB LED weatherproof strip 32 LED = $29.95• 4-pin JST SM receptacle cable = $1.50• 4-pin JST SM plug cable = $1.50• 5V 10A switching power supply = $25• 5V 2A (2000mA) switching power supply = $9.95• Female DC power adaptor: 2.1mm jack to screw terminal block = $2• Plus a bike and mounting hardware (PVC pipe, hula hoop, zip ties)The Code: We’ve included the code on the cover discThe Knowhow: learn.adafruit.com/light-painting-with-raspberry-pi

amount of ‘coolness’ in a project can cover for a lousy explanation.”

And there were other considerations. A 5V DC power supply was needed because the LED strip draws so much more power than the micro-USB connector can provide. A 26-pin IDC cable was sacrifi ced to create a purpose-built cable between the Raspberry Pi GPIO header, LED strip and power supply in order to make the whole project more robust.

Phil also says Python warrants a mention: “My fi rst attempts at communicating with the LED strip were in C, but if this project was to be shared, C with makefi les and extra libraries and such would add complexity. In 48 hours, starting with zero Python exposure, it was possible to get this not just working, but actually pretty well optimised as I got a better handle on the language. And it’s all in one source fi le, easily shared.”

www.linuxuser.co.uk25

Top Raspberry Pi projects to amaze and inspire10 amazing Raspberry Pi projects

FEATURE

RasPi 1st BIRTHDAYSPECIAL

018-029_LUD_123 PK.indd 25 25/01/2013 17:16

Page 26: Linux User & Developer - Bpfine

Feature 10 amazing Raspberry Pi projects

Michael Clemens’s idea for his Raspberry Pi project came less out of hobbyism and more out of a solution to a very personal problem. His wife’s grandmother is visually impaired and the couple fi nd it diffi cult to keep her entertained. Listening to television is not ideal and she struggles to operate her CD player.

It was a contest for young programmers, but few would have expected to see quality of the type produced by 12-year-old Aaron Hill, who ran away with fi rst prize in the under-13 category.

The one-button audio player

Time-lapse photography with Pysnap

Music to a grandma’s ears… it’s the easy-to-use audio player

The competition-winning CLI tool created by a talented schoolboy

■ The diffi cult part came in the automatic mounting of the USB fl ash drive and the process of deleting the old audiobook, copying the new one and refreshing the playlist of the music player daemon (MPD) which Michael used to play the MP3s

www.linuxuser.co.uk26

With her 90th birthday approaching, Michael sought a solution: to build an audiobook player that was inexpensive and easy to operate, with as few buttons as possible. It also needed to be open source. The Raspberry Pi was the answer.

“The idea came quick, but planning it through and building it was kind of fragmented because my work includes travelling,” he says. “When I knew what I wanted, I soldered the button and LED to a board that could be connected via the GPIO pins and then I used a little Python coding and confi guration of standard Linux software for the rest. Being no good coder or expert in electronics, this was the simplest way to achieve my goals.”

The sound quality can crack when you play or resume an MP3. “But,” Michael says, “that is a known problem in the Raspberry Pi community. The quality of the device itself is quite solid, but I’m thinking about building a new, large enclosure out of wood for the player together with the speakers.”

His success? Amazing software that turns a Raspberry Pi computer into a time-lapse camera. By connecting a USB camera to a Pi and running the software, it is possible to fi ne-tune the interval at which it takes pictures.

“My aunt has a motion-sensing camera set up in the woods near their hunting stand. That triggered the idea,” Aaron tells us. “The fi rst thing that I did was to fi nd out how I would get the program to take the pictures… I discovered a command-line program called Streamer, which was in the Debian and Ubuntu repos. I installed it and, after playing around with it, decided that

TRY IT YOURSELFThe Kit: • Raspberry Pi = €40• ModMyPi enclosure = €12• 1 button = €2• 2 resistors (330 ohm, 10 kilo-ohm) = few cents• 1 blue LED = few cents• 1 (slow) 8GB SD card = €8• Some wire = few cents• A pair of speakers – he already had them, rough cost about €30

The Code: We’ve inluded the code on the discThe Knowhow: blogs.fsfe.org/clemens/ 2012/10/30/the-one-button-audiobook-player

TRY IT YOURSELFThe Kit: • PySnap software• USB cameraThe Code: Aaron’s code is on the discThe Knowhow: www.raspberrypi.org/archives/2544

MAKER PROFILE: MICHAEL CLEMENS

Fascinated by electronics and mechanics from childhood, Michael began work as an IT apprentice and worked seven years as a UNIX and database administrator before becoming an IT security consultant.

MAKER PROFILE: AARON HILL

Aaron Hill is a 12-year-old schoolboy who loves to program and is very knowledgeable about computers.

As for how well the present was received, Michael laughs. “It was Christmas and she was obviously confused about all the people around her. On another day, we showed her how to use it and she was very happy about it.”

I would use it for my project. Next, I started writing the actual code. I started off with just adding the option to choose different time intervals: seconds, minutes and hours. Later I got the idea to allow taking of pictures on a specifi c day, and a specifi c time.”

One feature he initially liked but ended up discarding was having the program print out text one character at a time, instead of all at once. The effect wasn’t very noticeable with a fast speed, and irritating to the user if it was slower, he says. And although he didn’t have the GUI ready in time for the content, there was enough to prove that Aaron was very much on to a good thing.

The one-button Music to a grandma’s ears… it’s the easy-to-use audio playerMusic to a grandma’s ears… it’s the easy-to-use audio playerMusic to a grandma’s ears…

018-029_LUD_123 PK.indd 26 25/01/2013 17:16

Page 27: Linux User & Developer - Bpfine

Being able to control the real world using a computer is the sort of thing that we wanted back in the mid-Eighties when watching Back To The Future. There have been lots of solutions for this issue, but none has been as cost effective and wide open as the Pi-Face Digital Interface created by scientists at Manchester University.

“I’d been working on getting more people interested in computing for a few years,” explains Dr Andrew Robinson, the brains behind the device. “I was really excited to hear Raspberry Pi was coming along, but worried that people wouldn’t know what to do with it. I saw the interface as a missing link, to allow people to put the Raspberry Pi where they

Pi-Face - the digital interfaceLet the Raspberry Pi be the hub to your digital life

wouldn’t put a PC and connect it up to the world. So I designed Pi-Face to be ready for when the Raspberry Pi came out, and planned some fun activities – like the twittering chicken.”

The fi rst design was published on 15 December 2011 and the interface board is the same size as the Raspberry Pi. It slots onto the GPIO pins and has screw terminals so it’s very easy to connect up switches to sense things and lights/motors for the Raspberry Pi to control. It’s very easy to program in Scratch or Python too. It’s not just about the interface, either. The project is also about creating the fun activities and tutorials to support using the Raspberry Pi.

“It took four prototypes to get right,” says Dr Robinson. “The fi rst one has a yellow wire tacked

■ Pi-Face integrates with existing tools already prevalent in the classroom, such as Scratch and Python. A range of class activities are planned

■ The hardware architecture was altered during the project so that it would work with mobiles (with Android and USB OTG) and desktop PCs too. It works with Raspberry Pi through SPI, but also through USB

on because a connection got missed. It was a bit like the early Raspberry Pis that also had bits of wire tacked on by hand.”

Apart form that, it has all gone rather smoothly, however. “The interface has been designed to take some abuse since it’s targeted at beginners,” he adds. “We’ve connected things up wrongly a few times, but so far not seen any smoke! On the workshop side of things, the children have really loved it. We have a harder time when we run the workshops for teachers! Still we’ve learned from it.”

www.linuxuser.co.uk27

The interface has been designed to take some abuse

since it’s targetedat beginners

MAKER PROFILE: DR ANDREW ROBINSON

Andrew Robinson can trace his fi rst interest in electronics back to making a model lighthouse aged fi ve.

At the University of Manchester, Andrew did a PhD in low power processor architectures (which included looking at ways to make ARM processors more effi cient). While working in the group Andrew became interested in ‘public engagement’, to get more people interested in Computer Science.

The interface and software is being used all over the

world for robots and a central heating

controller, for example

The Pi-Face is credit card sized and it stacks on top of Raspberry Pi. It is buffered to protect the Pi

TRY IT YOURSELFThe Kit: Pi-Face is available complete from Farnell for £20, which is cheaper than buying the parts separately – piregistration.element14.com/signup.htmlThe Knowhow: pi.cs.man.ac.uk/interface.htm

Top Raspberry Pi projects to amaze and inspire10 amazing Raspberry Pi projects

FEATURE

RasPi 1st BIRTHDAYSPECIAL

018-029_LUD_123 PK.indd 27 25/01/2013 17:16

Page 28: Linux User & Developer - Bpfine

Feature 10 amazing Raspberry Pi projects

It’s hard to say what is more amazing – the photographs taken high up in space or Dave Akerman’s Raspberry Pi/webcam/GPS/hydrogen balloon combination which enabled him to capture such magnificent shots.

Not only are they believed to be the highest ever photographs transmitted live from an amateur device, the ability to thrust a Raspberry Pi into space is an amazing feat. And it barely took Dave any time at all to figure out, making it all the more extraordinary.

“The idea to combine the Pi and a weather balloon came after I took delivery of the Pi,” he tells us. “I ordered it just because I was curious, and didn’t really have any use planned for it. By then I’d been flying weather balloons with Arduino trackers for about a

Pi in the sky - 40km high photographyA record-breaking balloon mission records stunning near-space photos

year, and thought that it would be fun to fly the Pi instead. The Arduino is ideal as a basic tracker, but the Pi does make it much easier to add things like live picture downloads.”

It took about an hour to wire up a radio transmitter and GPS, and another hour to port Dave’s Arduino code over to the Pi. At that point he had a working Pi tracker and he was keen to fly it just to be the first to do so. But the weather remained poor and he couldn’t launch for two weeks. That gave him time to add some more capability.

“Adding a live image download was obvious, since the Pi can interface very easily to a USB webcam,” Dave says. “It was a couple of days’ work to get that working. After that I had to make a regulator so the tracker could run from batteries.”

He kept quiet about his project because he wanted to do it before anyone else. He didn’t say when the launch was planned either. “The launch itself was fairly stressful – as they usually are – but particularly this time because it was a new tracker and the first time I’d transmitted live images,” he admits. “I had two trackers to get ready, one as a backup, and a friend added his payload with a GoPro camera. So it was quite a complex launch and it made an impressive sight as it went up.”

n Above is the radio transmitter for sending data back, while below it is the GPS receiver

n This is the power regulator to reduce the battery voltage to 5V for the Pi. This became warm and David now uses an improved version

n In the future, Dave wants to use the forthcoming Pi camera: “That will mean I can record high-definition images and video”

Try IT yourSelfThe Kit: • raspberry Pi = £25• NTX2 radio transmitter = £25• Webcam = £13• lassen IQ GPS receiver and antenna = £30

• 1200g Hwoyee balloon = £70• Gas cylinder (Helium = £80)• Parachute = £30• 6x energizer AA lithium = £8• yupiteru radio scanner = £80• radio aerial = £15• Plus polystyrene foam, duct tape, nylon cord

The Knowhow: www.daveakerman.com/?p=592 www.ukhas.org.uk

MAker ProfIle: Dave aKerman

David Akerman is a high-altitude ballooning enthusiast who hit the headlines when he tethered a raspberry Pi, complete with a webcam to photograph its progress, to a helium balloon.

“I’m just about young enough to be a space cadet. I remember staying up when I was a kid to watch the

first shuttle launch. Dave Akerman was sending down images from 40 kilometres up. That is wonderful”

www.linuxuser.co.uk28

018-029_LUD_123 PK.indd 28 25/01/2013 17:16

Page 29: Linux User & Developer - Bpfine

This offi ce missile launcher is an inventive use of the Pi and while not original (the inspiration came from https://github.com/codedance/Retaliation#readme), the portable nature of the Pi has proved a perfect fi t. “The original project had a few limitations,” says Nathan Byrd. “Using a full computer for this project

Brew beer with BrewPi

Retaliation-inspired mobile missile launcher

Relax with a cool beer (and maybe a pie) thanks to the magic of the Pi

This simple foam-missile project is a great way to inspire young coders

■ The Pi offered a great alternative for the original BrewPi (called UberFridge). The Pi replaced a Linksys WRT54G router fl ashed with open source fi rmware and 16MB of RAM – running a Python script and a web server, it had logged data to a USB memory stick

■ While a powered USB hub can be used (and is recommended), Nathan removed the need for one by soldering across the polyfuses on his early-model Pi (bit.ly/RDIJVe)

Elco had experimented with analog temperature sensors, which were noisy and needed a lot of software fi ltering, so he replaced them with more accurate digital OneWire sensors. He also ditched fl oating-point fi ltering and used fi xed point. BrewPi uses solid-state relays which are safe and quiet. Elco also dropped the idea of a three-button interface in favour of a rotary encoder interface, which is much more intuitive.

Elco Jacobs loves his beer. So much so that he makes his own. What he has found, however, is that a tasty brew can be enhanced using the power of the Raspberry Pi. This capability led to the forming of the BrewPi project with three aims: to control the temperature of his fermenting beers, log temperature data into graphs and the ability to slowly raise or lower the beer temperature.

requires one to be on all the time or at least whenever there are people there to shoot… and greatly limits the placement of the missile launcher. With the Raspberry Pi I could mount it just about anywhere and leave it on all the time without requiring a full computer.”

Nathan bought the Pi to teach his 11-year-old son to program and familiarise him with hardware. Retaliation worked in this regard too: “What 11-year-old, or adult for that matter, doesn’t love shooting foam missiles around the house?” Nathan had to order the missile launcher, then fi nd the packages and software, before testing and documenting the build. Hooking it up without a powered USB hub proved a problem so there was a bit of soldering involved (although that is no longer the case with newer revisions of the Raspberry Pi). And along the way they had to shoot lots of foam missiles at each other.

TRY IT YOURSELFThe Kit: SparkFun Inventor’s Kit for Arduino, a professional kit for Arduino = £83Raspberry Pi = £25The Code: Elco’s code is on the cover discThe Knowhow: brewpi.com

TRY IT YOURSELFThe Kit: • Raspberry Pi (initially he used an early 256M revision with polyfuses) = £25

• Dream Cheeky USB missile launcher = $34.99 (www.dreamcheeky.com/thunder-missile-launcher)

• Powered USB hub = from £14• USB extenders, mounting hardware etc as needed for environment

The Code: You’ll fi nd everything on the DVDThe Knowhow: itr8r.tumblr.com/post/31840231144/raspberry-pi-retaliation

MAKER PROFILE: ELCO JACOBS

Elco Jacobs is a 26-year-old from Eindhoven, the Netherlands, studying electrical engineering at the Technical University of Eindhoven. He likes electronics, design, user interaction and entrepreneurship.

MAKER PROFILE: NATHAN BYRD

Nathan Byrd is a technical consultant in software development with almost 20 years of experience in the fi eld. He lives in Saint Louis, Missouri with his wife and son. Other hobbies include amateur photography and open source software development.

“Things like this let me have thermostatically controlled beer brewing!!”

www.linuxuser.co.uk29

Top Raspberry Pi projects to amaze and inspire10 amazing Raspberry Pi projects

FEATURE

RasPi 1st BIRTHDAYSPECIAL

018-029_LUD_123 PK.indd 29 25/01/2013 17:16

Page 30: Linux User & Developer - Bpfine

Start a direct debit today and for just £25.15 get the next six issues – saving over £23 a year■ Pay only £4.19 every issue■ Free UK delivery to your door■ Never miss an issue■ Money-back guarantee

FANTASTIC SUBSCRIBER OFFER

SUBSCRIPTION VOUCHER■ YES I would like to subscribe to Linux User & DeveloperYOUR DETAILSTitle First name Surname Address Postcode Country Telephone number Mobile number Email address

DIRECT DEBIT PAYMENT■ UK Direct Debit Payment Pay only £25.15 every six issues (save 30%)

PAYMENT DETAILSYOUR EXCLUSIVE READER PRICE, ONE YEAR (13 ISSUES)

■ UK: £62.40 (Save 20%) ■ Europe: £70.00 ■ World: £80.00Cheque■ I enclose a cheque for £ (made payable to Imagine Publishing Ltd)

Credit/Debit Card■ Visa ■ MasterCard ■ Amex ■ Maestro

Card number Expiry date

Security number ■■■ (last three digits on the strip at the back of the card)

Issue number ■■ (if Maestro)

Signed

Date

Code: PAG123 ■ Tick this box if you do not wish to receive any promotional material from Imagine Publishing Ltd ■ Tick this box if you do not wish to receive promotional material from other companies. Terms & Conditions apply. We publish 13 issues a year, your subscription will start from the next available issue unless otherwise indicated. Direct Debit guarantee details available on request. This offer expires without notice.

I would like my subscription to start from issue:

Return this order form to:

Linux User & Developer Subscriptions Department, 800 Guillat Avenue, Kent Science Park, Sittingbourne, ME9 8GU or email it to [email protected]

You will be able to view your subscription details online at www.imaginesubs.co.uk

Please complete your email address to receive news and special offers from us

HURRY

ORDER NOW

Instruction to your Bank orBuilding Society to pay by Direct Debit

Signature(s)

Date

Bank/Building Society account number

Banks and Building Societies may not accept Direct Debit instructions for some types of account A6 instruction form

Instructions to your Bank or Building SocietyPlease pay Imagine Publishing Limited Direct Debits from the account detailed in this instruction subject to the safeguards assured by the Direct Debit guarantee. I understand that this instruction may remain with Imagine Publishing Limited and, if so, details will be passed on electronically to my Bank/Building Society

Branch sort code

Originator’s Identification Number

Name(s) of account holder(s)

To: The Manager Bank/Building Society

Address

Postcode

Reference Number

5 0 1 8 8 4

Name and full postal address of your Bank or Building Society

Please fill in the form and send it to: Linux User and Developer Subscriptions Dept, 800 Guillat Avenue, Kent Science Park, Sittingbourne ME9 8GU

030-031_LUD123 PK.indd 30 25/01/2013 17:32

Page 31: Linux User & Developer - Bpfine

1. Onlinewww.imaginesubs.co.uk/ludAnd enter PAG123

2. Telephone0844 249 0282And quote PAG123

3.Post or emailPlease complete and post the form toLinux User & Developer Subscriptions Department800 Guillat AvenueKent Science ParkSittingbourne ME9 8GU

Or alternatively, you can scan and email the form to

[email protected]

THREE EASY WAYS TO SUBSCRIBE

and save 30% off the shop price

SUBSCRIBE TODAY TO

Readers in the US see page 84 for exclusive

offer

030-031_LUD123 PK.indd 31 25/01/2013 17:32

Page 32: Linux User & Developer - Bpfine

www.linuxuser.co.uk32

Open source genealogy with GrampsTutorial

Genealogy is a very popular hobby with people all around the world. If you pick up any of the genealogy magazines at your local bookstore, they will cover Windows programs that are available. But no one seems to have realised that people who use Linux are also interested in researching their family trees. While there have been text-based programs to work with GEDCOM files, there hasn’t been a really complete GUI program until Gramps came onto the scene. With Gramps, you have all of the functionality available

that Windows users have enjoyed for some time. Gramps is written in Python and is designed with a plug-in architecture. This means that you can rather easily write your own plug-in to add any specialised functionality that isn’t provided through a base installation. In this article, you’ll see how to get started on your family tree, analyse the data that you have collected, and generate reports that you can print and share with others. You’ll also learn how to share the data you have collected through GEDCOM files.

ResourcesGramps: gramps-project.org

This panel provides quick access to all the various sections, like people, events, places and media entries

You can find details for the item you select above. The tabs that are available depend on what type of object you are looking at

If you have many entries, you can filter down to a manageable subset by selecting filter criteria here

The centre panel will show lists of whatever object type you have selected in the left side panel, like a list of people if you select the ‘People’ entry

Genealogy is a fun hobby for many people around the globe. While there are lots of programs for Windows, Linux options have been lacking. Gramps helps fill this gap

Open source genealogy with Gramps

AdvisorJoey Bernard As a true renaissance

man, he splits his time between building furniture, helping researchers with scientific computing problems and writing Android apps. When the kids let him have some time, that is

032-034_LUD_123 PK.indd 32 25/01/2013 17:33

Page 33: Linux User & Developer - Bpfine

Use Gramps to research, organise and share your family treeOpen source genealogy with Gramps

TUTORIal

www.linuxuser.co.uk33

01 Getting GrampsGramps should be available in most

Linux distributions. For Debian-based ones, you would install with ‘sudo apt-get install gramps’. There are Windows binaries available, if you want to get your friends hooked on Gramps, too. As always, the source is available if you would rather compile your own copy.

02 Create a new treeThe first step, once you have Gramps,

is to create a new family tree. This can be considered almost like a project, for the software developers out there. A family tree will contain all of the information relevant to a single lineage going back in time.

03 add a new personA family tree is of little use without

people. So, the next step is to add your first person. If you are doing your own family tree, you may as well start with yourself. Clicking

04 Setting the home personTo generate charts and reports from all

of this data, you will need to set a ‘home person’ who will act as the root of the family tree. Again, if you are doing your own family tree, it would make sense to select yourself. To do so, you will need to select the People entry on left-hand side of the screen. Then select the person from the list, and click on Edit>Set Home Person from the main menu.

07 adding a spouseStaying in the Relationships section, you

can click on the ‘Add a new family’ icon to create a new family with this person as a parent. You can then either add an existing person or create a new person as the spouse.

06 adding parentsClick on the Relationships entry on the

left-hand side. This will open the relationship section for the selected person. You can add parents to this person by clicking on the plus icon in the top bar. You can either add existing people or create new people, for the father and mother.

09 adding childrenBefore closing the New Family dialog, you

can also add any children. Clicking on the Children tab in the bottom section will allow you to add either existing people or new ones as children of this family unit.

05 adding birth InformationDouble-clicking a person from the list

will reopen the Edit dialog. At the bottom, you can add events to the person’s record. Arguably the most important event is their birth. To add an event, click on the plus icon in the event section.

08 Setting marriage InformationWhile the New Family dialog is open, you

will need to click on the Event tab in the bottom section. Click on the plus icon to add a new event, selecting Marriage as the type. You can then set the date and location.

on the plus sign in the icon bar will bring up a dialog box where you can enter all of the relevant information.

032-034_LUD_123 PK.indd 33 25/01/2013 17:33

Page 34: Linux User & Developer - Bpfine

www.linuxuser.co.uk34

11 Adding and editing placesEvents take place somewhere in the real

world. When you add a new event, you can select a place where it happened. After you have added a place to an event, you can edit the details by clicking on the Places link on the left-hand side and selecting the place of interest.

14 Adding notesAll of the objects in Gramps can have

notes attached to them. This allows you to add extra information to items like photos that have been added, places of importance, sources of information. You can edit details of these notes by clicking on the Notes link.

You can generate a full website, with navigation, of all of your genealogical information

15 Displaying your ancestral chartNow that you have all of your information

entered into Gramps, you can start to see what your family tree looks like. There are many charting functions available in Gramps. They are available under the Reports menu item. The

13 Adding mediaIn this age of digital media, it is easier than

ever to add a new dimension to your research. You can add media objects (eg image files, videos) to your family tree. Once added, they can be linked through references to events and people.

usual chart that you will likely want to look at is the ancestral chart. This shows all of your direct ancestors in the classic family tree form. Clicking on the menu item Reports>Graphical Reports> Ancestor Tree will open a dialog window. Here, you can select how many generations to display and presentation details.

12 Adding sourcesYou can add sources to your family tree

by clicking on the Sources link on the left-hand side. You can add a new one by clicking the plus icon and filling in all of the relevant information. Recording where you get your information is a very important part of research.

Open source genealogy with GrampsTutorial

10 Editing eventsYou have used events to add information,

like births and marriages. There are many built-in event types when you install Gramps, covering most areas of life. You can edit the details of any of these events by clicking on the Events link on the left-hand side.

16 Displaying a fan chartAnother common way of visualising your

ancestors is by using a fan chart. You can select the number of generations to look at, and several display options. These graphs are interactive, allowing you to move around in your history.

032-034_LUD_123 PK.indd 34 25/01/2013 17:34

Page 35: Linux User & Developer - Bpfine

www.linuxuser.co.uk35

20 Exporting a GEDCOM fi leThe standard fi le format for genealogical

information is called GEDCOM. There are several versions around, the latest one being 5.5. Gramps exports to the latest version. This is how you can share the information you’ve collected with other researchers.

21 Checking an importYou can also import data from a

GEDCOM fi le. Sometimes these fi les may have errors in them. You can check the imported data by clicking on the menu item Tools>Family Tree Repair>Check and Repair Database. This will check several possible problems in your data.

23 Locating duplicatesOne common issue, especially when

importing data from other sources, is having duplicate entries in your database. Clicking on

24 Getting a full bookYou can generate a full book report

containing all of the information you have collected. Clicking on Reports>Books>Book Report will open up a window where you can select which items to include. Each of these elements can be confi gured individually. Once everything is ready, you can click on ‘OK’ to get output in either an ODT fi le or a PDF fi le.

18 Looking at a timelineYou can generate a timeline of events

throughout your history. Clicking on Reports>Graphical Reports>Timeline Chart will open a new dialog where you can set the options. By default, it will create an OpenDocument fi le, but this can be changed to one of several other fi le formats.

22 Verifying your dataYou may also need to verify the actual data

itself. Do you have a 200-year-old relative? Do you have someone who has kids that are older than they are? Clicking on Tools>Utilities>Verify the Data will bring up a dialog window where you can set the parameters to use in the verification.

17 Generating a calendarWith the power of Python, you have the

ability to do very complicated processing. One of the included plug-ins allows you to generate a calendar of important dates, like birthdays and marriage anniversaries. You can generate a calendar by clicking on Reports>Graphical Reports>Calendar.

19 Generating a websiteYou can generate a full website,

with navigation, of all of your genealogical information. You can choose how much information gets exported, and details of the formatting. You can set the stylesheet that is used for the display. You can even export the whole thing into a gzipped tarball.

Use Gramps to research, organise and share your family treeOpen source genealogy with Gramps

TUTORIAL

Tools>Family Tree Processing>Find Possible Duplicate People will bring up a dialog box where you can set the sensitivity. Then it will search through the data for possible matches.

032-034_LUD_123 PK.indd 35 25/01/2013 17:35

Page 36: Linux User & Developer - Bpfine

Want to use the Linux Mint desktop environment, but partial to a different operating system? We show you how to get Cinnamon on some major distros

Put Cinnamon on your distro

www.linuxuser.co.uk36

Put Cinnamon on your distroPut Cinnamon on your distroTutorial

thanks to a very smartly designed, traditional layout. The layout utilises the best parts of GNOME, namely the search function and keyboard shortcuts, with a familiar and easy-to-use interface for mousing around.

Not every Linux distro comes with Cinnamon by default. However, some have it readily available in the repository, or can have it added via other means. In this tutorial, we’ll show you how to get Cinnamon added to a number of major distros, and throw in a few essential tweaks as well.

Every time GNOME gets an update, more and more people seem to be complaining and ultimately switching from the once ubiquitous desktop environment to any number of alternatives. At the same time, one of the most popular Linux distributions in the world debuted its own homegrown desktop, as Ubuntu adopted Unity amid groans and complaints from fans and users alike.

Recently, Linux Mint’s Cinnamon desktop has been stealing the limelight from previous popular alternatives, such as LXDE or KDE,

A mixture of the KDE and GNOME 2 menu also includes a great search function

The panel shows you what windows you have open, unlike GNOME 3

There’s plenty of ways to add extra

bits of information and navigation

with applets

Cinnamon is also highly customisable

by default, and is extendable with

plenty of extensions

Cinnamon source: https://github.com/linuxmint/Cinnamon

Resources

AdvisorRob Zwetsloot models

complex systems and is a web developer proficient in Python, Django and PHP. He loves to experiment with computing

036-039_CinnamonTutorial_LUD_123 PK.indd 36 25/01/2013 17:36

Page 37: Linux User & Developer - Bpfine

Use the Cinnamon desktop environment with any major distroPut Cinnamon on your distro

TUTORIal

www.linuxuser.co.uk37

01 For starters… Remember, once you’ve installed

Cinnamon, you’ll need to log out and select it from the Session’s menu of your login/display manager before you log back in. It will show up as Cinnamon, and don’t worry about the GNOME options it might add.

02 Mint MaTEHere’s a simple one to start off with

– if you got the MATE version of Linux Mint and want to try out Cinnamon, you can easily install it either via the Software Centre, or in a terminal like so:$ sudo apt-get install cinnamon

03 Cinnamon FedoraCinnamon is included in the Fedora

repos, and once you find the package manager or a terminal somewhere in GNOME, you can either search for it, or install it with:$ sudo yum install cinnamon-destopThe install is fairly quick, and in Fedora 18 it’s looking a lot better.

05 CinubuntuOnce that’s finished, you can install

it from the terminal you’re using by first of all updating your package list with:$ sudo apt-get update…followed by:$ sudo apt-get install cinnamon

06 Ubuntu tipIn Ubuntu 12.10, if you have too many

desktop environments and too low a resolution monitor, you may not be able to click the Accept button to switch session. The trick to this is to key down with an arrow until you get to where Accept is, and hit Return.

07 openSUSE GNOMEThe first step to getting Cinnamon

onto openSUSE may sound a little odd – you need to install GNOME first. To do this, open the package manager and install GNOME 3.4. If you’re already running the GNOME spin, then you can continue to the next step.

08 openSUSE sourcesOnce you have GNOME installed, you

can add the repos you need by entering this in the terminal:$ sudo zypper ar http://download.opensuse.org/repositories/X11:/Cinnamon:/GNOME34/12.2/X11:Cinnamon:GNOME34.repoUnless you have an update or installation going, you can tell openSUSE to quit the PackageKit.

09 CinnamonSUSETo install Cinnamon, first refresh your

package list with:$ sudo zypper refreshYou can choose whether to trust the new repo temporarily or permanently. Follow that up with the installation command:$ sudo zypper in cinnamon…and you’re done!

04 Ubuntu repositoryCinnamon is not included in the

standard Ubuntu repos, but no matter what the reason for that is, you can simply add the official Cinnamon PPA using the following:$ sudo add-apt-repository ppa:gwendal-lebihan-dev/cinnamon-stableAgree to the prompt to add the PPA.

10 Debian distributionsYou can easily create a DEB binary to

work in any Debian-based distribution. First you’ll need to install dpkg-dev so you can download dependencies for other packages. Do this with:$ sudo apt-get install dpkg-dev

036-039_CinnamonTutorial_LUD_123 PK.indd 37 25/01/2013 17:36

Page 38: Linux User & Developer - Bpfine

www.linuxuser.co.uk38

Put Cinnamon on your distroTutorial

11 Cinnamon dependenciesNow that dpkg-dev is installed, you

can install the necessary dependencies with the following:$ sudo apt-get build-dep muffin…followed by:$ sudo apt-get build-dep cinnamonBoth will take a little while to download all the necessary packages.

12 Cinnamon sourceYou can get the source for Muffin and

Cinnamon from Git to build your DEB. First create a project folder with:$ mkdir CinnamonSourceThen sync the sources for Muffin with:git clone git://github.com/linuxmint/muffin.git…and Cinnamon like so:git clone git://github.com/linuxmint/Cinnamon.git

13 Compile MuffinUse cd to move into the Muffin folder we

downloaded in the project directory, and build the DEB binaries with:$ dpkg-buildpackageIt will take a while, but it will automatically compile you the correct packages to install.

16 Cinnamon MageiaWhile it’s definitely not recommended,

if you’re desperate to get Cinnamon in Mageia without compiling, the RPM binaries from Fedora will install and work. Long term, though, it’s not the best solution. The Mageia devs are currently considering adding the DE officially to the repos.

17 Arch CinnamonThere is a specific Arch Linux remix

called Cinnarch that already exists, but if you want to install it to an existing Arch system, you can find the source in AUR at:h t t p s: //a ur. a r c hlin u x .o r g /p a c k a ge s .php?ID=55330Download the tarball, makepkg, and then install with pacman to add it to your system.

Now we’ve built Muffin, we can actually build Cinnamon itself

14 Install MuffinMove back up to the working directory

with this command:$ cd ..Here’s where all the DEBs are you just made. The best thing to do is install of them using:$ sudo dpkg -i *.debAt the very least, though, install: libmuffin-dev, gir1.2-muffin-3.0, libmuffin0, muffin and muffin-common.

15 Build CinnamonNow we’ve built Muffin, the window

manager for Cinnamon, we can actually build Cinnamon itself. Move into the Cinnamon directory using cd, and start the process with:$ ./autogen.shThis will quickly get things set up to compile. You can create your DEB files by again using:$ dpkg-buildpackageThis shouldn’t take as long as the Muffin compiling. Once it’s done, cd back up again, and install the Cinnamon DEB with:$ sudo dpkg -i cinnamon[version and architecture].debLog out or reboot, and then select it from the session manager.

036-039_CinnamonTutorial_LUD_123 PK.indd 38 25/01/2013 17:37

Page 39: Linux User & Developer - Bpfine

www.linuxuser.co.uk39

Use the Cinnamon desktop environment with any major distroPut Cinnamon on your distro

TUTORIAL

19 Cinnamon appletsYou can add extra features to the panel

with the applets selector. To fi nd this, click on the up arrow next to the Network Manager, click Settings, and go to Applet. From here you can add buttons to click between workspaces, a shortcut link to monitor settings, and accessibility.

21 Cinnamon cornerLike GNOME 3, you can move the

mouse to the top left of the screen and zoom out to preview the workspaces. You can turn this function on or off, and move the location in the Cinnamon Settings. The Cinnamon Settings menu is automatically added to the left side of the Cinnamon Menu.

23 Cinnamon spinMore and more distributions are adding

Cinnamon to the repos, and there are some that come with Cinnamon spins for Cinnamon by default. Next time you need to reinstall a system and want to go with Cinnamon, look for such distros as Cinnarch, Snowlinux and more in the future.

24 Cinnamon everywhereNow you’ve got Cinnamon running,

play about with it. While every environment has its own quirks and can take a little bit of getting used to, Cinnamon should be familiar to anyone. Over the past year it’s got better and better, and we’re looking forward to the next year of updates.

20 Cinnamon spacesBy default, there are two workspaces

in Cinnamon, which can be accessed with the applet, or by using Ctrl+Alt+Left or Right. To add or remove workspaces, press Ctrl+Alt+Up, and press the ‘+’ button on the right side, or click X on the spaces. You can also use this mode to preview spaces and switch between them with a mouse.

22 Turbo CinnamonA quick and easy way to speed up

Cinnamon if you’re using a slightly older or low-powered system is to turn off the desktop effects. These are also found in the Cinnamon Settings under the Effects menu.

18 Cinnamon GentooCinnamon is actually available in the main

portage tree for Gentoo, and can be found here:http://packages.gentoo.org/package/gnome-extra/cinnamonMake sure to use the latest build, as older ones are unstable on x86 and x86_64 systems – you know, the kind you’re most likely using.

036-039_CinnamonTutorial_LUD_123 PK.indd 39 25/01/2013 17:37

Page 40: Linux User & Developer - Bpfine

www.linuxuser.co.uk40

Protect your network with SnortTutorial

AdvisorMichael Reed is a technology

writer and he’s been hacking away at Linux for over 15 years. He specialises in desktop Linux solutions

Whether meaning to be mischievous or malicious, hackers can wreak havoc on your network. Fortunately, Snort makes it easy to spot them and set up protection

Protect your network with Snort

Snort runs on single machine, but can monitor an entire network

Snort has one main configuration file, but it comes with sensible defaults for most scenarios

You can visit the website to grab the rulesets

Snort will sit on the network and output attack logs in a variety of formats

Snort is an intrusion detection system (IDS). It works by monitoring network activity and raising an alert in the case of suspicious activity. What constitutes suspicious activity is definable by rules, and it comes with a massive selection. It can protect a single machine from attacks or even an entire network. This guide will show you how to set up and use Snort and also take you through some typical security scenarios in which Snort will prove useful.

As you get to know Snort, you might consider setting up a testing environment using virtual machines. A simple approach would be to use a virtual machine that has its network adaptor configured to be visible on your network (the setting is called ‘bridged adaptor’ in VirtualBox, for example). The techniques outlined here are not dangerous, but they can be considerably easier to get working within a controllable environment.

ResourcesSnort: www.snort.org

The Snort manual: www.snort.org/start/documentation

A second network card (optional)

040-043_LUD_123 PK.indd 40 25/01/2013 17:39

Page 41: Linux User & Developer - Bpfine

Use the Snort intrusion detection system to log and block attacksProtect your network with Snort

TUTORIal

www.linuxuser.co.uk41

01 Install SnortInstall Snort with ‘sudo apt-get install

snort’. If you need the very latest version, visit the website and fetch, build and install it.

02 Set Up a ‘quiet’ network environment

When first setting up Snort, it helps to have as little activity on the network as possible. Disconnect other computers or even set up a VM with a bridged adaptor which you can operate upon from the host machine.

03 Test Snort installationNearly all Snort operations need to

be carried out by the root user. On Ubuntu, it’s probably worth using ‘sudo -i’ to avoid password prompts. Use ‘su’ on other distros. As root, type ‘snort -v’. This puts Snort into packet sniffer mode.

04 Create network activityPresuming that the network you are on is

reasonably quiet, you can generate some network activity by pinging the server. Open another terminal and type ‘ping [IP address of server]’, and cancel after a couple of successful pings. Now, go back to the terminal with Snort running.

05 Interpreting the dataIn this example, the ping activity is

reported in entries that end with lines ‘ECHO’ and ‘ECHO REPLY’. You may have to scroll back in the terminal to see these entries. Notice that the entries contain the time that the activity occurred and the source and destination of the traffic.

07 More detailHere’s a more extensive command line:

‘snort -vde’. This produces more output due to the d (display packet data) and e (application layer). For example, if you fetch POP email without SSL selected, you’ll be able to see the username and password scroll past.

06 Exiting SnortExit Snort by hitting Ctrl+C. When you

exit Snort, it prints a statistical summary of the traffic that it observed. In this example, there should have been some ICMP traffic from the ping operation.

09 Back up Snort configuration fileSnort comes with a default configuration

file which we will back up. Type ‘locate snort.conf’ to find the file and then make a copy of it. ‘cp /etc/snort/snort.conf /etc/snort/snort.conf_old’ should work for Ubuntu, for example.

08 log packet dataMake a directory called ‘snort_logs’.

Now run ‘snort -d -l ./snort_logs’ and Snort will log all recorded traffic into the log directory with a separate file for each interface. We’ll skip the verbose flag (-v), as all of the screen output eats into Snort’s throughput.

040-043_LUD_123 PK.indd 41 25/01/2013 17:39

Page 42: Linux User & Developer - Bpfine

www.linuxuser.co.uk42

16 Confi gure promiscuous modeAdd the following lines to the fi le: ‘iface

eth1 inet manual’, ‘up ifconfi g $IFACE 0.0.0.0 up’, ‘up ip link set $IFACE promisc on’, ‘down ip link set $IFACE promisc off’, ‘down ifconfi g $IFACE down’. Type ‘sudo ifup eth1’ to start up the second Ethernet adaptor and physically plug it into your router, hub or spanning switch.

10 Initial confi gurationOpen the confi g fi le in a text editor. For

now, make sure that the variable ‘HOME_NET’ accurately describes your network. For example, if your computers have IP addresses that begin at 192.168.0.1, set it to 192.168.0.1/24.

11 Create launch scriptMake a startup script to save time.

Create an empty fi le with ‘nano start_snort’, then add the line ‘snort -de -l [full path to script]/snort_logs -c /etc/snort/snort.conf’ to it, and then save. Now type “chmod +x start_snort”. This will launch snort in IDS mode, with reasonable defaults.

12 Intrusion detection modeFirst, fi nd the IP address of the machine

running Snort by using ‘ifconfi g’ and make a note of it. Now run ‘./start_snort’. Some extra startup information scrolls past as we are now using the Snort confi guration fi le and the rules fi les that it references.

13 Simulate an attack (Nmap)We’ll begin by carrying out a port scan

on the machine running Snort using Nmap, a common fi rst step in a typical intrusion attempt. From a different machine on your network, type ‘nmap [IP address of Snort machine]’. A fi le called ‘alert’ should have appeared in the log folder. Examine it.

14 Automatically start SnortThe method to launch a script at startup

varies between distributions. On Ubuntu, simply add our ‘start_snort’ script to ‘/etc/init’ by typing ‘ln start_snort /etc/init/’. Remember to use fully qualifi ed path names in the script.

17 Test promiscuous modeType ‘ifconfi g’ and eth1 should be listed

without an IP address. Now add ‘sudo ifup eth1’ to your Snort startup script along with the fl ag ‘-i eth1’ on the Snort launch command. When launched, Snort will now monitor all traffi c on your network.

network adaptor on your server. This is because the network card must be put into promiscuous mode to capture all traffi c being transmitted, and this is the scenario we will work with here. Once you have installed the second card and rebooted the machine, determine the naming of the two network interfaces by typing ‘ifconfi g’. In this example, the second network card is called ‘eth1’. Now open ‘/etc/networking/interfaces’ in a text editor.

Protect your network with SnortTutorial

We’ll begin by carrying out a port scan on the machine running Snort

15 Protect the networkProtecting an entire network requires

either a dedicated Snort machine or a dedicated

040-043_LUD_123 PK.indd 42 25/01/2013 17:39

Page 43: Linux User & Developer - Bpfine

www.linuxuser.co.uk43

19 Test simple ruleLaunch Snort with ‘snort -dev -l ./snort_

logs -c /etc/snort.conf’. From another machine, type ‘telnet [IP address of Snort machine]’. If everything has worked, you should now have an update in the alert file. See the Snort manual for a full breakdown, but open the file and check that source IP and destination IP look correct.

20 Fetch extra rulesGet extra rules from the Snort website

(free sign-up required). They belong in ‘/etc/snort/rules’ and should be enabled using the ‘include’ directive in snort.conf. The comprehensive selection is an excellent starting point for creating your own rules for dealing with, for example, application-specific exploits.

21 Add CSV output moduleUnless you know that you are going

to have to use Snort alert logs as input for another networking utility, consider switching it to CSV output so that you can view the data in a spreadsheet. Simply add the line ‘output alert_csv: alert.csv default’ to the end of the configuration file.

23 Block an attack (part 1)Block the IP address of the attacker as

reported in the alert file. Obviously, the address can change, but they tend to be fairly static from the most common type of automated attacks. Use the command ‘iptables -A INPUT -s [attacker IP address] -j DROP’.

24 Block an attack (part 2)It’s possible that an attack is targeting

an unused or unimportant port on your network. Use ‘/iptables -A INPUT -p tcp --destination-port 80 -j DROP’ to block a port, if you have determined that it will not harm the normal function of your system. To unblock a port or IP address, use the ‘-D’ switch instead of ‘-A’.

18 Create a simple Snort ruleFor the sake of simplicity, we are going

to add a rule to the configuration file rather than create a new rule file. As root, open up snort.conf in a text editor. On the final line of the configuration file, add the following line: ‘alert tcp any any -> any 23 ( msg: "telnet alert!"; sid: 1; )’.

22 Interpreting an attackWhen an attack is logged, begin by

looking up the IP address with the ‘whois’ command or by using an online geographic IP lookup address. Note the port number of the attack to try to figure out the service or application that is the focus of the attack.

Use the Snort intrusion detection system to log and block attacksProtect your network with Snort

TUTORIAl

040-043_LUD_123 PK.indd 43 25/01/2013 17:40

Page 44: Linux User & Developer - Bpfine

facebook.com/webdesignermag twitter.com/webdesignermag

DESIGN INSPIRATION BEHIND THE SCENES STEP-BY-STEP ADVICE

BUY YOUR ISSUE TODAYPrint edition available at www.imagineshop.co.uk

Digital edition available at www.greatdigitalmags.com

Available from all good

newsagents and supermarkets

ON SALE NOWDevelop with Spotify | Build a WordPress plug-in | Create 3D e� ects

DESIGN INSPIRATION

BUY YOUR ISSUE TODAY

STEP-BY-STEP ADVICE

BUY YOUR ISSUE TODAY

PRACTICAL TIPS INDUSTRY OPINION

BUILD A BETTER WEBwww.webdesignermag.co.uk

Available on the following platforms

WebDesigner_House ad_new.indd 2 22/01/2013 14:05

Page 45: Linux User & Developer - Bpfine

45 www.linuxuser.co.uk45

CelebratingAn exclusive interview with Pete Lomas and Eben & Liz Upton

The only Linux magazine for open source developers

We had the profile of a large

electronics company before

we shipped a single unit

Page 56

Wine for developersGet your Windows software running under Linux

Page 52

VPN with Raspberry PiConquer the dark art of virtual private networks

100% FOSS focused » Features » Tutorials » Sample code

RasPi Foundation special!

Page 46

life of Pithe

045_LUD_123 PK.indd 45 25/01/2013 17:44

Page 46: Linux User & Developer - Bpfine

www.linuxuser.co.uk46

Celebrating the life of PiInterview

■ Co-founder Eben Upton

■ Pi designer Pete Lomas

RasPi 1st BIRTHDAYSPECIAL

046-51_LUD_123 PK.indd 46 25/01/2013 18:16

Page 47: Linux User & Developer - Bpfine

INTERVIEW

We celebrate the first birthday of the Raspberry Pi with an exclusive interview with its creators covering its first year on sale and goals for 2013

The Raspberry Pi founders talk about its fi rst yearCelebrating the life of Pi

www.linuxuser.co.uk47

In a year when Nintendo was supposed to be taking the plaudits for its latest console; at a time when Apple was expecting punters to lap up its latest tablet and phone; during a period when small-form-factor gaming was going to be the sole preserve of the Sony PlayStation Vita, another machine was gathering column inches.

By the end of 2012, no less than The Independent newspaper was celebrating this underdog as the standout technology innovation of the year. And yet it was not one made by a well-known brand, nor one which had design aesthetics appealing to anyone but in-the-know geeks, nor a device which had dozens upon dozens of games for it.

It was the Raspberry Pi, a computer that’s barely larger than a credit card and which readers of this magazine don’t really need explaining in any greater detail. This computer has the potential to do so much more than any of the aforementioned giants and their kin, and that is because it is as much about ideology as it is about mechanics. And it has been successful, of that there is no doubt. “I really do think that this time last year we were starting to get the idea that we weren’t going to sell 10K of them,” Eben Upton, the co-founder of the Raspberry Pi Foundation tells us. “I think we were starting to get the idea that we were going to sell tens of thousands of units. But I don’t think any of us had imagined that it would come true.”

Gathering together Eben, wife Liz and technical guru Pete Lomas for this interview was not a simple task. Despite Eben’s

Celebrating the

Life of Piincredible work on the Raspberry Pi, he remains technical director and ASIC architect for Broadcom and, during a mammoth email exchange, suddenly had to change plans when he was asked to go to Los Angeles on urgent business.

Liz also has her work cut out. She is the Raspberry Pi Foundation’s only full-time worker – and that entails running the large community which has built up around the device, carrying out PR and communications work, looking after social media, taking photos and getting busy with a soldering iron when needed. On top of that, she is a professional writer and the sole blogger at gastronomydomine.com, which she has had to effectively abandon due to the mammoth Pi workload.

Then there is Pete, trustee of the Raspberry Pi Foundation and designer of the fi nal hardware that turned into the device so many love. But if they are busy, it is for a reason. And Pete just can’t quite believe the ride which has taken place since the fi rst Pi was swallowed up by those eager to buy it on 29 February 2012.

“The pickup from the community has been tremendous and the amount of innovation that has come out of the back of what is a relatively simple piece of kit has been absolutely fantastic,” he says. “The way that they have been able to repurpose it from our original ideas and the way that it just teaches kids how to program and do some basic interfacing has gone stratospheric. I say that literally too, because we’ve had Pis in space.”

The large number of projects for which the Pi has been put to use has been phenomenal

and the team say they still cannot believe the innovation which is evident on an almost daily basis. “Just today I was looking at a post on the blog about water droplet photography which somebody is doing with a Raspberry Pi,” says Liz. “It has been a whole year and pretty much every day there is something which we just haven’t considered. The educational stuff is working brilliantly, but there is also this huge hobbyist maker crowd out there just picking it up and running with and they are brilliant. They are really, really good people.”

One of the biggest challenges for the team has been the sheer demand for the device, and the major breakthrough came when they realised that they needed to create a licensing model for the Pi and have a UK manufacturer produce a high volume of them. The transition from a few thousand to tens of thousands went relatively smoothly in the end thanks to a lot of hard work by many people, and the complex transition has meant they now have a secure manufacturing base to take them forward. There were some bumps in the road – some customers experienced extensive delivery delays – but the biggest promise, which was to remain true to its initial price point, has held fi rm and it is something the Pi team remain committed to.

“That was something that, to be honest, scared me to death in the early days, because it was my responsibility to bring it in at the price points we stated,” says Pete. “It has taken us a

046-51_LUD_123 PK.indd 47 25/01/2013 18:16

Page 48: Linux User & Developer - Bpfine

www.linuxuser.co.uk48

“We had the profile of a large electronics company before we shipped a single unit”

while to get the model made at this price point, but it is now there and will be available very, very shortly at the price point that we stated. There is no doubt in the very early days where we were only making a couple of thousand to 20,000 that we would be struggling, but now we’ve got a user base, we’ve got a perception within the industry and the supplier base that allows us to get volume pricing has made that really achievable.”

The Foundation was keen not to build the Pi on charity. At no point, they say, has anyone been asked to lose money in order to keep the device affordable. “If there is not a commercial story for everyone involved, you are kind of building on sand,” says Eben. “Charity doesn’t scale, so you would get to a point where we might have gone to a component supplier and got a price that they could sustain for 20,000 or 30,000 units and then we would have got to

a point where they were just losing too much money and then they would have had to have jacked the prices up. So you know, the only thing that we ever asked from our component suppliers was, in the early days, that they not penalise us for having low volumes. You know, that they should be prepared to extend to us the kind of pricing that they would give you at a million of, at our initial volumes, which were down in the sort of 10,000 range. Now, of course, we do have those kinds of volumes and it looks much more like a regular commercial business for a lot of people in the supply chain.”

The exposure of the Pi has ensured that the Foundation and its team have been thrust into the limelight of the technology industry. One thing which blindsided them, however, was EMC testing. This is required to confirm that a particular device meets the required standards and it is divided broadly into emissions testing

Celebrating the life of PiInterview

Is Kickstarter pie in the sky?Over the past year, the concept of crowdfunding has become ever more popular, with services such as Kickstarter and Indiegogo attracting much cash for new projects. But would The Raspberry Pi Foundation have gone down that path?

“I can answer that: absolutely not,” says Eben. “No, absolutely no way,” adds Liz. “On some level, if you can get an unsecured interest-free loan from your customers to build the thing you want to build, it is a very appealing concept,” continues Eben. “And I think over the last year we have looked at one or two projects that have [had[ some success in that area and you know, on some level thought ‘Oh my God’ you know, that would have made a lot of problems go away. The reason we didn’t do that was we didn’t want to have that horrible day where you realise that you can’t hit the price point. I have seen projects in the past do this and I think we were very conservative in wanting to make absolutely sure that we’d build a few thousand of these on price before we went out and started taking money off people. I don’t regret having done that. I think it was a good move even if it gave me a lot of sleepless nights.”

RasPi 1st bIRthdaysPeCIal

046-51_LUD_123 PK.indd 48 25/01/2013 18:16

Page 49: Linux User & Developer - Bpfine

The Raspberry Pi founders talk about its first year

IntervIew

www.linuxuser.co.uk49

Celebrating the life of Pi

and susceptibility testing. “We spoke to the government about it, and they said if you sell two boards, two PCBs and you are not EMC tested and you are not CE marked, you are breaking the law,” says Pete. “But they said they had a light touch regulatory regime, which means that in general they don’t get to you until you’ve sold a decent bit of volume.”

This system allows low-volume products to climb up and get to a point where they have got volume in place and they have got revenue coming in the door before they have to jump through some of those compliance hoops. The problem with the Pi’s success, however, was that it was pushed into the spotlight very early on. “We had the profile of a large electronics company before we shipped a single unit,” says Eben. “So this is the reason why we had this horrible thing in March where we had to stall; we had to stop for a couple of weeks and Pete and I were down in Cardiff, EMC-testing these boards and crossing our fingers. All of this was simply because we’d achieved a level of visibility… We stuck our necks out, beyond anything that the actual volumes that we were shipping justified. It was an interesting experience and I think we continue to be surprised by both the level of interest and also the very positive interest that we get. I think people do appreciate that we are trying to do something new.”

A major aim of the Raspberry Pi project has been for education. The team stated early on that this was their driving motivation. The much-loved BBC Micro helped to encourage a generation of programmers and it kick- started interest not just in what computers did but how they achieved it. The bare-bones system of the Raspberry Pi invites young people to play around with the technology and understand the component parts. It also gives them a way to program the device. But is it fair to say that the huge take-up of the Raspberry Pi by adults and hobbyists has had an adverse impact on the number of units available for schools and universities?

“I think there was a backlog with at least one of the suppliers until shortly before Christmas and I think that that has actually impacted some people’s ability, especially outside of the UK, to get hold of them,” says Liz. “So at the moment we are saying about 20 to 25 per cent of them are actually getting straight into the hands of kids now, which is great and although that doesn’t sound like a massive percentage, when you look at that as part of sales of around

800,000 or 900,000 units, that is actually a lot of computers going to kids.”

In the future, the Foundation is keen for after-school clubs to use them, teaching programming in the evenings. “We are seeing lots and lots of pictures from parents of kids sitting in front of the television coding,” says Liz. “Somebody last week sent me some photos of his five-year-old girl actually building games from scratch, so that has been kind of an eye-opener for the whole family. It is just really, really nice to watch with everyone pushing ahead with this stuff.”

Pete admits that getting Pis into schools was always going to be a long haul. An educational manual has been produced and they have taken on board comments from teachers. They have been encouraged by the amount of extracurricular education taking place using the Pi. Talks have been held with exam boards and there is growing interest in computer science in schools. In 2013, the educational

side of the Foundation is going to be running separately from the technical side. And it is already reaping benefits.

“In September, when schools went back, we saw a great big bump in orders because a lot of teachers have been coming in now and outfitting whole classrooms,” says Liz. “We are also sending people out from the Foundation to master classes workshops, so that teachers actually get to be on top of things and [it’s] not as intimidating as some IT teachers think… One thing that I really, really like actually, is that we are seeing all the parents who are engineers, so using the Raspberry Pi as a tool to show their kids what it is that they do at work.”

It is a concept that strikes a chord for Pete, whose father was an electrical engineer. Such father-son bonding led to him becoming an engineer himself. His father would take bits

the Pi StoreLinux User & Developer: What was the thinking behind the Pi Store?

eben Upton: It is important to give non-technical users a route to get more content onto their Pi. One of the nice things about the store is that it provides a way to access all sorts of documentation and tutorials and examples and applications. It does this without having to cross that command-line hurdle on the first day. Obviously we want them to cross the hurdle at some point, but not necessarily on the first day.

LUD: Why have paid content?

eU: It gives kids an opportunity to make a little bit of money. If a child does an interesting thing they can put it up there for free and get respect, you know, get recognition, which was I think a powerful motivator for kids. Or if they want to make a little bit of money, and we’ve always said we want to compete with the paper round, then they can.

LUD: So it’s about empowering children and getting them to recognise their talent?

eU: You know, we want children to think ‘well you know I could go out and do a paper round or I could do this’. Maybe I’m an unusual money-grabbing capitalist, but it was a motivator for me. All of the motivators for me as a child were that there were stories about people, stories in the press about young people who had been able to make a bit of money using computer programming ability.

LUD: Were you pleased that Blitz Games is behind the Pi Store?

eU: the Pi Store was provided for us by IndieCity, which is a division of Blitz Games, which is the company founded by the Oliver twins, Andrew and Philip, who wrote [1980s computer game] Dizzy among other things. In fact, they were two of the people who I read about as a child, who were making a bit of money out of computer games. So there is a wonderful kind of closure there in terms of what we’ve done with the store, for me anyway.

LUD: Why have games content?

eU: Games get that rap you know. But it is what got me into programming. I love to program and write computer games and I think that is true of a lot of people.

046-51_LUD_123 PK.indd 49 25/01/2013 18:16

Page 50: Linux User & Developer - Bpfine

www.linuxuser.co.uk50

“Yes I think it has [peeled away] the levels of abstraction that the kids have seen with their ‘shiny toys’ that you can’t get inside”

of electronics home with him and Pete was inspired by what could be achieved. “We have children with their iPads, their computers and the games that they’ve been playing,” he says. “They are very comfortable with it, so they are just surprised that the Pi doesn’t come in a box and they can actually touch the bits and they can actually see the bits that do all the work. I mean I love the story about the young lad that looked at one and said ‘where is the computer?’, until somebody pointed out this little 2cm square chip in the middle and he went ‘wow, is that it?’.”

The sense that children can make a difference when programming on the Pi is noted by Eben, who says that kids coding on regular, desktop or laptop machines tend to think that the computer is responsible in some way for whatever they create. The Pi gives the illusion, he adds, that it is such a simple piece of hardware and that they are the driving force behind whatever they achieve with it. “There is a higher level of ownership of the things that the child has done,” he says. “They credit themselves more because they believe the Pi can’t possibly be as sophisticated enough to have helped them. So it must have

been all their own work, you know, and that is a great thing. Again, it’s something we didn’t see coming.”

Pete agrees. “Yes I think it has [peeled away] the levels of abstraction that the kids have seen with their ‘shiny toys’ that you can’t get inside,” he says. “It has allowed them to sort of peel the onion right back to centre core and see the bit that actually does the work. Although having said that, I mean we have software systems on there that are quite sophisticated and allow them to do quite sophisticated things. But in the essence they can actually see the chip that

Celebrating the life of PiInterviewC

C: J

im K

illoc

k

RasPi 1st bIRthday

sPeCIal

046-51_LUD_123 PK.indd 50 25/01/2013 18:16

Page 51: Linux User & Developer - Bpfine

The Raspberry Pi founders talk about its fi rst year

INTERVIEW

does the work, they can even feel it getting warm when it is working hard and staying cool when it is idle. So there is a massive amount of education that comes from having this bit of computer in front of you.”

Education seems very much to be the focus for the Foundation over the next 12 months and the aim is to get through to children who do not have a teacher at school and a parent at home with computer knowledge. They are looking beyond these shores too. “I very, very much want to see the educational side of things working in other places,” says Liz. “So I have got plans this year to look at the developing world as well because there are things that we can do there, not just with computing education, but with education in general. It is a good tool and giving people access to those tools I think is very, very important, so for me that is what it is about.”

At the same time, they do not want to lose the engineering focus, with Pete in particular keen on this area. “My drive is to see some of these extension boards actually get into the mainstream and get kids using them,” he explains. “I want them to actually build out from the Pi and see what they can control and what they can monitor and what they can measure, using the Pi as a tool. I mean that is a really exciting area for me because that is the bit that I love to do.”

For Pete, computing and real life has to interact. “I just think being able to make kids enthusiastic about being able to sense temperatures, pressures, humidity, measure light, cosmic rays or anything like that, is a good thing,” he says. “It allows them to interact with the real world and it brings home what computers are really about. They are a tool to allow you to achieve other things. They are not

just things to play games on – although I [must] admit to have spent most of my Christmas playing games with my nine-year-old on various products, including the Pi – but devices to capture imaginations and allow people then to say ‘wow, this is fantastic, I wonder if I can do this and I think I have got a tool in front of me that will allow me to at least try’.”

There will not, however, be a major overhaul of the platform. There will be a third revision at some point to the PCB and that will probably take the Pi very close to a state where the team are completely happy. But there are no immediate plans for a higher-performance Pi and efforts will concentrate on subsidising software development work to try to get more out of the existing platform.

For them, videogame consoles provide a good analogy. “If you compare a year-one PlayStation 3 game to a modern PS3 game they are almost unrecognisably different,” says Eben. “You would imagine they were different pieces of hardware. So it is kind of this other model where you put a marker down, you work on optimising the software experience and hardware on that. We want to look at taking cost out of the hardware, on adding incremental features to that piece of hardware rather than a revolution per year. So I guess

Celebrating the life of Pi

Minecraft and the Raspberry PiOne release which has got people very excited is Minecraft: Pi Edition. Markus Persson revealed the port at MineCon 2012 and it was said that the Pi Edition is similar to the Pocket Edition except that is downgraded to an older version, and with the added ability of using text commands to edit the game world.

“Marcus is like a rock star to a lot of these kids,” says Eben. “So yeah we were really

pleased when they said they were going to produce a Pi version. The Pi version has this very rich integration with other programming languages so there is wonderful stuff you can write.”

Liz continues: “I was talking to a teacher in America actually who is using Minecraft with his students. He is going to design stuff inside the Minecraft world and then exporting both things to a 3D printer, which I thought was super cool. Suddenly you are not stuck with the physical now.”

Educating teachersLUD: Is there a need to educate the teachers to understand the Raspberry Pi if they are to help children get the most out of it?

Liz Upton: Defi nitely yes and we’ve got some stuff in motion at the moment to do things about that in the next couple of months. We do recognise that for some ICT teachers this is a little bit intimidating because not everybody has necessarily done any coding before. Now we continue to believe that there is actually quite an attractable thing, but it is quite hard sometimes for teachers to come forth and say ‘Look I could do with a little bit of handholding here, I need some help just to get started’, so we are working very hard on that at the moment. And yeah we have got some stuff coming up.

LUD: To what level do you need to teach them?

Eben Upton: Teachers and professionals want to deliver a quality education experience to the kids who are in their care and there is that confi dence thing. Professional development is very important for giving them confi dence. They don’t need to be that good: we’re not talking about training teachers up to be professional engineers and then having them teach this stuff. We are talking about getting people to a point where they are just confi dent that they can answer the basic questions; confi dent they can stay a page ahead.

that is probably where we are going over the next year. And also things like putting in the camera in the display board, these things that we said we would do, bringing in the model A which we said we’d do. So to some extent we are introducing new hardware, it is already bringing out stuff, it is just kind of fulfi lling promises that we’ve made.”

046-51_LUD_123 PK.indd 51 25/01/2013 18:16

Page 52: Linux User & Developer - Bpfine

Tutorial Create a VPN with the Raspberry PiTutorial

www.linuxuser.co.uk52

The Raspberry Pi is cheap enough to leave on a network you’d like to connect to remotely, so let’s learn how to set it up to do just that…

Create a VPN with the Raspberry Pi

One possible scenario for wanting a cheap server that you can leave somewhere is if you have recently moved away from home and would like to be able to easily access all of the devices on the network at home, in a secure manner. This will enable you to send files directly to computers, diagnose problems and other useful things. You’ll also be leaving a powered USB hub connected to the Pi, so that you can tell someone to plug in their flash drive, hard drive etc and put files on it for them. This way, they can simply come and collect it later whenever the transfer has finished.

We’ll be using Arch Linux as the operating system for our VPN server, since it is lightweight and has only the minimum packages required for a working system. If it’s been a while since you’ve used Arch Linux, the distro has recently moved to a new service management framework called systemd, so it’ll be good to get up to speed on that also.

Our VPN server will be made up of the following software components:

Base Arch Linux systemOpenVPN – the software we will use to create a secure VPNNetcfg – used to easily manage the multiple network adapters we’ll needBridge-utils – used to bridge the VPN and Ethernet adaptorsSSH – will provide secure remote access to the Raspberry Pi and the files on itA dynamic DNS daemon (No-IP) – software that runs in the background and points a domain name to your router’s IP address, meaning that you can access your Raspberry Pi from anywhere using an easy-to-remember web address.

This tutorial assumes that you have flashed the latest Arch Linux ARM image to an SD card. If you haven’t, the instructions for flashing an image can be found at www.linuxuser.co.uk/tutorials/how-to-set-up-raspberry-pi/. You’ll only need to go up to the step where you write the image to the SD card. You’ll have to adapt the instructions slightly for using the Arch Linux image rather than the Debian one.

ResourcesA Raspberry Pi with all necessary peripherals :

www.raspberrypi.org

An SD card containing the latest Arch Linux image for the Raspberry Pi:

www.raspberrypi.org/downloads

A second computer to be used as a VPN client – we’ll assume you’re using a

popular Linux distribution that uses Network Manager, like Debian

AdvisorLiam Fraser is the creator of the RaspberryPi Tutorials YouTube series and volunteers as a Linux server administrator for the Raspberry Pi Foundation

052-055_LUD_123 PK.indd 52 25/01/2013 17:41

Page 53: Linux User & Developer - Bpfine

Configure the Pi as a VPN server that you can access from anywhereCreate a VPN with the Raspberry Pi

TUTORIal

www.linuxuser.co.uk53

01 logging into arch linuxConnect the necessary cables to the

Pi and wait for the Arch Linux login prompt. The login is ‘root’, and the password is also ‘root’. We’ll change the root password from the default later on.

02 Run a full system updateArch Linux runs on a rolling release

schedule, meaning that there are no version numbers and software is continually updated. The package manager in Arch Linux is called pacman. Use the command ‘pacman -Syu’ to start a full system update. If for some reason the update fails, try running ‘pacman -Syu’ again. Sadly, the Arch Linux ARM servers tend to be quite busy. There may be a lot of packages to update so it may take a while, especially because the Pi runs from an SD card.

03 Install the required packagesUse the command

pacman -S noip netcfg bridge-utils openvpn to install the required packages mentioned at the start of the article. Answer ‘y’ to any prompts you may encounter.

04 a word about subnetsOne thing to note here is that because

we’re setting up a client-to-site bridge, we’ll be connecting the client to the server’s network. This means that the subnet that the server is on needs to be different from the client subnet. For example, the subnet at your advisor’s home is 192.168.1.0/24, and the subnet here is 172.17.173.0/24. If the subnet here was 192.168.1.0/24, then there would be a routing conflict because the machine won’t know if you’re referring to a local address or one on the VPN. It’s a good idea to have a non-standard subnet for this reason. In our case, the client subnet is non-standard so it doesn’t matter what the server subnet is for now. However, we’re still going to change the server subnet at some point because you may end up needing to connect from a network such as public Wi-Fi, which may use a standard subnet. If you need to change your server subnet, we suggest picking a /24 subnet (subnet mask 255.255.255.0) in one of the private address ranges:10.0.0.0 – 10.255.255.255172.16.0.0 – 172.31.255.255192.168.0.0 – 192.168.255.255

You should be able to easily change your network configuration on your wireless router’s settings page.

05 Investigate your networkWe highly recommend assigning a

static IP to your server Raspberry Pi rather than being handed one by your router because you’ll always know where to find it on the network, which will be useful for accessing it remotely. You’ll also need a static IP if you want to access the Raspberry Pi from the internet. We’ll need to find out a couple of things about your current network setup before setting a static IP. You can use the commands ‘ifconfig eth0’ and ‘ip route show’ to do this.

07 log in with SSHOnce the Pi has booted back up, open a

terminal on your Linux computer and type ‘ssh root@[IP of your pi]’. Answer yes, to say that you want to connect, and type in the root password, which will still be root. You are now logged in over SSH.

06 Set up a static IP addressNow that we have found out things

about your network, such as your current IP address, the network mask and so on, we can set up a static IP address. We’re going to use the Arch Linux netcfg framework to manage our network connections as we’ll need three different connections eventually: Ethernet, which is automatically handled by the bridge adaptor; a VPN tap adaptor; and a bridge adaptor to combine the two.

Change directory to the /etc/network.d directory and open a new file called bridge in nano (or the text editor of your choice):cd /etc/network.dnano bridge

Then fill in the bridge configuration to look as follows and save the changes (swapping our network values for your own):INTERFACE=“br0”CONNECTION=“bridge”DESCRIPTION=“VPN Bridge connection”BRIDGE_INTERFACES=“eth0”IP=‘static’ADDR=‘192.168.1.215’NETMASK=‘24’GATEWAY=‘192.168.1.254’DNS=(‘192.168.1.254’)

Once done, save the file using Ctrl+O followed by Enter, then exit nano using Crl+X. We’ll add the VPN adaptor to the bridge later on.

We now need to configure what profiles netcfg should load by editing /etc/conf.d/netcfg

08 Change the root passwordSince we will probably be exposing an

SSH login to the internet, it would be a very good idea to change the password to something much more secure. Type ‘passwd’, then follow the on-screen instructions to change your password. Your SSH session will stay logged in, but you’ll need to use the new password next time you log in. You may also want to change the contents of /etc/hostname to set the hostname to a self-identifying name, such as ‘vpnserver’ rather than the default ‘alarmpi’. The change won’t take place until after a restart.

and configuring the networks array as follows:NETWORKS=(bridge)

Save the changes, exit nano and then run the following commands to disable DHCP and enable the Ethernet interface and the bridge with a static IP permanently:systemctl disable [email protected] enable netcfg.service

You can now restart the Pi for the changes to take effect.

09 Set up the public key infrastructure variables

We’re going to be using a certificate infrastructure to authenticate OpenVPN. This is where a certificate and private key (which

052-055_LUD_123 PK.indd 53 25/01/2013 17:41

Page 54: Linux User & Developer - Bpfine

Tutorial Create a VPN with the Raspberry PiTutorial

www.linuxuser.co.uk54

11 Configure the OpenVPN serverWe’re going to base our configuration

file on the example server configuration file using the command ‘cp /usr/share/openvpn/examples/server.conf /etc/openvpn/server.conf.’ Open /etc/openvpn/server.conf in nano.Start by changing: ;dev tapdev tunto:dev tap0;dev tunbecause we are using a network tap adaptor which allows us to bridge the networks, rather than create a tunnel.

Replace the certificates here with the ones you created:ca ca.crtcert server.crtkey server.key # This file should be kept secretdh dh1024.pemIn our case, the configuration looked like:ca /etc/openvpn/easy-rsa/keys/ca.crtcert /etc/openvpn/easy-rsa/keys/liamvpn.crtkey /etc/openvpn/easy-rsa/keys/liamvpn.keydh /etc/openvpn/easy-rsa/keys/dh1024.pemComment out the line:server 10.8.0.0 255.255.255.0by placing a semicolon in front of it because we want an Ethernet bridge rather than a regular server. To enable the Ethernet bridge, uncomment the line:server-bridge 10.8.0.4 255.255.255.0 10.8.0.50 10.8.0.100

Then change the values to match your server’s network configuration. The first is the server’s IP address; the second is the subnet mask. The

13 Enabling OpenVPNNow that we have configured OpenVPN,

we want to enable it permanently. Use the command ‘systemctl enable openvpn@server’ and then reboot the Pi to make sure that everything starts successfully from a clean boot. Our VPN is now configured, so we’re going to set up dynamic DNS and port forwarding so that we can access it from the internet.

14 Set up dynamic DNSHead over to www.no-ip.com/personal/

and sign up for the No-IP Free option. Once you have done that, don’t bother downloading No-IP’s client because we’ve already installed it. Go to your email inbox and follow the activation link that was just sent to you by No-IP. You can now sign into your account. Once you have logged in, select the ‘Add a host’ option. Choose a hostname and a domain to be part of from the drop-down list. Leave the host type as ‘DNS Host’ and then click the

10 Create the certificatesStart by generating the certificate

authority certificate, with which we will sign everything else (press Enter to leave fields set as they are):./build-ca

Following that, we want to generate a server certificate with:./build-key-server [server hostname]

Press Enter when asked for any information, don’t fill in a password or company name and accept the request to sign the certificate.

12 Configure the tap interfaceOpen the file /etc/network.d/tap in nano,

add the following lines, and then save the file:INTERFACE=‘tap0’CONNECTION=‘tuntap’MODE=‘tap’USER=‘nobody’GROUP=‘nobody’

We then need to add the tap0 interface to our bridge, so edit /etc/network.d/bridge and change the bridge interfaces line to look like:BRIDGE_INTERFACES=“eth0 tap0”

Finally, change the networks line in /etc/conf.d/netcfg to:NETWORKS=(tap bridge)

Notice that the tap network needs to be started first, so that it can be added to the bridge successfully.

We now need to generate the Diffie–Hellman parameters, needed to allow two users to exchange a secret key over an insecure medium using the Diffie–Hellman key exchange protocol (this may take a couple of minutes):./build-dh

The final step is to generate a certificate for each client that you would like to connect to the VPN. In this case, our client is a laptop../build-key liam-laptop

Simply do what you did during the build-key-server script and then you’ll have all the certificates you need.

must be kept a secret) is generated for each client, and signed by the certificate authority. Only clients with signed certificates are allowed to connect. The key and certificate are used to encrypt the data sent between the client and the server. This secure approach means that additional username and password authentication on the client is not necessary. There are a bunch of scripts which make setting this up easy. Start by copying the scripts to /etc/openvpn with:cp -r /usr/share/openvpn/easy-rsa/ /etc/openvpnand then change to that directory.

We’re going to be making a template to base our certificates on. Edit the vars file with nano and change the following lines at the bottom of the file from something like:export KEY_COUNTRY=“US”export KEY_PROVINCE=“CA”export KEY_CITY=“SanFrancisco”export KEY_ORG=“Fort-Funston”export KEY_EMAIL=“[email protected]”export [email protected] KEY_CN=changemeexport KEY_NAME=changemeexport KEY_OU=changemetoexport KEY_COUNTRY=“UK”export KEY_PROVINCE=“”export KEY_CITY=“Ormskirk”export KEY_ORG=“Home”export KEY_EMAIL=“[email protected]”export KEY_CN=“liamvpn-ca”export KEY_NAME=“liamvpn-ca”export KEY_OU=“None”Once you have saved the changes, export the variables with:source ./varsand then clean any previous configuration with:./clean-all

last two values are the start and end ranges of IP addresses allocatable to connecting clients.

Finally, uncomment the lines:;user nobody;group nobodyto give OpenVPN the least privileges possible and then save the changes to the file.

052-055_LUD_123 PK.indd 54 25/01/2013 17:41

Page 55: Linux User & Developer - Bpfine

TUTORIAL

www.linuxuser.co.uk55

19 Create the VPN connectionNote that you’ll probably want to be on a

different subnet to your server otherwise it’s likely you’ll run into connectivity issues on the client because of the aforementioned routing problem. We worked around this problem while at home by using a virtual machine that’s connected with NAT. As far as the virtual machine is concerned, it’s on the 10.0.2.0/24 subnet.

Click on the Network icon in the top menu bar and click on the ‘Edit connections’ option. You will then be shown a window that has multiple tabs at the top. Go to the VPN tab and click ‘add’. Select OpenVPN as the connection type and then click on ‘Create’. Now fi ll in the appropriate information.

20 Advanced settingsWe need to set the advanced settings

that we mentioned before:• Use a TAP device• Use LZO data compression

21 Route settingsThe fi nal thing we need to set is

the option to ‘Use this connection only for resources on its network’. To do this, go to the IPv4 Settings tab and click the Routes button. Tick the box for the aforementioned option and then click Okay. Once you have done this, you can Save your connection and close the Network Connections window.

22 Test your connectionClick on the Network icon in the menu,

hover over the VPN Connections option and then click on the VPN that you just created. You should see a success message and a padlock as part of the Network icon. Open up a terminal and run ifconfi g to check that the tap device has been corrected with an appropriate IP address, and that you can ping a device behind the VPN.

18 Copy the required certifi cates to the client

We need three fi les from the Raspberry Pi to be able to connect successfully:The certifi cate authority certifi cateThe client certifi cateThe client keyWe’ll be using SCP to copy the fi les into the /etc/openvpn/keys directory:cd /etc/openvpnsudo mkdir keyscd keyssudo scp root@[Pi’s IP address]:/etc/openvpn/easy-rsa/keys/ca.crt .sudo scp root@[Pi’s IP address]:/etc/openvpn/easy-rsa/keys/[client].crt .sudo scp root@[Pi’s IP address]:/etc/openvpn/easy-rsa/keys/[client].key .sudo chmod +r *

Confi gure the Pi as a VPN server that you can access from anywhereCreate a VPN with the Raspberry Pi

15 Configure No-IPRun the command

noip2 -C -Yto be taken through interactive confi guration of the No-IP client. We left the update interval to the default 30 minutes, meaning the client will check every 30 minutes for an IP address change. Once done, start the daemon with:/etc/rc.d/noip start

After a minute or two, your IP address will be accessible via your No-IP hostname. However, it’s likely that trying it from inside your house will simply take you to your router’s homepage.

17 Install an OpenVPN clientWe’ll use a virtual machine running

Ubuntu 12.04 as our example VPN client. There are simply too many possible combinations to show them all. There are a couple of options that must be used on every client, however:

• Use a TAP device• Use LZO data compression• Do not use the default gateway on the

remote network (on Ubuntu, this is called ‘Use this connection only for resources on its network’). This basically means ‘don’t tunnel my internet through this VPN’. If this option is disabled, then the client’s internet connection wouldn’t work because we haven’t confi gured our VPN to deal with internet.

Ubuntu uses Network Manager to confi gure its networks, so the instructions we give here should be almost identical to any other distribution that uses the same thing. Ubuntu doesn’t come with the OpenVPN plug-in for Network Manager by default, so we’ll need to start by installing it. From a terminal, run:sudo apt-get updatesudo apt-get install network-manager-openvpn-gnome16 NAT port forwarding

It is likely that there are multiple devices behind your router that all use the same external IP address. This is because of the shortage of IPv4 addresses, and also because it is more secure to segregate the internet from your internal home network. NAT (network address translation) forwards a port from the router’s external IP address to a computer on the LAN (local area network). In this case, we’ll want to forward any traffi c for TCP port 22 that comes to your router’s external IP address to the IP address of your Raspberry Pi. TCP port 22 is the port used for SSH. SSH will provide remote access to your Raspberry Pi, and also access to any fi les on it via SCP (Secure Copy Protocol). You’ll also want to forward UDP port 1194, as that’s what OpenVPN uses.

The confi guration of port forwarding really depends on the router that you are using, so you may have to look it up. The chances are

that it will be hidden away in the ‘Advanced’ section of your wireless router. You should be able to access your router by typing your No-IP hostname into your web browser. If not, it should be at the address of your default gateway that we used earlier on.

On our router, we had to go to Advanced>NAT> Port Mapping, and add a mapping (Fig 1). We then had to add a second mapping for OpenVPN, using port 1194 specifying UDP rather than TCP as the protocol.

‘Create Host’ button. For example, we used the hostname liam-ludtest with the domain no-ip.org, so we would access that using liam-ludtest.no-ip.org.

Note that we use chmod to add read permissions because the fi les need to be readable by all users. We need to do this because the Network Manager GUI doesn’t run as root.

Fig 1 NAT port mapping

052-055_LUD_123 PK.indd 55 25/01/2013 17:42

Page 56: Linux User & Developer - Bpfine

Tutorial

www.linuxuser.co.uk56 www.linuxuser.co.uk

Wine for advanced users and developersTutorial

01 Rules of engagementThe fi rst step to any porting project

is to make sure your code is ready for the new platform. There are a few basic rules of thumb that apply to any application which is supposed to be ported. These cover some basic Windows and Linux operating environment differences. First, differences between DOS and UNIX text

AdvisorKunal Deo is a veteran open source developer.

Currently he is leading two open source projects: WinOpen64 and KUN Wiki. He is also a KDE developer. He has contributed to many open source projects, including KDE-Solaris, Belenix and Openmoko

Build and run windows apps without using Windows

Wine for advanced users and developers

ResourcesMandatory development tools: GCC, G++, Make etc

Git: It is used by the Wine project as the primary source control system

Access to Windows system with Microsoft Visual Studio 2008 installed (optional)

While Linux has one of the largest software catalogues on the planet, there are still many software applications which are either only available for Windows or are only possible to make on Windows. For users, it means that they will miss out on some of their favourite software (for example, Microsoft Offi ce and a lot of games). For developers it means losing a signifi cant market to people who are using Linux. While most of the software can be written for both the platforms if you plan ahead, it becomes painfully diffi cult (and sometimes impossible) when the software is already written. This is where Wine comes to rescue.

For users, Wine provides a way of running Windows applications without any modifi cation on a Linux system. For developers, it provides a way of making their applications work with Linux with maximum compatibility.

WineBefore we dive into the tutorial, let’s understand what Wine is. Wine is not an emulator that emulates the Windows OS to run Windows applications. It is a compatibility layer for Windows applications on POSIX-compliant operating systems such as Linux, BSD and Mac OS X. It translates Windows API calls into POSIX calls on-the-fl y. Being just a compatibility layer means that Wine runs applications at native performance. That’s not all: since it doesn’t need Windows to function, you won’t need a Windows licence to run Windows applications. In addition to the Windows compatibility, Wine provides open source implementations for some of the most sought-after APIs in the industry (like DirectX, ActiveX, DDE etc).

Wine helps Windows developers to bring their software to Linux in the following ways…

Direct binary execution: This is achieved with the tool called ‘wine’ (part of the Wine distribution). In this process, application source code is compiled on the Windows platform, and then the binary fi le is taken to the Linux system and is run through Wine. When the application is run with binary compatibility, it can use all existing .dll fi les. This process is pretty

straightforward, but is not able to unleash the full power of the Wine subsystem. However, this is the only way to go if you do not have the access to the source code. You can also wrap Wine with your application to create an easy-to-use way to run it on the Linux platform.

Recompiling the application with Winelib: In this method the source code fi le is taken to the Linux box, where it is compiled against the Winelib libraries using GCC. This way, the application will also be able to catch up with UNIX API calls in order to leverage the full power of UNIX. Winelib ships with a tool called Winemaker, which creates a GNU standard autoconf-based makefi le out of a VC++ project. Winemaker is a Perl script that does all the dirty work involved in converting the source code, making it UNIX specifi c, clearing up case issues and a lot more.

WinelibWinelib is a software development kit for building Windows applications for Linux (and other POSIX operating systems). It includes the Win32 API implementation providing the necessary libraries and header fi les. It supports C/C++ and shares 100 per cent of its code with Wine.

Winelib is capable of building GUI applications, console applications and dynamic-link libraries (DLLs).

One of the biggest benefi ts Winelib provides is the ability to make calls to UNIX APIs directly from your Windows source code, resulting in better integration than with the direct binary execution method.

In this tutorial we will be using Winelib to compile a Visual C++ application on the Linux platform.

Build and run windows apps without using Windows

Wine for advanced users and developers

056-059_Wine Developer Tutorial_123 PK.indd 56 25/01/2013 17:42

Page 57: Linux User & Developer - Bpfine

TUTORIAL

www.linuxuser.co.uk57

Build and run windows apps without using Windows.Wine for advanced users and developers

02 Building WineThere is a very good chance that

the Wine shipping with your favourite Linux distribution is outdated. That’s why we will build Wine directly from the source. This will allow us to build Wine to our liking.

NOTE: We are using Ubuntu 12.10 64-bit for this tutorial. If you are using any other 64-bit distribution you will need the respective package management command. If you are using Ubuntu 12.10 32-bit or any other 32-bit distribution, skip this – go directly to installing build dependencies.

Creating chroot for Wine: Since Wine depends upon a lot of 32-bit libraries, it is a good idea to build it in a chroot environment. A chroot is a way of isolating applications from the rest of your computer, by putting them in a jail. In this case we will set up a chroot with the 32-bit binaries and libraries.Install the chroot packages$ sudo apt-get install dchroot debootstrapCreate a directory which will hold the root of

the chroot environment$ sudo mkdir /var/chrootCreate chroot confi guration for the current distribution@config file: /etc/schroot/schroot.conf [quantal]description=Quantal Quetzaldirectory=/var/chrootusers=kunalgroups=sbuildroot-groups=root

You’ll need to replace ‘Quantal’ with the name of the distro you are using. You will also need to replace ‘kunal’ with the correct username.

NOTE: The distribution name should be a valid distribution, else chroot environment will not be created. To fi nd valid and supported distribution names, look in the directory /usr/share/debootstrap/scripts/.

Install the base system for your chroot$ sudo debootstrap --variant=buildd --arch i386 quantal /var/chroot/ http://mirrors.us.kernel.org/ubuntu/

NOTE: You can replace the mirror with one of your liking, preferably nearby. A list of mirrors is located at https://launchpad.net/ubuntu/+archivemirrors. You will need to make sure that the mirror you are selecting contains the distribution you are chrooting.

Set up the Apt sources$ sudo cp /etc/apt/sources.list /var/chroot/etc/apt/Enter chroot and install the

■ Wine Notepad running in chrooted environment

build dependencies$ sudo chroot /var/chroot# apt-get update# apt-get build-dep wine# apt-get install gitInstall additional dependencies# apt-get install libosmesa-dev ocl-icd-opencl-dev libhal-dev libxml-perl

Cloning the Wine Git $ git clone git://source.winehq.org/git/wine.gitBuild and install WineWe are now all set up to build Wine.# cd wine*# ./configure# make# make install

Setting up the X-serverTo make the GUI applications work from within the chrooted environment, you will need to set up the X-server:

On the system shell$ xhost +On the chrooted shell # export DISPLAY=:0.0You can now test the setup by running the following command# wine notepad

Now you can use the chrooted environment for all your Wine-related activities.

fi les must be fi xed. Otherwise you may receive errors related to carriage returns and numerous other similar errors.

Then there’s the case of fi lenames. As you will probably be aware, kunal.c and Kunal.c are the same in a Windows environments, but not in Linux. So, the fi lenames used in include statements might be different from the original fi les you are actually referring to.

Include statements should avoid using ‘\’ – instead they should use ‘/’. ‘/’ is recognised in both the environments, but using ‘\’ may cause errors in UNIX.

Makefi les should be changed accordingly to fi t into the new environment. Makefi les are not generally cross-platform compatible.

Sprinkle your code with #ifdefs. This good old technique can be used to isolate the platform-specifi c code in a very effi cient manner.#ifdef _WIN32 // Windows (x64 and x86)#elif __unix__ // all unix // Unix#elif __posix__ // POSIX#elif __linux__ // linux#elif __APPLE__ // Mac OSX code#endif

056-059_Wine Developer Tutorial_123 PK.indd 57 25/01/2013 17:42

Page 58: Linux User & Developer - Bpfine

Tutorial

www.linuxuser.co.uk58

Tutorial Wine for advanced users and developers

03 Porting Hello World Win32 application

In this step we will see what it takes to build a simple Hello World application in Linux using Wine.

The following example shows a message box with the text ‘Hello from Windows World!’.hello.c#include <windows.h>int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nShowCmd ){ MessageBox(NULL,TEXT(“Hello from Windows World!”),TEXT(“HelloMsg”),0); return 0;}

Winelib ships with nice GCC wrappers which are compatible with the MinGW compiler. These wrappers are called winegcc and wineg++. This way if you have an application that uses the MinGW compiler on Windows, you can simply replace the gcc/g++/windres with winegcc/wineg++/wrc .

To compile the application, we use the winegcc command:# winegcc hello.c -o hello

Upon successful compilation, you will notice that it produces two fi les instead of just one. In this case…hello.exe.so: This is the main binary of the application. But you cannot execute this directly. It is a shared object fi le that must be run using Wine. It is directly linked to the Wine library.# ldd hello.exe.so linux-gate.so.1 => (0xf771d000) libwine.so.1 => /usr/local/lib/libwine.so.1 (0xf75b9000) libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xf740f000) libdl.so.2 => /lib/i386-linux-gnu/libdl.so.2 (0xf7409000) /lib/ld-linux.so.2 (0xf771e000)hello.exe: Although it looks like the main output of the source, it is merely a script to launch the main application. You can modify hello.exe to customise the launch parameters. You can even specify a different version of Wine for use with the executable.#!/bin/shappname=”hello.exe.so”# determine the application directory

appdir=’’case “$0” in */*) # $0 contains a path, use it appdir=`dirname “$0”` ;; *) # no directory in $0, search in PATH saved_ifs=$IFS IFS=: for d in $PATH do IFS=$saved_ifs if [ -x “$d/$appname” ]; then appdir=”$d”; break; fi done ;;esac# figure out the full app pathif [ -n “$appdir” ]; then apppath=”$appdir/$appname” WINEDLLPATH=”$appdir:$WINEDLLPATH” export WINEDLLPATHelse apppath=”$appname”fi# determine the WINELOADERif [ ! -x “$WINELOADER” ]; then WINELOADER=”wine”; fi# and try to start the appexec “$WINELOADER” “$apppath” “$@”

04 Porting a bigger project using Winemaker

Winegcc is helpful if your application consists of only one fi le, but that isn’t usually the case. In

most cases a Windows application consists of multiple source fi les as well as resource fi les. Winelib ships with a tool called Winemaker. It is capable of generating UNIX-compatible makefi les from Windows project source code. Winemaker is a very important tool in getting your fi rst step (also the most diffi cult one) ready. It does all the dirty work for you, from fi xing up fi les to creating a UNIX-compatible makefi le. It is capable of fi xing most of the issues mentioned in step 1 ‘Rules of engagement’.

Winemaker provides the following options to help you out with porting your code. These options customise the resultant makefi le to suit your needs.--lower-uppercase: This option deals with the cases of fi lenames and puts them in order.--dll: This option instructs Winelib to build a DLL (dynamic-link library) project instead of a GUI project.--console: This option directs Winelib to build a console application.--mfc: This directs Winelib to build an MFC (Microsoft Foundation Class) library application. Please note that Wine does not ship with the MFC library; you will have to build it on your own with Winelib.--nobackup: Winelib keeps a backup of fi les which it changes. If you already have this source code present somewhere else, you can use this option to save a lot of time and disk space.-Idir: Specifi es to include fi le directories. This option accepts paths to fi les in absolute format.-Ldir: Specifi es library fi le directories.-idll: Directs Winelib to import a library fi le through the spec fi le mechanism.-llibrary: Instructs Winelib to import UNIX library fi les.

■ Visual Studio 2008 New Project dialog

056-059_Wine Developer Tutorial_123 PK.indd 58 25/01/2013 17:43

Page 59: Linux User & Developer - Bpfine

www.linuxuser.co.uk59

TUTORIAL

www.linuxuser.co.uk59

Build and run windows apps without using Windows.Wine for advanced users and developers

05 Conclusion Wine is one of the key technologies

which can help you go Windows free. There are an enormous number of Windows applications that just work on Wine without developer support – see the full list at appdb.winehq.org. If your application is not on that list, you can use Winelib to port your application natively to Linux. It will have the same performance as any other native application. Winelib is very easy to use, especially with a tool like winemaker which takes care of much of the standard porting issues by itself. So, if you are a Windows developer avoiding the Linux platform because you thought it was too much work, it’s time to give Wine a try.

In this step we will take the default application built by Microsoft Visual Studio and try to compile it with Winemaker on Linux.

Creating the Win32 Application:Open Microsoft Visual Studio 2008. Click File>

New>Project…From the New Project dialog box, select Visual

C++>Win32. Then select Win32 Project. Give an appropriate Name for the project, Location and Solution Name. Then click OK. The Win32 Application Wizard will open.

Click Next to continue. On the Application Settings page, select the Application type as a Windows application. Leave the rest of the settings as is. Click Finish to create the project.

The fi nished project will now open in Visual Studio. Solution Explorer will show all the fi les created for the project.

As you can see, this is a fully featured project with multiple header fi les, source fi les and resource fi les. For this tutorial we need to modify the project itself. We would rather focus on porting part of this application.

Let’s run this application to see if everything is working perfectly. Click Build>Build Solution to build the project, then click Debug>Start Without Debugging.

Copy the LUDWin32Project directory to the chrooted folder, ie /var/chroot/. Then perform the following steps to create a UNIX makefi le project using Winemaker:cd into main project directory# cd LUDWin32Project/ LUDWin32Project/Run Winemaker to fi x the source fi les and create UNIX makefi les:# winemaker --lower-uppercase --nomfc .Winemaker 0.8.3Copyright 2000-2004 Francois Gouget <[email protected]> for CodeWeaversCopyright 2004 Dimitrie O. Paun

Copyright 2009-2012 Andr� HentschelScanning the source directories...Projectfile found! You might want to try using it directly.Fixing the source files... LUDWin32Project.cpp LUDWin32Project.rc LUDWin32Project.h Resource.h stdafx.cpp stdafx.h targetver.hGenerating project files... .

The above command fi xes the case-related issues with the source code. ‘-nomfc’ indicates that we do not want to use the MFC library with this project. As you can see in the output above, it has located a project fi le (vcproj), but we will skip it for this tutorial as Visual Studio project fi les are not fully compatible with Winemaker.

Winemaker will fi x the fi les and create .bak fi les for the modifi ed fi les. It will also create the makefi le which we can run against the standard GNU Make utility to build the application.

Makefile structure of a Winelib project: Most of the time, the makefi le generated with Winemaker will be a good fi t for your project. However, for some advanced and complex applications, you might need to customise the makefi le yourself. The following explains the very basic structure of a Winelib project.Makefile generated by WinemakerSRCDIR = .SUBDIRS =DLLS =LIBS =EXES = ludwin32project### Common settingsCEXTRA = -mno-cygwinCXXEXTRA = -mno-cygwin

### Global source listsC_SRCS = $(ludwin32project_C_SRCS)CXX_SRCS = $(ludwin32project_CXX_SRCS)RC_SRCS = $(ludwin32project_RC_SRCS)### ToolsCC = winegccCXX = wineg++RC = wrcAR = ar

This is not a complete makefi le, but the main options you should take a look at. However, most of the options will be fi lled by Winemaker itself.Compile the project by issuing Make# makewineg++ -c -mno-cygwin -I. -o LUDWin32Project.o LUDWin32Project.cppwineg++ -c -mno-cygwin -I. -o stdafx.o stdafx.cppwrc -I. -foLUDWin32Project.res LUDWin32Project.rcwineg++ -mwindows -mno-cygwin -o ludwin32project LUDWin32Project.o stdafx.o LUDWin32Project.res -lodbc32 -lole32 -loleaut32 -lwinspool -lodbccp32 -luuid As you can see, the correct compilers are used for respective fi les. For example, wineg++ is used for .cpp fi les, wrc (Wine Resource Compiler) is used for .rc fi les.

The ‘make’ command will produce ludwin32project.exe.so and ludwin32project.exe. Run the ludwin32project.exe fi le to start the ported application.

■ Solution Explorer with LUDWin32Project open

056-059_Wine Developer Tutorial_123 PK.indd 59 25/01/2013 17:43

Page 60: Linux User & Developer - Bpfine

Kolab: David and GoliathFeature

Groupware is a tough domain to break into. With competition from giants the likes of Lotus Notes and Exchange, how can an open source offering, like Kolab, ever hope to compete? Dr Karl Beecher investigates…

www.linuxuser.co.uk60

Kolab:

Groupware is an overused and ill-defined term, so you have to make clear what it is you’re talking about. It’s often taken to mean any software that allows users to work together on common projects over a network. Such programs usually package together email, a shared calendar, task management, an address book and document management as a minimum. Just about any organisation that uses a computer these days needs some sort of groupware on their systems. If you use a computer on the planet Earth, you’re probably aware of two groupware programs that dominate the market, namely Microsoft Exchange and

Dr Karl BeecherUntil recently an academic specialising in computer science and open source, Karl now works as a freelance consultant, writer and trainer based in Berlin, Germany. You can check out more of his stuff at computerfloss.com

AUthor

David and Goliath

Lotus Notes. Between them, these entrenched players can boast hundreds of millions of users around the world and the backing of some of the wealthiest technology companies in existence. It’s a tough domain to break into and not one you might automatically associate with open source software.

Nevertheless, it’s in this domain that Kolab has positioned itself. Kolab is just one of a number of collaborative software applications, both proprietary and open source, which fight to be noticed on a crowded stage. How on earth can a participant in this market hope to distinguish itself, not only from the giants of Microsoft and IBM, but also from a sizeable pool of other more similar players?

Entering the groupware domain can be fraught with difficulty if you wish to see any significant usage of your application. In such a well-established realm, where proprietary technologies have long reigned supreme, how can users be convinced to leave their current applications behind and take up an alternative?

Imagine this was your groupware product. You know that users, through desire or necessity, often want to keep using their familiar old systems and will resist change. Any proposed alterations to their setup must therefore cause minimum disruption or risk being rejected; key features must remain intact and the disruptive effects of migration should be few. You basically need to entice users away from the world of Exchange in favour of your product. It needs to provide the same feature set and it had better offer compatibility with Exchange, or an easy migration path at least.

Many free and open source (FOSS) products are in this very position. A popular strategy that emerges is to retain Outlook as the desktop client (sometimes offering web and phone interfaces too), but connected to new back-end systems. By building on FOSS technologies, and by virtue of its smaller size, a company attempting this should be able to offer an alternative at a cheaper price than a full-blown Exchange installation. Sounds reasonable, yes?

060-063_LUD_123 PK.indd 60 25/01/2013 17:46

Page 61: Linux User & Developer - Bpfine

Can open source groupware take on the big proprietary players?Kolab: David and Goliath

feature

2003 (see page 60 boxout ‘Profile: Community and Company’). Accordingly, FOSS issues were given a high priority from the start. The CEO of Kolab Systems, Georg Greve, has been outspoken on issues of freeness in groupware and other so-called ‘open source’ alternatives.

“Often they turn out to be open core,” Greve explains, pointing out the disappointing mix of proprietary and open source. “But there is another, bigger problem. Outlook is based on the Windows platform. And while the web clients give some level of platform independence even for Microsoft Exchange itself, there are many scenarios where web clients are just not good enough.” We still live in a world where users insist on the rich client experience. If the rich client is Outlook, available only on Windows and Mac, that poses real problems for users of a free operating system.

In light of all this, Kolab’s strategy is somewhat different from its competitors’. Kolab itself is still clearly groupware, but it’s trying to distinguish itself in different ways. I first learned about Kolab’s alternative approach when I briefly helped them set up

61 www.linuxuser.co.uk

their new community website in 2011. You can better appreciate this approach when you realise the nature of Kolab’s architecture.

“Kolab is not a single monolithic application,” Adams explains. “When you deploy the Kolab server, you’re actually deploying several independent services. The job of the Kolab code is to make all these work together.” These are programs like OpenLDAP, Postfix, Cyrus and OpenSSL.

Hence, Kolab’s developers are not trying to compete on the terms of the entrenched market leader; the Kolab back-end has nothing to do with an Exchange server at all. Instead, Kolab provides its own server, one which makes extensive use of open standards and can boast of being 100% FOSS. The server uses IMAP as its underlying protocol (not just for email storage, but other information too, like tasks, calendar events and contacts) and configuration and user details are stored in LDAP directories using Kolab’s own, published

Kolab’s alternative strategyAs it turns out, customers with tight IT budgets may go for it, as would smaller clients with humble requirements and an even humbler bank balance. However, groupware users who are more financially flush are apt to stay with Exchange, paying a premium for the warm feeling of ‘reassurance’.

“In short,” argues Paul Adams, “this approach is basically a race to the bottom. You can hoover up the smaller customers but the bigger ones will stick with Exchange.”

Dr Adams is the chief operating officer at Kolab Systems, the professional organisation behind the Kolab groupware. He and his colleagues believe they know how to avoid this downward race and achieve real success in the FOSS groupware domain. And it’s not just idle talk – it’s the strategy on which they are driving the development of Kolab.

Kolab Systems was formed in 2010 to provide services around Kolab, as well as leadership of the development community. Prior to this, the software had been commissioned by the German government in

n Georg Greve, CEO, Kolab Systems

“You can hoover up the smaller customers but the bigger ones will stick with Exchange” Dr Paul Adams

n Roundcube, with its rich UI, becomes the default web interface in the latest version of Kolab

n Dr Paul Adams, COO, Kolab Systems

060-063_LUD_123 PK.indd 61 25/01/2013 17:46

Page 62: Linux User & Developer - Bpfine

Maemo/MeeGo and Windows Mobile. But, as already mentioned, achieving a consistent cross-platform user experience is a challenging thing to do. What’s Kolab’s answer to this problem?

Kolab’s client is actually based on Kontact, which itself is a KDE-based application. For several years now, it’s been possible to run

XML format. Other open formats are supported too, like iCal and vCard.

By glueing several independent programs together, the developers of Kolab make extensive use of open standards. Of course, this can make their job more diffi cult, but it pays dividends. As well as the obvious modularity, there’s the interoperability which makes Kolab a fertile ground for innovation. For instance, at a recent development sprint, Kolab engineers collaborated with OwnCloud developers to work on integrating OwnCloud functionality into Kolab, a possibility thanks in large part to modularity and open standards.

And it’s not just on the server that Kolab deviates from the norm. Kolab’s tagline is ‘Five platforms. One groupware,’ a reference to the rich-client support on no less than fi ve different platforms, including Linux, Windows, OS X,

www.linuxuser.co.uk62

Qt-powered applications on a wide range of operating systems, meaning that Kolab’s client is as consistent and widely supported as Qt allows it to be. Nevertheless, a web-based client is available as well. In fact, the recent release of Kolab version 3.0 might make all this rich-client vs web-client talk quite redundant, because the new release sees Roundcube becoming the application’s default web interface. While web-based mail clients typically aren’t enormous fun to use, Roundcube has been making a big name for itself thanks to a highly fl uid and responsive interface. Its judicious use of AJAX makes the browser-based experience much closer to traditional rich-client applications.

Kolab races alongSo how is Kolab faring in the race? Is it, too, destined to serve only small customers, making do with the crumbs off Exchange’s table? Its makers claim not, although they’re

To get started with the Kolab server, you will need a “reasonably recent version of Linux” (CentOS, Debian, Fedora and RHEL are all cited as suitable). At its easiest level, setting up a Kolab server is as simple as entering ‘apt-get install kolab’ at the command line, although this is a meta-package that installs all components on a single machine. The individual packages are: LDAP,

IMAP, MTA, the web admin and the web client.

Kolab ships with a standard confi guration specifi cally tailored for smaller, all-on-one-box deployments, which are the most common. If you want to spread the deployment over many boxes, Kolab’s packages do a lot of the work for you, but some post-install confi guration will be required.

REQUIREMENTS

PROFILE: COMPANY AND COMMUNITYWho’s behind all this?The Kolab community dates back to 2002, when a consortium of companies (made up Klarävdalens Datakonsult, Erfrakon and Intevation) won a contract from the German Federal Agency for IT Security for the development of Kolab. The Kolab Konsortium, as it became known, led the community until it was succeeded by Kolab Systems, a Swiss-based company that sponsors Kolab’s development and provides related services. The company also maintains the Kolab

System Enterprise Community, an association of organisations that act as Kolab consultants and user support.

A good proportion of development is done by paid employees engaged mainly in packaging and distribution. Although there’s plenty of community participation, there are some problems obtaining contributions back from users. Kolab’s user base is highly corporate and, in practice, these business-oriented users have precious little time to give to community participation.

■ Kolab is just as at home on Windows as it is on Linux

■ The 2012 development sprint was a rare, face-to-face gathering. Most Kolab developers work around the world from home

Kolab: David and GoliathFeature

060-063_LUD_123 PK.indd 62 25/01/2013 17:47

Page 63: Linux User & Developer - Bpfine

www.linuxuser.co.uk63

frustratingly unable to cite specifi c examples, as much as they’d like to brag.

“We can’t reveal names,” admits Paul Adams. “Large organisations see their choice of groupware as a strategic advantage and so prevent us from advertising them as users.”

The best he can do for now is cite certain tricks up Kolab’s sleeve which are essential for attracting big users. Chief among these are the fl exibility on offer and the scalability that results from it. When I worked with the community, the developers often boasted how a Kolab sysadmin has lots of options when it comes to evolving their system. Because Kolab is made up of loosely coupled parts, components can be spread out over several machines. The mailboxes, the storage folders, the authentication server etc; these could all be deployed on different machines and maintained separately. This allows an organisation to scale their deployment with a fi ne level of control, increasing power or space to individual services. The standard approach to scaling – purchasing new boxes as demand increases, installing a separate copy of the whole server on each one and then managing incoming requests via load balancing –

seems like overkill beside Kolab’s method. It’s on these grounds that Kolab’s developers claim its suitability for a wide range of users, from small clubs and societies right up to enterprises and governments.

And speaking of elite users, there’s one other attribute of Kolab that makes its developers beam with pride, and that’s security. For big business and government, security of data is paramount. When they use groupware, they want it to be as hard as possible for an attacker to gain unauthorised access to user data. Kolab’s approach makes this very diffi cult indeed (not surprising when you learn that Kolab’s fi rst major user was the German Federal Agency for IT Security). Storing data the standard way – on a server-side database, like MySQL – means that the data store has an admin account that can automatically access all the contents. Therefore, the danger always lingers that a cracker compromises this account and so gains access to all an organisation’s data.

This danger isn’t present for a Kolab installation, because a central database administrator simply doesn’t exist (although a MySQL database is necessary for certain

Can open source groupware take on the big proprietary players?Kolab: David and Goliath

FEATURE

FURTHER READING AND RESOURCES• www.kolab.org: The community website where

you can get information, help, and the latest news from the developers.

• www.kolabsys.com: Kolab Systems is the professional organisation behind the Kolab groupware offering.

• If you want to get face-to-face (in a virtual sense) with Kolab’s developers, then you’ll fi nd them hanging out in various IRC channels. #kolab and #kontact are sure-fi re bets.

• There are lots of community mailing lists. Good ones for beginners are: [email protected] and [email protected].

• And there’s a presence at all the usual social media outlets:

• diasp.eu/u/kolab• identi.ca/kolaborg• twitter.com/kolaborg

“And speaking of elite users, there’s one other attribute of Kolab that makes its developers beam with pride, and that’s security”

components to store application data). Instead, all of the user’s data are stored in IMAP folders under the auspices of a Cyrus server and are accessed via services. To get at their data, a user must authenticate against a service. Thus, if a cracker manages to compromise an account, they would only be able to access the data belonging to the compromised user. Without a central admin account, the cracker cannot gain themselves sweeping access to user data.

The futureAt the moment, the Kolab community are busy with their latest major release. Kolab 3 has just been launched and brings a raft of improvements to existing features. Version 3 also aims to make Kolab more easily integrated into an existing setup; it will happily work with an existing LDAP system rather than its own, should you be migrating.

Other changes include the internal data format, switched from Kolab’s own version (XML based on iCal and vCard) to xCal and xCard. One of the developers’ other devotions, security, also gets a boost from the improved mobile synchronisation. Users will be able to have different credentials on mobile devices, so that the main credentials aren’t compromised in the event of a device being lost.

The fi nal release of Kolab 3 was made available on 15 January and the community are now aiming for a six-monthly release cycle. Meanwhile, the race to offer FOSS enterprise groupware will continue.

060-063_LUD_123 PK.indd 63 25/01/2013 17:47

Page 64: Linux User & Developer - Bpfine

HARDWARE REVIEWS ANDROID HACKING HELP & ADVICE APP REVIEWS

UNLOCK THE POWER OF ANDROID

ON SALE NOW> Kindle Fire HD > 30 hacks & tweaks > Galaxy Note II > Security

w w w . l i t t l e g r e e n r o b o t . c o . u k

Available from all good

newsagents and supermarkets

TIPS & TRICKS

BUY YOUR ISSUE TODAYPrint edition available at www.imagineshop.co.uk

Digital edition available at www.greatdigitalmags.com

facebook.com/littlegreenrobot twitter.com/lgrobot

Available on the following platforms

w w w . l i t t l e g r e e n r o b o t . c o . u kw w w . l i t t l e g r e e n r o b o t . c o . u kw w w . l i t t l e g r e e n r o b o t . c o . u k

Available from all good

newsagents and supermarkets

House AD Android210x297.indd 1 09/01/2013 16:29

Page 65: Linux User & Developer - Bpfine

www.linuxuser.co.uk65

Essential kit, software and resources for the open source sceneReview index

REVIEWS

How we reviewOur experts thoroughly test the kit and grade it using the following criteria

Avoid at all costs

A designer/developer’s bad day

Good but could do better

Get this. It won’t disappoint

Software or hardware nirvana

72 Live distro super-test The latest live distros fight to earn space on your USB stick

78 Fedora 18 The Spherical Cow has finally arrived!

80 Pear Linux 6.1 We put the squeeze on the

latest Pear build to see if it’s ripe

82 Fuduntu 2013.1 A fun and functional desktop for everyday use

Software

SolidRun CuBox

66 HTC One X+HTC updates its flagship smartphone for 2013

68 SolidRun CuBoxAnother tiny-PC contender

70 Samsung Galaxy Ace 2The market leader takes another shot at budget handsets

Hardware

Books 85 The latest Linux

reads dissected

“It’s one of the smallest fully featured

microcomputers around”smallest fully featured

reads dissected

065_LUD_123 PK.indd 65 25/01/2013 18:33

Page 66: Linux User & Developer - Bpfine

HTC One X+

SMARTPHONE

www.linuxuser.co.uk66

Review

ProsUp to 64GB of internal storage, very powerful and a stunning screen

ConsNo microSD card slot or removable backplate; a very large phone

HTC One X+ £462

HTC began 2012 telling the world about how it intended to streamline its range and focus on a small number of high-quality handsets rather than repeat the strategy that let the company down so disastrously the year before, fl ooding its portfolio with multiple devices barely

discernible from the rest. Alas, while HTC has made great improvements, it still has not been able to completely resist tinkering. And so we get the HTC One X+, a modest update to the company’s fl agship phone released only a few months ago. For once though, it is not tweaking for the sake of it. This update attempts to address the two main complaints about the original One X, and is worthwhile, even if it could lead to the inevitable criticism that this new model is what HTC should have produced in the fi rst place.

HTC’s One X was hailed as one of the hits of the year. With a quad-core processor, high-resolution screen, good camera and plentiful built-in storage, it was a high fl yer only let down by suspect battery life – quite a serious issue. The update improves on many of the core specs and adds a larger battery. The One X+ has a massive 64GB of internal storage and a very impressive 1.7GHz quad-core processor. It positively fl ies

HTC moves into 2013 with an update of its 2012 flagship. Does it fix what was wrong with the original?

along, though we did notice it getting hot when we pushed it by asking it to run more graphic-intensive games.

The handset supports a range of up-to-date technologies including NFC and MHL (providing HDMI-out through an adaptor used in the micro-USB connector port). It also adds a further 25GB of Dropbox storage to the internal memory for two years. And the front camera has been upped to 1.6 megapixels and takes advantage of access to a dedicated imaging chip to produce quite passable photos. Great if you like self-portraits. The main camera retains the One X’s ability to shoot a still while taking a video, and will produce the latter to 1080p resolution.

It is a pity that HTC has not seen fi t to include a microSD card slot on the One X+, though. For all that internal memory and access to Dropbox, it would have been nice to also have access to hot-swapping storage. But sadly that’s not to be.

HTC has improved on the battery this time around, providing a 2100mAh battery in place of the 1800mAh cell that was used in the original. If you’re hoping this has dealt with the poor

Operating System Android 4.1 Processor Quad-core 1.7GHz Memory 164GB storage Dimensions 134.36 x 69.9 x 8.9mm Weight 135g Display Size 4.7-inch Display Resolution 1280 x 720 pixels Expansion Slot None

Technical specs

It’s one of the best handset screens we’ve seen

066-067_LUD_123 PK.indd 66 25/01/2013 17:50

Page 67: Linux User & Developer - Bpfine

www.htc.com/uk/

More information

Improved fl agship Android smartphoneHTC One X+

REVIEW

battery life issue you’re only half right. The more powerful processor must cause a larger drain, because while we found life to be a bit better than before, it is far from superb. If we spent time gaming and using mobile data during the day, an early evening trip to the mains power was often in order.

Physically HTC has retained the HTC One X chassis design almost entirely, with only a couple of stylistic alterations. So, this handset has a polycarbonate shell with a rubberised fi nish – and it is a bit too easily scratched for our liking. A Beats Audio logo on the back indicates that the partnership continues, and fi ve little notches on the back are the clue that a docking kit can be used with the HTC One X+.

Incidentally, the chassis does not incorporate a removable backplate. The micro-SIM goes into a caddy that sits on the top edge of the casing at the back. If you’re worried about battery life, then you should be warned that you can’t swap in a spare in desperate times.

This is a big handset, and its screen is a generous 4.7 inches in size, with 1280x720 pixels of display resolution. It’s one of the best handset screens we’ve seen and perfect for reading

www.linuxuser.co.uk67

webpages, and for looking at video. It’s almost large enough for serious catch-up TV.

It is great to see Android 4.1 being used here, and HTC Sense has been given a slight makeover too. It’s not enough to jar or present you with any complex or diffi cult new learning curves, but if you are upgrading from a recent HTC handset you might notice some subtle changes.

For the most part HTC has done well with its upgrade to what was its fl agship handset of 2012. A faster processor and plenty of internal storage headline the updates. But the weakness in battery life has not been completely solved. The trade-off between power and performance looks set to continue for some time yet.

Sandra Vogel

The One X+ launches with Jelly Bean, but like on all HTC handsets the OS is largely obscured by the presence of HTC Sense. This overarching skin reworks many of the features of Android, giving them their own distinctive style and functionality

The 4.7-inch Super LCD 2 display is as good as any we’ve seen on any smartphone. It really shines here, although do beware that it saps the battery quickly as well

HTC has stuck with the dedicated buttons below the screen. They

are capacitive rather than physical buttons, and the task-switching

one can be reassigned to the Menu function if you wish

The front camera is improved to 1.6MP and takes decent pictures. The main 8MP camera on the rear can still take a still while shooting

video – the latter at 1080p

066-067_LUD_123 PK.indd 67 25/01/2013 17:50

Page 68: Linux User & Developer - Bpfine

SolidRun CuBox

MINI PC

www.linuxuser.co.uk68

Review

ProsThe CuBox offers a remarkable amount of multimedia performance in an incredibly small package, with IrDA and CEC support

ConsGeneral-purpose performance is poor for the price; little to excite developers looking to play with the ARM architecture

SolidRun CuBox £105

The CuBox, announced in December 2011, has been slow in coming to the UK, but is fi nally available through compact computing specialist New IT. Has it been worth the wait?

The fi rst thing that strikes you about the CuBox is its size: measuring just 55mm on a side and 42mm tall, it’s one of the smallest fully featured

microcomputers around. Its compact footprint comes courtesy of a split design, which moves some components onto a mezzanine board above the main PCB. Unlike the

One of the smallest fully featured ARM microcomputers on the market, can the CuBox justify its top-end price?

Raspberry Pi, OLinuXino and similar, it’s also provided in a specially designed casing which hides the components and a large aluminium heatsink that’s bonded to the processor.

The system-on-chip is a Marvell Armada 510. Based on the ARMv7 instruction set, the chip runs at 800MHz and includes an integrated Vivante GC600 graphics engine. A vMeta HD Video Decoder provides extra grunt for 1080p video playback.

That does have a knock-on effect on the system, though: the CuBox’s 1GB of memory seems generous in a market where 512MB is the norm, but a whopping 256MB is reserved for the GPU and a further 128MB for the vMeta – meaning a mere 640MB is available to the user. This can, however, be tweaked: operating system images are available to turn the CuBox into a headless server, disabling the GPU in order to give the user access to the full 1GB of DDR3 memory – extended to 2GB in the recently launched CuBox Pro.

The HDMI output on the CuBox is picky

about display types, preferring standard

16:9 TVs and monitors

Extra storage can be added via USB

2.0 or an eSATA 3.0Gb/s port, as

well as through the microSD slot

An optical port on the side of the CuBox provides S/PDIF audio output at up to 192KHz

Gigabit Ethernet makes the CuBox adept at shuffl ing high-defi nition video around a network

068-069_LUD_123_CUBOXREVIEW PK.indd 68 25/01/2013 17:52

Page 69: Linux User & Developer - Bpfine

www.newit.co.uk

More information

Miniature desktop computerSolidRun CuBox

REVIEW

Software is the CuBox’s weak point. Although it’s been out in the US for a year, development is slow and the available software lags behind rival devices. The stock OS, Ubuntu 10.04 supplied on a bundled 4GB microSD card, is particularly poor: as well as being nearly three years out of date, the software is compiled for soft-fl oat – a decision which cripples performance and makes the desktop almost unusable.

Replacing the operating system – a handily easy process, thanks to a built-in serial console available on the micro-USB port and a clever script that allows the CuBox to download operating system images and write them to its own microSD card – with a hard-fl oat build of Ubuntu 12.04 drops the SysBench benchmark time from 174.2ms to 48.83ms, beating the Raspberry Pi’s score of 51.45ms. For an ARMv7 chip, though, that score is somewhat disappointing: the Olimex A13-OLinuXino scores 25.7ms on the same benchmark and costs half the price.

Where the CuBox shines is not as a general-purpose desktop, but as a home theatre PC. Its eSATA port allows for easy connection to high-capacity external hard drives, and its Gigabit Ethernet connectivity is more than up to the job of streaming 1080p video around the place. Installing the recommended GeeXboX operating system, which includes XBMC, results in an incredibly capable home entertainment system with support for Consumer Electronics Control (CEC) for pausing, playing and navigating the menus using the TV’s

Olimex A13-OLinuXino-WiFi £59.95 A fully open source design, the OLinuXino lacks on-board wired network connectivity but comes with integral Wi-Fi support and a general-purpose processor that wipes the floor with the CuBox. Sadly, multimedia support is lacking, with the board limited to 800x600 resolution video output over an analogue VGA connection. www.olimex.com

Also consider

www.linuxuser.co.uk69

remote. An IrDA port at the front allows for a dedicated remote control – not included – and an optical port at the side provides S/PDIF digital output at sample rates of up to 192KHz.

The only real fl y in the ointment for home theatre use – aside from the £105 price tag, which puts it head and shoulders above the competition and nearly into the realm of professional development platforms – is a somewhat picky HDMI output, which is happiest when working with standard 1920x1080 displays. There’s no support for 16:10, 17:9 or 3:2 display aspect ratios, nor does it support the PAL SD resolution of 768x576. For most users, though, this will be a minor inconvenience.

The multimedia performance of the CuBox is excellent, let down only by the selective nature of its HDMI video output. The integrated micro-USB serial console makes recovery from disaster simple, and the compact dimensions make it easy to hide among home entertainment devices. Sadly, its general-purpose compute performance and high price make it a poor choice for other uses.

Gareth Halfacree

Raspberry Pi £25General compute performance of the Raspberry Pi is equal to or better than that of the CuBox, at a fraction of the price. While it lacks IrDA, eSATA or optical audio output, the Pi has a larger community and supports a wider range of resolutions over HDMI. www.raspberrypi.org

1GB of memory is generous, but a lot gets sucked up by the GPU and video decoder

A mezzanine PCB provides the secret to the CuBox’s

tiny footprint Processor Marvell Armada 510 (ARMv7)

800MHz GPU Vivante GC600 2D/3D Accelerator plus vMeta HD video decoder Memory 1GB DDR3 (shared with GPU, 640MB available to system) Storage None (expandable via microSD/SDXC card and eSATA) Ports 2x USB 2.0, 1x micro-USB, HDMI, S/PDIF optical audio, eSATA 3.0Gb/s, Gigabit Ethernet, IrDA Audio Digital via HDMI and/or S/PDIF optical port Power 5V DC at 2A (includes suitable PSU) GPIO None Extras Serial console available via

micro-USB port Operating System Ubuntu 10.04 ARMEL

soft-fl oat Size 55 x 55 x 42mm Weight 91g (excluding cables)

Technical specs

A small sensor at the front, with a transparent block in the

case, provides IrDA remote

A large aluminium heat sink is attached to the processor but

sits snug against the plastic casing, harming its dissipation

068-069_LUD_123_CUBOXREVIEW PK.indd 69 25/01/2013 17:52

Page 70: Linux User & Developer - Bpfine

It’s tough if you have around £200 burning a hole in your pocket and you are looking for the ideal SIM-free Android handset. There’s a fair bit of choice hovering around that price and Samsung recently added another option for you to ponder in the shape of the Samsung Galaxy Ace 2.

This is an update of an earlier handset that proved extremely popular with the pay-as-you-go crowd, and it has to be said that while some of the specifications are noteworthy, others most certainly are not. It also has to be said that Samsung has barely bothered to do anything novel in the design of this phone, but its solid lines are perfectly good enough.

In fact, the Samsung Galaxy Ace 2 looks very, very familiar. A physical Home button beneath the screen. A black chassis with rounded corners. Samsung’s trademark name and a silver sliver of speaker above the screen. All these are very clearly Samsung design elements.

While it might be a bit dull and samey, what’s good about the design is the well-placed buttons and connectors. Headset on the top edge, micro-USB on the bottom. Volume rocker on the left edge, power switch on the right. What’s not so good is the flimsy backplate that you could snap if you are overenthusiastic when you remove it.

Samsung Galaxy Ace 2

SMArtphone

www.linuxuser.co.uk70

review

prosHighly affordable and at 3.8”, the screen is right in the sweet spot for size and usability

ConsThe chassis is a bit chunky, it features Android 2.3 and doesn’t attempt to innovate

Samsung Galaxy Ace 2 £230

Samsung has managed a strange feat with the sound output. It’s poor through the back-mounted speaker: loud enough but rather too tinny for our tastes. Use the provided headphones, though, and it is much, much better with pretty good bass tones.

The camera benefits from an on-board photo editing app, but shooting itself isn’t a great experience. You can’t expect more than 5 megapixels from a handset in this price bracket, and photos are okay as far as quality goes, but there is a big issue: there is serious shutter lag here, and you will need a steady hand to take a half-decent photo. Don’t even think about trying to capture a sharp image of anything that’s moving. If your pet cat is photogenic, you’ll need a proper camera to capture its antics instead of this phone.

The highlight of the Samsung Galaxy Ace 2 has to be its screen. At 3.8 inches it hits the sweet spot between size and usability. Larger than this and phones tend to get a bit too big for many people to use one-handed. Smaller and it can be difficult to do media-rich activities like browsing webpages or watching video. At this size both those activities are nice, and eBook/email reading are easy on the eye. The keyboard is perhaps a bit cramped for some hands, but that particular size/usability compromise will be a personal matter.

operating System Android 2.3 processor Dual-core 800MHz Memory 4GB storage Dimensions 118.3 x 62.3 x 10.5mm Weight 118.5g Display Size 3.8-inch Display resolution 800 x 480 pixels expansion Slot microSD

technical specs

The Samsung Galaxy Ace 2 is a budget handset with highs and lows to reel you in, turn you away and reel you in again

070-071_LUD_123 PK.indd 70 25/01/2013 17:53

Page 71: Linux User & Developer - Bpfine

www.samsung.com/uk

More information

Low-cost Android all-rounderSamsung Galaxy Ace 2

Review

The screen itself is clear and sharp. Its 800 x 480 pixels aren’t top-notch, but they do deliver pretty crisp results, and we had no real problems. It’s perfectly acceptable for the price point.

We do have a couple of major gripes, though. Android 2.3 is used here, and that just feels quite old hat now. It’s not that you’d have a big problem with it, and it is well hidden for the most part beneath Samsung’s TouchWiz UI, but it’s a couple of paces behind the leading edge and you will find that some apps are not available for the device, such as the Chrome browser for instance. More significant is that the 4GB of storage installed equates to just over 1GB that’s user accessible, and that probably won’t be enough for you. While microSD cards are cheap enough these days, we’d rather not have to buy one right from the off, or would at least prefer to pay a very small amount extra to have one included in the box.

There’s good news on the performance front. The dual-core 800MHz processor is nippy, supported ably by 768MB of RAM,

www.linuxuser.co.uk71

and the battery ought to get many users who place average-level demands on their phone through a whole day between charges. This is not a phone for those who want to play the latest high-end games, but for the Angry Birds crowd it is more than up to the job.

Overall, when you add up the pros and cons, the Samsung Galaxy Ace 2 comes out as a pretty good phone, its screen and capable processor standing out in particular. However, if it is on your new phone shortlist, make sure the negatives aren’t things you really care about.

Sandra Vogel

The dual-core 800MHz processor is nippy

The micro SD card slot is on the edge of the phone, and protected by a hinged cover

The 5-megapixel main camera is supplemented by a front-facing VGA option

The screen might not be as large as we’re accustomed to, but it delivers good quality

One thing is guaranteed to give away the value of a phone, and its position in the pecking order: its girth. The Ace 2 is a thickset device, taking away much of the benefit that is gained from the smaller all-round profile

070-071_LUD_123 PK.indd 71 25/01/2013 17:53

Page 72: Linux User & Developer - Bpfine

group test

www.linuxuser.co.uk72

Live distro group testreview

trackers, are available for programming. Every major video and music player, creator and editor is also included, along with preconfigured Wine and a decent set of system management tools.

It’s more than a lot of people may be wanting to use; however, if you’re planning to install this to a USB stick and use it as a mobile system, you can easily add and remove missing or superfluous packages as you see fit. The separate HD and flash disk installers give you different options to automatically or manually partition drives, and you can choose a persistent memory option at the end of the flash install to create a way to save system settings.

Speed-wise, Knoppix manages to boot incredibly fast thanks to its own custom bootloader that allows you to add your own specific options at boot time. The so-called cheat sheet for this is available on the website to get the most out of it, although simply hitting Return will get you going for any normal situation. It’s still a great live distro after all these years, and that’s no easy accomplishment.

Knoppix 7Which portable Linux distro allows you to have a fully functional Linux system with office suites, IDEs and more, wherever you need it?

Knoppix has been around for a long time now, and the Debian-based distro has gone through a lot of changes over the years to keep it current with not only the changing computing landscape, but differing user requirements. USB installs and a change from KDE to LXDE are just two examples of these developments in recent years, to deal with the proliferation of large USB sticks and low-power hardware respectively.

Knoppix takes a kitchen sink approach to the distro, loading it up with an absolute ton of software that really bulks out the DVD version of the live disc to a full 4GB or so – packing it with much more software for office use, programming and engineering, according to the official blurb. For web you have multiple browsers such as Chromium and Iceweasel, torrent clients, mail clients, instant messenger clients, feed aggregators and more. The full LibreOffice suite is included in the office software, along with some lightweight alternatives and a LyX processor. Major IDEs such as Eclipse and IDLE for a number of languages, as well as web editors and bug

Live distros

n Knoppix has hundreds of apps pre-installed

n Installation is handled by different apps for different storage

scores

customisabilityBoot options give you a lot of customisation while live, which carries over to installs

softwareFantastic selection of default software, and access to much more

InstallationA quick and easy process that automates some key processes 9

overallKnoppix was and continues to be a great live or portable distro if you have very specific Linux needs you cannot always satisfy

9

9

9

knoppix.netMore information

speedThanks to using LXDE, Knoppix boots very quickly and stays fast while using it

8

072-076_LUD_123 PK.indd 72 25/01/2013 17:54

Page 73: Linux User & Developer - Bpfine

Three years in the making, Slax 7 brings a major overhaul to the previous 6.x line of the Slackware-based portable OS. Most noticeable in the update has been the upgrade of KDE to a much more recent 4.9, a big leap over 3.5 that was in the last version, and a technical triumph as the usually bloated KDE has been wrangled into a fully functional Linux distro that can come in a tiny 210MB ISO if needed.

This base ISO has very little to it, though – Firefox and SMPlayer are among the most exciting applications included by default, and you’ll need to load up a Google Doc if you want to do any more word processing than Kate can handle. If you want to have a bit more included with Slax, you can add ‘modules’ to the ISO before you download directly from the Slax website. Different categories of module are available, maintained by the community, and they allow you to add software, office suites and programming IDEs to expand the functionality. Before Slax 7 came along, the modules for 6 numbered in the thousands and were kept well up to date, as best as Slax 6 would allow. Unfortunately, this number has reduced significantly since 7’s release and has not recovered yet, with temporary solutions to use Calligra Office suite, while Eclipse isn’t even available yet. This will turn around, but it won’t be for a little while.

As a more portable OS, Slax doesn’t really have a way to be installed to a system HDD in

the software, and the best way to put it onto a USB stick or similar is by using something like UNetbootin or any other alternative flash installer. While Slax does automatically detect any attached USB storage, like the one it lives on, it would be nice to have the tools to replicate it to other USB sticks or hard drives. At the very least, it’s much more common and practical to use live distros from USB storage.

Even using KDE, as Slax is so lightweight in general, it runs at lightning speed. Of course, the more you put on the ISO, the slower it will get; however it doesn’t have anywhere near the bloat of some of the full desktop distros.

Four of the best live distros battle it outLive distro group test

Review

www.linuxuser.co.uk73

Slax 7

n The extra modules section is a bit thin right now

n The modified KDE is fast yet still works just like KDE

ScOReS

customisabilitySoftware on the distro is highly customisable, when it’s actually ready

SoftwareThe base version has very little, and there’s not much to add to it right now from modules

installationNo dedicated installer program, but putting it onto a USB stick is fairly easy 6

OverallWe like Slax, but it’s going to be a few months or even a year before there’s enough available software to make it worthwhile 6

4

10

www.slax.orgMore information

SpeedExtremely fast thanks to a very lightweight image and modified KDE

8

072-076_LUD_123 PK.indd 73 25/01/2013 17:54

Page 74: Linux User & Developer - Bpfine

www.linuxuser.co.uk74

Review

to any device really, and even includes tools to prepare a USB stick for installation. Also, if you put the image onto a USB stick to begin with, you have a portable way to install Ubuntu, and UNetbootin will allow you to create some specific space on the storage to save files and changes.

So it’s not the absolute worst live distro – in a pinch you can easily get some office work done or even just watch something to pass the time. However, if you need a serious portable distro and you need to do some real work on the go on many different computers, Ubuntu is probably not the best distro for the job.

Ubuntu 12.10Ubuntu was one of the earlier distros to adopt the use of a live disc, and while it is primarily used to let you test out some of the Ubuntu basics, this test environment gives you access to quite a large selection of default applications.

The software present on this base Ubuntu covers you pretty well for a lot of simple tasks: Firefox for web browsing, Thunderbird for emails, Rhythmbox for music, a video player, torrent client and even apparently a disc-burning utility in Brasero. There are some system tools present as well, so you can manually set up your computer before installing it on a regular machine. However, there aren’t any programming tools or IDEs to let you get on with some more heavy coding from the environment. There is the ability to add some extra software, but it’s limited to only the packages in the Ubuntu Main repo – while apparently numbering 10,000, this is a lot less than the full 60,000+ of full Ubuntu.

One of the major problems using Ubuntu as a live distro is that it’s slow in comparison to all the others, and is not well suited for older or very underpowered machines. While it will certainly run, the user experience will be pretty terrible and it doesn’t have the benefit of being able to boot into either a 32- or 64-bit kernel like Knoppix can.

Installation-wise though, it’s probably the best. From the live environment, it allows you to install

Review

n Installation to all types of storage is quite easy

n Good for office and media, not so good for programming

Live distro group test

scoRes

customisabilityYou can add the odd piece of software and change the off-system setting

softwareUsable and extensible, but otherwise still a fairly basic selection of applications

InstallationIt’s Ubuntu, so it has a fantastic native installer for all devices 10

overallIt was worth a look, but Ubuntu just doesn’t really cut it as a live distro, although it wasn’t really designed to be one 5

6

3

www.ubuntu.comMore information

speedWhile fine on modern PCs, anything where resources are a premium will be affected

4

072-076_LUD_123 PK.indd 74 25/01/2013 17:54

Page 75: Linux User & Developer - Bpfine

Review

www.linuxuser.co.uk75

Porteus 1.2

Review

n Simple and with a decent number of applications, Porteus can add more though

n You can select different

boot options like choosing

a desktop

existing files to the hard drive or a USB stick takes a few minutes at most, depending on system and write speeds, and it allows you to set up bootloaders. If you’ve installed it to a USB stick, then you’ve basically got a clone of whatever live media you were using, allowing you to install it onto further devices and storage in the same way.

The one thing we have to say is that Porteus is not presented all that well, and although we gladly make concessions for such a small distro, Slax itself looks a lot more professional – better than the sort of hacked together live distro it really is. Functionality-wise though, Porteus is pretty amazing.

Four of the best live distros battle it outLive distro group test

scoRes

customisabilityActivating and deactivating modules and other customisations affords you a lot of control

softwareA decent set to start, with a full library accessible after the fact

installationWe like its quick and simple installations that can be done over and over 9

overallPorteus is a great reimagining of Slax that allows you to change and tweak stuff after installing, rather than having to get a brand new ISO

8

8

7

www.porteus.orgMore information

speedVery fast in general, although mildly laggy sometimes, but only relative to the others

8

Based on an older version of slax, Porteus provides a much more comprehensive ‘base’ than its ancestor, but still comes in a tiny package of around 250MB while including multiple desktop environments, along with a handful of extra applications to get you going. It handles a lot of functions quite differently from Slax as well, making it a little more customisable post-installation.

Mainly, instead of using a system to add software modules to the ISO, it has its own package manager for adding and removing software. The Porteus package manager treats this in a similar manner, though, referring to the packages as modules, and grants access to other Slackware- and Slax-based distros’ libraries to download from. Porteus itself has a large number of programs available in its repos anyway, so this should only be necessary for the more obscure packages. The Slax style of adding modules to the image does still exist to a degree, though, as you can add specific video drivers to the image beforehand.

Porteus is very fast. Boot time is minimal, with a pause taken only to choose a desktop environment to begin with – LXDE or KDE for the basic version. LXDE is of course slightly faster, but the KDE version is definitely much faster than a lot of other KDE 4 implementations, save Slax 7. Speaking of that, Porteus is perhaps not as fast overall as Slax, but it beats it by a mile in the installation department: merely copying the

072-076_LUD_123 PK.indd 75 25/01/2013 17:54

Page 76: Linux User & Developer - Bpfine

Installation Dedicated install options for multiple types of storage

Limited installation options other than using UNetbootin from other systems

Ubuntu installation is simple and straightforward onto any storage

Installation is easy and fast and can be done from installed devices

Software Comes with a huge selection, and you’re able to add more

At the moment the software database is slowly being rebuilt, but is lacking

A fairly basic selection that can be somewhat augmented

A good selection of all types of software but offi ce, with more to add

Customisability Easy enough to add and remove software, with other system modifi ers

Fully customisable with different modules of software to add and remove

Not a huge amount can be changed other than a little software per session

Not much can be done beforehand, but a rich selection of packages can be installed

Speed Very fast, in part thanks to a custom bootloader and LXDE

Thanks to it being very lightweight, it’s fast even using KDE

On modern machines it’s fi ne, but in comparison it chugs along

Generally very fast, but seems to lag a little on slower machines more than others

Overall

A comprehensive live and portable distro for working on system maintenance

Out of the gate with a limp, Slax still needs a few months to mature

Not suited for a live or portable distro if that’s what you need, but okay in an emergency

A great Slax remix adding functionality and post-install customisation

www.linuxuser.co.uk76

Review

KnoppixKnoppix takes home the trophy in this group test for a number of reasons. Firstly, even for what could be considered a bloated image for CD and DVD compared to the Slaxes of this world, it still runs fast enough for this to be of little consequence. And the best part is, you then get to keep the sheer plethora of available applications that Slax frankly lacks right at the moment.

If Slax had full access to a more complete library of packages, it may have been a different story, though. While it may not be a clear victor, it would give Knoppix a run for its money by being able to have a much more focused and lightweight image with a similar selection of apps far more customisable to what the user wants. This space saving can be essential when using USB storage if nothing else.

Rob Zwetsloot

AND THE WINNER IS…

In brief: Compare and contrast our verdicts

GROUP TESTWINNER

■ Full software repos are available to customise your Knoppix

8

9

9 4

69 10 9

8

8

6

10

4

3

8

7

9 6 5 8

Live distro group test

072-076_LUD_123 PK.indd 76 25/01/2013 17:55

Page 77: Linux User & Developer - Bpfine

The Cloud Computing Book Packed with tutorials and guides to help you make the most of cloud computing, you can learn how to share fi les, store documents, send images, play games, read books, watch movies and much more. £12.99

Linux & Open Source Genius Guide Vol. 3 This book will walk you through everything you need to know to become a Linux master. With tutorials for Ubuntu, Android, SUSE and more.£14.99

The Cloud Computing Book Packed with tutorials and guides to help you make the most of cloud computing, you can learn how to share fi les, store documents, send images, play games, read books, watch movies and much more. £12.99

Perfect products for Linux professionals…

Essential guides to mastering open source softwareand operating systems from Imagine Publishing.

Linux & Open Source Genius Guide Vol. 2From in-depth features and step-by-step tutorials to expert interviews and essential software, the Linux & Open Source Genius Guide will walk you through everything you need to know to become a Linux master.£7.99 with code

Web Design: From Desktop to Dotcom eMag Vol. 1 A visual guide to Flash, Dreamweaver and Photoshop. Including 256 pages of walkthroughs on one disc!£4.99

Web Designer eMag Vol. 1 Enjoy 21 issues of Web Designer on one interactive disc. Over 1800 pages of expert tutorials, case studies and features. Plus all tutorial workshop fi les included!£4.99

Discount code

Get Linux & Open Source Genius Guide Vol. 2 for

half price with the code…

OPEN

Order online

Become an ImagineShop customer and leave reviews of your favourite products.

MAGAZINES BOOKS DVDS DOWNLOADS GIFTS

Back issues

Bookazines DVDs

Web Designer eMag Vol. 1 Enjoy 21 issues of Web Designer on one interactive disc. Over

Web Design: From Desktop to Dotcom eMag Vol. 1 Web Design: From Desktop to Dotcom eMag Vol. 1 Web Design: From Desktop

A visual guide to Flash,

DVDsDVDs

£19.99now from

£4.99

@imagineshopuk/imagineshopuk

£6From £4with code

TUX

LinuxAd_ImagineShop.indd 1 25/01/2013 15:37

Page 78: Linux User & Developer - Bpfine

www.linuxuser.co.uk78

Fedora 18Review

A new Fedora is always a big deal, as the Linux distribution is known for being on the bleeding edge of free and open source software and technology, coming with the best and brightest the extended community has to offer. Fedora 18 may have had a bit of a bumpy ride to the finish line, but the longer

wait hasn’t hampered the quality of the release at all. Any quality problems are mainly down to GNOME 3.6, but we’ll get onto that later.

As we mentioned in our review of the beta, the new installer is a wonderful, minimalist-designed app that allows for quick installations with decent default settings, and a more advanced setup if you have some specific requirements.

It also starts copying and installing while you finish up with root passwords and such, similar to how the Ubuntu installer works. While there’s not always much to do after the actual installation starts, it’s a step in the right direction to streamline the installation process. It also has the standard post-reboot user setup that we also saw in Fuduntu this issue, which is good for OEMs and sysadmins, and doesn’t really slow down the process for desktop users. The actual installation itself is a little slower than we’d like, but it won’t keep you waiting for too long.

It’s after all this that you’re put straight into an updated GNOME environment – GNOME 3.6. We’ve aired our grievances in previous issues about this latest version of GNOME, about how it slows down workflow in favour

Fedora 18distRo

After much delay, the Spherical Cow makes an entrance. How does the final version of Fedora 18 measure up?

n The new Fedora is finally here

n Installation is easy and looks great

ProsA great installer, and it’s also nice to see MATE and Cinnamon in the standard repos

ConsLimited software selection due to FOSS commitment, GNOME 3.6 is horrible to use

078-079_LUD_123_FEDORA18 PK.indd 78 25/01/2013 18:08

Page 79: Linux User & Developer - Bpfine

of being touch and keyboard friendly. Luckily, it’s at this point that you can start installing any number of other desktop environments, such as KDE, Xfce, or newcomers Cinnamon and MATE. Now that both of these are native to the repos, they definitely look a lot better than previous implementations on Fedora 17, with fonts being crisper on Cinnamon, and MATE gaining the ability to look a lot more like a modern desktop. Red Hat has a big stake in GNOME, same as Fedora, so it’s not surprising that it still shows up as the main desktop choice. It would be nice to have more available spins, though.

There’s a bit of an update to the default app selection as well, and while nothing has really changed that’s not related to the system settings, the Fedora Project has at least added the LibreOffice suite to the starting selection. While it’s a minor thing, it’s a nice addition. On the system tools side, the package manager, updater etc are all now part of the same generic Software app. This is not accessible by typing ‘update’ or ‘updater’ into the search bar, and in GNOME 3.6 the drop-down menu to access the graphical updater is a little hidden. It’s easier to just use YUM to update the system.

The Fedora devs also thought it noteworthy to mention the inclusion of a new command-line tool, System Storage Manager. Available in the repos, this can do some basic partition management, as well as checking partitions for errors and such. It’s a nice little tool, perhaps more suited to headless servers or working from the command line.

Otherwise, it’s got the standard package and security updates, a move to Linux kernel 3.6.y, and is still a great operating system for desktop, server or the cloud.

Fedora 18 is a minor but important improvement over Fedora 17, and the new desktop environment choice is great for desktop users, especially with the inclusion of a default GNOME 3.6. Fedora is just as slick, up to date and free as ever, and well worth the update.

Rob Zwetsloot

fedoraproject.org

More information

Final release of cutting-edge Linux distroFedora 18

Review

www.linuxuser.co.uk79

n The GNOME 3.6 features and simplification can be frustrating to navigate

The new installer is a wonderful, minimalist-designed app

n The inclusion of Cinnamon is a great, modern alternative to GNOME 3

n MATE integration is great, and brings GNOME 2 back for purists

n The default app selection has grown just a bit

078-079_LUD_123_FEDORA18 PK.indd 79 25/01/2013 18:08

Page 80: Linux User & Developer - Bpfine

The last time we reviewed Pear Linux, the French developer had just changed the name to Comice OS in an effort to rebrand it slightly, to whatever end. This was an updated version of Comice OS 4, which launched with several bugs making it difficult to install, and near unbootable unless you exited to command

line and started X manually. The ‘fixed’ version worked all right, but there were still some underlying bugs that made it unsuitable for day-to-day use. So after a name change back to Pear Linux, and a couple of version number upgrades, we’re back to try out the OS X-inspired Ubuntu distribution. And it’s still a mess, only for wholly different reasons now.

The image for 6.1 is a point update to another, apparently troubled, 6.0 release, and at the very first step it will not

even live-boot. On different machines it either started X and then did nothing else, or hung at the boot graphic. This is a wide-ranging problem also affecting other users; however, at the very least, if you choose the install option at the boot menu, this works just fine. The installation is pure Ubuntu, with a few branding changes, so it’s pleasant enough to use and installs at an average/decent speed on a modern computer.

After installation, you’re presented with the fairly clean, custom Pear desktop environment. Drawing its interface inspiration from OS X, there’s a dock at the bottom of the screen, and the top bar displays user and time information. While you can click the top left of the bar to open up a list of applications, the so-called Launcher (named after the Mac equivalent) is also on the dock. It’s split up into categories

www.linuxuser.co.uk80

Pear Linux 6.1Review

n Pear comes with built-in social networking tools

Has the beleaguered Ubuntu spin sorted out all its issues, or is this OS X clone still not ripe?

diSTRO

Pear Linux 6.1ProsA shiny interface that does a good impression of OS X while offering the superior workflow of a Linux DE

ConsStill very buggy, albeit for different reasons. Won’t live-boot, problems with virtualising, and Appstore broken

080-081_LUD_123_PEAROS v2 PK.indd 80 25/01/2013 18:09

Page 81: Linux User & Developer - Bpfine

in the standard GNOME way, but there’s very little on there after you first install it.

At this point you’ll want to start installing packages, and there’s a special Pear Appstore (a reskinned Software Centre) to give you access to the various software. Only, the Appstore will never load, cycling a loading animation for as long as we could bear to watch it. Based on our impressions on earlier versions of Pear Linux, this is a great-looking software centre that works absolutely fine, grabbing the right data from the repos and Ubuntu sources to make it a different experience from its Linux counterparts. Luckily, the distro comes with Synaptic installed by default, so if you’re uncomfortable installing all your packages from the command line, you can at least do it graphically. It’s a shame though, as this is one of the selling points of Pear Linux.

Another problem that occurred during testing was when we decided to install it on a virtual machine – everything

was going well, just like it had on a physical machine, and it even had the correct Guest Additions installed for VirtualBox. However, once logged in, a permanent black bar covered the right quarter of the screen, obscuring full-screen windows and not letting you click past it. Virtualising is great for testing out app builds and if you only have access to a severely handicapped version to test on, it won’t go well.

It’s disappointing really, as while not everyone is hankering for an OS X experience on Linux, it doesn’t mean there shouldn’t be one for those that do. The interface is great to use, almost perfectly copying the Mac while throwing in a few Linux extras that make it overall a bit better. Maybe next time we look at it, it will work flawlessly. And we won’t have to use a ‘ripe’ pun again.

Every time we use Pear, we want to like it. There’s a lot of great potential for a custom, ‘unique’ interface that goes beyond the OS X one it’s trying to imitate. However, each time there’s always something pretty major that breaks the experience. One to avoid for the moment, especially the 64-bit version.

Rob Zwetsloot

pearlinux.org

More information

OS X-inspired Ubuntu spinPear Linux 6.1

Review

www.linuxuser.co.uk81

You’re presented with the fairly clean, custom Pear desktop environment

n Pear looks great, but does not work so well

n At least there’s an alternative to the broken Pear Appstore

n There’s a browser choice app similar to Windows

n The black bar obscures a fair portion of the virtual desktop

080-081_LUD_123_PEAROS v2 PK.indd 81 25/01/2013 18:09

Page 82: Linux User & Developer - Bpfine

Fuduntu 2013.1

distro

www.linuxuser.co.uk82

review

ProsGreat to use, plenty of apps in repos, only Linux distro to support Netflix and Steam

ConsGNOME 2 is still great, but it’s starting to show its age in the light of MATE’s maturity

Fuduntu 2013.1Whenever we get a chance to look at the new Fuduntu, our first impressions are always about how nice it is to work with. Positioning itself as a lightweight, battery-friendly distro, Fuduntu is one of the few remaining Linux distributions that still uses the venerable

GNOME 2 desktop environment, enhancing its functionality with a dock similar to OS X. It’s quite fast, and comes with a decent selection of default apps to let you hit the ground running while you further enhance the experience.

Installation of Fuduntu is nice and simple, with some advanced options for storage and partitioning, followed by setting up users and other system options post-reboot. This particular Red Hat/Fedora style of install is always great for

Designed to fit somewhere between Fedora and Ubuntu, this fork of Fedora is a fully functional and easy-to-use distribution

OEMs or sysadmins, and the Fuduntu version is as good as any other bar the Mandriva-derived distros. The whole process runs at a fairly normal speed on a modern computer, but is nothing to shout about.

The initial Fuduntu setup comprises Chromium for web browsing, LibreOffice suite for all kinds of office work, and a small selection of media players. Enough to get yourself going, then, and the repos are well stocked with programming packages and IDEs, among everything else, so it’s quick enough to get down to some serious work if time is short. The dock for the GNOME 2 interface has been changed from AWN in previous versions to Cairo – apparently AWN is no longer maintained and there are a few bugs present that are not being fixed. The Cairo dock is a nice replacement, works

n A nice welcome when you start Fuduntu

082-083_LUD_123_FUDUNTU PK.indd 82 25/01/2013 18:10

Page 83: Linux User & Developer - Bpfine

proprietary, non-free software, and that is not likely to change in the foreseeable future – it’s just nice to have them so readily accessible.

Fuduntu is a great, user-friendly distro that is very much focused at users who are in the community and need a straightforward version of Linux to use day to day. The extra additions and changes make sure it’s kept relevant as well, and as a rolling distro it means you’ll have to worry about upgrading a lot less than with others.

Fuduntu is a pleasure to use and doesn’t really have any concessions made to appease any particular sect of the community. The use of GNOME 2, while perfectly fine, still seems odd, but it works well even with the new additions of Steam and Netflix. The distro is great for laptops too, with its power management.

Rob Zwetsloot

Latest release of Fedora forkFuduntu 2013.1

Review

www.linuxuser.co.uk83

in practically the same way and allows for some snazzy UI effects like previewing the contents of a folder on the dock, and of course hides away just fine when it’s not in focus.

It seems odd in 2013 for a modern, up-to-date distro to still be using GNOME 2, especially with some high-profile alternatives. Especially MATE, which is slowly maturing as a very competent replacement and upgrade to the original codebase. GNOME 2 still runs fine, of course, and the extra functionality from Cairo is much appreciated; however, it may be time to think about changing to MATE.

There are a couple of new, fairly high-profile apps that have been added to Fuduntu – namely Netflix and the Steam Beta client. Fuduntu is the first Linux distro to officially support and distribute either of these via its repos, although there are a few caveats. Netflix itself has to run on Wine, and installing and setting it up takes a while as it sets up enough core Wine modules to allow it to run. It can then be found in the Sound & Vision part of the applications menu; however, we generally had issues getting it to work on our review setup in what was apparently a rare case for people using Fuduntu. Steam is a native app, though, so there wasn’t any problem there. Of course, both of these apps are restricted, www.fuduntu.org

More information

New, fairly high-profile apps that have been added – Netflix and Steam

n The default apps in Fuduntu are a great starting point

n The repos are well stocked with more software

n GNOME 2 still works fine, but it might be time to move to MATE

082-083_LUD_123_FUDUNTU PK.indd 83 25/01/2013 18:10

Page 84: Linux User & Developer - Bpfine

Subscribe today & start savingSubscribe

• Subscribe today and pay just $128 for 13 issues*

• Pay as little as $9.85 an issue – usually $15.99 in stores

For more information and to order visitwww.imaginesubs.co.uk/ludOr call +44 (0) 1795 418661

Exclusive subscriber benefits

*Terms and conditions: This is a US subscription offer, please don’t forget to quote USA when ordering. You will actually be charged £80 sterling for an annual subscription. This is equivalent to $128 at the time of writing, although the exchange rate may vary. Five free issues refers to the newsstand price of $15.99 for 13 issues being $207.87, compared with $128 for a subscription. Your subscription will start from the next available issue. This offer expires 31 May2013.

Imagine Publishing publishes more than 20 monthly magazines, some of which have been running for over 10 years, reaching over 4 million readers every year

Non-USA readers see page 30

5 free issues*today and get

SubscribeUSA special offer

For more information and to order visitYour

exclusive offer code:

USA

84 www.linuxuser.co.uk

084_LUD_123 PK.indd 84 25/01/2013 18:10

Page 85: Linux User & Developer - Bpfine

www.linuxuser.co.uk85

Latest Linux books revealedBook Reviews

REVIEWS

Prentice Hall is known for Charles ‘SGML’ Goldfarb’s XML series, and in particular Definitive XML Schema, the classic work on XML schema. This second edition, ten years after the first, is updated for XML 1.1 (released by W3C in 2012) and looks set to extend the classic for at least another decade.

Walmsley’s work of reference is also intended to be read through as a tutorial, starting with the purpose of schemas (and considering alternatives such as RELAX NG); then walking the reader through an example schema; exploring the role of namespaces; the relation between instances and schemas; then exploring elements and attributes, the building blocks of XML, and when to use local or global declarations.

As knowledge is introduced, it is related back to the reader’s own design problems, such as how to break down data values. Complexity is built from simplicity. Design, documentation, extensibility, reuse and versioning round off a work that should sit on the bookshelf of anyone who has to work with XML documents.

Definitive XML Schema, Second Edition

Object-oriented design (OOD) has been bogged down carrying Java and C++’s baggage train, and OO principles are usually picked up by osmosis, rather than in any systematic fashion. Metz is here to bring back the certainties of real OOD, giving Ruby programmers of all levels rules and principles, and preparing you to use design patterns properly.

“OOD is about managing dependencies” – to reduce the cost of change. Metz brings design squarely into programming with agile techniques: OOD techniques giving the ability to support the changes that the agile methodology needs.

From the right way to create a class (hint: a single responsibility), to really making dependencies work, Metz helps you code a ready-to-evolve collection of loosely coupled objects. Using Ruby’s duck typing, and walking you through, then around, a number of elephant traps, the author is bursting with insight that she communicates into the fractal nature of object-oriented design, laying down the rules, then giving the reader the confi dence to try breaking them.

Author: Sandi MetzPublisher: Addison WesleyISBN: 978-0321721334Price: £25.99

Ethics of Big Data: Balancing Risk and InnovationA timely enquiry into IT’s newest set of problems

With 90 per cent of the world’s data generated in the last two years, the unprecedented size, variety and velocity of new information generates new questions, and companies that have lost reputation through mishandling of aggregated data seem to be those who have failed to ask the right questions, and act on their values.

Davis looks at four distinct areas of big data ethics: identity, privacy, ownership, and reputation – and how to frame enquiry into your values in terms of these areas. He then walks us through methods (and benefi ts) of putting values into practice.

The book is a timely ethical enquiry into big data, giving organisations and individuals the necessary framework to ask important questions which just weren’t necessary a few years ago. If your organisation wants to align its actions to its values, here is the framework you need to conduct the necessary conversations. In cyberspace, it seems, philosophy still has something to contribute to practical action.

COMING SOONThe best Linux books heading to a bookshelf near you…

Really understand the what and how of OOD

Still the defi nitive guide to XML schemasAuthor: Priscilla WalmsleyPublisher: Prentice HallISBN: 978-0132886727Price: £38.99

Practical Object-Oriented Design in Ruby:An Agile Primer

CentOS 6 Linux ServerCookbook: RAW

Author: Jonathan HobsonPublisher: PacktISBN: 978-1849519021Price: £30.99

Maintain a performance-based server solution, from

monitoring your RAM to managing the syncing of remote fi les. Administer the fi le system, from monitoring hard disks to rebuilding a logical volume. Design and implement a series of checkpoints to protect your server. Deliver a domain name service to power the working environment.

ProcessingCreative Coding and Generative Art in Processing 2

Authors: Ira Greenberg, Dianna Xu, Deepak KumarPublisher: ApressISBN: 978-1430244646Price: £35.49

A fun and creative approach to learning programming.

Using the easy-to-learn Processing programming language, you will quickly learn how to draw with code, and from there move to animating in 2D and 3D. These basics will then open up a whole world of graphics and computer entertainment.

Performance Modeling and Design of Computer Systems Queueing Theory in Action

Author: Mor Harchol-BalterPublisher: Cambridge University PressISBN: 978-1107027503Price: £48.00

Bringing queueing theory decisively back to computer science, this book is written with computer scientists and engineers in mind and is full of examples from computer systems, as well as manufacturing and operations research. The goal is to train readers not only to customise existing analyses but also to invent their own.

Author: Kord DavisPublisher: O’Reilly

ISBN: 978-1449311797Price: £15.50

monitoring your RAM to managing the

Prentice Hall is known for Charles ‘SGML’

Definitive XML Schema, Second Editionguide to XML schemas

085_LUD_123_BookReview PK.indd 85 25/01/2013 18:11

Page 86: Linux User & Developer - Bpfine

Send us your questions and we’ll do our best to answer them!

Russell Barnes has been a computer and technology journalist for nearly 15 years

Questions & answers

This month your questions were answered by…

ASK THE EXPERTS

Rob Zwetsloot studied aerospace engineering, using Python to model simulations

www.linuxuser.co.uk86

answeredYour questions

Contact us...Email: [email protected]: www.linuxuser.co.uk

Become a fan on

Linux User & DeveloperContact us @linuxusermag

Gareth Halfacree has been breaking, fixing and overclocking his PC for years

Joey Bernard helps researchers with scientific computing problems

n LibreOffice is readily available in the Fedora repos

Out of OfficeHi, I’ve run into a problem that I hope you can help me with. I tried to install LibreOffice 3.6.4 on Fedora 17, 32-bit version, using the following method:

First I downloaded the compressed Fedora RPMs from the website using wget, then made sure to remove any older version of OpenOffice. It turned out there was no OpenOffice on my system, so I then extracted and then installed the packages like so:$ cd /tmp/LibO_3.6.4_Linux_x86_install-rpm_en-US/RPMS/$ rpm -Uvh *.rpm$ rpm -Uvh desktop-integration/l i b r e o f f i c e 3 . 6 - f r e e d e s k t o p -menus-3.6*.noarch.rpmAfter that was all done, I tried to run LibreOffice from the command line using ‘libreoffice3.6’ and was greeted with this error:/opt/libreoffice3.6/program/soffice.bin: error while loading shared

libraries: libpng12.so.0: cannot open shared object file: No such file or directoryIt’s also not showing up in the menus, under Office or anywhere else. Have you got any suggestions on how to fix it?

Mark Poffo

Well, what you can do is try to locate the shared object file. You can do that using:$ find /usr/lib /lib -name libpng12.so.0 or

locate libpng12.s0.0Then run:$ ldd /path/libpng12.so.0After that, find out the missing object file from the ldd o/p and then search/locate for the missing object file: $locate <missing so file>If you find out there’s a similar file, create a soft

086-89_LUD_123_Qand A PK.indd 86 25/01/2013 18:34

Page 87: Linux User & Developer - Bpfine

All your technical problems solvedQuestions & answers

www.linuxuser.co.uk87

Q/A

■ GnuCash is popular among accountants

link to that fi le and run ldd again. Alternatively, you could just try installing again, this time using YUM instead. LibreOffi ce is in the Fedora repos, though, and is kept fairly up to date, so you shouldn’t have to download the fi les separately.

Money managementWhich personal fi nance program would you suggest? I’m currently looking at GnuCash or KMyMoney, and I had planned on being further down-the-road in my testing of both products, but alas it is now getting close to my self-imposed deadline to make a decision. My objective is to dump Quicken.

To get the data out of Quicken and into either GnuCash or KMyMoney, I need to generate a QIF, which turns out to be less than satisfactory. As an editorial aside, Quicken is very hostile when it comes to sharing (exporting/importing) data. In fact, the ability to export/import data from Quicken seems to have been essentially deprecated. A major reason for moving to a Linux-based accounting program.

So far, I have only accomplished preliminary massaging of imported data. In terms of testing, it has been easier to import data into GnuCash than into KMyMoney. Last night I was able to ascertain that KMyMoney ‘chokes’ when attempting to import securities. The

■ RAID 10 offers simple striping and mirroring in one array

Storage RAIDHi, I’ve done a couple of mdadm arrays and foolishly assumed I knew what I was doing. Now I’m stuck. I was trying to build a four-drive RAID 10 array, but I messed up the command syntax:$ mdadm -v --create /dev/md0 --level=raid10 --raid-devices=4 /dev/sda1 /dev/sda2 /dev/sda3 /dev/sda4

Notice I was incrementing the number and not the letter. Well, the array creation failed and I found my mistake. I then tried to create the array using the correct syntax:$ mdadm -v --create /dev/md0 --level=raid10 --raid-devices=4 /dev/sda1 /dev/sdb1 /dev/sdc1 /dev/sdd1

It once again failed to create an array so I tried to remove what I thought was a broken array. But the stop command$ mdadm --stop /dev/md0just gives me an ‘It’s a directory’ error message. When I try to zero the superblock I get an error message saying it couldn’t open /dev/sdx. I tried deleting partitions but I get a ‘Device or resource busy’ message.

If you guys have any ideas, suggestions or recommendations I’d greatly appreciate hearing them.

Joe Barton

You’re very nearly there, and I’m sorry to tell you that you’ve missed a fairly minor step. You’ve set up the RAID array, and now you need to format it

as a disk/partition. To do this, you need to use the command:$ mkfs.ext3 /dev/md0And once that’s fi nished, it should be working for you. Good luck with mdadm in the future.

program crashes. I will be checking into how to resolve this issue since it is critical.

Which accounting program would you suggest?

Steve Richards

Both GnuCash and KMyMoney are quite popular among accountants using open source software. However, we have heard of more people having issues with

KMyMoney than GnuCash in general. Importing the data from Quicken is trickier the more data you try to import, and we’ve heard of some people just giving up and deciding to enter the data from scratch.

You’ll also have to get used to the idea of double-entry bookkeeping, and there may be a few more manual entries than you’re used to. Otherwise though, the best way is to get stuck in as soon as possible and fi gure out if you like it or not.

Install again, this time using YUM instead

086-89_LUD_123_Qand A PK.indd 87 25/01/2013 18:35

Page 88: Linux User & Developer - Bpfine

www.linuxuser.co.uk88

Questions & answers

www.linuxuser.co.uk88

Become a fan on

Linux User & DeveloperContact us @linuxusermag

NFS niggleI have a problem with NFS regarding fi le permissions when copying a fi le that has no read/write permissions for a group.First, this is how I set up NFS:• Created accounts for users on the server.• Each user has in server’s /etc/exports line with exported folder and his machine IP as well as following parameters: anonuid and anongid to match his uid/gid, rw and all_squash.• All users are in one common group, let’s call it ‘fornfs’.• Each user has in his .profi le on their machines umask set to 002.Example of /etc/exports line:/mnt/share 192.168.1.10(rw,no_subtree_check,all_squash,anonuid=1001,anongid=1004)Server is Debian Squeeze, clients are Kubuntu 12.04.1. Exported folder is SEC_TYPE=”ext2” TYPE=”ext3”

Now, if user A makes a fi le, it gets correct permissions (by correct I mean also rw for group) thanks to umask. He puts that fi le on NFS and other users from the ‘fornfs’ group can open it and edit too.

BUT, if user A gets some fi le via Skype for example, and that fi le lands on user’s machine with permission 600, and user A then puts that fi le on NFS, other users can’t use that fi le at all because of the permission.

What I am looking for is, if there is some kind of umask or similar that will force default permission on a fi le being copied to NFS. Which means a user puts that fi le on NFS, NFS sees that fi le permission has no read and write for the group, and corrects it. Like umask sets for a newly created fi le.

I should mention also that you should assume that users are people that do not know/care to change permissions, they just expect to put fi les on NFS and that it should work automatically. So advising users to chmod fi les before putting on a mounted NFS is no-go (nor would I like that system, although that depends on user behaviour).

Thank you in advance.

Andrew Nguyen

Well, there are a few things you can try. Firstly, a cron job could be created to just chmod the fi les on a regular basis – obviously it’s not ideal and will cause unnecessary

server load, even if it’s incredibly minimal. Otherwise, if the fi le goes to a user folder fi rst,

■ Write permissions in Linux are difficult to exploit for good reason

Speak upI was looking for a low-resource voice-only chat software for Linux. From what I saw, Mumble/Murmur seems a good choice. The problem is, one of the machines, which will be running the Mumble client only (not the Murmur server) is old – so old that it’s running Ubuntu Intrepid. Due to its remote location, I cannot upgrade that machine right now.

So I went back and found an older version Mumble client from Ubuntu Hardy, mumble_1.1.3-0ubuntu2.1_i386.deb to be exact. Newer versions had too many dependencies that were not met. This old version had only libqt4-core and libqt4-gui as unmet dependencies. I then went and got those older versions of libqt4* from Hardy as well.

These seemed to install fine, apart from libqt4-gui, which asks to remove libqt4-designer. It tries to do this automatically; however, it fails and quits out. I don’t know what libqt4-designer does and I am hesitant to remove it as the above message advises, because this is a remote computer I have no physical access to. Since many apps may be dependent on Qt I want to be on the cautious side before doing any removal. What should I do?

John Wilkinson

■ Mumble is popular among game clans

Search for the dependencies manually and install binaries

We hate to be the bearers of bad news, but it seems like the best way to fi x this is really to go and upgrade the operating system so you can use the newer, or even up-

to-date packages.You could use a more creative method, though

– using the Launchpad search feature, you can search for the dependencies manually and install the binaries from there. It will be a little tricky, but defi nitely a lot easier and faster than getting to this remote system, wherever it is.

086-89_LUD_123_Qand A PK.indd 88 25/01/2013 18:12

Page 89: Linux User & Developer - Bpfine

www.linuxuser.co.uk89

All your technical problems solvedQuestions & answers

Q/A

www.linuxuser.co.uk89

Remix with LinuxI’m a composer. I’ve been using the (wonderful!) program MuseScore to notate music and play it back with MIDI. This is fine for composition purposes, but not for releasing music to the public, since even good MIDI samples tend to sound very artificial. More importantly, this program (or perhaps the samples/MIDI back-end) is unable to articulate things like pitch bending, tapering dynamics etc.

I’m aware that ProTools (and others) can use ‘virtual instruments’ to accomplish this, and even be nearly indistinguishable from actual instruments. Audacity seems unable to use MIDI/

n Rosegarden is one of the best free synthesizers on Linux

score input to control its virtual instruments (not yet implemented). I’m about to give Ardour a shot, but I’ve been having trouble getting a bead on what it can actually do, and am not sufficiently experienced with the program to know if I’m being inept or if the program doesn’t support what I want.

Do you know if you can use notation software, or the MIDI output, to control virtual instruments on Linux?

Thanks for any help you can provide.

Ryan Everson

Ardour right now is strictly for recording and mixing audio – currently it does not have any software synthesizers. And while a few may be added in the next

version of Ardour, it sounds like it won’t be a full suite. For the moment, I would suggest trying out Rosegarden.

Rosegarden is able to do MIDI-controlled software synthesizers in the form of DSSI, as well as LADSPA v2, and while by default they may

Ardour right now is strictly for recording and mixing audio – it does not have any software synthesizers

say in home, you can do some permission tweaking. This will result in that any file downloaded to the folder will then inherit the correct permissions. You can do it with:$ chmod g+xs /home/UserA

Alternatively, you could switch the whole system to Samba, although of course that could take a while to get properly set up depending on the network.

not be the quality you want, you can get some proper samples to try to use in Rosegarden itself. Otherwise if you want to emulate it, you’ll get varying results depending on the instrument.

Hopefully this is enough information to get you going!

086-89_LUD_123_Qand A PK.indd 89 25/01/2013 18:12

Page 90: Linux User & Developer - Bpfine

GreatDigitalMags_A4_Man.indd 2 25/01/2013 15:48

Page 91: Linux User & Developer - Bpfine

3 Choose a digital magazine or book

1 Visit the websiteGreatDigitalMags.com

4 Purchase in-store, download & enjoy!

2 Filter titles by your favourite store

GreatDigitalMags_A4_Man.indd 3 25/01/2013 15:48

Page 92: Linux User & Developer - Bpfine

Whether you’re a hosting firm or a happy customer who wants a favourite provider listed, drop us a line with the details!

Got a deal you think we should list?

[email protected]

Sponsorship opportunityBring attention to your brand by sponsoring this section. Contact Rhian Carter on +44(0)1202586421

www.linuxuser.co.uk92

Hosting listings

C4L www.c4l.co.uk

Entry-Level 0800 0470481 £79.99 12 months

Quad Core 2.40GHz

250GB 10Mbps ✗ ✓ ✓ 100% ✓ ✓ ✓

Mid-range 0800 0470481 £119.99 12 months

Quad Core 2.40GHz

2x 250GB 100Mbps ✓ ✓ ✓ 100% ✓ ✓ ✓

High-End 0800 0470481 £239.9912 months

2x 6 Core 2.66GHz

2x 500GB ✓ ✓ ✓ ✓ 100% ✓ ✓ ✓

HA

RD

WA

RE

RA

ID

PRIV

ATE

SUB

NET

24/7

PH

ON

E SU

PPO

RT

UPT

IME

GU

AR

AN

TEE

CPU

CO

RES

/ SP

EED

DIS

K S

PACE

REM

OTE

PO

WER

REB

OO

T

NET

WO

RK

BAC

KU

P ST

OR

AGE

PER

MA

NEN

T K

VM

MIN

IMU

M

CON

TRAC

T TE

RM

COST

PER

M

ON

TH

PHO

NE

NU

MB

ER

1GB

PS IN

TER

NET

CO

NN

ECTI

ON

PACK

AGE

NAME AND URL

Dedicated server listings

O = Option

Webfusion (www.webfusion.co.uk) Dell PowerEdge R210 0845 130 1602 £79.99 12 months 2x 3.06GHz 250GB Up to 100Mbit ✗ ✓ ✗ 99.99% Free O ✓

Webfusion (www.webfusion.co.uk) Dell PowerEdge R210 0845 130 1602 £119.99 12 months 4x 2.66GHz 2x 250GB Up to 100Mbit ✓ ✓ ✗ 99.99% Free O ✓

Webfusion (www.webfusion.co.uk) Dell PowerEdge R210 0845 130 1602 £149.99 12 months 4x 2.66GHz 2x 500GB Up to 100Mbit ✓ ✓ ✗ 99.99% Free O ✓

Webfusion (www.webfusion.co.uk) Dell PowerEdge R410 0845 130 1602 £229.99 12 months 4x 2x 2.13GHz 2x 1TB Up to 100Mbit ✓ ✓ ✗ 99.99% Free O ✓

Webfusion (www.webfusion.co.uk) Dell PowerEdge R410 0845 130 1602 £329.99 12 months 6x 2x 2.66GHz 2x 600GB Up to 100Mbit ✓ ✓ ✗ 99.99% Free O ✓

catalyst2 (www.catalyst2.com) Bronze Managed Dedicated Server 0800 107 79 79 £199 1 month 1x 2.4GHz vCPU 50GB ✓ ✓ ✓ ✓ 99.90% ✓ ✓ ✓

catalyst2 (www.catalyst2.com) Silver Managed Dedicated Server 0800 107 79 79 £299 1 month 1x 2.4GHz vCPU 80GB ✓ ✓ ✓ ✓ 99.90% ✓ ✓ ✓

catalyst2 (www.catalyst2.com) Gold Managed Dedicated Server 0800 107 79 79 £399 1 month 2x 2.4GHz vCPU 150GB ✓ ✓ ✓ ✓ 99.90% ✓ ✓ ✓

123-Reg (www.123-reg.co.uk) Dell PowerEdge R200 (Ubuntu Linux) 0871 230 9525 £69.99 12 months 4x 2.13GHz 2x 160GB 10Mbit ✓ ✓ ✗ 99.99% O ✗ ✓

123-Reg (www.123-reg.co.uk) Dell PowerEdge R200 (Windows Web Edition) 0871 230 9525 £79.99 12 months 4x 2.13GHz 2x 160GB 10Mbit ✓ ✓ ✗ 99.99% O ✗ ✓

Heart Internet (www.heartinternet.co.uk/dedicated-servers) Linux Dual Core 0845 644 7750 £79.99 12 months Dual Core Xeon

2.33GHz 160GB ✓ ✓ ✓ ✗ 99.99% ✓ ✗24/7 Ticket

support

Heart Internet (www.heartinternet.co.uk/dedicated-servers) Windows Dual Core 0845 644 7750 £89.99 12 months Dual Core Xeon

2.33GHz 160GB ✓ ✓ ✓ ✗ 99.99% ✓ ✗24/7 Ticket

support

Heart Internet (www.heartinternet.co.uk/dedicated-servers) Linux Quad Core 0845 644 7750 £129.99 12 months Quad Core Xeon

2.5GHz 250GB ✓ ✓ ✓ ✗ 99.99% ✓ ✗24/7 Ticket

support

Daily (www.daily.co.uk) Linux VPS Pro 0845 466 2100 £29.99 1 month 2.27 Intel Quad Core 60GB 100Mbps ✓ ✓ ✗ ✗* ✓ - full backup ✗ ✗**

Daily (www.daily.co.uk) Linux VPS Max 0845 466 2100 £59.99 1 month 2.27 Intel Quad Core 100GB 100Mbps ✓ ✓ ✗ ✗* ✓ - full backup ✗ ✗**

Daily (www.daily.co.uk) Windows VPS Pro 0845 466 2100 £34.99 1 month 2.27 Intel Quad Core 60GB 100Mbps ✓ ✓ ✗ ✗* ✓ - full backup ✗ ✗**

Daily (www.daily.co.uk) Windows VPS Max 0845 466 2100 £64.99 1 month 2.27 Intel Quad Core 100GB 100Mbps ✓ ✓ ✗ ✗* ✓ - full backup ✗ ✗**

Daily (www.daily.co.uk) VPS Pro Hyper-V 0845 466 2100 £44.99 1 month 2.27 Intel Quad Core 60GB 100Mbps ✓ ✓ ✗ ✗* ✓ - 1GB ✗ ✗**

Daily (www.daily.co.uk) VPS Max Hyper-V 0845 466 2100 £74.99 1 month 2.27 Intel Quad Core 100GB 100Mbps ✓ ✓ ✗ ✗* ✓ - 1GB ✗ ✗**

Daily (www.daily.co.uk) VPS Ultra Hyper-V 0845 466 2100 £139.99 1 month 2.27 Intel Quad Core 200GB 100Mbps ✓ ✓ ✗ ✗* ✓ - 1GB ✗ ✗**

Bravo14 (http://bravo14.co.uk) Starter Linux N/A £20 N/A N/A 2,000MB N/A ✓ ✓ ✓ ✓ ✗ ✓ ✓

Bravo14 (http://bravo14.co.uk) Starter Windows N/A £20 N/A N/A 2,000MB N/A ✓ ✓ ✓ ✓ ✗ ✓ ✓

Bravo14 (http://bravo14.co.uk) Business Linux N/A £45 N/A N/A 4,000MB N/A ✓ ✓ ✓ ✓ ✗ ✓ ✓

Bravo14 (http://bravo14.co.uk) Business Windows N/A £45 N/A N/A 4,000MB N/A ✓ ✓ ✓ ✓ ✗ ✓ ✓

Bravo14 (http://bravo14.co.uk) Ultimate Linux N/A £60 N/A N/A Unlimited N/A ✓ ✓ ✓ ✓ ✗ ✓ ✓

Bravo14 (http://bravo14.co.uk) Ultimate Windows N/A £60 N/A N/A Unlimited N/A ✓ ✓ ✓ ✓ ✗ ✓ ✓

092-093_LUD_123 PK.indd 92 25/01/2013 18:13

Page 93: Linux User & Developer - Bpfine

Hosting listingsLISTINGS

www.linuxuser.co.uk93

[email protected]+44(0)1202586421

GET YOUR LISTING HIGHLIGHTED! CONTACT RHIAN

SHO

PPIN

G C

ART

NAME AND URL PACK

AGE

DAT

AB

ASE

SUPP

OR

T

PHO

NE

NU

MB

ER

COST

PER

YEA

R

WEB

SPA

CE

MO

NTH

LY

BA

ND

WID

TH

POP3

AC

COU

NTS

VIR

US

FILT

ER

FIR

EWA

LL

PHO

NE

SUPP

ORT

EMAI

L SU

PPO

RT

WEB

CO

NTR

OL

PAN

EL

SER

VICE

LEV

EL

AGR

EEM

ENT

Donhost (www.donhost.co.uk) Reseller Unix 0845 226 5566 £399.99 Unlimited Unlimited Unlimited ✓ ✗ ✓ ✓ ✓ ✓ ✓ ✗

Donhost (www.donhost.co.uk) Reseller Windows 0845 226 5566 £499.99 Unlimited Unlimited Unlimited ✓ ✗ ✓ ✓ ✓ ✓ ✓ ✗

Donhost (www.donhost.co.uk) Enterprise 0845 226 5566 £89.99 1GB 2GB 250 ✓ ✗ ✓ ✓ ✓ ✓ ✓ ✗

Donhost (www.donhost.co.uk) Commerce 0845 226 5566 £179.99 2GB 5GB 500 ✓ ✗ ✓ ✓ ✓ ✓ ✓ ✗

Donhost (www.donhost.co.uk) Designer 0845 226 5566 £119.99 1GB 2GB 250 ✓ ✗ ✓ ✓ ✓ ✓ ✓ ✗

Donhost (www.donhost.co.uk) Developer 0845 226 5566 £259.99 2GB 5GB 500 ✓ ✗ ✓ ✓ ✓ ✓ ✓ ✗

eHosting (www.ehosting.com) Starter 0844 999 4100 £23.88 1GB 25GB 10 ✗ ✗ ✗ ✗ ✗ ✓ ✓ ✓

eHosting (www.ehosting.com) Personal 0844 999 4100 £59.88 2.5GB Unlimited 50 ✓ ✗ ✗ ✗ ✗ ✓ ✓ ✓

eHosting (www.ehosting.com) Expert 0844 999 4100 £95.88 5GB Unlimited 250 ✓ ✗ ✗ ✗ ✗ ✓ ✓ ✓

eHosting (www.ehosting.com) Virtual 0844 999 4100 £227.88 50GB Unlimited Unlimited ✓ ✗ ✗ ✗ ✓ ✓ ✓ ✓

Equiphase (www.equiphase.net) Bronze 0121 314 4865 £30 200MB 2GB 10 ✓ ✓ ✗ ✓ ✗ ✓ ✓ ✓

Equiphase (www.equiphase.net) Silver 0121 314 4865 £42 400MB 5GB 20 ✓ ✓ ✗ ✓ ✗ ✓ ✓ ✓

Equiphase (www.equiphase.net) Gold 0121 314 4865 £72 800MB 10GB 100 ✓ ✓ ✗ ✓ ✗ ✓ ✓ ✓

Equiphase (www.equiphase.net) Platinum 0121 314 4865 £114 1,200MB 40GB 200 ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

Eurofasthost.com (www.eurofasthost.com) Email Only 02380 249 823 £40 1GB 2GB 10 ✗ ✗ ✓ ✓ ✓ ✓ ✓ ✓

Eurofasthost.com (www.eurofasthost.com) Essential 02380 249 823 £75 2GB 5GB 10 ✗ ✗ ✓ ✓ ✓ ✓ ✓ ✓

Eurofasthost.com (www.eurofasthost.com) Superior 02380 249 823 £140 5GB 10GB 25 ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

Eurofasthost.com (www.eurofasthost.com) Premium 02380 249 823 £250 10GB 25GB 100 ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

Evohosting (www.evohosting.co.uk) Starter N/A £29.99 500MB 1GB 3 ✓ ✓ ✓ ✓ ✗ ✓ ✓ ✓

Evohosting (www.evohosting.co.uk) Home N/A £54.99 2.5GB 30GB 50 ✓ ✓ ✓ ✓ ✗ ✓ ✓ ✓

Evohosting (www.evohosting.co.uk) Business N/A £79.99 6.5GB Unlimited Unlimited ✓ ✓ ✓ ✓ ✗ ✓ ✓ ✓

Evohosting (www.evohosting.co.uk) eCommerce N/A £159.99 30GB Unlimited Unlimited ✓ ✓ ✓ ✓ ✗ ✓ ✓ ✓

Giacom (www.giacom.com) Business Pro 0800 542 7500 £199 100MB 2GB 100 ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

Heart Internet (www.heartinternet.co.uk) Starter Professional 0845 644 7750 £29.80 2.5GB 10GB 1,000 ✗ ✗ ✗ ✓ ✗ ✓ ✓ ✓

Heart Internet (www.heartinternet.co.uk) Home Professional 0845 644 7750 £89.99 10GB 50GB 10,000 ✓ ✓ ✗ ✓ ✗ ✓ ✓ ✓

Heart Internet (www.heartinternet.co.uk) Business Professional 0845 644 7750 £129.99 Unlimited Unlimited Unlimited ✓ ✓ ✗ ✓ ✗ ✓ ✓ ✓

Heart Internet (www.heartinternet.co.uk) Reseller Professional 0845 644 7750 £299.99 Unlimited Unlimited Unlimited ✓ ✓ ✗ ✓ ✗ ✓ ✓ ✓

Hostway (www.hostway.co.uk) Silver 0808 180 1880 £79.50 150MG 3GB 5 ✗ O ✓ ✓ ✗ ✓ ✓ ✗

O = Option

* Excluding planned maintenance, we regularly hit 99.9% uptime on the VPS platform **Hardware and network are monitored 24/7; however, support hours are the following: Monday to Friday 8.00 am to 7.30 pm, Weekends (inc. Bank Holidays) 10.00 am to 3:00 pm

Dedicated and Shared server listings

Netcetera www.netcetera.co.uk

DEVELOPER 0800 061 2801 £32.98 1GB Unlimited 500 ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

ONE 0800 061 2801 £109.99 5GB Unlimited 1,000 ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

RESELLER 0800 061 2801 £274.89 Unlimited Unlimited 1,000 ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

VM500 Server 0800 061 2801 £300 20GB Unlimited Unlimited ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

2200DC Server 0800 061 2801 £720 160GB Unlimited Unlimited ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

3000DC Server) 0800 061 2801 £1,200 2 x 500GB Unlimited Unlimited ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

2600QC Server 0800 061 2801 £1,800 2 x 500GB Unlimited Unlimited ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓

Fasthosts www.fasthosts.co.uk

Personal 0808 168 6777 £32.87 5GB Unlimited 50 ✓ ✗ ✓ ✓ ✓ ✓ ✓ ✗

Business Bronze 0808 168 6777 £58.38 50GB Unlimited 500 ✓ O ✓ ✓ ✓ ✓ ✓ ✗

Business Silver 0808 168 6777 £76.39 Unlimited Unlimited Unlimited ✓ O ✓ ✓ ✓ ✓ ✓ ✗

Business Gold 0808 168 6777 £101.89 Unlimited Unlimited Unlimited ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✗

WD Starter 0808 168 6777 £149.99 20GB Unlimited Unlimited ✓ O O ✓ ✓ ✓ ✓ ✗

WD Advanced 0808 168 6777 £199.99 Unlimited Unlimited Unlimited ✓ O O ✓ ✓ ✓ ✓ ✗

092-093_LUD_123 PK.indd 93 25/01/2013 18:14

Page 94: Linux User & Developer - Bpfine

www.linuxuser.co.uk94

Your source of Linux news and viewsYour viewContact us…Register and post your comments…www.linuxuser.co.uk/forum/

Email us directly…[email protected]

THREAD BARE

YOUR VIEW

Linux User Letters

Right before Christmas, we posted Richard Hillesley’s in-depth feature on the fate of GNU Hurd, the microkernel OS championed by Richard Stallman some time ago. It quickly became one of our most read articles ever, and sparked a little debate on the blog. You can see more at: http://bit.ly/12ItLWz

That’s what happened to the Hurd

Don Brown said:Good article. I had many “Heh… I didn’t know that…” moments. I enjoy reading these types of stories. Even if they make me keep

looking things up.I never wrote an OS or a compiler – I never wanted to, but I sure do

appreciate the people who do. God bless them all. They helped me become the Engineer/IT Guy/Teacher that I am today.

Michael Engel said:This may seem like nitpicking, but mentioning that “Rashid’s work [at Carnegie Mellon] had suggested that this problem was not so

terribly signifi cant after all” in relation to microkernel performance problems does not tell the whole story. Performance problems were IMHO one of the reasons for the slow acceptance of Mach – this still shows today in Apple’s OS X kernel, which is based on Mach 3, where for performance reasons the idea of a clearly separated microkernel was given up and a hybrid kernel was developed that again ran the BSD emulation layer (among other things) in kernel space to avoid context

switch overheads. People interested in this specifi c topic might want to read Amit Singh’s excellent book Mac OS X Internals.

In the context of microkernel performance, the work of Jochen Liedtke and the numerous people working on L4 should not be underestimated. For a discussion of microkernel performance, I would recommend Liedtke’s paper ‘µ-Kernels Must And Can Be Small’. In this paper, he discussed why microkernels have to be small and why this in turn is required for developing a fast microkernel.

Nevertheless, thanks for the interesting story on the Hurd!

DrunkButHappy said:Listen, the Stallman/GNU defence is: “oh, it was too hard [to take the Mach kernel and DO something with it”. And yet, Apple took it

and – together with the FreeBSD userland stuff – made the best UNIX out there for the end user.

It’s clear to me Stallman did not have the chops for his lofty goals. When GNU wrote GCC, the standard book was the Dragon book. ANYONE, today, can probably write the early GNU stuff.

And Linux is the OS, it’s not GNU. Here I’ll prove it: even before LLVM came along, I saw people use other compilers (Intel, for example). The userland NEVER had to be GNU tools. So that leaves you… Linux as the fundamental part.

Nymphus said:Oh please. OS X is BSD-for-noobs. FreeBSD is too busy sucking up to OS X these days. OpenBSD is where it’s at! ;)

dos said:DrunkButHappy please. RMS is a beast. The Dragon book is a great book.

Touch the buttonI recently read the interview you had with Michael Meeks from the Document Foundation a while back, and I had an issue with something he said re touch-screen interoperability. It’s a completely different issue to Android platform compatibility – LibreOffi ce would best be ported to Android and there should also be a project to provide a touch-screen UI to LO, regardless of platform.

Yes, Windows 8 is touch oriented. Ubuntu has been moving towards touch friendliness for some time. iOS is a touch platform. That is not to suggest

Your opinions about the magazine, Linux and open source

all users on any particular platform will want a touch interface. Given Android is making inroads into smart TVs, we can expect those to have high-defi nition mouse wands, or actual mice attached – not touch. We can expect some Android users will want the standard windowed LO interface.

Not all platforms do support mice and physical keyboards, so we shouldn’t presume a UI based on platform. We really need LO to have a touch-friendly UI available on all platforms, but at the same time, keep the standard UI available.Nick Hill

■ Coming to Android at some

point, but in what form?

You’re brushing next to a much wider problem than touch for Android ports, and we totally agree. Even the desktop interfaces you’ve pointed out still primarily use a mouse and keyboard, which is why LibreOffi ce is using it with them in the fi rst place. While we’re not sure how much use people will get out of an offi ce suite on their TV with a limited remote control, Android phone manufacturers keep trying to break the desktop market by using docked Android phones – which also use a mouse and keyboard. Of course with Android, though, it is primarily touch, and there are space considerations to keep in mind.

094-095_LUD_123 PK.indd 94 25/01/2013 18:17

Page 95: Linux User & Developer - Bpfine

LibreOffi ce, GNU Hurd, Linux securityYour view

LETTERS

The website for the GNU Generation

The ultimate resource for open source enthusiasts and professionals

Never miss an updateSubscribe to our RSS feed today!

• Latest news • Reviews • Tutorials • Opinion

Become a fan on

Linux User & DeveloperContact us @linuxusermag

Android MagazineWith more and more Android features being merged back into the Linux kernel, it’s becoming easier to develop for one of the most popular mobile operating systems around. With over 25 billion app downloads,

and over 500 million Android devices worldwide, there’s a wide audience of folks ready and willing to consume apps. For a more Android-driven editorial, you can look to our sister mag Android Magazine, the only publication dedicated to the platform. Along with news and reviews to keep you up to date on everything Android, there are also tutorials and advice on developing and hacking your hardware. Find out more at www.littlegreenrobot.co.uk.

Utmost securityI’ve noticed a couple of reviews where you comment on the lack of users on login. A display manager that requires entry of the username increases system security, which can only be a good thing. Installations that either encourage automatic login or whose login managers list the username go against good security practice.

When I regularly hear about people losing their laptop/netbook that contains all their personal data, important photographs etc, I can feel reassured that by having an encrypted and password-protected installation, and all my valuable data backed up in triplicate on encrypted external hard drives (and nothing of great importance or value on my netbook’s hard drive), my data is fairly safe.

Of course, I could encrypt each folder and fi le, as well.Pierre Millien

Security is very important, of course. However, that’s why we explain in our reviews what we do and do not like. If you don’t agree with a particular point, like the above, then you can

■ It’s your choice to decide between user-friendliness and security

use that to make your own decision whether to try out a distro or not. Although, people can learn a thing or two about backing up data to the degree you do!

094-095_LUD_123 PK.indd 95 25/01/2013 18:17

Page 96: Linux User & Developer - Bpfine

✓iPad ✓iPhone ✓Android phone ✓Android tablet ✓Apple Mac ✓Windows PC

Page 97: Linux User & Developer - Bpfine

To get the most out of your digital editions, be sure to enjoy all of our fantastic features, including:

• Zoomable text and pictures• In-app browsing• Searchable text• Take your collection with you• Read offl ine

Imagine digital editions are a new and exciting way to experience our

world-leading magazines and bookazines.

No Disc. No ProblemMany of the � les you’re looking for can be

found on the magazine’s website

To buy more Imagine digital editions and for the latest issues and best offers, please go to www.GreatDigitalMags.com

Page 98: Linux User & Developer - Bpfine

98

What’s coming up…Next issue

www.linuxuser.co.uk

Imagine Publishing LtdRichmond House, 33 Richmond HillBournemouth, Dorset, BH2 6EZ☎ +44 (0) 1202 586200Web: www.imagine-publishing.co.uk www.linuxuser.co.uk www.greatdigitalmags.com

Magazine team Editor Russell [email protected]

☎ 01202 586272

Editor in Chief Dave Har� eldStaff Writer Rob ZwetslootDesigner Stephen MathewsHead of Publishing Aaron AsadiPhotographer James SheppardHead of Design Ross Andrews

ContributorsPhil King, Simon Brew, Jon Masters, Liam Fraser, Gareth Halfacree, Richard Hillesley, Rory MacDonald, Joey Bernard, Michael Reed, Kunal Deo, Dr. Karl Beecher, David Crookes & Sandra Vogel

AdvertisingDigital or printed media packs are available on request.

Head of Sales Hang Deretz

☎ 01202 [email protected]

Advertising Manager Jennifer Farrell

☎ 01202 [email protected]

Account Manager Rhian Carter

☎ 01202 [email protected]

Cover discHead of Digital Mat ToorDigital Products Co-ordinator Steven [email protected]

InternationalLinux User & Developer is available for licensing. Contact the International department to learn more.

Head of International Licensing Cathy Blackman

☎ +44 (0) 1202 [email protected]

SubscriptionsHead of Subscriptions Lucy [email protected]

For all subscriptions enquiries

☎ 0844 249 0282 (UK)

☎ +44 (0) 1795 418661 (Overseas)Email: [email protected] issue subscription (UK) – £25.1513 issue subscription (Europe) – £7013 issue subscription (ROW) – £80

CirculationHead of Circulation Darren Pearce

☎ 01202 586200

ProductionProduction Director Jane Hawkins

☎ 01202 586200

FoundersGroup Managing Director Damian ButtGroup Finance & Commercial Director Steven BoydGroup Creative Director Mark Kendrick

Printing & DistributionPrinted by William Gibbons, 26 Planetary Road,Willenhall, West Midlands, WV13 3XT

Distributed in the UK & Eire by Seymour Distribution, 2 East Poultry Avenue, London, EC1A 9PT.

☎ 0207 429 4000

Distributed in Australia by Gordon & Gotch, Equinox Centre, 18 Rodborough Road, Frenchs Forest, NSW 2086.

☎ + 61 2 9972 8800

Distributed in the Rest of the World by Marketforce, Blue Fin Building, 110 Southwark Street, London, SE1 0SU.

☎ 0203 148 8105

DisclaimerThe publisher cannot accept responsibility for any unsolicited material lost or damaged in the post. All text and layout is the copyright of Imagine Publishing Ltd. Nothing in this magazine may be reproduced in whole or part without the written permission of the publisher. All copyrights are recognised and used speci� cally for the purpose of criticism and review. Although the magazine has endeavoured to ensure all information is correct at time of print, prices and availability may change. This magazine is fully independent and not af� liated in any way with the companies mentioned herein.

© Imagine Publishing Ltd 2013

ISSN 2041-3270

THE MAGAZINE FOR THE GNU GENERATION

Create your own NAS

ALSO INSIDE:>> Mark Shuttleworth exclusive>> ISO to USB super-test>> Jon Masters’ kernel column>> 20+ pages of reviews

Master network-attached storage using GlusterFS

Create a virtual keyboard with Raspberry PiTake the pain out of touch-screen typing

COMING IN THE NEXT ISSUE

Get started with ArduinoThe fi rst in a new series of beginner Arduino tutorials

Create a virtual

Ditch Dropbox and drop Google’s Drive. Build it better yourself next issue!

cloud serviceBuild

your own

Look out for issue 124

on sale 14 MarchWant it sooner? Subscribe

today!

098_LUD_123 PK.indd 98 25/01/2013 18:20

Page 99: Linux User & Developer - Bpfine

MAX

Get MORE power when you need it!With a fully scalable 123-reg VPS and our powerful new add-ons.

TURN YOUR VPS

UP TO THE MAXMAXMAXMAXMAXMAXMAXMAXMAX

FROM ONLY a month£14.99£14.99£14.99£14.99£14.99£14.99£14.99£14.99£14.99Power up your business at www.123-reg.co.uk/VPS

PLESK ADD-ONS ADDITIONAL IP’s BACKUP STORAGE

Super charge Plesk with the latest add-ons including Plesk’s Power Pack, Language packs and Anti-virus software.

Add extra IP addresses to your VPS so you can use multiple SSL certificates on the same server.

Keep your valuable data safe from error or hardware malfunction with our FTP backup storage add-on.

ON

OFF

ON

OFF

ON

OFF

Terms and conditions apply. Prices quoted are exclusive of VAT and are subject to change. Additional charges apply for Plesk Add-Ons, Additional IPs and FTP Backup Storage.

Full pg.indd 1 22/01/2013 10:01

Page 100: Linux User & Developer - Bpfine

“Here at The Pi Hut, we believe that the Raspberry Pi is one of the most exciting things to happen in computing for many years. Our aim is to help Raspberry Pi owners get the most out of their Rpi experience.”- Jamie Mann, Company Director

Preinstalled SD CardsCases

Power SuppliesWifi Adapters

Heatsinks... and much, much more

www.twitter.com/ThePiHutwww.facebook.com/The.Pi.Hut

[email protected]

www.ThePiHut.com

5% off ALL orderswith promotional code

“LINUXUSER”

The

Pi H

ut is

a tr

adin

g na

me

of M

ann

Ente

rpris

es L

td.

Rasp

berr

y Pi

is a

trad

emar

k of

the

Rasp

berr

y Pi

Fou

ndat

ion

FULL PG.indd 1 17/01/2013 12:10