ebook img

Linux User & Developer 168 - Multi-Boot Your System PDF

100 Pages·2016·14.957 MB·English
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Linux User & Developer 168 - Multi-Boot Your System

FREE DVD WITH 3 LIVE BOOTING DISTROS www.linuxuser.co.uk L IN U X U S E R & D E V E L O P E R IS THE ESSENTIAL MAGAZINE S FOR THE GNU GENERATION U E 1 6 8 MRUNU THRELE DISTTROSI WI THB THE UOLTIMATOE GUIDET YOUR SYSTEM M U L TI B • Everyday Linux • Windows • Enterprise solutions • Specialist distros O O T Y MASTER VIRTUALISATION HANDLE CONTROL O U R STRUCTURES IN BASH S YS Set up a host and run virtual machines 10Modify a script’s execution sequence T E BEST M COMPILE SOURCE CODE SAFELY Harden binaries against memory corruption exploits BOARDS COLLABORATE IN GANIB Manage enterprise-level FOR MAKERS multiuser projects RUN LINUX ON Looking for an alternative to Raspberry Pi? Try one of these AN ANDROID DEVICE Install your favourite OS in a chroot on your phone w w w .lin DELL XPS 13 COMPILE SOFTWARE PLUS ISSUEIS 1S6N 82041-3270 £5.99 u DEVELOPER EDITION FASTER WITH DISTCC » Use Go packages 68 > xu » Office suites s » Hack a toy er.c The laptop with Linux on board Make your Pi do the hard work with the Pi Zero 9 772041 327002 o.u BUILD AN EXPLORER ROBOT PPAARRTT TTWWOO k 001_LUD168.indd 1 13/07/2016 09:49 FOR ANYTHING POSTGRES THERE’S ONLY ONE PROVIDER WORTH TRUMPETING ABOUT Full Page.indd 1 11/07/2016 16:27 THE MAGAZINE FOR THE GNU GENERATION Welcome Imagine Publishing Ltd Richmond House, 33 Richmond Hill Bournemouth, Dorset, BH2 6EZ ☎ +44 (0) 1202 586200 Web: www.imagine-publishing.co.uk www.linuxuser.co.uk www.greatdigitalmags.com to issue 168 of Linux User & Developer Magazine team Editor April Madden [email protected] ☎ 01202 586218 Designer Rebekka Hearl This issue Photographer James Sheppard Senior Art EditorAndy Downes Editor in ChiefDan Hutchinson Publishing DirectorAaron Asadi Head of Design Ross Andrews » Multi boot your system Contributors Dan Aldred, Joey Bernard, Toni Castillo Girona, Christian Cawley, » Master virtualisation Sanne De Boer, Kunal Deo, Alex Ellis, Tam Hanna, Oliver Hill, Phil King, Jon Masters, Paul O’Brien, Swayam Prakasha, Richard Smedley, Jasmin Snook, Nitish Tiwari and Mihalis Tsoukalos » 10 best boards for makers Advertising Digital or printed media packs are available on request. » Run Linux on an Android device Head of Sales Hang Deretz ☎ 01202 586442 [email protected] Sales Executive Luke Biddiscombe ☎ 01202 586431 Welcome to the latest issue of Linux User & Developer, [email protected] FileSilo.co.uk the UK and America’s favourite Linux and open source Assets and resource fi les for this magazine can now be found on this website. magazine. Wouldn’t it be nice to be able to run every Support fi [email protected] operating system or distro you fancied? The trouble is, International Linux User & Developer is available for licensing. affording the hardware to do so might be a bit of a problem H☎e a+d4 4of (I0n)t 1er2n0a2ti o5n8a6l 4L0ic1ensing Cathy Blackman – unless, of course, you multi boot your machine. [email protected] Partitioning your hard drive allows you to run two or more Subscriptions For all subscriptions enquiries distros or operating systems on one computer. Each one gets to [email protected] ☎ UK 0844 249 0282 take full advantage of the system’s resources, and you can fl ip in ☎ Overseas +44 (0) 1795 418661 www.imaginesubs.co.uk and out of them with the fl ick of a restart switch. In this issue, we’ve Head of Subscriptions Sharon Todd got the complete guide to multi booting, from backing up your data Circulation Circulation Director Darren Pearce and partitioning your hard drive to how to run Windows and Linux ☎PP☎rro o00dd11u22uc00tci22ot ni55o D88ni66re22c00t00or Jane Hawkins ioLsnos ou2ke5 f1Ao6ur9g oconn tfih geu sraem, eed mit aacnhdi neeve, hno pwre ttot irfuyn t hmeu GltRipUleB Lbionoutxl odaisdteror sth aantd c honowtro tlos Finance Want it sooner? the whole thing. Check it out on p16. Finance Director Marco Peroni Subscribe Also in this issue we take a look beyond the Raspberry Pi and Founder Group Managing Director Damian Butt today! round up the ten best boards for makers. Whether you’re looking Printing & Distribution at the best option for getting kids interested in making and PPrriinntteedd bbyy WWiilllliiaamm GGiibbbboonnss,, 2266 PPllaanneettaarryy RRooaadd,, Willenhall, West Midlands, WV13 3XT coding or whether you’re after the ultimate board for Internet of Distributed in the UK, Eire & the Rest of the World by: Things projects, quick deployment or x86 architecture, we’ve got Marketforce, 5 Churchill Place, Canary Wharf London, E14 5HU you covered. Take a look on p56, and if we haven’t featured your ☎ 0203 148 3300 www.marketforce.co.uk favourite board, be sure to give us a shout on the links below! Distributed in Australia by: April Madden, Editor Gordon & Gotch Australia Pty Ltd 26 Rodborough Road Frenchs Forest, New South Wales 2086, Australia ☎ +61 2 9972 8800 www.gordongotch.com.au Get in touch with the team: Disclaimer The 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 [email protected] in whole or part without the written permission of the publisher. All copyrights are recognised and used specifi 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 Buy online availability may change. This magazine is fully independent and not affi liated in any way with the companies mentioned herein. Facebook: Twitter: If you submit material to Imagine Publishing via post, email, social Linux User & Developer @linuxusermag network or any other means, you automatically grant Imagine Publishing an irrevocable, perpetual, royalty-free license to use the material across its entire portfolio, in print, online and digital, and to deliver the material to existing and future clients, including but not limited to international licensees for reproduction in international, licensed editions of Imagine products. Any material you submit is sent at your risk and, although Visit us online for more news, opinion, tutorials and reviews: every care is taken, neither Imagine Publishing nor its employees, agents or subcontractors shall be liable for the loss or damage. www.linuxuser.co.uk © Imagine Publishing Ltd 2016 ISSN 2041-3270 www.linuxuser.co.uk 3 003_LUD168.indd 3 12/07/2016 16:44 Contents Reviews Subscribe 81 Office suites & save! How do these free alternatives stack 26 C gUchraSeena cc tksu n usoebtuowstm c ooruefibfrres er ! up in features and usability? on page 80 OpenOffice LibreOffice WPS Office FreeOffice 16 Multi boot your system Get three distros running on one machine OpenSource Tutorials 08 News 28 Bash masterclass: Script execution T he biggest stories from Bash provides a set of scripts that modify the the open source world execution sequence 86 Dell XPS 13 9350 10 Interview 32 Compile software using Developer Edition Reynold Xin of Apache modern protections A laptop with Linux out of the box Spark talks data Hardening binaries can prevent corruption- memory-based exploits taking over 14 Kernel column 88 deepin 15.2 The latest on the Linux 36 Run a Linux chroot on Android The Debian-based distro’s latest kernel with Jon Masters Android is Linux-based and uses a Linux update promises big things... kernel, making it ideal for a chroot 94 Letters 90 Free software Your questions answered, 40 Organise collaborative projects Richard Smedley recommends some from tech help to advice with Ganib excellent FOSS packages for you to try Install Ganib and use it to manage and simplify your collaborative projects 44 Set up a virtualisation host and virtual machines Take a closer look at setting up virtualisation hosts and virtual machines on Ubuntu 48 Learn Go: Explore, create and use Features Go packages LLeeaarrnn hhooww ttoo ddeevveelloopp aanndd uussee GGoo ppaacckkaaggeess 16 Multi boot your system Using multiple operating 55 Practical Raspberry Pi systems increases efficiency Continue our Explorer robot series, check out a gesture-based remote control, get 56 10 best boards 97 Free downloads Arduinos talking to the Pi in Python, hack a for makers Find out what we’ve uploaded to our digital toy and compile programs with distcc Alternatives to the Pi content hub FileSilo for you this month Join us online for more Linux news, opinion and reviews www.linuxuser.co.uk 4 004_LUD168.indd 4 13/07/2016 14:30 Normal Use Heavy Use Back To Normal ELASTIC CONTAINERS Linux-based cloud servers Hassle-free auto-scaling Unique usage-only billing f rom £3 a month FREE TRIAL www.elastichosts.co.uk [email protected] 020 7183 8250 Full Page.indd 1 12/07/2016 14:24 Open Source On the disc On your free DVD this issue Load DVD Find out what’s on your free disc To access software and tutorial files, simply insert the disc into Welcome to the Linux User & Developer DVD. need, including essential backup software, the your computer and double-click This issue we’ll help you multi boot your machine. best open source partitioning utility and a choice the icon. Whether you want to combine Windows and of distros. Follow the instructions to live boot or Live boot Linux or several distros, we’ve got everything you install your software and distros from the disc. To live-boot into the distros supplied on this disc, insert the Featured software: disc into your disc drive and reboot your computer. Please note: • You will need to ensure that your computer is set up to boot from disc (press F9 on your computer’s BIOS screen to change Boot Options). • Some computers require you to press a key to enable booting from disc – check your manual or the manufacturer’s website to find out if this is the GParted case on your PC. • Live-booting distros are read Ubuntu 16.04 from the disc: they will not be GParted is the ultimate partitioning utility for your Linux installed permanently on your PC. Whether you want to combine Linux with Windows or computer unless you choose The perfect everyday distro for all-round use, the latest mix it up with an everyday Linux install plus a specialist version of Ubuntu offers unparalleled convergence distro, GParted allows you to partition your hard drive to do so. across your desktop and mobile devices. This distro live into sections. It also live boots from the disc so that you boots from the disc. can easily partition your PC at any time. For best results: This disc has been optimised for modern browsers capable of rendering recent updates to the HTML and CSS standards. So to get the best experience we Arch Linux CentOS 7 recommend you use: Want to explore a command-line interface on your Linux Get all the benefits of Red Hat for free with this • Internet Explorer 8 or higher PC? Arch Linux offers you exactly that. It’s the perfect community-driven open source ecosystem. Please • Firefox 3 or higher introduction to command-line computing as it aims to note that due to CentOS’s ISO structure this distro does • Safari 4 or higher offer a lightweight and flexible distro that keeps things not live boot from the disc – follow the instructions for • Chrome 5 or higher simple. This distro live boots from the disc. installation from the disc interface. Problems with BackupPC the disc? It’s essential that you back up all data on your computer Send us an email at linuxuser@ (including images of your current operating system) imagine-publishing.co.uk to optical media , network attached storage or to an external HDD or SSD before you begin the process of Please note however that if you partitioning your PC’s hard drive and installing one or are having problems using the more distros. This highly rated open source backup programs or resources provided, utility provides everything you need to ensure that your then please contact the relevant data is secure before you get started. software companies. 6 006-007 Disc Tutorial.indd 6 12/07/2016 16:26 Disclaimer Important information Check this before installing or using the disc For the purpose of this disclaimer statement the phrase ‘this disc’ refers to all software and resources supplied on the disc as well as the physical disc itself. You must agree to the following terms and conditions before using ‘this disc’: Loss of data In no event will Imagine Publishing Limited accept liability or be held responsible for any damage, disruption and/or loss to data or computer systems as a result of using ‘this disc’. Imagine Publishing Limited makes every effort to ensure that ‘this disc’ is delivered to you free from viruses and spyware. We do still strongly recommend that you run a virus checker over ‘this disc’ before use and that you have an up-to-date backup of your hard drive before using ‘this disc’. Hyperlinks: Imagine Publishing Limited does not accept any liability for content that may appear as a result of visiting hyperlinks published in ‘this disc’. At the time of production, all hyperlinks on ‘this disc’ linked to the desired destination. Imagine Publishing Limited cannot guarantee that at the time of use these hyperlinks direct to that same intended content as Imagine Publishing Limited has no control over the content delivered on these hyperlinks. Software Licensing Software is licensed under different terms; please check that you know which one a program uses before you install it. • Shareware: If you continue to use the program you should register it with the author • Freeware: You can use the program free of charge • Trials/Demos: These are either Live boot time-limited or have some Distros functions/features disabled Insert the disc into your computer and Distros can be live booted so that you • Open source/GPL: Free to use, reboot. You will need to make sure that can try a new operating system instantly but for more details please visit your computer is set up to boot from disc without making permanent changes to https://opensource.org/licenses/ your computer gpl-license FOSS Explore Unless otherwise stated you do not Insert the disc into your computer and have permission to duplicate and double-click on the icon or Launch Disc Alternatively you can insert and run the distribute ‘this disc’. file to explore the contents disc to explore the interface and content wwwwww..lliinnuuxxuusseerr..ccoo..uukk 77 006-007 Disc Tutorial.indd 7 12/07/2016 16:26 08 News & opinion | 10 interview | 94 Letters | 96 Filesilo Distro Fedora 24 shows off three new editions The latest Fedora release is available for server, workstation and the cloud Despite not receiving the mainstream attention that Ubuntu gets, Fedora remains one of the most popular open source distributions out there for both developers and end users. So it’s with much fanfare that Red Hat’s distribution has inally hit its 24th release. Fedora 24 predominantly keeps up the patterns of its previous releases, consisting of three base packages that combine to form three separate editions: Fedora 24 Server, Fedora 24 Workstation and Fedora 24 Cloud. Users can choose to download whichever one caters to their needs the best. One of the most pleasing aspects of Above GNOME 3.20 provides a new look for your stored software Fedora 24 is that it’s based on the 4.5.7 Linux kernel, with an emphasis on new tools and managing containers. The Cloud edition for developers to get more from their Linux has also been revamped to improve Docker containers. Of course, you can expect a wave integration, a problem that many were facing of enhancements and a couple of critical ixes in previous updates. to boot. The team has been quick to point out Server roles have consistently played a big that isn’t the inished article and to expect part in the Server edition of Fedora, so we’re incremental updates to hit soon. excited to see a deeper implementation of There’s also a marked improvement for rolekit introduced into Fedora 24 Server. For transitioning Linux into the cloud. Fedora end users, this should make it considerably 3.20 Delhi. Again, this is another preview, but 24 Cloud now includes OpenShift Origin, an easier to set up server roles. Also included the overall desktop environment has some on-board cloud distribution, which has been is a new identity management program, noticeable tweaks and still boasts that ease- heavily optimised for developing applications called FreeIPA 4.3. While for many it won’t be of-use we’ve come to expect. If GNOME isn’t a household name, it’s a great tool for overall for you, then there’s still a myriad of desktops domain control, but certainly requires some to enjoy, including Cinnamon 2.6, MATE 1.14, Fedora 24 Cloud has advanced knowledge to use. KDE Plasma 5 and Xfce 4.12. On a smaller OpenShift Origin, an on- Where the bulk of the changes have come scale, eagle-eyed users will also notice some into place, however, is through Fedora 24 upgrades to Fedora’s Software app. There’s board cloud distribution, Workstation. The biggest of the bunch is the now the capability to perform a full system which has been heavily preview of Wayland, a unique X display server. upgrade from the comfort of your desktop, as Although it’s very much an early preview, it’s well as leave reviews on available software. optimised for developing an exciting addition and one that Fedora plans It’s these little touches that make Fedora 24 applications and to implement as its default graphics server one of the biggest updates yet. in the future. GNOME users will also want to All three editions of Fedora 24 are now managing containers pay close attention to the inclusion of GNOME available to download from getfedora.org. 8 008-009_LUD168.indd 8 13/07/2016 14:51 HARDWARE DISTRO FEED Top 10 (Average hits per day, 31 May – 30 June) Linux Mint 1. 2,949 Debian 2. 1,892 Manjaro 3. 1,393 Ubuntu 4. 1,323 openSUSE 5. 1,121 Deepin 6. 1,033 Fedora 7. 1,028 Zorin 8. 1,015 ElementaryOS 9. 1,009 CentOS 10. 980 This month Sony to compensate ■ Stable releases (18) users for Linux on ■ In development (10) While there’s nobody particularly new in the top 10 this month, the PS3 debacle latest Linux Mint update has seen it rocket to the top of the download list. Sony will pay out millions to those Highlights affected by the OtherOS issue One of the gleaming features of the PS3 when bought a PS3 for the ‘OtherOS’ functionality will Mint it first launched was the introduction of the be able to claim $9. The current settlement, which The beta release for Linux Mint 18 ‘OtherOS’ feature. At the time, it caused quite a stir still needs to be approved by a federal judge in the ‘Sarah’ launched to a lot of fanfare, in the open source community. This momentous US, is currently only available for those residing in promising widespread changes in its design and feature would allow users to install Linux on their the United States who bought a fat PS3 between overall usability. For new users, it remains one of the easiest distributions to get your head around. machine and access all the extra functionality November 1st 2006 and April 1st 2010, but it’s likely that it brings with it. Unfortunately the feature that the ruling could go much further than that. Fedora was relatively short-lived, with a software During the litigation, it was alleged that piracy Expect Fedora to dramatically go up the update essentially killing off the feature back in was one of the key decisions behind the removal rankings over the coming months with 2009. While the update wasn’t mandatory, it all of the feature. Sony also added that its terms the release of Fedora 24. As usual, there’s three but disabled several of the PS3’s key features of service, which gamers agree to when initially different editions to test, with each bringing a unique set of features. until it was applied, preventing Linux users from setting up their console, allowed it to remove the connecting to the PlayStation Network or playing OtherOS feature, and that it wasn’t as widely-used elementaryOS games online. as the company initially thought it would be. The stylish elementaryOS also released A lawsuit was soon raised, stemming from For gamers to claim their $55 and subsequent a big update this month, with its Loki Sony’s claims for third-party OS capabilities on payout if the case is more widespread, they must beta providing a plethora of big fi xes and the team their console. Lawyers representing as many as provide proof of their purchase, PlayStation Sign- claiming over 800 issues have been solved. 10 million console owners on one side and Sony on In ID and submit proof of their use of the OtherOS the other, have now reached a deal which would functionality. Sony has also agreed to use its see Sony make a mandatory multi-million dollar PlayStation Network database to notify everyone payout to consumers. The proposed settlement potentially affected, with the steps they need to Latest distros will see gamers eligible to receive $55 if they ever take to make their claim and seek compensation available: used Linux on their console, while users who from the console giant. fi lesilo.co.uk www.linuxuser.co.uk 9 008-009_LUD168.indd 9 13/07/2016 14:51 OpenSource Your source of Linux news & views INTERVIEW REYNOLD XIN Data processing made easy Apache Spark is one of the most highly regarded engines for data processing on the market, but what makes it so good? Reynold Xin explains all Reynold Xin Reynold Xin is a member of the Apache Spark Project Management Committee and chief architect and co-founder at Databricks. He set the 2014 world record in 100TB sorting, beating the previous record held by Apache Hadoop with 30x higher per-node effi ciency. Apache Spark is a fast and general engine However, we are always looking at ways to continuously for data processing, used primarily by data expand our community, and there are plenty of ways engineers, data scientists and business that those interested can get involved with the future analysts. It provides high-level APIs in Scala, Java, development of Apache Spark. Python, R and SQL. It also supports a rich set of higher- An interesting titbit is that according to level tools that make it attractive for machine learning, StackOverfl ow’s 2016 survey, Apache Spark has graph computation, stream data processing, ETL and become the top-paying technical skill in the United business intelligence. In a way, it’s the Swiss army knife States (developers that know Spark are more likely to of data processing. make the highest amount of money). That’s a pretty Spark was originally started by Matei Zaharia at staggering fact if you ask me. UC Berkeley in 2009, and was donated to the Apache Software Foundation in June 2013. Spark became an How easy is it for users to implement Apache Spark Apache Top-level Project (TLP) in February 2014. into their systems? Apache Spark has seen rapid adoption by enterprises There are primarily two ways to use Spark. The fi rst is across a wide range of industries. Internet powerhouses to use the engine itself interactively. The second is to such as Netflix, Yahoo and Tencent have eagerly deployed embed Spark as a library in data applications. They both Spark at massive scale, collectively processing multiple require very different tools and attributes. petabytes of data. When you consider that some of the Although Spark has been used in the past mostly biggest companies in the world have adopted Apache as a big data processing engine, the engine also runs Spark, it just shows how many people believe in it. It has smoothly on a single machine. Many users use Spark on quickly become the largest open source community in their laptops, either to unit-test their data applications big data, with over 1,000 code contributors and with over or to directly analyse small amount of data interactively. 187,000 members in 420 Apache Spark Meetup groups. To do this, users can simply download the tarball from 10 010-013_LUD168 PK.indd 10 13/07/2016 11:57

See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.