Page 1


EDITOR COLUMN

General Contacts General Enquiries Fax Subscriptions E-mail Enquiries Letters

COMMENT

01625 855169 01625 855071 www.linux-magazine.co.uk subs@linux-magazine.co.uk edit@linux-magazine.co.uk letters@linux-magazine.co.uk

Editor

Faris Raouf fraouf@linux-magazine.co.uk

Staff Writers

Keir Thomas, Dave Cusick , Martyn Carroll

Contributors

Richard Smedley, Jono Bacon, Martin Milner, Dr. Inder Singh

International Editors

Harald Milz hmilz@linux-magazin.de Hans-Georg Esser hgesser@linux-user.de Bernhard Kuhn bkuhn@linux-magazin.de

International Contributors

Ulrich Wolf, Mirco Dölle, Michael Engel, Christian Reiser, Clemens Rudolph, Frank Bernhard, Klaus Bosau, Martin Strubel, Thorsten Fischer, Stefanie Teufel, Jo Moskalewski, Björn Ganslandt, Christian Perle, Hagen Höpfner, Torsten Rahn, Tim Schürmann, Georg Greve

Design

vero-design Renate Ettenberger, Tym Leckey

Production

Hubertus Vogg, Stefanie Huber

Operations Manager

Pam Shore

Advertising

01625 855169 Neil Dolan Sales Manager ndolan@linux-magazine.co.uk Linda Henry Sales Manager lhenry@linux-magazine.co.uk Verlagsbüro Ohm-Schmidt Osmund@Ohm-Schmidt.de

Publishing Publishing Director

Robin Wilkinson rwilkinson@linuxmagazine.co.uk Subscriptions and back issues 01625 850565 Annual Subscription Rate (12 issues) UK: £44.91. Europe (inc Eire) : £73.88 Rest the World: £85.52 Back issues (UK) £6.25

Distributors

COMAG, Tavistock Road, West Drayton, Middlesex England UB7 7QE

Print

R. Oldenbourg

Linux Magazine is published monthly by Linux New Media UK, Europa House, Adlington Park, Macclesfield, Cheshire, England, SK10 4NP. Company registered in England. Copyright and Trademarks (c) 2000 Linux New Media UK Ltd No material may be reproduced in any form whatsoever in whole or in part without the written permission of the publishers. It is assumed that all correspondence sent, for example, letters, e-mails, faxes, photographs, articles, drawings, are supplied for publication or license to third parties on a non-exclusive worldwide basis by Linux New Media unless otherwise stated in writing. ISSN 14715678 Linux is a trademark of Linus Torvalds Linux New Media UK Ltd is a division of Linux New Media AG, Munich, Germany Disclaimer Whilst every care has been taken in the content of the magazine, the publishers cannot be held responsible for the accuracy of the information contained within it or any consequences arising from the use of it. The use of the CD provided with the magazine or any material providied on it is at your own risk. The CD is comprehensively checked for any viruses or errors before reproduction. Technical Support Readers can write in with technical queries which may be answered in the magazine in a future issue, however Linux Magazine is unable to directly provide technical help or support services either written or verbal.

4 LINUX MAGAZINE

5 · 2001

Faris Raouf discusses the fate of Linux in the coming years

FUTURE PROOF Editorial column from Faris Raouf Judging the worth of an operating system is easy to me. It’s measured simply by how long it stays on my main PC before I get annoyed with it and revert to my trusty Linux kernel. One operating system that didn’t last very long at all was IBM’s OS/2. As an operating system, OS/2 actually has an awful lot to recommend it. It doesn’t gobble system recourses like there was no tomorrow. It is also very stable and was generally easy to use and administer. In its ”Warp” desktop variant, which IBM launched at great expense, it can even run Windows desktop applications through a sort of emulator, using code licensed from Microsoft. As you’d expect, running Windows applications is not an ideal thing to do and is much more trouble than it’s worth. Still, back in the OS/2 heyday it was the only way for many OS/2 users to get access to the kind of applications they need because few OS/2specific products of any note ever hit the streets. Those that did were custom written, such as those used in the banking sector. From my point of view, however, the real trouble with OS/2 was its lack of drivers and relatively poor hardware recognition during installation. The recognition problem could be solved with a bit of effort but drivers were a real problem – few hardware manufacturers couldn’t be bothered to write any. The end result of all this (plus a few other factors, of course, including Microsoft’s marketing machine) is that OS/2 is far from popular. I hear that it is nowadays an order of magnitude better at everything than when I tried it out. But how many people do you know who run it? Some predict a

similar fate for Linux for similar reasons but they are undoubtedly wrong. I know this because Linux has stood the test of time and has remained on my system ever since I first installed it. Using my criteria above, it’s clear that Linux has a great future ahead of it – you only have to look at the amount of news generated and the number of big name manufacturers getting involved with the operating system in one way or another. More and more manufacturers are voluntarily producing Linux drivers for their hardware too, which means better compatibility than ever before (as you’ll find if you look at our notebook supertest on page 34). Not only that but comprehensive and stable USB support is now almost with us, as you’ll see in the USB storage feature in this issue. And with each new distribution released, hardware recognition gets even better and system configuration gets easier. I installed Linux Madrake a few days ago and could count on one hand the amount of clicks and key strokes I undertook! And this being Linux, if you are willing to experiment you can download patches and test versions of drivers and Kernels almost as soon as the last line of code has been written. The unstoppable momentum behind Linux is bringing it head to head with Windows sooner rather than later. Of course it will still be a very long time before a little Penguin appears on almost everyone’s screens instead of a Microsoft logo during boot up. You never know, though – Microsoft might decide to start speaking Penguin at some point. It could happen, you know. Only time will tell.

Faris Raouf

We pride ourselves on the origins of our magazine which come from the very start of the Linux revolution. We have been involved with Linux market for six years now through our sister European-based titles Linux Magazine (aimed at professionals) and Linux User (for hobbyists), and through seminars, conferences and events. By purchasing this magazine you are joining an information network that enjoys the benefit of all the knowledge and technical expertise of all the major Linux professionals and enthusiasts. No other UK Linux magazine can offer that pedigree or such close links with the Linux Community. We're not simply reporting on the Linux and open source movement - we're part of it.


NEWS

Linux lowdown Next year will see the publication of Linus Torvalds’ book giving his account of how he came to develop Linux. ”Just for Fun: The Story of an Accidental Revolutionary” has been cowritten by Torvalds and David Diamond and will be published by HarperBusiness. The book combines Torvalds’ autobiography with his business philosophy and technology insights. In it, he describes the experiences and long-standing belief in free software that led him to develop a free, open source alternative to the operating systems on the market. With a user base of more than 12 million people, the success of Linux is supported by an international community of programmers and users who contribute to its refinement, while Torvalds continues to control the essential kernel software, orchestrating the contributions of a core group of programmers. ”The Linux operating system has offered a real challenge to the power of Microsoft and other proprietary systems,”said HarperInformation Associate Publisher Adrian Zackheim, ”and the principle of freely-shared code offers a range of new business models and development options to the technology industry. The insights and experiences of such a key figure as Linus Torvalds will be invaluable in this changing environment.”

Linus Torvalds, leader of the revolution...

Dreaming? Rumours of a Linux kernel for Dreamcast have been flying around the Internet for months, but they may be set to become reality. According to Linux Magazine’s sources, work is under way for at least four different ports of Linux for Dreamcast, all at different stages of development. Reports go on to say that some developers have recently joined forces on the Dreamcastlinux and the DCLinux site. Although unofficial ports have appeared, these ports may become the first to be made publicly available with source. According to sources, developers are now trying to track down as many of the unofficial ports as possible, in order to use them in the integration, where possible. Linux Magazine’s source did not wish to name the author of a ”pre” port kernel, written before the project got off the ground, until the author’s breach of GPL could be addressed, but added, ”Hopefully he will release his code to this project and become a part of it. His contribution would of course be very valuable.”

Info http://www.dreamcastlinux.org http://www.dreamcastlinux.org/ http://dclinux.sorceforge.net ■

Fox adds it all up Fox on Linux has launched its accounting software solution for the Linux environment. Fox on Linux provides businesses with an Internet based multiuser accounting solution. It has a 12 kbs bandwidth requirement and is designed to be easily integrated with other corporate front-end applications. The software comes with online support and training. Fox on Linux spokesperson, Mark Rees said, ”We developed Fox on Linux to meet the growing trend in business for easy to use Linux applications. We took a well honed financial package used in a commercial environment and secured exclusive rights to port and support it for Linux.” Fox on Linux is currently inviting those interested to trial the system by registering online and use the software over the Internet for a limited time period.

8 LINUX MAGAZINE 5 · 2001

Easy does it The latest version of Easy Software’s HTML document conversion and formatting software, HTMLDOC, features a new portal CGI, enabling web servers to dynamically serve Portable Document Format (PDF) versions of their HTML pages. In addition HTMLDOC v1.8.9 adds support for ROWSPAN in tables, BMP image files, new page number formats, and HTTP file references.

Info http://www.easysw.com ■

Trend Micro launches new anti-virus solution Internet gateway anti-virus solution provider Trend Micro has announced that the next release of its InterScan VirusWall gateway virus protection and content-filtering solution will be available for Red Hat, SuSE and Turbo Linux. Scheduled for release in the first quarter of next year, InterScan VirusWall 3.6, offers an optional content filtering module InterScan eManager v3.6, which supports Red Hat Linux (v6.1 and v6.2), SuSE Linux (v6.4 and v7.0), and Turbo Linux (v6.1J and v6.1). The software sits on the gateway server to provide real time Internet protection against viruses and other types of malicious code. Because detection is from the gateway, the protection can be extended to any platform. The virus scanning engine features both rule-based and pattern recognition technologies to detect and remove viruses. The software integrates with Trend’s central management console Virus Control System enabling virus protection to be managed across the enterprise. Some versions of InterScan are fully integrated with Check Point FireWall-1 and the software is compatible with most other major firewalls. Evaluation copies of the software are available for download from the Trend Web site. Oscar Chang, senior vice president of product development at Trend Micro, said, ”The addition of the SuSE and Turbo Linux versions of InterScan VirusWall really stemmed from developers who wanted the same gateway-level protection Trend Micro was currently offering for other platforms, like Red Hat Linux. Developers and technologists have always been an important part of our customer base, so we wanted to give something back to the open-source community.”

Info

Info

www.foxonlinux.com.

http://www.antivirus.com


NEWS

Tooled up! Hard Hat Linux developer MontaVista Software has announced the availability of its toolkit for enabling legacy VxWorks code from Wind River Systems to run on a Linux platform. The MontaVista suite provides applications with a VxWorks virtual machine which implements key system calls and behaviours of the VxWorks kernel to run on a standard Linux platform. This means the VxWorks APIs can often build and run unmodified, or with only modifications to the header files. The MontaVista tools emulate the most frequently used APIs associated with the VxWorks executive. Other APIs may translate directly to common UNIX/POSIX APIs native to Linux, or require VxWorks configuration and initialisation calls not needed in a Linux environment. Kent McMullen, MontaVista vice-president of marketing commented, ”This multi-tiered approach reflects how Hard Hat developers already are making the move away from proprietary embedded Oses. We are just delivering a no-nonsense, off-theshelf package that accelerates and standardizes the porting process.” The VxWorks to Linux toolkit is available for download from the MontaVista project site and will also be bundled with the Hard Hat Linux Professional Developers Kit, along with targeted and supported pre-built packages for each of the MontaVista target embedded processors.

Info http://www.vxworks2linux.org ■

The biz Following its announcement in October that Red Hat Linux would support the full IBM eServer range and all IBM Linux enabled software, Red Hat has continued its work with IBM to introduce new IBM software infrastructure packages for enterprises of all sizes. The new software will be available through Red Hat’s channel and from its Web site from the first quarter of next year. It aims to extend the range of options open to enterprises that wish to deploy their mission critical e-business applications on the Linux platform. The bundles are the first of a series, which will later include IBM DB2 Universal Database and WebSphere Application Server software solutions for the enterprise. The Red Hat Domino Bundle is an integrated messaging, collaboration and Web application software platform aimed at expanding companies. The bundle includes Lotus Domino R5

New Itanium-based prototype at Manchester

Caldera announces new appointment

The Computer Services for Academic Research (CSAR) organisation based at the University of Manchester has announced that it has installed an Intel Itanium processor-based prototype systems from SGI to be used for porting parallel scientific and engineering codes to the Itanium processor platform. CSAR aims to replace its existing 816 processor Cray-T3E 1200E with a next generation system from SGI by the end of next year. The installation is one of the first in Europe and the initial configuration is a multi-node Linux cluster with two pre-release Intel Itanium processors per node, and using a Myrinet interconnect. The CSAR service is operated by the CfS (Computation for Science) consortium, which is composed of CSC, SGI and the University of Manchester, and is dedicated to providing state of the art, high end computing facilities to the UK research community. Jan Silverman, vice president of marketing at SGI commented, ”We are delighted to be delivering one of the first Itanium processor based systems to be installed in the UK. This demonstrates our continued commitment in high performance computing and academic research. The combination of the Intel Itanium processor and SGI Pro64 high performance compiler technology will enable new price performance for the academic and research market places.” ■

Linux management solution provider Caldera Systems has announced the appointment of Edgie E Donakey to the position of the company’s new vice president and chief of staff. Donakey, who supervised the later stages of the Novell-Word Perfect merger earlier in his career, has already served as director of international marketing and director of the mergers and acquisitions team at Caldera since February 2000. Prior to that, Donakey served as an executive for 3Com Corporation and as president of The Bison Group, where he designed and implemented strategies for Fortune 500 companies. Donakey said, ”Working at Caldera while acquiring two divisions of SCO has shown me that this is the company with the people and technology to transform the Linux and UNIX industries. I feel confident in Caldera’s ability to deliver superior Internet open software that will meet any business’s infrastructure needs.” Caldera chief executive Ransom Love, said, ”Ed’s attention to detail and abilities to multi-task and synchronize many departments with energetic follow-through made him the natural choice. His background in sales, marketing, technology, and administration is a tremendous contribution to Caldera, particularly as we move into the future with The Santa Cruz Operation’s Server Software and Professional Services Divisions.”

Application Server, 25 Lotus iNotes CALs and Red Hat Linux 7 Professional. For smaller businesses with fewer than a hundred users, the Red Hat Linux Small Business Suite offers a cost-effective solution featuring Lotus Domino R5 Application Server, IBM DB2 Workgroup Edition IBM WebSphere Application Server Standard Edition, WebSphere Homepage Builder, WebSphere Studio and Red Hat Linux 7 Professional. Colin Tenwick, vice president and general manager, Red Hat EMEA commented, ”There is a growing demand for solution-based products and our new offerings will give our customers the best possible foundation on which to build their Internet infrastructure. As the World’s market leader in Open Source and Linux technology, Red Hat is now able to provide a total e-commerce solution jointly using IBM’s technology and Red Hat’s operating system and services.”

Info http://www.calderasystems ■

5 · 2001 LINUX MAGAZINE 9


NEWS

SUBRUBRIK

Linuxcare’s portfolio expands

Compaq announces new server The DL320 is an ultra-thin, single-processor 1U server designed to offer users a straightforward way in which to deploy, manage and remotely control one to thousands of servers, to simplify the administration of complex, growing multi-server environments. In addition, Compaq has launched its new proactive management tools in the form of the Compaq Availability Agents, designed with the help of Availant, designed to simplify the management of complex IT infrastructures supporting Internet technologies. Compaq Availability Agents have a web based interface to provide administrators with a way of automating responses to Microsoft Windows server events to increase system availability, without the need of scripting language knowledge. Iain Stephen, Intel server business manager, Compaq’s Industry Standard Server Group said, ”Service providers and other emerging companies with growing environments need servers that deliver power without depleting their budgets or their floor space. The power and manageability of the ProLiant DL320 specifically addresses both of these needs. The industry-defining technology of the Compaq ProLiant DL line, combined with our latest management tool offerings, is an example of Compaq’s inspiration technology that is redefining and simplifying our customers’ IT experience at a compelling, new price point.” Mark Melenovsky, research manager at IDC commented, ”Compaq is the worldwide unit marketshare leader in the density rack-optimised server market. Customers in this space require cost-effective, fast and easy-to-deploy systems for their rapidly expanding IT infrastructures. Compaq’s latest offering, the ProLiant DL320, is a logical extension of its density line to address the needs of emerging local service providers and dot-coms.” ■

Less is more with VectorLinux 1.8 Microsoft Windows users who want a taste of Linux without using up large amounts of system resources may be interested in the new distribution release of VectorLinux 1.8. This offers a fully functional X Windows based version of Linux 2.1.17 which can run in 16 MB of memory and needs just 170 MB of disk space. The new release is designed to be straightforward to install and configure and enables a dual-boot environment in which the ICEwm windows manager provides a multi-desktop environment, as well as the Linux operating system. VectorLinux has the features of a small, high-performance, x86-based Linux distribution and offers full functionality with a GUI desktop, a development environment, FTP server, sendmail, networking utilities, laptop support, and a range of desktop and console applications. The software is available for download from the VectorLinux Web site http://www.ibiblio.org/pub/linux/distributions/vectorlinux/veclinux-1.8/

10 LINUX MAGAZINE 5 · 2001

The new additions to the Linuxcare customer base include Adaptec, Digital Island, Ecrix Corporation, Ivenue.com, Maxtor, SGI, Espial, 3ware, VERITAS Software and WSE/Honeywell. These companies join the ranks of Linuxcare customers, which have grown over the past six months to include Compaq, Eazel, Hewlett-Packard, IBM, Motorola, SmartDisk, Sun Microsystems, Tricord Systems and Zelerate. Linuxcare specialises in providing a vendor-neutral approach to the needs of its customers, combining its consulting, support, education and product testing and certification services. According to Linuxcare, its aim of maximising the benefits of the Linux environment for its customers delivers considerable business benefits, while at the same time helping to drive the adoption of Linux in the corporate environment. Linuxcare chief executive Art Tyde said, ”Linuxcare has made remarkable strides in accelerating the use of Linux, spanning networking, storage and other technologies that provide the foundation for building successful e-business infrastructures. Our unique and complementary service offerings provide the perfect match for meeting the Linux outsourcing needs of a variety of companies. For many, we are an essential component as they define and execute on their Linux go-to-market strategies.” ■

Telia comes in from the Sun Scandinavia’s largest ISP and telecommunications company Telia has announced that it has replaced its seventy Sun servers with Shark storage technology and an IBM mainframe zSeries G6 server running Linux. Under the deal, which is estimated at $3 million, the IBM solution provides simultaneous hosting for more than 1500 virtual Linux servers. For management purposes by Telia’s business customers, the virtual servers will appear to be independent physical systems, although a single administrators will be able manage the entire mainframe from one graphical management interface. Henrik Wulff Riedl, Telia’s chief financial officer, said that the company now intends to replace an existing customer billing system for Internet service providers based on Oracle databases. ”This new S/390 running Linux allows us to rethink our total pricing structure for Internet services and to offer customers a more affordable Web application service than ever before. The combination of the IBM mainframe with Linux makes it easy to install new servers for Internet service customers on the fly. Before, it took us five hours to set up a new server. Now, it is a matter of less than five minutes. With Shark’s storage capacity, ”we now are able to give virtually unlimited Web capacity to our customers without going through the trouble of installing and reconfiguring the systems all the time.”


ad


NEWS

Caldera announces new appointment Linux management solution provider Caldera Systems has announced the appointment of Edgie E Donakey to the position of the company’s new vice president and chief of staff. Donakey, who supervised the later stages of the Novell-Word Perfect merger earlier in his career, has already served as director of international marketing and director of the mergers and acquisitions team at Caldera since February 2000. Prior to that, Donakey served as an executive for 3Com Corporation and as president of The Bison Group, where he designed and implemented strategies for Fortune 500 companies. Donakey said, ”Working at Caldera while acquiring two divisions of SCO has shown me that this is the company with the people and technology to transform the Linux and UNIX industries. I feel confident in Caldera’s ability to deliver superior Internet open software that will meet any business’s infrastructure needs.” Caldera chief executive Ransom Love, said, ”Ed’s attention to detail and abilities to multi-task and synchronize many departments with energetic follow-through made him the natural choice. His background in sales, marketing, technology, and administration is a tremendous contribution to Caldera, particularly as we move into the future with The Santa Cruz Operation’s Server Software and Professional Services Divisions.”

Info http://www.calderasystems ■

Virtual development environment released Linux-based embedded systems solution provider Lineo has announced that it has begun shipping the Lineo Embedix software development kit for Windows. Embedix offers Windows developers a virtual development environment with real-time response capabilities, X86 and PowerPC processor support, in which they can develop embedded Linux solutions while using native Windows applications and tools within a Windows NT 4.0 or Windows 2000 hosted environment. One of the key features of Embedix SDK is the Target Wizard library compilation tool, which automates the way in which developers select their requirements for a target image as well as how they check software interdependencies. The Target Wizard tool also helps developers create the smallest possible software image for their embedded device by stripping out unnecessary features and lines of code. ”Windows developers can now expand their development portfolio to include embedded Linux without leaving their Windows environment,” said Bryan Sparks, chief executive of Lineo. ”Embedix SDK for Windows provides the tools and technologies to make it easier for developers to create embedded Linux for consumer devices, Internet infrastructure and industrial controls without the need for costly or time-consuming training. With this product release, we are giving Windows developers the same capabilities that native Linux developers enjoy.” Lineo also offers Embedix SDK for Linux, which provides developers with the same tools for software development, but enables them to work within a native Linux development environment.

Xi Graphics releases AcceleratedX Display Servers update Release 6 of the software includes a variety of new features developed in response to customer feedback, including XiG X Full Screen Extension (XiG-XFS) support for VMWare, Preliminary USB support for Linux and Solaris 8 and Digital Flat Panels (DFP) support, as well as dual view support for cards such as the Matrox G400 and Appian Duet and Touchscreen support and TSC calibration support via the tscal program. Release 6 also features a new, dynamically loadable, I/O subsystem and LBX and XKB extension support. Downloadable demos for the desktop and laptop servers are available at Xi Graphic’s Web site. Dan McGregor, national sales manager at Xi Graphics, said the company takes customer feedback very seriously. ”The additional features offered in version 6 are, for the most part, in response to customer inquiries and requests. We are particularly sensitive to market demands and set our engineering goals in accordance with what our customers want. This is particularly important with the popularity of Linux on the rise, resulting in new markets and potential customers appearing every day.” He added, ”We feel that our attention to the needs of our customers is one of the things that really sets us apart from our competitors. Customer requests have prompted the addition of version 6 features such as support for VMWare, USB in Linux and Digital Flat Panels. This customer- oriented attitude is also apparent in our free technical support that comes with all Xi Graphics’ products.”

Info Info

www.xig.com

www.lineo.com ■ ■ 12 LINUX MAGAZINE 5 · 2001


NEWS

VMware introduces new products for Intel customers VMware has announced two new server software products to help Intel server customers scale their Internet computing infrastructures. The new products, VMware GSX Server, and VMware ESX Server aim to offer service providers and enterprise IT organisantions using Intel and Intel-compatible servers a way of scaling their infrastructures safely, reliably and on demand. VMware GSX Server offers users mainframeclass control of their Intel servers, while VMware ESX Server provides a scalable solution for high-performance server environments adding mainframe-class resource and system management capabilities. Both are based on VMware’s MultipleWorlds technology, which provides a thin software layer that sits between the Intel architecture and the operating system, to virtualise the hardware and manage

Motif defect database publicly available OSF/Motif products and support supplier ICS has made the Motif defect database, previously only accessible by The Open Zone employees, publicly available online at its MotifZone Motif community Web site. The publicly available defect database tracks problems from all releases of OSF/Motif from version 0.7 to the current Open Motif 2.1.30 release and is the result of several months work on the part of ICS as it had to reformat, hide the identities of submitters and their companies, and load the defect reports into the Bugzilla open source bug tracking system first made available by Netscape’s Mozilla project. Howard Greenwell, Director of Business Development for The Open Group commented, ”Our goal continues to be to promote the use of Open Motif on Linux and other open source operating systems. ICS’ investment in formating the defect database for Web access helps promote open access, a critical success factor in Open Motif being embraced by open source developers.” ”This database demonstrates the stability and maturity of the toolkit,” said Mark Hatch, Chief Operating Officer for ICS. ”The number of reported defects is low for the complexity and breadth of a product such as Motif. This database makes a natural complement to the existing public access we provide to the Open Motif source code on the MotifZone.”

Info http://www.motifzone.net ■

hardware resources. ”We’re at the centre of three IT trends,” said Diane Greene chief executive of VMware. ”One is the need to deliver managed services on Intel servers with mainframe-class quality and Internet speed. Another is a computing environment that is complex, with an incredible number of incompatible hardware platforms, operating systems and applications. And the third is growing pressure to meet these challenges without increasing IT budgets or adding staff.” She continued, ”With VMware, you can create a uniform software platform for delivering applications and services on Intel servers that factors out hardware and operating system differences and simplifies deployment and management. That’s of huge value to service providers and enterprise IT.” ■

IBM and Linux IBM has underlined its enthusiasm for the Linux environment with the announcement of its new set of Linux tools, including a DB2 Universal Database for Intel based Linux clusters. This, says IBM, is the only commercial database software available for Linux on the mainframe. The release comes as part of IBM’s initiative to provide support for the Linux operating system across the entire range of its e-business software, servers and services. Other Linux tools now available from IBM include the DB2 Enterprise Edition for IBM Z Series and S/390 platforms for Linux – IBM’s software providing embedded environments for enterprise servers and IBM’s web application server software – WebSphere, as well as extended support for the open source operating system through its Websphere middleware and development platform. Dan Kusnetzky, Vice President of System Software Research at IDC commented, ”Linux is seeing increasing usage as a part of basic IT infrastructure at many organisations. Over half of the respondents in one of IDC’s demand-side studies indicated that they considered their Linux applications to be ‘major’ applications. IBM has positioned itself well to be considered one of the leading suppliers in this emerging market.” To accompany the databases, IBM has released DB2 Connect, a tool set enabling users to access their mainframe-based DB2 data from any Web-based applications that run DB2 on Linux. ■

5 · 2001 LINUX MAGAZINE 13


NEWS

Interstar Technologies announces new release Fax solution provider Interstar Techonologies has announced the release of the latest version of its LightningFAX enterprise fax software. New features available with LightningFAX 7.0 include improved integration of Lotus Notes, support for high-density fax boards, and support for LDAP and T.37. LightningFAX 7.0’s new intuitive Lotus Notes interface can be used to compose and receive faxes, configure personal information and fax priority, and track the status of fax documents, as well as unifying inboxes and outboxes. The Notes administrator supports day-to-day LightningFAX administration directly from the Domino interface. The new release also supports the NMS AG 4000, which offers fax resources and network interfaces on a single PCI card for up to 120 channels with 4 T1 or E1 trunks. There is also support for the Dialogic DM3 Fax series, which can scale to 96 channels for a T1 configuration. Other new features include a Lightweight Directory Access Protocol (LDAP) support, which lets LightningFAX use third-party software directory with, or instead of, the LightningFAX database, an Advanced Phone Book with new find capabilities to enable users to search results and create dynamic distribution lists from one or more databases, as well as to search the LightningFAX Phone Book and third party contact directories directly from the LightningFAX SendFAX window. The new Rasterizer Extended Format support enables native conversion of all PCL and Postscript files to fax format. ”The advanced features of LightningFAX 7.0 are a

direct response to what customers have been telling us they want,” said Guy Blanchette, chief executive of Interstar Technologies. ”Major enterprises need a complete range of fax solutions that integrate into any business environment. LightningFAX 7.0 shows our customers that we’re committed to developing reliable, cost-effective solutions that deliver missioncritical documents on time, every time.”

Info www.faxserver.com ■

RedWire to distribute Cyclades E-Commerce International IT Systems Integrator RedWire Ltd. has announced its appointment as official distributor of Cyclades E-Commerce for the UK and Ireland. RedWire (which has Linux open source solutions as its focus) currently offers an extensive range of IT Solutions and Integration for corporates, with emphasis on Consulting, Development, E-Commerce Solutions, Service and Support. It has now taken over responsibility for the online distribution of Cyclades products for the UK and Ireland via its e-commerce portal, www.penguinwarehouse.com. Both companies see the appointment as strengthening their Linux strategies.

Free Software Foundation Europe A Declaration of Intent has been published by Georg C. F. Greve of the GNU organisation, on the concept of a Free Software Foundation Europe as a sister organisation of Richard M. Stallman’s Free Software Foundation (FSF). The FSF is a charity dedicated to eliminating restrictions on copying, redistribution, understanding, and modification of computer programs. It’s core activity is supporting the GNU project which, with the Linux kernel, forms the Operating System which we know and love. The recent European consultation on patent law – and the UK patent offices own consultation round – has acted as a wake-up call to Open Source and Free Software supporters in Europe. Patents include the concept of a ”Computer system and method for performing multiple tasks,” filed by six engineers from IBM Germany in 1993 and Amazon’s patenting of ”one-click” shopping using a Web cookie. EuroLinux collected over 62 000 signatures against European software patents and galvanised opposition. A separate body reflecting European culture and working within European time zones was mooted. The FSF-Europe is not a splinter group, rather a sister organisation to the FSF, reflecting European culture and providing local organisation with the same goals: 14 LINUX MAGAZINE 5 · 2001

- Political lobby for Free Software & the GNU Project - Providing an organisational backbone - Raising and distribution of funds It will work with existing national bodies such as the French group April (Association Pour la Promotion et la Recherche en Informatique Libre) and the German Förderverein für eine Freie Informationelle Infrastruktur (FFII or Association for the Promotion of a Free Informational Infrastructure). The FSF Europe will start with an organisation in Germany, followed by other European countries. These local bodies will allow Europeans to make tax deductable donations to the FSF. The aim is to take it slowly to get the organisation right. Debate in the mailing list is considered and careful. As we go to press, FSF Europe is in an ”about to become reality” phase, as their Web site (http://www.fsfeurope.org/) puts it. Mailing lists have been set up to discuss the new body and keep people up to date with announcements.

Info http://mailman.fsfeurope.org ■


BUSINESS

ANNUAL REVIEW

The year 2000 through the eyes of Linux

THE MORNING AFTER THE PARTY ULRICH WOLF

The year just passed was as eventful as any in Linux’s history. Here we take a look at the business movers and shakers involved with the free operating system.

By the end of 1999 there had been a rapid succession of news stories to bring a smile to the face. Young companies who felt they had a duty to free software appeared to be on track for a victory parade without equal. The more established ones were rushing so as not to miss the boat. The world was in upheaval. In the meantime it was ”Business as usual” for Linux – still doing okay but with just a few of the revellers suffering the morning after the party. Let’s begin with the good news. Free software in general and GNU/Linux in particular has definitely found its way into the mainstream of the computer business. As a server-operating system at least, Linux is fully accepted by the big boys in the sector such as Hewlett Packard who, in August, declared the free operating system a strategic platform. This ranks it alongside HP-Unix and Windows 2000. Following this there was an interesting reaction from Eric S. Raymond who challenged the HP-CEO Carla Fiorina in an open letter to make her loyalty to free software clearer and, for example, to give away the code for HP Unix. The letter ended with the words: ”Show us the code, Ms. Fiorina. That’s where the real co-operation starts.” The letter and Fiorina’s reply can be found at [1] and [2] respectively. The latter contains numerous references to Linux and Open Source activities at HP but we do not have space here to mention them individually.

Big fish break the nets Compaq is continuing the strategy it began last year to get Linux on the Alpha platform. This is bearing fruit in the Sandia research laboratory in New Mexico where a cluster of Linux-run Alpha servers is 16 LINUX MAGAZINE 5 · 2001

being created, currently working with some 1300 nodes. This cluster, called Antarctica, is intended to become number 20 in the top twenty of the world’s fastest computers [3]. On Intel-based servers, too, Compaq is embracing Linux – you’ll find it among the actively-supported operating systems in the Proliant range. The company is mainly building its strength in this area with the introduction of enterprise features such as high availability or hardware monitoring. An overview of Compaq’s Linux activities can be found at [4]. Most of the positive Linux headlines in 2000 were generated by IBM. The investment of 200 million dollars in Europe alone, announced by IBM in July, was made it into even the daily newspapers. However, the fact that IBM is also investing the same amount in East Asia for Linux was overlooked. Nevertheless IBM currently appears to be the only group which has a company-wide open source strategy complete with more or less clearly defined interfaces to the community.

Symbiosis between great and small For the young start-ups in the open-source domain the commitment of the heavyweights was a doubleedged sword. On the one hand, there might be something like a symbiotic relationship between the developers of free software and companies such as Hewlett Packard or IBM. The further development of the operating systems does devour quite a bit in terms of resources, which can scarcely be recouped with licence sales alone. With Linux as a crossplatform Unix-type operating system on the other hand this expense can be saved in the first place, and secondly can make a considerable contribution to the consolidation of the company’s own server lines, as shown, among others, by the rebranding at IBM. Everything there, from RS/6000 via AS/400 to the S/390 mainframes, is now trading under the generic term ‘e-server’. And on all these platforms,


ANNUAL REVIEW

Linux porting is largely completed. This means the opportunity is opening to dispense with the development and upkeep of a company’s own operating systems altogether in the long term and nevertheless not have to fall into a disastrous dependency on an individual software company. Conversely, Linux is profiting from the enterprise features which the hardware manufacturers are having to bring into development in their own interest if their strategy is to succeed. The image of Linux is also being boosted by its association with large companies. A win-win-situation, then?

Do you hear the people sing? The evidence that this is not quite so true is becoming more evident. At the moment it does seem that neither Microsoft or Sun will be among the losers in this development, but that the revolution is beginning to claim its own children. The ”victims” appear in the first instance to include the young start-ups who build their business plan solely or primarily on service – firms such as Linuxcare in the USA or ID-Pro in Germany, to name two prominent examples. Linuxcare had in the summer of last year (and primarily on the grounds of personnel problems) cancelled its IPO. It is now certainly glad it did! ID-Pro, with its massive liquidity problems, is now facing either bankruptcy or a not-sofriendly take-over... or at least that’s what the rumours say. A whole range of factors play a role in the stories of such companies, which start with an ”exulting to the skies” phase and end-up usually in the ”worried to death” stage. Both examples are also hard to compare with each other, taking place on different continents in different environments. Nevertheless, the market for consulting, support and services of all kinds is a dangerously slippery path for those who, apart from services, have little or nothing to offer.

Growth opportunities or niche existence? The symbionts described above rapidly turn into competitors in the service domain and woo key customers and staff. It is not wholly improbable in this case that the consulting divisions of the company groups such as IBM Global Services, Siemens Business Services or, in the future, the Debis system houses which have joined up with Telekom, will pull ahead. The ”youngsters” would then be left with more or less large niches, or unattractive markets, populated by competing companies of similar size and origin where they would be forced to perform gladiatorial combat. But the time has not yet come for definitive statements. It may be the ”early adopters” have just come to the market a little too early and the age of the big, successful companies with a business plan based solely on open source software is still ahead of us. That would be a topic

BUSINESS

for a review of the year which lies ahead of us. Instead, let’s take a look at the fiscal events of the year 2000 in double-quick speed.

Linux and the stock market Where there is light, there is also shadow. The year 2000 has of course brought Linux widespread recognition in the IT world and beyond but it has also been a year of disillusionment for all those who wanted to use Linux to make a fast buck. The year started with a continuation of the high-altitude records for technology stocks which had begun in autumn 1999. Linux shares profited from this more than others. Stocks being traded for the first time on the market were given a vote of confidence which expressed itself in price rises seldom previously experienced. In Autumn 1999, VA Linux set a NASDAQ record, when the share rose on the first day of trading from 30 to 240 dollars. If the auspicious stock market launch of Red Hat last year was a surprise success, the successors such as VA Linux, Caldera or Linuxmall immediately became the pampered children of analysts and investors. On 13 January Caldera Systems announced its stock market launch in the wake of these high-altitude flights and was traded on NASDAQ for the first time on 21 March. But by Spring the mood was already changing. Linux stocks were badly affected even more than average by the drop which followed. By now many shares were below their launch price, despite positive reports and the continuing good economic situation, and scarcely a single company, because of the continuing bad feeling, dared to venture onto the market. So nothing came of the planned stock market launch of SuSE in the autumn, about which insiders had been gossiping even in early summer. The irrationality of stock markets works strongly in other directions too – also hard hit by the effects were the Linux activists who believed in the rapid success of Linux and were investing in the corresponding shares. The success of Linux has certainly come true but not as expected. The fact that the operating system is winning through does not now necessarily mean that Red Hat is making a lot of money, for example. Open Sesame: Some commercial software products which became Open Source in 2000: • Interbase 6, Enterprise databank, announced in January by Borland, released in Spring under its own licence[6] which is largely identical with the Mozilla Public License. • Motif, the veteran of GUI toolkits, receives an Open Source Licence [7] in May 2000 after decades of use; the licence roughly corresponds to the GPL but is only applicable to free operating systems. A commercial licence is valid for proprietary systems. • OpenCascade, released on 1 June by the French company Matra Datavision, is a highlyprofessional multipurpose CAD tool. The core of the program is an object library programmed in

[top] Adversaries in the fight for code release – Eric S. Raymond, hacker (in the true sense of the word), and Carla Fiorina, boss of HewlettPackard [above] The Linux supercomputer ”Antarctica” in the Sandia Laboratory.

5 · 2001 LINUX MAGAZINE 17


BUSINESS

ANNUAL REVIEW

C++, quickly extendible, for the creation of one’s own CAD applications [8]. • In October SAP put its company’s own databank [9] under the GNU General Public License. • Long-announced and warmly welcomed by the developer community, the source of StarOffice was placed under GPL by Sun at the start of November. OpenOffice [10] is to be closely meshed with the GNOME desktop with development taking place mainly at Sun as before.

Capital: Investments in opensource firms

The stock market rewarded the resignation of Corel founder Michael Cowpland as CEO with a price leap of 13 percent.

Many Linux and open-source companies had no need to worry in 2000 about a lack of capital. By January, even before initial quotation and NASDAQ, Caldera was given an injection of 30 billion dollars. Those involved included, among others, Sun, Citrix, Novell and SCO. TurboLinux was able that same month to celebrate the receipt of over 57 million dollars. The knock-on financing of Eazel also went without a hitch; this is the company in which Macintosh veterans hope will raise the userfriendliness of the GNOME desktop to a new level. 15 million flowed in January into the start-up from, among others, Intel. In April, Accel Partners handed over another eleven million. The venture capital company was in the past involved at an early stage in UUNET, Realnetworks and Macromedia. Free web application servers were also at a premium among investors, even if they did not recognise the trend until towards the end of the year. In August Lutris Technologies, the home of Enhydra, received 16 million dollars from a consortium consisting of Compaq, NEC, Deutsche Bank, Alex Brown and the Chase Manhattan Bank. Wherever Enhydra is, Zope can’t be far away. And Digital Creations (http://www.digicool.com), the firm which created Zope, was still able during 2000 to complete a financing deal for 12 million dollars. Those involved

The Corel Story It would be arguably incorrect to describe Corel as the Linux Company Of The Year 2000. But it terms of its appearances in various news columns and news tickers, the traditional Canadian company definitely deserves ranking. Corel Linux came to the market at the end of 1999. The sales figures in the first quarter appeared to be highly promising. But turnover went into a decline and then, at the same time, Corel surprised the world by announcing a take-over of Borland/Inprise. This was meant to take place by a share swap. The stock market price of Corel, however, collapsed by 70 percent with the result that Borland shareholders refused to approve the deal. Corel fell into financial difficulties and a wave of redundancies followed. The investment plan to rescue the company became more daring and less transparent from one round of financing to the next. Then in Autumn, Microsoft, of all people, leapt in as the white knight. One part of the contract is an obligation to port Microsoft’s .NET technology onto Linux on demand. Rumours say that the port is already in existence. In the meantime Corel plans to separate completely from its Linux activities.

18 LINUX MAGAZINE 5 · 2001

included among others, Intel once again. The first big take-over the year caused a stir in the Linux community. In February, VA Linux bought Andover.net which includes the community sites Slashdot and Freshmeat. The purchase price was just under a billion dollars in shares, if one takes as the basis their price at the date of take-over. In January SCO announced server products for Linux and in Summer there was talk of their own Linux distribution. Then Caldera suddenly declared that it wished to take over the entire server software division of SCO. Announced in August, there remain some formal legal problems posing an obstacle to the merger. But the union of the two companies may even have taken place by the time you read this. Caldera will then possess a fullygrown, well-organised distribution channel and with Unixware, a product which is well-established, especially among medium-sized companies, a good, strong position compared with other distributors which have to put a lot of energy into distribution. A few more take-overs: Lineo is buying, among others, the potential competitors in the embedded domain, Zentropix and RT-Control (uCLinux); VA Linux is bringing in-house, with its purchase of Precision Insight, the graphics know-how of Daryll Strauss, David Dawes and Brian Paul, and their hardware basis will be further extended by the acquisition of TruSolutions (1U-Rackserver) and NetAttach (Network Attached Storage). SuSE came to the fore, less by aggressive purchasing of companies than by steady expansion. Sales in the USA has been expanded and branches have been founded in, among others, the Czech Republic, Italy and Venezuela. Turbolinux is building itself a European presence and lots of other activities of this type have occurred in the course of this year. But to list them all here is impossible for reasons of space.

Love matches and marriages of convenience – joint ventures, mergers, expansions The first big take-over the year caused a stir in the Linux community. In February, VA Linux bought Andover.net which includes the community sites Slashdot and Freshmeat. The purchase price was just under a billion dollars in shares, if one takes as the basis their price at the date of take-over. In January SCO announced server products for Linux and in Summer there was talk of their own Linux distribution. Then Caldera suddenly declared that it wished to take over the entire server software division of SCO. Announced in August, there remain some formal legal problems posing an obstacle to the merger. But the union of the two companies may even have taken place by the time you read this. Caldera will then possess a fullygrown, well-organised distribution channel and with Unixware, a product which is well-established, especially among medium-sized companies, a good,


ANNUAL REVIEW

strong position compared with other distributors which have to put a lot of energy into distribution. A few more take-overs: Lineo is buying, among others, the potential competitors in the embedded domain, Zentropix and RT-Control (uCLinux); VA Linux is bringing in-house, with its purchase of Precision Insight, the graphics know-how of Daryll Strauss, David Dawes and Brian Paul, and their hardware basis will be further extended by the acquisition of TruSolutions (1U-Rackserver) and NetAttach (Network Attached Storage). SuSE came to the fore, less by aggressive purchasing of companies than by steady expansion. Sales in the USA has been expanded and branches have been founded in, among others, the Czech Republic, Italy and Venezuela. Turbolinux is building itself a European presence and lots of other activities of this type have occurred in the course of this year. But to list them all here is impossible for reasons of space.

BUSINESS

been given short shrift in this report). It remains to be seen how the world of desktops is going to look but this report would be incomplete without at least a mention of the GNOME Foundation [11] and the KDE League [12], lobby organisations which, with the aid of the industry, will create a breakthrough in precisely that field. ■ A few stock market-quoted Linux companies in figures

What a year Linux has built itself a stronghold in the IT world and is becoming established on more and more systems. This has been made more than apparent by the developments in 2000. But not all business plans based on open source have a chance of survival. The advance of free operating systems is most marked at present in the lower to middle server domain and in embedded systems (which unfortunately have

Info: [1] „Show us the code, Ms. Fiorina.” Open letter from Eric S. Raymond: http://linuxtoday.com/news_story.php3?ltsn=20 00-10-18-009-06-NW-CY [2] Carly Fiorina’s reply: http://www.linux.hp.com/open_letter.html [3] Antarctica-Supercomputer: http://www.sandia.gov/media/NewsRel/NR2000 /antarct.htm [4] Linux information page at Compaq: http://www5.compaq.com/products/software/li nux/ [5] The gentle giant, IBM and Open Source: Linux Magazine 08/2000, page 52 (German edition) [6] Interbase Public License: http://www.borland.com/interbase/IPL.html [7] The Open Group Public License: http://www.opengroup.org/openmotif/license/ [8] Open Cascade: http://www.opencascade.org/ [9] SAP DB databank: http://www.sap.com/solutions/technology/sapdb/ [10] OpenOffice: http://www.openoffice.org/ [11] GNOME Foundation: http://www.gnomefoundation.org/ [12] KDE League: http://www.kdeleague.org/ ■

Red Hat was only able to record moderate increases in sales compared with the previous quarter. The loss rose in proportion to turnover. Total turnover Loss 1st quarter 2000 $16,029 2nd quarter 2000 $18,493 Price on 31.12. 1999 Price on 15.11. 2000

$14,851 $15,713 105.625 11.625

VA Linux:As a hardware manufacturer they were less severely affected on the whole by the general price slide. VA Linux is an exception in particular for two reasons. Firstly the price at the end of the year was still massively overvalued, and secondly VA was forced to issue a profits warning shortly before the second reporting date, which almost halved their share price. Total turnover Loss 3rd quarter 2000 $34,595 4th quarter 2000 $50,662 Price on 31.12. 1999 Price on 15.11. 2000

$20,627 $47,515 206.625 12.563

Cobalt:Cobalt Networks showed itself to be remarkably unimpressed by the general sinking feeling. „Only” 40 percent share price drop is celebrated by many as a grandiose success. Cobalt is now on the shopping list of Sun Microsystems.

Corel:Stagnation in Corel’s sales figures. In the year 2000, there is nothing to be seen for miles around of the earlier profits in the software sector.

Total turnover 1st quarter $12,033 2nd quarter $16,242 3rd quarter $20,370 Price on 31.12. 1999 Price on 15.11. 2000

Total turnover 1st quarter $44,141 2nd quarter $36,639 3rd quarter $36,357 Price on 31.12. 1999 15.125 Price on 15.11. 2000 3.625

Loss $2,583 $6,021 $12,239 78.5 46.688

5 · 2001 LINUX MAGAZINE 19

Loss $12,401 $23,618 $10,745


REPORT

DESKTOP SYSTEMS

The future of Linux and the desktop

WHICH WAY FORWARD? JONO BACON

Choice is, in general, a good thing. But choice also brings with it the headaches of decision-making. Linux/UNIX already offers more then 30 window managers in combination with several desktop systems. What will the future hold?

Over the past couple of years I have been involved with the KDE project in contributing to a leading desktop for Linux/UNIX systems. Although my time has been spent with other open source projects, KDE has remained my desktop of choice. One of the most positive elements of Linux is the power of choice, and this is particularly evident in the world of desktops. Alongside KDE is GNOME, Afterstep, Windowmaker, FVWM and hundreds more. Some of these projects vary in their target, but they are all related in providing an easy to use GUI experience for the Linux user. Although my interest in KDE is clear, I am going to focus this article on the future of Linux and the desktop, and this covers far more than KDE alone. Of course, I will exercise absolute objectivity in my appraisal of the desktops. My focus is not which desktop to use, but what to expect from each of them. I will leave the decision of personal choice with whom it should be left – you.

(with most Linux users using XFree86). Both systems offer a good graphical interface and provide user and developer with a range of services that can ease the use and development of software running on the respective systems. Both have the following abilities: • Common styles and interfaces across applications • Reusable compants • Object embedding systems • Graphical system configuration software The above are a few of the main features of both systems – features that users not only expect, but need building on with innovative features that set the systems apart. Other than KDE and GNOME, there is currently a well-built and supported X Windows implementation – XFree86. XFree86 currently supports lots of hardware configurations, and is by far the most popular windowing software.

The limitations The current state of the desktop Before we can look into the future we need to first look at the current state of the desktop. Using this information we can then examine what we can expect from the desktop in the future. At the moment the bulk of Linux users appear to be employing either the KDE or GNOME systems. Both of these systems run off the X Window system 22 LINUX MAGAZINE 5 · 2001

Although the current state of the desktop is quite good, it is by no means perfect. Each system (as well as the general architechture) has its flaws. An example to begin with is X itself. X is a bit of a beast as it stands, and although development of X improves daily, it still has some performance issues. This no doubt due to the general structure of the desktop in which the OS is loaded first, and then X,


DESKTOP SYSTEMS

and then the desktop environment such as KDE or GNOME. In the current system, each layer is required, and the X layer is provided so the desktop system can access the graphics hardware and other services. This extra layer ensures a performance hit compared with other systems, which access the graphics hardware and other services directly. Another problem of X is that it is an established part of an old institution of technologies. X has been around for a number of years, and therefore has a requirement to continually support older software that runs on it (and which could possibly be omitted for a higher performance system). Another major stumbling block for the current desktop model is that of interoperability. This is the issue of the various desktops sharing information and services with each other so that changing desktops appears seamless. At the moment some things are compatible – such as drag and drop using the XDND protocol. KDE support GTK themes and applications can run under varying desktops if the correct software is installed (Kmail, for instance, will run fine in GNOME). A more serious problem is that of sharing data between applications. An example is if I would like to embed a Spread spreadsheet in

REPORT

AbiWord. In each environment it is easy to do within that desktop’s applications. However, cross desktop embedding is still problematic. Another uncertainty surrounding the current state of the desktop is the lack of a standardized desktop model. An example is that there are a great many desktop environments available, with a great many varying tools to build applications that run on these environments. Take for example KDE and Qt, GNOME and GTK, Motif, Afterstep, Window Maker, ICEWM, FVWM etc. While I am not saying choice is a bad thing, quite the opposite – it is a very good thing. A lack of standards however is a very bad thing.

The future The future of the desktop is one which seeks to fix current limitations, and one which works on extending the desktop model to areas and standards. Like any other Open Source project, there are enthusiastic developers from all sides, and just like the 200,00+ CD players we seem to have, there are certainly a variety of different options available.

A typical GNOME Desktop

5 · 2001 LINUX MAGAZINE 23


REPORT

DESKTOP SYSTEMS

To best describe the varying projects and where they are going, I will look at each separately and then assess how they fit together.

XFree86 When XFree86 4.0 was released it marked a change in the architecture of X, and added some new features. As XFree86 continues to develop, it gets faster and adds more and more features that make the desktop experience better. Newer features such as alpha blending (the ability to use transparency in graphical objects) and anti aliasing (making graphical objects look less pixilated) are slowly working their way into XFree86. At the moment these technologies are available to varying degrees. They are implemented by the toolkit which sits on top of X (Alpha Blending, for instance, is now supported in KDE2). After made technologies such as Alpha Blending it into XFree86, it can enhance performance. There are also some interesting developments with X in the implementation of XRender; a technology that will make X perform better and more flexibly.

KDE As I have most experience with KDE, I can fairly faithfully predict its future, and comment on current developments that will come to eventual fruition. At the time of writing, KDE 2.0.1 has just been released, and Alpha Blending has made it into KDE. KDE has been technically superior to many other desktops. The release of KDE2 consolidates its position, as a result of the sheer number of new features and capabilities. The range of technologies that were released in KDE2 makes both development and use of KDE applications easier. Technologies that were released as part of KDE include KParts (a component system for embedding software components in applications), DCOP (an inter-application message mechanism) and numerous other technologies. Although these technologies were new at the time of release, and many heralded a new wave of Linux development, an even more important role can be ascribed to a significant portion of them. Many of these technologies have formed the basis for even more impressive technologies of the future. Other interesting developments are taking shape in KDE. These consist of the implementation of a better printing system (possibly using CUPS or APS)and a more themeable desktop that will be implementated as time goes on. I have been told by some developers that transparent menus, alpha blended windows and other eye candy may be in store and the KParts model will no doubt be extended and perfected so data sharing can exist. A little while before KDE2 was released, Qt was also GPLed – which has enabled development for some parties who were previously restricted. 24 LINUX MAGAZINE 5 · 2001

GNOME Like XFree86 and KDE, GNOME is developing at an impressive rate, and is getting better and better all the time. The GNOME team have been working hard perfecting ORBit (the GNOME CORBA implemenatation), GConf (configuration system), Pango (internationalisation), Bonobo (component model) etc. The GNOME team have been developing their new technologies steadily. They have also made good progress on user interface development. This development is continuing to provide a solid development framework for GNOME developers using the new technologies. GNOME is based upon the GTK toolkit – an area of development which is also progressing smoothly. GTK continues to add new and improved features, and an impressive amount of language bindings.

X vs Framebuffer When the 2.2.x Linux Kernel was released, interest found its focus around a feature known as the framebuffer. The framebuffer is a technology that enables direct access to graphics hardware (a feature only recently being implemented in X). The benefit of the framebuffer is that the extra layer of X is not required and therefore there is a large increase in performance. Direct graphics access is a requirement in many cases for high-powered applications that require correspondingly highpowered graphics. A perfect example of this is in the use of games. The framebuffer support in the kernel opened up many possibilities for this new kind of support – which obviously bodes well for the desktop. The problem with the framebuffer at the moment is that it does not support accelerated graphics, which is important for many users. As the Linux kernel develops, and the framebuffer support improves, it makes the possibility of bringing the desktops (such as KDE and GNOME) closer to the kernel and running these directly off the framebuffer increasingly likely. The realisation of the desktop is already being developed and tested in some ways, and the tools for such development are already in the pipeline. An example is Qt from Troll Tech (Qt is the software which is used to build KDE). Qt is already available for X, Win32 and a port was made to the framebuffer. The Qt API has remained the same, and Troll Tech also decided to release Qt for the framebuffer under the GPL. This makes the development of a framebuffer KDE possible as the Qt API (the programmers interface) remains the same. Most of the KDE code uses the Qt API, and therefore little work would theoretically be necessary to port it to the framebuffer. Although a framebuffer desktop could be theoretically possible, and could have many benefits in terms of performance, there are of course some disadvantages in taking X out of the


DESKTOP SYSTEMS

picture. The main two problems are simply that you would not be able to run your X software on the framebuffer, and that you would lose the network transparency that X provides. For many users these disadvantages do not matter, but for some they do. The problem is reaching a good balance that is agreeable to most users.

KDE and GNOME collaboration If you take a look at the various technologies that KDE and GNOME have to offer, you can see that these technologies are performing the same functions in many ways. An example is KParts and Bonobo; both are component technologies. KDE and GNOME also use the same kind of humancomputer interfacing characteristics and common GUI elements (such as scroll bars, buttons etc). Surely there must be a way for KDE and GNOME to talk to each other? The answer to that is the same as the answer to many questions of this type – yes and no. Technically virtually anything is possible. However, there are some considerations that may make this feasible and some reasons it may not be so practical. The first is that many KDE and GNOME users are simply not interested in any collaboration

REPORT

as they only use one desktop and that one desktop’s applications. There are however, many users who want to share data between applications. There is certainly some support for this. I believe that there will, at some point, be collaboration. It is not likely that this collaborative effort will be written by someone who codes for the love of it, but by a company. Regardless of its origin, at some juncture the gap is sure to be filled. Many of the Linux distributors hire coders to write software that is needed for an enterprise desktop, but has not been previously conceived of. We need to always remember that Linux is built by many people in their spare time. Most of the software that we use is built by people who hack away when they arrive home from work, school or university. If nobody finds a particular area interesting, it simply won’t get written, no matter how desperately it is needed. That is why we seem to have 200,00 CD players, yet we lack some of the essential software that distributors end up writing. There does seem to be a will amongst developers to write the code, but I sense that technical control is difficult to coordinate between the two projects. By the time you read this it may have already been written, and I think that KDE/GNOME collaboration is a likely occurrence in the future.

A fully featured KDE Desktop

5 · 2001 LINUX MAGAZINE 25


REPORT

DESKTOP SYSTEMS

Multimedia and the desktop One area in which Linux and the desktop is making good progress is that of multimedia. The future looks good. Because Linux has a strong UNIX-based server background, multimedia was neglected in some respects until the desktop revolution in Linux came along. As the desktop gets more and more multimedia laden, and the Web provides better bandwidth and more multimedia content, Linux and the desktop needs to be able to support and execute these emergent multimedia effectively. The development of multimedia in Linux has taken a number of routes, but one route that is looking most promising is the development of aRts. The aim of the aRts project is to provide a multimedia framework that can be used by applications. The aRts team has phased in key technologies and while playback of multimedia content was primarily the focus, a strong codebase is also being developed in the creation of synthesizers and digital effects. The aRts project does not rely on any particular desktop to function correctly, although it is being used officially in KDE for multimedia content. I have not heard anything from the GNOME team about using aRts, but they may be using it officially for multimedia in GNOME. As a student of multimedia communication at university, I needed to rely upon a variety of multimedia technologies for the successful implementation and execution of multimedia products. As Linux currently stands it is a good platform for playback and execution, but is not wholly suitable for multimedia authoring. I predominantly use Macromedia Director for multimedia authoring, and although I am not aware of plans to port Director to Linux, I am surprised there are no Open Source multimedia authoring packages available. If you know differently and have seen some projects to develop a multimedia development package, please get in touch with me and let me know.

Applications, applications, applications It is well known that a computer cannot function without usable software. This is particularly true in the world of the desktop. A Linux desktop is nothing but an interface to a computer, and a way of working in a controlled environment. Once the

Some useful Web sites: KDE GNOME XFree86 Troll Tech KDE League GNOME Foundation

26 LINUX MAGAZINE 5 · 2001

http://www.kde.org/ http://www.gnome.org/ http://www.xfree86.org/ http://www.troll.no/ http://www.kdeleague.org/ http://www.gnomefoundation.org/

environment is in place, applications are required to exploit its features and get the user’s work done. When examining applications for the desktop, we note that there are predominantly three types: • Productivity • Custom • Browsing Productivity applications are applications which a user can use to create something and get his/her work done. Examples include office suites, graphics manipulation programs, personal information management systems etc. It’s applications like this that users really want so they can get their work done using Linux. In terms of office suites, the future looks good. Currently the contenders are KOffice, GNOME Office, OpenOffice amongst others. All of these office suites work quite well on a basic level at the moment, but the road ahead looks bright. With the basic functionality there, special features are being added such as automatic formatting, HTML generation etc. Also these office suites are using the new technologies that both KDE and GNOME are developing, thus making sharing data between each component in an office suite a simple proposition. The second category is custom applications. This includes applications specifically written for a particular purpose and not for general usage. Examples include scientific applications, custom business applications for particular business practices and research applications for conducting research in institutions. As this category does not really deal with the general usage of the desktop it is not strictly relevant. Custom built software will always be written to specification and is not always necessarily available to use publicly. What is relevant however is that as the varying desktops make application development easier and more scalable, the benefits of exploiting these technologies are real and accessible. The third and final category is browsing software. This includes software that enables you look at various types of content, such as Web sites, FTP sites, images, textual documents, sounds, video etc. Browsing software is crucial to the success of the desktop, and some serious progress has been made recently in the ability to browse content across the desktops. Examples of applications that can browse content include Konqueror for KDE and Nautilus for GNOME. The essential thing about browsing software is that people who use a desktop frequently use it to look at already available content rather than publishing content. A typical example of this type of user is someone who browses the Web. The only tool they really require is a capable Web browser. They do not need an HTML editor, image editor and FTP client to browse. The actual proportion of people who spend most of their time browsing is high. Even the people who use productivity software still browse too. The future certainly looks good for the browsing software fans, with progress being made in virtually all areas of browsing, and projects maturing steadily. Web browsers such as Konqueror and Mozilla are


DESKTOP SYSTEMS

becoming more capable at displaying content, image viewers such as Electric Eyes continue to develop strongly and support more and more file types, and document-centric viewers such as Adobe Acrobat viewers are displaying the latest PDF specification files. Probably the most difficult of all browsers to develop is the Web browser, as so many new technologies are added to the Web experience. However, most technologies are implemented extremely quickly.

Commercial backing of the desktop When Linux was in it’s earlier stages of development, many companies shunned it as a geeks’ system which only programmers could have any shred of interest in. As time went on, and development got stronger and stronger, companies started putting a firm foot on the bandwagon and began supporting Linux both verbally and substantively. As the desktop revolution of Linux then gathered steam, some companies began to realise the potential of Linux, or simply to accept that it was not going to go away. Although there had been some backing for the various desktops, on August 15th 2000 the first major support agreement for the GNOME desktop was announced with the unveiling of the GNOME foundation. The official announcement stated the following about the aim of the GNOME Foundation: ”The GNOME project today announced the creation of the GNOME Foundation, which will be governed by a board of directors elected by the hundreds of volunteer developers who contribute to GNOME. In addition, industry leaders and organisations including Compaq, Eazel, Free Software Foundation, Gnumatic, Helix Code, Henzai, Hewlett-Packard, IBM, Object Management Group, Red Hat, Sun Microsystems, TurboLinux and VA Linux have announced their support for the foundation, with the goal of advancing the availability of this easy-to-use, open source, desktop environment.” This move was a turning point in the development of GNOME and is a sign that the future of the GNOME desktop will be supported by a range of companies, who might possibly wish to use GNOME in an enterprise environment. This could pass some major benefits onto users. The KDE team had been preparing a similar system, although they initially put the idea on hold in order to get KDE 2.0 finished. Once KDE 2.0 was released however, it was time to explore the idea further, and the KDE League was born. The official announcement of the KDE League stated: ”The KDE League is a group of industry leaders and KDE developers focused on facilitating the promotion, distribution, and development of KDE. The League will focus on promoting the use of the advanced Open Source desktop alternative by enterprises and individuals and on promoting the development of KDE software by third-party

REPORT

developers. The League will not be directly involved in developing the core KDE libraries and applications, although League members are encouraged to contribute to the KDE codebase in the spirit of KDE’s wildly successful ‘Bazaar-style’ development.” The importance of the GNOME Foundation and the KDE League factors cannot be over-estimated when it comes to predicting the future of the desktop. Although the GNOME Foundation and KDE League do differ – many think they don’t but they definitely do – both organisations are there to help promote each desktop and what it has to offer. This will been more developers will get involved and that means more software. Also, the companies behind each organisation will no doubt be using their power to put the desktops on more computers, and get more software ported to each desktop. The marriage of Linux and the desktop is developing at an incredible rate, and the usability of software for the Linux desktop becomes easier and easier all the time. Although many hardcore Linux addicts frown upon the commercialisation of Linux, it is happening. It needs to happen to help Linux into enterprise and thence into the domain of the common or garden home user. With the rapid advancement of development and the enthusiastic twenty-four hour global coding frenzy, it is difficult to predict the future for a system that moves so quickly and holds the potential for such dynamic growth. There is no doubt that the desktop environments such as KDE and GNOME are going to develop smoothly and efficiently on their own merits, but the future should bode well for both systems integrating together more tightly. We will no doubt see embeddable components within both desktops’ compliant applications, and more sharing of themes and inter-application communication. We can also expect to see the desktops integrating better with palmtop computers and devices, and maybe even seeing both KDE and GNOME available for pocket computers! The future for the X Window system looks both bright and gloomy as we get a better implementation of X, with more features and performance improvements, but with the rapid development of the framebuffer, X may be taken out of the picture altogether. Application support for the desktop is getting better and better all the time. The work of the KDE League and the GNOME Foundation should bring more commercial software natively to the desktop, as well as protecting the valuable community of developers who contribute their time and skills for free. The future of the Linux desktop is bright. As I conclude this article just remember this – it took years and years to make other commercial desktop environments usable enough to appeal to the average consumer. The Linux desktops have virtually caught up with these other desktops in an impressively short time. With this pace of development, and the enthusiasm of millions of developers and users, who knows where the future will take us? ■ 5 · 2001 LINUX MAGAZINE 27


REPORT

EMBEDDED SYSTEMS

From heavyweight applications to Embedded Linux

OS TO THE HEART OF GADGETS DR. INDER SINGH

Embedded Linux is here to stay. The only question is: how big a player can it really become in the marketplace?

Dr. Inder Singh CEO and chairman LynuxWorks

The early focus for embedded Linux was on thin clients and network appliances – extending the operating system’s pivotal part in Web and mail servers, Internet gateways and firewalls. Also, with heavyweight support from software and hardware developers in the real-time arena, Linux is being adopted as the platform for critical sub-systems in communications, retail technology, industrial control, transportation systems and aerospace. Pretty soon it will be leading the way towards a post-PC generation of gadgets in the home, as well as PDAs, mobile phones and mobile entertainment systems. For those who are used to Linux as the OS of choice for their servers – and increasingly their desktop workstations – the idea of Linux inside their PDA or games console, let alone their mobile or MP3 player, seems surprising. Yet Linux enthusiasts have been recompiling Linux kernels to run on their Palm devices for years, and building hobby projects such as MPEG decoders in their basements. For real commercial applications, however, it has required robust, productive development environments, specialised distributions and broader CPU support to get the embedded Linux bandwagon rolling. Yet rolling it surely is. Over the last few months the computer press has reported a wave of new embedded Linux designs that will appear in the shops very soon. This includes a mobile phone with

28 LINUX MAGAZINE 5 · 2001

a 10cm square screen; a screen phone, a high-end games console, a home networking gateway and a palm-sized PDA. The appeal of Linux to embedded designs is clear. In contrast with proprietary operating systems such as Windows CE, Embedded NT, or Wind River Systems’ VxWorks, it is both Open Source and an open system. It’s royalty-free and, like the best of real time OS’, Linux supports POSIX and other standard, open interfaces for networking and graphics. Developers are protected from single-vendor dependency. They can readily move applications to Linux systems from multiple suppliers and other flavours of Unix, and benefit from a massive body of existing software and expertise. Wide availability of drivers, open source code and licensed software, all work to reduce development effort and cost. Linux is well supported by the thousands of developers working to refine and improve the OS and has a reputation for being robust, reliable and secure. These are major advantages for embedded systems. Most importantly for the gadget industry, the configurable, modular kernel of Linux makes it easy to meet the resource constraints of embedded applications. It is relatively simple to compile a compact OS that supports just the functions required, and in the tiny footprint of a portable, battery-operated device.


SUBRUBRIK????

Comprehensive hardware support For embedded system developers, comprehensive hardware support is a must: the operating system has to perform with specific processors, I/O devices, buses, networking and graphics standards. Linux does not disappoint – it has already been ported to more CPUs than any other OS. In addition to Intel x386 to Pentium-class processors, the latest versions of Linux have been ported to Power PC, Hitachi SuperH, ARM, StrongARM and MIPS embedded CPUs. Hitachi processors are widely used in a variety of embedded systems such as multimedia and consumer products – including hand-held personal digital assistants, digital still cameras, and game machines. Meanwhile, ARM versions are set to accelerate development of new applications, including audio and digital imaging, video appliances and kiosks, Web-enabled cell phones, highly intelligent point-of-sale (POS) terminals, residential gateways, navigation systems and others. And Linux’ hardware capabilities go a lot further. It can handle a rich mixture of target environments, from single boards to VME- or PCIbased multiprocessor systems, and a wide variety of devices and system buses. Drivers are quickly made available to the developer community – for free – as new I/O devices are introduced with increasing frequency. For busbased systems there are Linux ports to VME and PCIbus single-board computers and drivers for a variety of other standards, including CAMAC, CAN, GPIB and BitBus. Despite these attractions, adopting Linux for embedded systems has only recently become a simple task. Why? For a start there have been few distributions specifically for the embedded developer. By and large developers have had to work with distributions geared mainly to desktop computers and servers. Worse, these constitute a fast-moving target as new kernel versions are posted frequently. Embedded developers have to balance cutting edge innovation against stability. Fortunately, specialised versions of Linux – such as BlueCat Linux from Lynuxworks – are now being introduced to address these issues. Typically, these bundle a version of Linux with a range of specialist tools to aid embedded system development. In common with several other alternatives, the

REPORT

LynuxWorks option features a highly configurable kernel, making it simple to create variations according to user requirements.

[links] The game console Indrema L600 with Linux. [mitte] Agenda (Agendacomputing) and Yopy (G-Mate) are available, soon.

Development environments Designing an embedded system is a very different process from developing software to run on a workstation or server. Traditionally, developers use their familiar workstation or PC environments to develop code, then use specialised tools for subsequent cross deployment in the more resourceconstrained target hardware. The development environment needs to support this cross development paradigm with powerful cross compilers, debuggers, image binding tools, and networking resources on the host. Equally critical, developers using Linux need various add-on tools that enhance the ability to build, debug, test and deploy embedded applications. BlueCat Linux, for example, includes industrystandard ANSI C and C++ compilers, structured macro assemblers for supported target processors, the ld Linux linker for ELF relocatable file binding, and mkimage, a powerful tool for building kernel downloadable images containing complete bootable and ROMable user application and Linux OS binaries. To provide cross-execution of system-level code in a controlled setting, Linux distributions can carry a variety of debugging tools aimed at embedded system developers. For example, the Total/db source level debugger is based on the popular GNU gdb, but enhances its core features to target the Linux OS kernel, specialised device drivers and embedded applications. Embedded Linux is also benefiting from add-on tools, such as new performance analysers, like the LynuxWorks SpyKer event tracing tool, to find elusive errors resulting in resource contention, throughput bottlenecks, deadlocks and race conditions, which source-level debuggers alone do not easily tackle. The fact that these facilities are now starting to appear is a clear indication that Linux is set to grow substantially in the embedded applications market. Once developers of embedded systems find that they can count on support by vendors who are focussed on their needs, and can provide Linux solutions that meet their most demanding requirements, industry observers expect the use of embedded Linux to far outweigh the operating system’s use in general computing applications. ■

[rechts] Looks like a PDA, but is a cell phone: the IMT-2000 from PalmPalm

Read further: LynuxWorks: http://www.lynuxworks.com Lineo: http://www.lineo.com Montavista: http://www.mvista.com Embedded Linux News Channel: http://www.linuxdevices.com ■

5 · 2001 LINUX MAGAZINE 29


REPORT

LINUX FOR SCHOOLS

Linux for Schools – An Introduction.

LESSONS IN LINUX RICHARD SMEDLEY

Linux – and Free Software in General – is not just a cheap ICT solution for cash-strapped schools but a chance to improve the creative learning process. This article examines the state of Linux use in the UK and its prospects for employment in the classroom environment.

Whilst many readers use Linux at work, at least on their servers, and the majority choose it as their home desktop OS; how many of you are sending your children out to benefit from Free Software at school? Unfortunately the answer is not many. ”Point ‘n’ drool” proprietary software is the norm in our schools. Children leave the education system with little idea of what a computer can really do or even how to use one to get anything achieved. Unless students take a science subject at university they may never see powerful applications like Tex running on a free (or even a proprietary) Unix. This compares very badly with the situation twenty years ago when, despite a shortage of machines in schools, we were taught the basics of programming and learnt the ”underlying 30 LINUX MAGAZINE 5 · 2001

principles” of computing. Schools and the birth of home computing produced a generation of innovative coders whilst the government funded Free software for the BBC B Microcomputer. The dumbing down of ICT in schools is causing a severe skills shortage in the UK. Linux start-ups, and established companies venturing into the Free Software world, are fighting for the few who haven’t gone the easy MSCE route to riches. Andy Roffe of Cheshire-based iTS-LiNUX is one who has had to work hard to find capable staff. He is a keen supporter of Linux Users Groups (LUGs), and their role in Linux advocacy in schools and the business community, a sentiment shared in a recent editorial of this magazine. ”We have offered our time, free, to schools and trade associations,” says Roffe, ”to


LINUX FOR SCHOOLS

try and make a case for Linux, but so far with no takers. The Open Source model and my experiences in Germany have taught me that many more people are learning to code on the Linux platform, due to the inclusion of all the development tools.” However this is no cause for gloom, change takes time. Two years ago few were backing Linux for success on the desktop, now rapid growth there looks certain. Similarly in schools, Linux use is patchy and unsupported by those in power, but change is coming.

First the bad news Policy on IT use is governed by the Department for Education and the Environment (DfEE) and implemented by the Local Education Authorities (LEAs). Guidance comes from Becta (the British Educational and Technology Agency) the government-funded agency which supports ICT in curriculum subjects. Becta have recently given the DfEE a briefing sheet on Open Source Software (OSS) which should lead to all tender documents no longer specifying particular closed source solutions. Under the National Grid for Learning (NGfL), schools have been encouraged to take up Managed Services. Goods and services are provided by Certified Solutions Providers (certified by Becta), the school just delivers curriculum content, which can reduce the skills-base in the school. The barriers to becoming a Provider are more financial than technical, though the documents have not been phrased to prevent Linux implementation in schools. Nevertheless Becta have not been wholly succesful in explaining Free Software to schools or government, and many industry players are unhappy with the new competition that it brings. A planned conference on Open Source Software was called off because of pressure from a large software publisher, and other attempts to flag up Open Source Solutions have met with a similar fate. ICT teachers and technicians look to Becta for a lead and find no officially backed alternative to expensive closed source software. As we go to press Becta were planning on publishing a Technology Information Sheet on Open Source Software on their Web site. There is an impression that those in government circles really do not ”get” Open Source or Free Software, seeing it as a rival commodity rather than a better way of doing things with strong educational advantages.

Linux growth Recent announcements on Linux support from IBM and Sun are excellent news. However Linux has become popular because of grassroots enthusiasm – from coders and developers initially, but lately from users too. The government may show little understanding of what free software is, not to mention its benefits, but in

REPORT

schools Linux is slowly appearing, server side first, as it did in the corporate space. One looks with encouragement at the Powys example. The county IT strategists suggested a look at Linux ”principally on cost grounds,” says Dr Martin Williams, the co-ordinator of ICT services for Powys LEA, who installed servers in two schools as a trial. ”It worked so well that not only did we put it in all our schools but Linux is now always the platform of choice for County servers.” Powys, as a large rural county, has provided ”telecottages” where the community can take advantage of IT resources. Here and elsewhere in the county Linux powers the servers, leveraged by cost and native ease with network protocols.

Normal service will be resumed Of course Linux power on the server side does not just mean Apache or files served by Samba. Individual schools around the world are putting Linux servers to many imaginative uses. Holding a disk image for an MS Windows installation which is transferred to the workstation each time it is booted up, giving a clean installation (no matter what damage the previous user did) is one prime example. Of course all work is saved centrally to the Linux file server. The Linux Terminal Server Project (ltsp) enables redundant old PCs to be recycled as diskless workstations booting from a central network server. Other similar projects exist. One modern PC with, say, 256MB of RAM, can serve several dozen clients running X - though the number drops if spreadsheets on Star Office are involved! Like many developers, Phil Jones met considerable resistance when trying to give away his Linux for Schools Project (lfsp) software to schools. Most schools didn’t even reply and we wouldn’t have heard about it if it hadn’t been taken up so enthusiastically by Nigel Pauli of St. John’s school in North London. The Linux for Schools Project (lfsp) introduces pupils to the Unix Command Line Prompt from the ”safety” of their WinTel box, teaching them the benefits of a multi user, multi tasking networked environment. See the lesson plan on their Web site. Applications over the net are the next big thing apparently, with Microsoft trumpeting their .Net strategy. Several Linux-based remote solutions, such as Schoolmation, are being developed and the desktops can be any platform at all. The natural objections to this on security and privacy grounds can be overcome, but locally-run applications will always have their place on the desktop. Many of the projects mentioned above show the advantages of a mult-user, multi-tasking OS. However each machine served by the Linux box still costs the school big money as Microsoft collect a site license for every Mac or Pentium in most schools, regardless of what it’s running, as it has the 5 · 2001 LINUX MAGAZINE 31


REPORT

Pupils at St. John’s school in North London, accessing GNU tools through their MS Windows workstations.

LINUX FOR SCHOOLS

potential to run Windows or Office. Such cost considerations are going to affect schools in the same way that they have in the business sector – particularly at upgrade time.

Totally free Debian Junior is a project to make Debian GNU/Linux appealing and interesting to children ”aged 2 to 80”. Though at first they will be concentrating on the two to eight age group. Debian is a coalition of 500 developers – many are parents, and interested in adapting Linux for younger children. ”Debian Jr. has avoided directly addressing the Linux in the schools problem, preferring to leave that to SEUL/edu and others,” says project leader and Debian developer Ben Armstrong. ”Debian Jr. is a developer-driven project. Therefore, we focus on Linux in the home, which holds a personal interest for us because many of us are parents as well. By working first with what we know, we manage to keep what we produce very relevant. We hope that this will supplement the work that is being done by those who are interested in deploying Linux in the schools.” Armstrong does hope that Debian Jr’s responsiveness to its user base could lead to schools use, but ”it needs to be a user-driven project, with the teachers and administrators

Info Open source in Education: http://www.ose.org.uk. British Educational and Technology Agency: http://www.becta.org.uk/ National Grid for Learning: http://www.ngfl.gov.uk/ SuSE: http://www.suse.de/uk/schools/index.html Debian: http://www.debian.org/devel/debian-jr/ A new forum on KDE in the classroom: http://master.kde.org/mailman/listinfo/kde-edu K-12 Linux in Schools: An American project: http://www.riverdale.k12.or.us/. US-based discussion group for Linux in education: http://www.seul.org/edu/ Linux for Schools Project: http://www.lfsp.org/ Linux Terminal Server Project: http://www.ltsp.org/. Day-to-day info on the ICDC Schools Linux project: http://www.sc.lug.org.uk/schools ■ 32 LINUX MAGAZINE 5 · 2001

communicating with us (Debian – not necessarily Debian Jr.) about what they need. In turn, we would then draw from the more general resources we have at our disposal, such as SEUL/edu, and build on their success to make Debian easier to implement in schools.” SEUL/edu is a USA-based discussion group for Linux in education, part of the Simple End User Linux (SEUL) project. Although Red Hat are said to be planning support for education in Europe, the only commercial distributor to be actively promoting schools use of Linux in this country is SuSE. In Germany SuSE are developing KNLinux for schools and have just published a book ”Linux in der Schule”, by Dr Karl Sarnow. Roger Whittaker, SuSE UK’s Training Consultant and himself a former teacher, has offered SuSE’s professional edition to high schools at half-price in a mail-out and several hundred have taken him up on the offer. This includes the full support package. Whittaker also maintains a mailing list for those using Linux in schools. Here much of the traffic revolves around setting up Squid and Samba, and the needs of new users on the Server side can be quickly gauged. But what of the desktop?

Desktop The value of the International Centre for Digital Content (ICDC) Schools Linux project lies not so much in gathering together a ”distribution” – anyone can do this with the resources and applications currently available. The project’s value lies rather in leveraging their experience with schools, and their strength in the visual curriculum, to produce a study of what schools need to make Linux work for them in the classroom. Then in using this to show the benefits of using free software from an educational, as well as a financial and technical viewpoint. Laurie Peake of ICDC, sees many other advantages in breaking away from the current straitjacket of ”rote learning of standardised procedures via proprietary software.” Peake sees a role for free software in more creative learning processes. ”It is clear from our research at ICDC that a new set of skills is required for the [emergent] knowledge economy and that the current education system is not providing these. The system itself must seriously consider how it can provide the workforce of the future with the skills it needs.” So Linux is getting ready for the classroom. Can our education system get ready for Linux?

Resources We hope you will be hearing far more of Linux in schools this year. More information on the projects mentioned can be found at the sites listed below. All the Open Source projects listed welcome any help that you can give. ■


COVER FEATURE

NOTEBOOK GROUP TEST

Notebooks under the Linux spotlight

PORTABLE ALTERNATIVES MIRKO DÖLLE

Linux has advanced in leaps and bounds in recent years. It can now be easily installed on almost any desktop computer alongside its traditional home of a server or enterprise workstation. But is the same true when it comes to installing Linux on notebooks? After all, the frequently quirky hardware configurations and generally less sophisticated hardware can cause problems. To find out, we got ten of the latest brand-name notebooks on the test-bench and put them through some rigorous testing.

For our test we sent invitations to all the wellknown manufacturers, from Acer through to newcomer Wortmann. The result was a test field of eight products with prices ranging from around £1250 to £4000 or so. We deliberately concentrated on big-name manufacturers because they rarely change hardware specifications on a particular model. The reverse is true in the case of no name devices – although we might review a particular notebook, by the time you come to order it the hardware might have been changed, making our test results and conclusions irrelevant. Buying a big-name product has drawbacks, of course. The most significant is a higher price. However, as a reward for spending a little bit extra it’s fair to anticipate decent hardware support under Linux although this isn’t always the case, especially 34 LINUX MAGAZINE 5 · 2001

when a particular model makes use of state of the art hardware that may not yet be properly supported. But on the notebooks we looked at every single device was at the very least detected by Linux, though things like winmodems and some built in network adapters didn’t respond, and we occasionally found that the X-server had some minor but usually solvable problems. You can easily circumvent these problems by adding modems or network cards via a notebook’s PC Card slots if need be, though, so unsupported hardware like this is not a total disaster. As well as good Linux compatibility, we were pleased to note that no notebook manufacturer used proprietary memory expansion; standard and easily available SDRAM SO-DIMMs were used on all the notebooks. We were also generally satisfied with


NOTEBOOK GROUP TEST

the notebooks in terms of specifications levels. Even the 12-inch display on the Sony Vaio was capable of running XGA resolution and, thanks to the 700 MHz Pentium III, it was bursting with power. We were not particularly thrilled with the new plug standard used on most of the notebooks; standard ”kettle” leads for notebook power supplies are now a thing of the past and have been replaced by idiosyncratic designs. A lost or misplaced power cable can therefore be a major problem and we found that we were unable to source any compatible replacement cables from anywhere. Nevertheless many of the notebooks – the Toshiba, for example – did use a the ”figure of eight” lead often used by electric shavers, so you know what to do if disaster strikes. By far the biggest disappointment we had was to discover that except the Wortmann none of the notebooks we looked at are available with Linux pre-installed. Even worse, most companies seems to be not aware of Linux in any way – Acer’s Web site, for example, had not a single page refering to Linux. Hopefully this test will make some contribution towards breaking down the prejudices of many of these companies. ■

COVER FEATURE

Notebook add-ons: We used a Nokia 6210 and Siemens S25 to test infrared ports and mobile Internet access. The black card at bottom left is the Calluna Type III PC Card hard disk.

The tests All devices were weighed and measured immediately after unpacking. Then, wherever possible or necessary, the existing Windows partition was reduced in size to make room for Linux by using GNU/Parted. We used SuSE Linux 7.0 Professional for our tests, installing from CD (or DVD where possible). We decided to use SuSE because it is one of the most widely used distributions and to some extent also because it is available on DVD. Most importantly of all, though, we chose this operating system because, in our experience, anything that works with SuSE will generally also work with Red Hat, Mandrake or Debian, even if a bit of extra work is required in order to do so in some cases. The installed hardware was catalogized using lspci or – if that failed or we were in doubt about the results – the Windows system info. As far as possible we left the X-configuration set to YaST2 during initial installation of the operating system. For notebooks fitted with the S3 Savage graphics chip, however, we first installed the patched XF86_SVGA-server and then used XF86Setup, which we stole from a copy of SuSE 6.4 as it is isn’t included in Version 7.0. We had to skip a battery rundown test because so far we have found no realistic benchmark capable of reflecting a normal, day to day workload. And to quote the battery rundown time at full load, something we could do, isn’t very informative, either. This is because power-saving options would not have any real impact during testing and therefore no sensible results would be produced – who would really leave the kernel to recompile on a battery-powered notebook all day long, or render time-consuming scenes on a journey to the office? We did not run any performance measurement benchmarks, either, as five percent or so more power in one device over another shouldn’t have an effect on your buying decision. We did, however, measure temperature and noise levels. For our temperature tests, we ran a PovRay scene (which can be seen on the photos of the notebooks) and measured temperatures in four places 90 minutes after the program had been started. The temperatures were recorded at the warmest point on the keyboard, the warmest place on the underside of the device, the outlet from the notebooks’ main air vent and, finally, at the contacts on a PC Card slot (when a PC Card hard drive was in place). In the case of the IBM Thinkpad we had to fall back on an indirect measurement – the sensor would not fit into the slot with the drive installed, so we measured the temperature of the contacts immediately after ejecting the drive. We could not install the Type III hard disk into the Sony Vaio’s slots at all so we used an ActionTec modem card during this test. We also had to measure indirectly, though, just as with the IBM, because again our probe wouldn’t fit with the card installed. The actual operating temperatures in the PC Card slots of these two notebooks will therefore be a little higher than we measured them at. Measurement of noise levels was done with an ELV 8921 sound level meter, which was used to determine criterion C levels at head height for a normal user – 25 cm in front and 35cm above the front edge of the notebook. In the results table, the peak values in full-load operation are all listed both with and without the CD/DVD drive spinning. For PC Card compatibility testing we used a selection of PCMCIA- and CardBus cards from 3Com and AVM along with an ActionTec modem and Calluna 130MB Type III hard disk. We also tested infrared port operation and mobile Internet access using a Nokia 6210 and a Siemens S25 mobile phone. We’ll be reporting on our experiences in more detail at a later date.

5 · 2001 LINUX MAGAZINE 35


COVER FEATURE

NOTEBOOK GROUP TEST

ACER TRAVELMATE 737 TLV

The Acer notebook is a high-end device and is designed to completely replace a desktop PC. This means you get two big but discrete loudspeakers which, when we listened carefully, we traced to a site under the stylish hump on the lid. This means the TravelMate produces sound for the person or people sitting opposite very well and is therefore ideal for presentations. One feature we liked on the one hand but found irritating on the other is the TV output. This is an SVHS-socket, designed to plug into a modern television or video, except that under Linux it would not work – irritating to say the least. The notebook’s design is truly individual, especially the hump already mentioned which is 36 LINUX MAGAZINE 5 · 2001

located on the back of the 15-inch display. This makes the notebook fairly distinctive. The disk drive is permanently integrated into the notebook and the 8x-DVD-ROM sits in a drive slot and can be exchanged for a second battery, an additional hard drive or a CD-ROM. The facility for running drives externally is not provided with this model.

Hot air The cooling technology is of interest. Part of the airflow is conducted to the left lower side of the magnesium housing. This warms the underside very


NOTEBOOK GROUP TEST

nicely and, therefore, the user’s upper thigh. By far the majority of the excess heat is conducted away via ventilation slots under the display hinge which rise fore and aft of the lid. The keyboard also gets warm although this is mainly in the back left corner. The keyboard has an offset cursor block but unfortunately no separate keys for Home and End – these can only be achieved by a combination of the [Fn] and scroll keys. In place of a mouse, the Acer TravelMate provides a Touchpad with two keys and a scrolling rocker. Installed as IntelliMouse (IMPS/2) the mouse went a little bananas in use so we returned to the PS/2-emulation, leaving the rocker pad unused.

Irda The infrared port is, as with the Fujitsu-Siemens Lifebook, placed handily on the side of the unit. It was installed under Linux after activating CONFIG_SERIAL_DETECT and recompiling the kernel. This was done without a hitch. Together with the Nokia 6210 it provided our first mobile Internet experience.

Conservative equipment Elsewhere the hardware supplied is fairly conservative. The integrated ATI Rage Mobility with 8 Mb of memory is pretty popular among other notebook manufacturers and was installed within YaST2 easily, as was the sound card ESS-1969 Solo-1. With the latter you should turn down the volume using the rotary wheel – the internal microphone is very close to the loudspeakers and produced severe feedback at the upper settings. Like the Compaq, the TravelMate 737TLV Acer has both an Ethernet card (with an Intel Ether Express Pro 100 chip) and a Lucent LT winmodem, both on a single plug-in card. While the Ethernet card was detected and installed automatically, there is some manual work necessary with the winmodem.

COVER FEATURE

emulated by the combination of [Ctrl]+[Alt]. In the Acer TravelMate the sleep-function is activated when [Fn]+[F4] is pressed so we sent the device to sleep as the result of function key emulation. However, with the Acer this cannot be switched off in the BIOS. There is a workaround, however. By pressing [Ctrl]+[Alt]+[F4] and then [F4] again you will finally end up where you want to be. No dangerous situations can arise as the result of using [Ctrl]+[Alt] since only the keys [F1], [F2], [F4] and [F5] are affected. Perhaps Acer takes care of the Linux users and implements a toggle function for the [Fn] key emulation in their next BIOS update. All of which leaves the CardBus interface which has an O2 Micro 6832 controller. It initialised the Type III PCMCIA hard drive in two seconds and is thus one of the fastest tested here. But the slots, covered with spring shutters, unfortunately lie in the immediate vicinity of the side air outlet. At a temperature of almost 50 degrees at full load it gets very hot for the cards, which are only specified to work at temperatures of up to 55 degrees. Together with the heat the many expansion cards create on top of that, your PC Card devices might run the risk of getting damaged on hot Summer days.

Acer TravelMate 737TLV (+)

Hardware supported "out of the box"

(+)

very quiet

(+)

large display

(-)

TV-output not activated

(-)

CardBus-Slots too hot

Conclusion The Acer TravelMate 737 TLV was the notebook in this test where Linux worked best on. Apart from the SVHS output and the problems with the mouse not working in IntelliMouse mode, the TravelMate was completely without problems – Linux support for its hardware is already out there. We particularly liked the practical volume control wheel, the clever heat conduction and not least the lowest noise level. It is a shame that Acer did not seize this opportunity and offer the TravelMate with preinstalled Linux – we feel that this is the ideal Linux notebook. ■

Quick out The 17 Gb hard drive sits behind the cover in the middle of the front side and can be removed by loosening a screw. The hard drive slot can only take disks up to 12 mm thick. Smaller models can be fixed into place using the useful holding frames.

Secretive keys One big surprise came about when we tried a typical Linux keyboard combination – when changing from the X-console to the text console with [Ctrl]+[Alt]+[F4], the computer bleeped once and the screen went dark. By chance, we saw after a few seconds that the ‘Zz’-symbol had lit. There was no room for doubt – the TravelMate had fallen asleep! The solution was revealed by the Toshiba notebooks where one can set, in the BIOS, whether on external keyboards the function key [Fn] should be

Modem and network sit on a separate card, bottom left the two slots for commercially-available SD-RAMsoDIMMs can be seen. 5 · 2001 LINUX MAGAZINE 37


COVER FEATURE

NOTEBOOK GROUP TEST

COMPAQ ARMADA M700/7700 used. For this reason, Compaq has tilted the [B] away from the trackpoint so there is more room for the index finger, something which doesn’t noticeably affect the typing feel or ability. Under the space bar are three mouse keys which can be operated with no problem using the PS/2 protocol. Due to the compact dimensions – the lid is only a few millimeters larger than the 14.1-inch TFT display – the centre of the image is slightly offset to the left with respect to the keyboard. The result of this is that you have to look at the display a bit askew. This is not really a big problem but takes some getting used to – you tend to sit centred to the display but then type one row of keys to the left and keep producing gibberish.

First Start

The Compaq Armada M700/7700 belongs to the category of ultraportable notebooks. At first glance the M700 is worth the asking price for its robustness alone since aside from a few bits and pieces here and there its housing is made completely of magnesium alloy. The design also stands out from the rest because of the generouslycurved edge at the left front sinde which is an eyecatcher in itself. When closed, the Armada looks very much like a book, which is due to the straight right-angled sides and the Compaq logo which is turned to look like the title of a book. Overall the device is very handy and its simple elegance is inspired. The keyboard is, like the case, fairly nonstandard. The trackpoint, a sort of mouse-cumjoystick, sits as usual between the keys [G], [H] and [B]. When using most trackpoints it’s not hard to slightly touch the [B] key with the index finger and this may be bad depending on the program being 38 LINUX MAGAZINE 5 · 2001

The notebook was supplied pre-installed with Windows 98 although you don’t get the CDs. A standalone disk drive is supplied together with a set of cables consisting of a parallel port adapter, modem and Ethernet attachments. The power pack has the new triangular power socket which is incompatible with common power leads. If at all possible, you should try not to lose this because replacements could be costly. But Compaq is not alone when it comes to this new standard – Acer and IBM made the same choice. Before you delete Windows when installing Linux, you should change the TV output of the ATI Rage Mobility graphics chipset from NTSC to PAL as there is no option for this to be found in BIOS. This changeover under Windows is necessary only once and remains permanently active. While we’re talking about TV, it’s worth nothing that the Compaq Armada is the only device here to simultaneously output to display and TV over the entire range of resolutions – there is no need to set lower resolutions for


NOTEBOOK GROUP TEST

COVER FEATURE

By slanting the [B]-key on the upper side, there is more finger room when using the mouse.

presentations. Switching between simultaneous and purely external operation, by the way, is done by means of a little knob on the left next to the standby switch which worked under Linux without problems.

Loading Linux ... Installation of SuSE Linux 7.0 Professional went smoothly – YaST2 configured the XF86 _SVGAServer and then included the integrated Ether Express Pro 100 from Intel. But the installation of the sound card, an ESS 1978 Maestro 2E, was something the SuSE-Tool found too hard a nut to crack – the kernel module refused to co-operate. But with modprobe maestro the sound card was installed by hand with no further problems. During the entire installation the display flickered noticeably. After changing to text mode it was hard to recognise anything at all, in fact. This probably stems from the mode lines in YaST2 not being quite correct. After a reboot, though, the phenomenon disappeared and was never encountered again. The Irda chip was not recognised by findchip using irda-utils but could be used as /dev/ttyS1. What matters more is that in the kernel under Character devices the option CONFIG_SERIAL_DETECT has been selected and in the start script of the irmanager the second serial port is assigned to IRQ 3 via setserial.

CardBus problems A further surprise was waiting for us. In the manual Compaq states with regard to PCMCIA and CardBus that, at least under Windows 2000, one can only exchange cards with the device switched off. Funnily enough, this also seemed to relate to Linux because after every insertion or removal of a card (with cardmgr running), the kernel promptly died. The solution is to manually enter the irq-lines of the card services – we used IRQs 7, 9, 10 and 15 for PCMCIA and IRQ 11 for CardBus. After these entries the cards could be changed at will. The CardBus controller from Texas Instruments PCI 1450 needed for the initialisation of our Type-IIIPCMCIA hard disk a good 20 seconds to get going. During this period the whole system was paralysed. The positioning of the two Type-II CardBus slots at front right of the device may be something of a nuisance with some cards that have lots of external cable connectors, but on the other hand they remain astonishingly cool at just 30 degrees. The overheating which occurs with other notebooks will not happen to this one. The only thing we found irksome was the dummy inserts used to cover the CardBus slots – in practice they’re bound to get lost or damaged. Spring shutters which close automatically after the cards are removed are better. Compaq also supplies

as an accessory a shutter for the drive slot so that for example on an aeroplane where built-in CDROM- and DVD-drives are not allowed you don’t have to sit around with a hole in the side of your notebook.

Big Brother X11 Last of all we have a piece for the Cabinet of Curiosity. As already known from the world of desktop PCs, it’s frequently the case that when restarting the X-server, you can see the old screen content for a fraction of a second. The reason is that the graphics RAM is not completely flushed at every X start or X shutdown and is only wiped when power is lost. However, this isn’t the case with the Compaq Armada – hours later the desktop from the last session is clearly visible for just under half a second. This is perhaps not enough to spy out complex management structures, but may convict the son of his “immoral” internet activities on daddy’s laptop. So it is worthwhile restarting the X-server again before shutting down the computer or at least to close any traitorous windows.

Conclusion The Compaq Armada M700/7700 is one of the best notebooks in our test. All the integrated hardware could be installed with minor tweaks to the standard installation. The only niggle was that the sleep mode under X11 always ended with a crash, while no report of this problem was seen on the console. It was also a bit difficult to keep the Armada on one’s lap. The main air vent lies over the left knee and warms it to just under 60 degrees. – it might help cure rheumatism but isn’t ideal for constant use. As you’d expect, the only thing left to say is that it’s a pitty that Compaq does not offer this device pre-installed with Linux. ■ Compaq Armada M700/7700 (+)

robust, handy case

(+)

Hardware is completely supported

(+)

TV-output supports high resolutions

(-)

Sleep mode under X leads to a crash

(-)

high price

5 · 2001 LINUX MAGAZINE 39


COVER FEATURE

NOTEBOOK GROUP TEST

FUJITSUSIEMENS LIFEBOOK E-6560 expense of correspondingly narrower [Ctrl], [Alt] and cursor keys. Apart from the Wortmann Terra Aura the E-6560 is the only device with just two mouse keys. In the way of mouse control FujitsuSiemens provide a touchpad.

Hard disk swap

The silvery grey plastic case of the Fujitsu-Siemens E-6560 makes a good impression, even compared with the magnesium cases of some of the other notebooks tested here. Unfortunately with just two rubber feet it doesn't have a good grip on smooth surfaces and in normal use we found it constantly slides back and forth. The keyboard is relatively soft but offers a comparatively deep key depression. Despite the standard 'Windows' keys and a cursor block which is not offset, the Lifebook has an amazingly wide space bar although this is at the 40 LINUX MAGAZINE 5 ¡ 2001

Together with sound connectors and a loudspeaker control on the front of the unit, there are five special keys which unfortunately do not function under Linux. The developers have dreamt up a particularly crafty solution for the hard disk on our test model, however, which is that the disk sits in a 'swap frame' which can be taken out without a screwdriver. Another highlight is that the eyelet for the notebook lock is also part of the swap frame and thereby prevents theft of the hard disk. Sadly the swap frame is not a standard accessory but an extra. Not only that but it's described even by Fujitsu-Siemens themselves as 'very expensive'. We received the test device with a 24x CD-ROM drive but without the disk drive in the external drive slot, something which will be standard on the model you buy. The ejection mechanism of the CDROM is not ideal as a lever has to be folded out and then pressed in. But it is a very smooth mechanism although the protruding lever will keep on catching on things – clearly some room for improvement. The positioning of the infrared port has been taken well care of by placing it on the left front side. So the mobile used in the test was easy to get up and running transferring data. We were unable to investigate the IR port for a mouse on the lower right edge of the display because we had no suitable device.


NOTEBOOK GROUP TEST

Linux Installation After starting YaST2 it was indeed possible to see a graphical user interface but the image was very badly distorted and, in fact, unrecognisable. Obviously there are problems here with the activation. The way out was to connect an external monitor, switch once to external display and then remove the monitor after returning to internal. The image is then, as usual for TFT screens, pin sharp. The rest of the installation including XFree86 was uneventful. But care is recommended after this step – although the integrated sound card is correctly recognised as ESS-1978 Maestro 2E (unlike the Compaq Armada which has the same chip), YaST2 will then crash along with the kernel if you use automatic installation. So you shouldn't even try this but load the maestro module manually later on.

Modem and Infrared With this notebook we found another Lucent WinModem although, as with the Acer TravelMate, this was activated without any problems. The same applies to the infrared port – after a few minutes we were able to surf the Internet using the test mobile phone connection. The Lifebook E-6560 was the only device in the test with an LCD status display. It provides the most important informations on the laptop such as battery level, hard disk and CardBus activity. However, this is hidden when the display is closed so there's is no way of telling whether the device has gone into sleep mode or is switched off. The CardBus hardware is a Ricoh RL 5c476 controller which is the same as in the Sony Vaio and Wortmann Terra Aura devices. As it takes a good 20 seconds for initialisation of the Type-III PCMCIA hard disk, this is also one of the more leisurely types of Cardbus chipset on test here.

COVER FEATURE

device can theoretically be propped on the lap without causing heatstroke. But this is not really a ideal solution because the underside, at up to 45 degrees, is almost as hot as the airflow. Even higher temperatures reign in the CardBus slots protected by the spring shutters, and at almost 50 degrees they are heated up a great deal by the ventilation slot located in their immediate vicinity. Here too we can well envisage PCMCIA cards ceasing to work on particularly hot Summer days. As with the Compaq Armada the Lifebook E6560 has problems with the sleep mode under X which always ends in a total crash. For this reason, you should first deselect in BIOS the option Lid Closure Suspend, which can be found in the Power menu under Advanced Features . But from the text console itself the Lifebook woke up again with no problem with keyboard, mouse and X remaining intact and working.

[left] The hard drive sits in a swap frame, which – also fitted with a notebook lock – secures the whole housing. [right] Nothing for Linux – the keys on the front can only be used under Windows.

Conclusion The Lifebook E-6560 offers much when used under Linux. It can be bought in two versions – either with the Lucent WinModem tested here or with an Ethernet port which, according to a statement from Fujitsu-Siemens, runs under Linux without any problems. Sadly, this notebook, too, does not come with Linux preinstalled. The hardware is completely supported and apart from the sleep problem we didn't encounter any crashes. It was not possible for reasons of time to take up the opportunity of testing the even smaller and lighter Lifebook B200 but we will be making up for that as soon as possible. ■

Fujitsu-Siemens Lifebook E-6560 (+)

Hardware is completely supported

Hot problem

(+)

Hard disk in swap frame

(+)

Clear LCD status display

The cooling deserves limited praise. As in the Toshiba notebooks there is a side air vent so the

(-)

Sleep mode under X led to a crash

(-)

CardBus slots too hot

5 · 2001 LINUX MAGAZINE 41


COVER FEATURE

NOTEBOOK GROUP TEST

TOSHIBA TECRA 8100 AND SATELLITE PRO 4300

Toshiba is known for its robust and well manufactured notebooks. For this test we borrowed a machine from the top-of-the-range Tecra series and one from the company's Satellite Pro range. 42 LINUX MAGAZINE 5 · 2001

We'll start with the little brother of the big bold Tecra – the Satellite Pro 4300. This comes into the high-end notebook category and is designed to replace a desktop PC. Accordingly, the disk drive and 8x DVD-ROM are permanently installed.


NOTEBOOK GROUP TEST

COVER FEATURE

The plastic case is conventional in design but we would have liked an Ethernet connector as well as a line output from the sound card. However, Toshiba has added a reset button which is recessed into the case and has to be pressed using a pointed object such as a pen. The grille protection on the side air vent seemed a little delicate – it's merely a plastic cross just under a millimetre thick. Even a forgotten biro could easily penetrate it during transport in a carrying bag. You won't need external speakers because two excellent and large loudspeakers have been installed in the Satellite Pro directly above the keyboard. These can make a fair old din if you want them to.

Toshiba Tecra 8100 The design of the Toshiba Tecra 8100 is, apart from the keyboard and mouse which are identical to the Satellite Pro, completely different. As an ultraportable device it is noticeably flatter but on the other hand it only has one drive slot. The DVD-ROM located there is identical to that of the Satellite Pro and in addition the notebook also comes with an external housing for the disk drive which is attached to a special port beneath the CardBus slots. Unlike its little brother, the loudspeakers are located on the left and right on the notebook at the front.

Whistle while you work The speakers are just as loud but this causes its own problems – unlike the Satellite Pro, Toshiba has installed a microphone in the Tecra and this is also at front right, about one millimetre above the right loudspeaker. If the Tecra is allowed to run without any intervention, there is no feedback. But if an arm or hand covers the microphone slightly, there is a piercing whistle in the 8-kHz range. This may sound petty but the Tecra costs around half the price of a small car so we expect more care in the design with respect to the microphone. Evidence this can be done better is proved by the HP Omnibook XE3 where the microphone sits centrally over the keyboard, with the loudspeakers in the front of the device. We therefore recommend simply sticking a headphone jack into the socket of the external microphone until the microphone channel has been turned down with a mixer program such as aumix or kmix.

Best Keyboard Toshiba deserves praise for the unusual keyboard on both devices reviewed here – while the space bar is comparatively small, the cursor keys and [Ctrl], [Alt] and [Fn] are very large and easier to hit. Toshiba has moved the 'Windows' keys to the top right corner. This is where they should be because they're therefore out of the way. In all, we liked the Toshiba keyboards best, including the typing feel. The

application of the slanted [B] key on the Compaq Armada would have been the icing on the cake here and perhaps the Toshiba engineers might take a closer look at this trick. The only real problem was that we constantly and inexplicably kept hitting the [Caps] key whilst typing – perhaps a general problem with keys not being quite where we expect them to be. However, a manual hack to solve this is easy. One can enter the following two lines into the keyboard table which is usually us.map.gz:

Like in a rocket silo – the on-/off switch of the Tecra 8100 is secured with a sliding flap which prevents accidental use.

keycode 58 = Shift control keycode 58 = Caps_Lock This turns the [Caps] key into a normal [Shift] key, but by pressing [Ctrl]+ [Caps] the caps-lock function is activated. Due to lack of time we were unable to discover how to adjust the Ctrl-Caps function under X but the following commands turn the [Caps] at least into another [Shift] key: xmodmap -e "remove Lock = Caps_Lock" xmodmap -e "add Shift = Caps_Lock"

Linux times two Apart from the variation in the processor clock frequency and the bigger hard disk in the Tecra, both devices have almost identical hardware, which is why we are describing them together. The first thing to strike us was the unusually fast BIOS POST procedure. Scarcely had the Toshiba logo been displayed than LILO was up and running and then booted the installation system from DVD. Installation itself at first went uneventfully. Toshiba had even left space for our Linux system – Windows 2000 or Windows 98 respectively were accommodated in the first 5 GB. However, when in the final installation steps we wanted to select the X-server, YaST2 only offered us the XF86_VGA16 with 640x480 pixels. The reason is that the Toshiba devices, like HP and Wortmann, use an S3 Savage MX (86C270-294) chipset and this cannot be activated with the XF86_SVGA server. You should therefore first completely skip the automated X-installation.

Toshiba Tecra 8100 (+)

very good processing

(+)

hardware almost fully supported

(-)

microphone-loudspeaker feedback

(-)

Irda-Port could not be installed

(-)

dearest device in the test

Toshiba Satellite Pro 4300 (+)

very good processing

(+)

hardware almost fully supported

(-)

no Ethernet connection

(-)

Irda-Port could not be installed

5 · 2001 LINUX MAGAZINE 43


COVER FEATURE

NOTEBOOK GROUP TEST

Problematic Irda Getting the infrared port up and running was a real headache. According to findchip the irda-utils in the Tecra 8100 is an SMC chip, while it was unable to determine that of the Satellite Pro. We anticipated Toshiba's own-make FIR chips being installed in both. Whatever the case may be, neither the smc-ircc- nor the toshoboe module could be made to run. Since it was also impossible to activate an emulation as serial interface we gave up after two days and rated the IR port in the style of the Linux laptops sites as "unsupported".

TV output

Not quite so obvious is the little catch under the switch on the Satellite Pro 4300.

Further along the installation line and the lack of an Ethernet card left just the configuration of the Yamaha YMF-744B, which went off smoothly. Like most of the other devices in the test the Toshibas also have a Lucent WinModem, which as described above can be activated manually without demur.

X11 Installation Despite documentation which says otherwise, in XFree86 4.0 the S3 Savage MX chipset is not supported by the XF86_SVGA server. What's needed is the X-server adapted specially for S3 cards by Tim Roberts, which can be obtained from http://www.probo.com/timr/savagemx.html. This is simply installed under /usr/X11R6/bin. But SaX could not cope with the patched server so we used the XF86Setup which is tried and tested for notebooks. Since this is no longer included in SuSE 7.0, simply grab the package xfsetup.rpm from the series x1 of SuSE 6.4 via your favourite FTP server. You can ignore any warnings at the start about incomplete documentation. In the selection of graphics cards you simply change to the more detailed set-up and enter the SVGA server direct. For the monitor it is best to choose High-Frequency SVGA and 1024x768 @ 70 Hz. But you can also simply set the corresponding link manually under /var/X11R6/bin/X and use XF86Config from our FTP server. A notebook is not necessarily the right platform for 3D games but for the two Toshibas a hardware accelerated 3D-server is offered from Xi Graphics. At ftp://ftp.xig.com/pub/3Ddemos you can obtain the X-server demos with a ten-minute time limit for both models. Using this the Q3demo runs and delivers 22 or 19.7 fps respectively. The full version costs 129 dollars but with the notebooks device costing just around £2,500 or over £3,750 respectively, this should not be an issue! 44 LINUX MAGAZINE 5 · 2001

There were no problems with the composite TV output of both devices – 640x480 and 800x600 were displayed without demur although at 1024x768 only the top left corner is displayed. The signal format can be changed in the BIOS, something which is activated by pressing the [Esc] key when switching on. Unfortunately we were unable to achieve simultaneous operation of TV and display and all in all, the TV picture was not great – the first character of every line disappeared on the text console and the whole picture is too far towards the top right of the screen. Another problem occurred when switching from the graphical interface to text mode which involved changing to the internal display and then to the TV set, in order to get a stationary image again.

Conclusion We very much liked the keyboards of both devices. One very good point is that there are accelerated Xservers for both notebooks and all in all the graphics chipsets may set any new benchmark records but they are adequate for short gaming experiences. The processing power in both devices is excellent and the hardware – apart from the Irda ports anyway – we found to be fully supported. The big drawback is the price. Both notebooks are far more expensive than their counterparts and, we reckon, verge on unaffordable unless you have very deep pockets indeed. No only that but we have complaints that we shouldn't have with machines of this calibre, such as the quality of both displays – the lower corners of the image show a markedly poorer brightness than the rest of the display. It is also interesting that Toshiba has installed its own SD-RAMS in the Tecra 8100 but the hard disk is bought in from competitor IBM despite Toshiba itself being one of the biggest hard disk manufacturers in the notebook sector. Considering the two notebooks are similarly specified, the Satellite Pro 4300 would be our choice but the Tecra is simply too expensive to warrant consideration. ■


NOTEBOOK GROUP TEST

COVER FEATURE

SONY VAIO PCG-Z600 TEK

The Vaio series from Sony is well-known for its compact construction coupled with high performance. Even if Sony has no ambitions at present to supply devices with Linux pre-installed, they kindly sent us the brand-new Vaio PCG-Z600 TEK. The differences between the new TEK model range and the somewhat elderly NE- and RE-devices are marginal. The vast number of postings published on Ken Harker's Linux laptop sites thus also apply to a great extent to the TEK range. In fact, Sony has only dispensed with the infrared port and also the NeoMagic graphics chips have been replaced by an ATI Rage Mobility.

Problem-free X-configuration No special steps are necessary for X11 installation and the standard SVGA server functions perfectly.

Once we had booted either from the USB diskette drive or PCMCIA CD-ROM, the SuSE installation and the subsequent X-configuration progressed uneventfully. The Ethernet card was correctly recognised as eepro100 and installed easily. SuSE 7.0 also had a driver ready and waiting for the Yamaha DS-XG WDM Audio Codec although there were a few problems here. Why aplay hangs when testing the card and always plays the same chord was not clear and after the fourth test we saved our ears with a dummy-plug in the headphone socket. Other wave players also refused to comply and sometimes came up with nothing but noise. The modem was recognised as a Conexant SoftK56 although was a hopless case, just as with IBM, HP and Wortmann before it. Unusual but very clever was the fold-out modem socket placed on 5 路 2001 LINUX MAGAZINE 45


COVER FEATURE

NOTEBOOK GROUP TEST

The Vaio has a Firewire connector, two USB ports and a slot for Memory Sticks. The traditional ports for monitor, printer and serial devices, together with an additional USB- and firewire port, are located on the port replicator which Sony also delivers. There is no PS/2 connection for keyboard and mouse nor for Irda. For USB operation we had to change the setting in the BIOS under Advanced for Plug & Play OS to No , after which the usb-uhci module loaded with no problems.

Firewire stays cold

The price of compactness – there is only one CardBus slot available which is already taken up with connecting the CD-ROM.

the back right-hand corner where the modem lead is inserted at an angle of 45 degrees.

Attractive Design The design of the Sony Vaio is definitely appreciable even if violet is not necessarily everyone's favourite colour. Rare for notebooks but standard for Sony is the 12-inch display with 1024 x 768 pixels. Anyone with good eyesight (or at least a good optician) will not want to settle for anything less than the sharpness and clarity of this display. The keyboard is also good and though the flatas-a-pancake notebook is only 3.1 cm high, the key lift is adequate. However, you perhaps wouldn't want to hack around on it for hours at a time. The only real point of criticism is that there is no offset cursor block and the functions Home, End, PgUp and PgDn can only be accessed via the [Fn] function key, so both hands are needed for scrolling. The touchpad with two buttons is also violet in colour but is easy to use, even with damp fingers. The mouse acceleration was a bit low although we were able to correct this in the KDE control centre.

Miniature battery The battery was also born under the sign of compactness and at 1400 mAh is very small. It acts as the upper keyboard closure which means that without the battery, the Vaio's case has a large hole. Next to the battery are the somewhat small loudspeakers which, nevertheless, still sound acceptable. With respect to sound, we found that whilst there's a line output on the external CDROM, the Vaio itself has none. The one available CardBus slot, controlled by a Ricoh RL5c475 chipset, does somewhat limit expansion options because this is where the CDROM connects. The cards stayed at 34 degrees Centigrade although this was measured indirectly at the ActionTec modem, which ran pleasantly cool. 46 LINUX MAGAZINE 5 · 2001

The firewire ports, referred to by Sony as ilink but known to the rest of the world as ieee1394, could not be tested simply because we didn't have a firewire peripheral. The same applied to the slot for the Memory Sticks. Anyone who is seriously interested in these topics might like to take a look at the Linux laptops sites and the Firewire sites at http://linux 1394.sourceforge.net. However, at present the XCD-3222 hardware used by Sony is shown as not supported. On the other hand there were no problems with power management – at the push of a button the Vaio Z600 goes to sleep from the text console just as under X and in both cases it was brought back to life with no problem.

Conclusion The Sony Vaio PCG-Z600 TEK is the not far from being the paragon of notebooks, and, due to its lightness, it's especially suitable for those who travel often and do not wish to carry around a three-kilo lump of plastic and circuit boards. However, the very small battery and the power hungry Pentium III (700 MHz) allow for very brief periods away from mains sockets so the power supply should really be calculated into the travelling weight. Linux support is good with only the sound problems caused a little doubt. It's also a pitty that no modem driver is available because otherwise the Vaio would definitely have come out near the top of our list. But what is truly deplorable is that Sony is not making any preparations to offer devices with Linux installation. However, that doesn't stop others taking the lead – one front-runner in this field is the laptop specialist Walter Heuser, from whom one can obtain, for example, the predecessor model Z600 NE with pre-installed Linux at http://www.xtops.de. ■

Sony Vaio PCG-Z600 TEK (+)

attractive design

(+)

12-inch display with XGA

(+)

lightest device in the test

(-)

problems with sound card

(-)

modem not supported

(-)

tiny battery


NOTEBOOK GROUP TEST

COVER FEATURE

WORTMANN TERRA AURA A74 LD

Fresh from the SuSE certification lab, the Wortmann Terra Aura A74 LD was the only device to arrive with Linux preinstalled. The oddly metallic-looking case is actually made of plastic but nevertheless looks very elegant and has nothing to fear from comparison with other notebooks such as the Lifebook E-6560. As is representative of the high-end category, the diskette drive and 8x DVD-ROM are permanently fixed in place and cannot be removed.

Ethernet socket for modem An inventory of the ports brought a bit of a surprise. In addition to the usual ports, we found an apparent Ethernet port in the form of an RJ45 socket. However, this turned out to be a modem

port. Wortmann was unable to say why there was an RJ45 socket instead of the RJ11 normally provided for modem ports. A version of the notebook with Ethernet capabilities instead of the modem does not exist, which is fairly odd. The keyboard is rectangular and has no offset cursor block. The space bar is pleasantly large and the left Shift key is fairly big. On the other hand though, Wortmann has unusually positioned the key for the pointed brackets on the left next to the cursor keys. The typing feel was very comfortable overall and the keys are mounted so as to move only slightly and have a soft feedback. As with the Lifebook, in the Terra Aura a touchpad with two mouse keys has been installed beneath the key field.

Wortmann Terra Aura A74 LD (+)

certified for Linux

(+)

hardware almost fully supported

(-)

no modem support, no Ethernet

(-)

CardBus slots too hot

5 路 2001 LINUX MAGAZINE 47


COVER FEATURE

Good news: Many notebooks already have two USB ports. The Wortmann Terra Aura unfortunately, needs a special plug for the TV connection.

NOTEBOOK GROUP TEST

Linux Installation

CardBus

Naturally although this is a preinstalled machine, we were keen to look at the course of a typical installation, this notebook being certified by SuSE. At this point it's worth taking a look at the small print of the certificate, as it includes restrictions with respect to the X-server and sound card. As there is an S3 Savage MX in the Wortmann Terra Aura, the patched X-server is needed, as we also used in the Toshiba devices and the HP Omnibook. Accordingly, we left YaST2 without having installed X. Also, the driver for the sound card is still brand-new and we used, as with the HP Omnibook, the Maestro-3 sound driver from Zab Brown, still in the Alpha stage, which can be found at http://www.zabbo.net/maestro3.

The Terra Aura also contains the popular Ricoh RL 5c476 CardBus controller which, like most others, took 20 seconds for the initialisation of our PCMCIA hard disk. Unlike the Lifebook E-6560 the CardBus slots here are a bit further away from the main air vent but the cards still heat up to almost 50 degrees and at higher external temperatures could certainly get damaged.

ESS Modem No driver of any kind could be found for the built-in modem with ESS-1989 chip so we can only hope that Ensoniq will soon remedy this. Maybe Wortmann can check just once more whether it might be possible to supply an Ethernet card instead of the modem. Nevertheless, the infrared port is immaculate and after the obvious adjustments it was installed without any problem.

Conclusion In principle at least the Wortmann Terra Aura is a Linux laptop and in a few months, when the Maestro-3 driver and the patched X-server are included in the distributions, there won't even be any manual work involved in configuration. Only the ESS modem somewhat spoilt the overall impression. We had no problems worth mentioning otherwise – even the TV output could be wired up without complaint (up to 800x600 pixels). At higher resolutions, as with the Toshibas, only the upper left corner is visible. Wortmann deserve huge praise for taking the trouble to get SuSE certification, even if it not yet quite "Ready for SuSE Linux 7.0". This clearly shows that at last one manufacturer is taking Linux users seriously and offering its devices with Linux. The Terra Aura is only just becoming available in the UK and Wortmann, which is a German company, advise you to enquire with your local notebook dealer about availability. ■

Dell Latitude C600 Just before we went to press, the Dell Latitude C600 arrived by express courier. It is equipped with a Pentium-III (750 MHz) and 128 MByte RAM and counts among the so-called 'ultraportable' class. As a special feature, it has two front slots – in the right one you can insert a CD-ROM drive, a DVD-ROM, a second battery or a diskette drive, as you choose. The left-hand slot is reserved for the main battery. A fully-functioning second drive slot would be very interesting, like the one there used to be years ago in the Scenic Mobile series from Siemens. This let people accommodate two drives at once if one were working in an office, for example. It has to be said that due to the very short time available we were unable to test the notebook with the detail used elsewhere, so you will only find here some first impressions from a brief test. The unknown infrared port turned out to not be a problem after all. After a kernel patch was sought and found, the irda-utils could be started without demur and the Nokia 6210 was specified in the list of accessible devices. The ESS 1983S Maestro-3i sound card was correctly detected by YaST2 but SuSE did not supply an appropriate driver. We installed – as with the Wortmann Terra Aura and HP Omnibook – the Maestro-3 module from Zab Brown and were thus able to activate the sound card without any problems. Network card and modem in the Dell Latitude C600 are located on a mini-PCI plug card. The 3com chips installed there were recognised in the SuSE standard installation but because of a limited timeframe we could not look for a suitable driver. Posing more of a problem was the ATI Rage Mobility M3 – unlike the Mobility P/M present elsewhere in the test, this did not respond to the SVGA server and came up with a few oddities, mainly in connection with the framebuffer support. We will have to go into this, too, in more detail, before we can give a well-founded judgement. One big fat plus to finish off is that the Latitude was the only device able to call up the BIOS set-up via function key both in text mode and under YaST2 and then to return without a problem. And the suspend function worked without complaint. We will bring you the whole test report in one of our upcoming issues, together with other latecomers from Gateway, Apple and Fujitsu-Siemens.

48 LINUX MAGAZINE 5 · 2001


NOTEBOOK GROUP TEST

COVER FEATURE

IBM THINKPAD I1200 No connection ...

IBM ThinkPad i1200, Model 1161

IBM gave this ThinkPad a parallel port for the printer and two USB connections which can be operated with Linux. Otherwise they've been fairly skimpy with regard to the ports – there is neither a serial nor an Irda. The situation is aggravated by the fact that the internal modem is unusable because the modem chip turned out to be an Intel 7196 which is unsupported within Linux. The scope of the device for the Internet is therefore highly questionable. But hold on – there are four special keys for Mail, Shopping, Searchand Home. But these are inoperable within Linux. However, if you're lucky enough to have a LAN or ADSL internet connection then you're also out of luck – as a device at the bottom of the range, the i1200 has no Ethernet socket. We actually asked IBM for one model each from the A-, X- and the i-series but Big Blue delivered a ThinkPad i1200 to our labs. According to their own advertisements this is "optimised for Internet". Fair enough!

Installation As the device has no disk drive, there was no need to repartition the hard disk as with the other test devices. SuSE-Linux was booted from CD courtesy of the permanently integrated 24x CD-ROM drive. YaST2 then started, surprisingly, in text mode. Reverting to Windows, we first made an inventory of the drivers installed at which point we learned the graphics chip was a Silicon Motion LynxEM+. The installation of Linux was attempted again with the surprising result that the graphics subsystem could be used with the XF86_SVGA server. At the end of the second Yast2 run, the Crystal WDM Audio Codec also ran. The small 800x600 pixel 12.1 inch TFT display failed to blow our socks off, either under Linux or under Windows. Elsewhere in the test only the Sony has an equally-modest diagonal – on the other hand, though, it does weigh a whole kilo less with a resolution of 1024x768. The Intel Celeron 500 MHz is also the slowest in the our test. As if to confirm this, in the course of the our tests, PovRay rendered the image on the IBM's in a very leisurely fashion.

Ergonomics Unlike the mediocre graphics, there is also some positive news about the human interface devices – the keyboard is stable, has a pleasant lift and perceptible pressure points. Because of the cursor block being offset at top right and the functional mouse replacement, it is possible to work on the ThinkPad almost like on a standard PC.

Conclusion For such a low price one can't expect miracles. But up-to-date components which function under Linux is not asking too much. The IBM also disappointed us with an outmoded processor and a small display. We also suspect that even IBM aren't keen on this notebook. An call to the order hotline to get the price had the sales clerk ask us to confirm three times if the performance of this device was really adequate for him. The fact that in the test there were also system crashes and graphics errors when switching between text console and X was annoying, and was the cherry on the cake of an unsatisfactory overall impression. We would really have preferred a device from the A- or X-series which we suspect would have done better. ■

(-)

no IRDA

(-)

crashes under X

(-)

obsolete hardware

(-)

overall, too high a price

Last thoughts This test was a far more positive affair than we expected. In the case of XFree86, which was our main worry, just the fact that there is an X-server which works counts as a success. However, all the devices ran at maximum resolution and colour depth with most even fully supporting the TV output. Another pleasing discovery was the 3D-accelerated X-servers for the Tecra 8100 and Satellite Pro 4300 from Toshiba. Let's hope development of these will continue. But the greatest surprise is that although most notebooks are equipped with the Lucent WinModem chipset which, after the linux/include/linux/tty.h patch, worked without any problems. Lastly we must plead with all notebook owners who are running Linux – the "Linux on Laptops" project relies on the support of Linux laptop users. A brief listing of the hardware of individual devices, perhaps with an indication of what you personally have got working, will make a welcome contribution and further the cause.

5 · 2001 LINUX MAGAZINE 49


COVER FEATURE

NOTEBOOK GROUP TEST

HEWLETT PACKARD OMNIBOOK XE3

The truly huge HP OmniBook XE3 comes in a striking suitcase design with offset and rounded corners made of a softer plastic material than the rest of the housing. This enables them to work very effectively as corner protectors.

Self-sufficient CD Player The CD player in the HP OmniBook can be operated when the device is switched off, courtesy of the round slider. In the multifunction display you can then view the track number and playing time, along with the date, time and the remaining capacity of the battery expressed as a percentage. 50 LINUX MAGAZINE 5 路 2001

Keyboard and touchpad are generously designed with both the cursor functions and the cursor block protruding from the otherwise flat plane of the keys. The Internet keys arranged around the central sleep button cannot be detected under Linux as they do not supply a scan code. The keyboard has a number of other vices too. The key repetition rate, at some 5 characters per second, is much too low, and the keyboard feel is too soft which makes for a lot of typing errors. The internal microphone lies in the middle above the keyboard while the powerful loudspeakers are recessed on both sides of the CD panel in the front. Acoustic feedback is rarely going to be a problem here.


NOTEBOOK GROUP TEST

COVER FEATURE

Even without Windows by no means superfluous: Behind this display and the operating keys lies a self-sufficient CD player.

The fan is a bit intrusive with its cooling phases lasting only a few seconds and causing a howling noise. On the other hand it does keep the device comfortably cool with a maximum of 43 degrees at the CardBus slots. The CardBus controller is the Texas Instruments PCI 1420 which, as in the 1450 in the Compaq Armada, took 20 seconds to initialise our PCMCIA hard disk. Disk drive and DVD-ROM are built-in. Unfortunately Linux compatibility is not ideal. The ESS 56CMV-PI modem and the Accton EN2242 Ethernet card are on the same expansion card. While we were unable to find any driver for the winmodem right after we had sent back the HP OmniBook a patched Tulip driver was released. As the description on the Linux laptop page says it should support the Accton Ethernet card of the OmniBook XE3. To get the proof HP will sent us the notebook again, we will report in one of the next issues about our experiences, together with the latecomers from Dell, Apple & Co. We also had to pass on the TV output. But on the other hand the infrared port worked because a serial emulation is offered and the port is thus recognised as a normal serial port.

Sound problems The Allegro-1 sound card would only work with the Maestro-3 sound driver from Zab Brown which is still in the Alpha stage (and can be found at http://www.zabbo.net/maestro3). Like the two Toshibas and the Wortmann notebook, the OmniBook also has an S3 Savage MX graphics chip. Unfortunately there is no hardwareaccelerated server for the OmniBook so the packages designed for the Satellite Pro and Tecra by Xi Graphics do not function.

Conclusion Assuming the Ethernet driver is working well the HP OmniBook XE3 is a good choice. Especially the low price makes this notebook interesting to low budged buyers who are normally forced to do with no name products. Compared with the rarely cheaper IBM ThinkPad i1200 the HP is the better choice. But even if it turns out that Ethernet is not working with the new driver, anyone owning this device should not immediately shy away from Linux as the most important functions can still be used. ■

HP OmniBook XE3 (+)

self-sufficient CD player

(+)

"suspend to disk" functions

(+)

low price

(-)

Ethernet and modem not usable

Infos: Linux on Laptops, comprehensive collection of links by Ken Harker with hundreds of referenced laptop sites and many useful hints, tips and tricks: http://www.cs.utexas.edu/users/kharker/linuxlaptop/ From the Linux-Mobile-Guide via individual experience reports and a hardware compatibility list to PDAs or activation of mobile telephones – on the Web pages of Werner Heuser you can find lots of useful information on using Unix on portable devices:http://www.mobilix.org/ The sites of the Linux Irda Project and the URL of the FTP server, on which you will find the IrdaUtilities: http://irda.sourceforge.net/ftp://irda.sourceforge.net/pub/irda/irda-utils/ Linux-WinModems-Support, where the Lucent-LT-WinModem driver as used in the test is available for download: http://www.linmodems.org/http://www.linmodems.org/linx565a.zip Linux PCMCIA Information Page with lists of supported PCMCIA- and CardBus-add-ons: http://pcmcia-cs.sourceforge.net/ linux-laptop@vger.kernel.org is the Linux Laptop Mailing list, forum for all questions about Linux on laptops. To register, just send a message to majordomo@vger.kernel.org with the content subscribe linux-laptop. ■ 5 · 2001 LINUX MAGAZINE 51


COVER FEATURE

NOTEBOOK GROUP TEST

All the notebooks at a glance Manufacturer, Model,

Compaq

Fujitsu-Siemens

Acer TravelMate

Hewlett Packard

Name

Armada M700

Lifebook E-6560

737 TLV

OmniBook XE3

Category:

Ultra-Portable

Ultra-Portable

High-End

High-End

Processor:

P III SpeedStep

P III SpeedStep

P III SpeedStep

P III SpeedStep 700MHz

700 MHz

700 MHz

700 MHz

Memory [MB] (Slots/free)

64 (2/1)

128 (2/1)

128 (2/1)

64 (2/1)

Hard disk [GB]:

11.5

7.6

17.3

9.6

Diskette drive:

external/Insert

internal

internal

plugable/parallel port CD-ROM:

-

24x/Insert

-

-

DVD-ROM:

8x/Insert

-

8x/Insert

8x/internal

Drives open sideways:

yes

yes

yes

yes

Expansion slot for drives/

yes/yes

yes/yes

yes/yes

none

usable for second battery Connections: PS/2 / serial / parallel / Line USB / IRDA / TV Docking-Port/external drives Display:Type/size [inches]

+/+/+/-

+/+/+/+

+/+/+/+

+/+/+/-

+/+/+

+/+/-

+/+/+

+/+/+

+/-

+/+

+/-

+/-

TFT/14.1

TFT/14.1

TFT/15

TFT/14.1 187

Usable angle [degrees]

152

201

141

Even colour/brightness distribution

yes/no

yes/yes

no/yes

yes/yes

yes

no

yes

yes

All Cursor functions without [Fn]

yes

yes

no

yes

Loudspeaker covered when typing

yes

no

no

no

Trackpoint/3

Trackpad/2

Trackpad/4

Trackpad/4

Battery: Type/voltage [V]/capacity [mAh]

LiIo/14.8/3200

LiIo/10.8/3600

LiIo/11.1/5400

LiIo/11.1/5400

Accessories:

yes

no

yes

no

+/+/-

+/-/-

+/-/-

+/-/-

Preinstalled operating system / Media

Win98/none

Win98/Recovery CD

Win98/Recovery-CD

Win98/none

Graphics chip

ATI 3D Rage

ATI 3D Rage

ATI 3D Rage

S3 Savage MX

Mobility P/M

Mobility P/M

Mobility P/M

Keyboard: Offset cursor block

Mouse Type/buttons

Special power cable for PSU Modem-/Ethernet-cable/video-adapter

Memory [MB] Modem chip (useable) Ethernet chipset (useable)

8

8

8

8

Lucent LT

Lucent F1156 IV

Lucent LT

ESS ES56CVM-PI (-)

WinModem (+)

WinModem (+)

WinModem (+)

Intel EtherExpress

none

Pro 100 (+)

IIntel EtherExpress

Accton Tech EN 2242 (-)

Pro 100(+)

Sound chip (useable)

ESS 1978 Maestro 2E (+)

ESS 1978 Maestro 2E (+)

ESS 1969 Solo-1 (+)

ESS 1988 Allegro-1 (+)

PC Card chipset:

TI PCI 1450

Ricoh RL 5c476

O2 Micro 6832

TI PCI 1420

CardBus slots:

2x Type II or 1x Type III

2x Type II or 1x Type III

2x Type II or 1x Type III

2x Type II or 1x Type III

CardBus cover:

dummy card

spring shutter

spring shutter

spring shutter

IRDA chipset (useable)

not recognised (+)

not recognised (+)

NSC PC87338 (+)

SMC FDC37N869 (+)

Composite

none

TV-output connection: Usable / simultaneous to display

yes/yes

max. viewable resolution

1024x768

Power off/sleep/suspend to disk usable

SVHS/SVHS

Composite

not usable

not usable

yes/yes/no

yes/yes/no

yes/yes/no

yes/no/yes

yes/no

yes/no

yes/yes

yes/yes

Width/depth/height [cm] (weight [kg])

31.5/25/3.4 (2.65)

30.8/26.2/3.6 (2.85)

32.5/26.5/5.3 (3.3)

33.2/27/4.3 (3.3)

Noise level [dB(A)]:normal/CD or DVD

41/46

46/52

32/39

47

Usable on text console/under X11

Temperature [°C]: Underside/keyboard

41/39

45/39

46/39

41/35

Temperature [°C]: card slot

30

49

49

43

Temperature [°C]: Main air vent

58

48

50

33

Guarantee/spare parts warranty [months]

36/60

36/60

36/60

12

Market launch:

May-00

Oct-00

Sep-00

Aug-00

Price [approximate UK£]:

2,375

2,250

2,825

1,575

52 LINUX MAGAZINE 5 · 2001


NOTEBOOK GROUP TEST

Toshiba Satellite

Toshiba

IBM ThinkPad

COVER FEATURE

Wortmann

Sony Vaio

Pro 4300

Tecra 8100

i1200 (1161)

Terra-Aura A74 LD

PCG-Z600 TEK

High-End

Ultra-Portable

Starter model

High-End

Ultra-Portable

P IIISpeedStep

P IIISpeedStep

Mobile Celeron

P III SpeedStep

P IIISpeedStep

700 MHz

750 MHz

500 MHz

700 MHz

700 MHz

64 (2/2)

128 (2/1)

64 (1/1)

128 (2/1)

128 (?/?)

11.5

18.6

5.59

19

19

internal

external/Insert

-

internal

external

plugable/special port

plugable/USB

-

-

24x/internal

-

16x/external/PCMCIA

6x/internal

6x/Insert

-

8x/internal

-

no

yes

yes

yes

none

none

yes/yes

none

none

none

+/+/+/-

+/+/+/-

+/-/+/+

+/+/+/+

-/+/+/+

+/+/+

-/+/+

+/-/-

+/+/+

+/-/-/Firewire

+/-

+/+

-/-

+/-

+/-

TFT/14.1

TFT/14.1

TFT/12.1

TFT/14.1

TFT/12.1

179

162

203

177

203

yes/no

yes/no

no/no

yes/yes

yes/yes

no

no

yes

no

no

yes

yes

yes

yes

no

no

no

no

no

no

Trackpoint/4

Trackpoint/4

Trackpoint/3

Trackpad/2

Trackpad/2

LiIo/10.8/4000

LiIo/10.8/4500

NiMH/9.6/4500

LiIo/14.8/3300

LiIo/14.1/1400

no

no

yes

no

no

+/-/-

+/-/+

+/-/-

+/-/+

+/-/-/USB-Adapter

Win98/Recovery-CD

Win2000/RecoveryCD

Win98/Recovery-CD

SuSE Linux 7.0

Win2000/Recovery-CD

S3 Savage MX

S3 Savage MX

Silicon Motion

S3 Savage MX

ATI 3D Rage

LynxEM+

Mobility P/M

8

8

8

8

8

Lucent 56k

Lucent 56k

Intel 7196 (-)

ESS 1989 WinModem (-)

Conexant SoftK56 (-)

WinModem (+)

WinModem(+)

none

none

none

none

Intel EtherExpress Pro 100 (+)

Yamaha YMF-744B (+)

Yamaha YMF-744B (+)

Crystal WDM (AC-97) (+)

ESS 1988 Allegro-1 (+)

Yamaha DS-XG WDM

Toshiba ToPIC95

Toshiba ToPIC95

O2 Micro OZ6812

Ricoh RL 5C476

Ricoh RL 5C476

2x Type II or 1x Type III

2x Type II or 1x Type III

2x Type II or 1x Type III

2x Type II or 1x Type III

1x Type I

spring shutter

spring shutters

spring shutters

spring shutters

dummy card

Toshiba F IR Port Type-DO (-)

SMC FDC37N869 (-)

none

NSC PC87338 (+)

none

Composite

Composite

none

Composite/Special

none

yes/no

yes/no

yes/no

800x600

800x600

800x600

yes/yes/no

yes/yes/no

yes/yes/no

yes/yes/no

yes/yes/no

yes/yes

yes/yes

yes/yes

yes/yes

yes/yes

31.3/26.7/5 (3.05)

32/25.5/4.4 (3.2)

31/24.5/4 (2.65)

31/25.7/4.4 (3)

27.8/22.3/3.1 (1.65)

47/49

34/39

40/40

47/50

46/-

41/31

40/32

38/34

41/34

43/35

35

46

38

49

34

46

55

44

41

46

Dec-60

36/60

12/-

36/60

36/-

Oct-00

Oct-00

2000

Feb-00

Jun-00

2,500

3,925

1,350

2,125

2,200 5 路 2001 LINUX MAGAZINE 53


ON TEST

LINUX ON PPC

Linux distributions on PowerPC systems

POWER TO THE PENGUINS! MICHAEL ENGEL

Owners of PowerPC systems are spoilt for choice. Linux is an interesting alternative to the operating system usually provided, whether it's AIX, BeOS or MacOS. We give an oyverview of the distributions available on the market and test their compatibility with various PowerPC systems. A lot has been going on in the market for Linux distributions for PPC over the past few years. Besides SuSE – the newcomer to the PowerPC domain which, with SuSE Linux 7.0 PowerPC Edition, has now released its second PowerPC Linux version – we have tested LinuxPPC 2000, Yellow Dog Linux Champion Server 1.2 and Debian Potato for PowerPC. Red Hat and Mandrake don't yet offer versions for PowerPC-based systems.

Hardware Support for PowerPC systems isn't totally straightforward for those offering Linux distributions. In the six years that have elapsed since the introduction of the PowerPC 601, many manufacturers have produced PPC-based systems. Most of those are no longer on the market. Apart from the well-known PowerMacs from Apple and 54 LINUX MAGAZINE 5 · 2001

diverse clones from Motorola, PowerComputing and UMAX, RS/6000 systems from IBM, PowerStack-, MTX- and MVME systems from Motorola, Escala- and Estrella-systems from Bull and the BeBox are equipped with PowerPC processors. There are also some PowerPC-based cards for installation in Amiga computers. Support for at least five different bus systems (PCI, ISA, Microchannel, VME, Zorro-Bus), six processors (not including the embedded PowerPC processors), four different connection options for input devices like keyboards and mice (PS/2, ADB, USB, serial) and three different connection systems for mass storage (SCSI, IDE, FireWire) would be necessary in an ideal PowerPC Linux distribution. Let's get one thing out of the way – there's no such thing as a perfect distribution. But you didn't seriously expect one, did you? Even for a passionate collector of computers it's hard to get hold of all the systems supported by the


LINUX ON PPC

various distributions for a test. Yet we did manage to drum up at least one example of each of the available computer platforms and to test the available distributions on them. All the tested models are listed in Table 1. A BeBox and an Amiga equipped with PowerPC were unfortunately not available.

ON TEST

The various distributions came in a wide variety of packages. Yellow Dog came in a smart bag with room for CDs and documentation; SuSE 7.0 PowerPC Edition came in the usual SuSE carton; LinuxPPC 2000 sent CDs and the manual and Debian came direct from the ftp-server onto a blank CD.

by Motorola. The computer is still in use today by Martin "Joey" Schulze as an automatic package build daemon, that is, a machine which automatically constructs Debian packages for all new source files. So the origins of Debian for PowerPC lie in the first Linux version available for PowerMacs – the Developer Release of MkLinux from Apple. The poor Debian maintainers thus had to fight their way through all the ups and downs of PowerPC Linux development (glibc 1.99, compiler problems etc.). Since BootX isn't supported, Debian is not a system for beginners – there isn't even a graphical installation tool available. But anyone used to Debian on the PC will very quickly get used to a PowerPC with Debian.

Debian

LinuxPPC 2000

The CD-ROMs with Debian 2.2 Potato for PowerPC are available commercially; for the sake of simplicity, though, I burned the ISO images direct from the ftp-server onto blank CDs. On the three CD images there are pretty well all the programs found in the x86 version of Debian, none of which resisted compilation onto PowerPC too strongly. Boot support comes in the form of boot diskette images for CHRP-, PReP-, APUS- and Powermac systems. Macs can also be booted via yaboot. For BootX, unfortunately, there is no support to be found on the CDs. According to the PPC port websites Debian has so far been tested on very few systems. However, experience shows that a large number of systems can be made to run with a tolerable amount of time and effort. Otherwise Debian on PowerPC doesn't differ substantially from the x86-version (which of course is the whole idea). The story of the porting of Debian to PowerPC is really interesting. It started at the 1997 Linux Congress in Würzburg (yes, like so many developments in the field of Linux, this one also began in Germany) where a generous benefactor gave the Debian project a Motorola StarMax 4000 The heart of the tested systems: PowerPC CPUs (a Mac-compatible system

LinuxPPC 2000 arrived on two CDs and with a manual of just under 130 pages. The manual was compiled from information taken from various FAQs and HOWTO documents which are mostly found at http://www.linuxppc.org . The manual, which has excellent screenshots, explains the installation mainly for Mac users, but isn't short of instructions for using ftp under MacOS. The Linux beginner is given a brief introduction to basic filesystem construction under Linux as well as the most important shell commands. For any more advanced help, though, go to the mailing lists at http://lists.linuxppc.org and a list of additional URLs. In the annexes to the manual there are instructions on the use of OpenFirmware, disk partitioning with pdisk and fdisk and installation on non-Apple PowerPCs (BeBox, CHRP and PRePsystems). LinuxPPC 2000 can now be booted from the CD on PowerMacs. The system structure is Red Hat-based, but the installer takes the form of a Perl-Tk script (as an option a text-based installer is also available). Installation is done in several simple steps (making the filesystem, rough selection of the packages to be installed, setting the root password and starting the installation procedure), during which the complete installation environment is loaded on a RAM disk (including the framebuffer X-server). On PRePand CHRP-systems a boot diskette must first be

Distributions

Table 1: Tested models Manufacturer Model Apple PowerMac G3 blue/white Apple PowerMac G4 Apple PowerBook G3 "Wallstreet" IBM RS/6000 B50 IBM RS/6000 43P Model 120 Motorola PowerStack Motorola MTX+ Motorola MVME 2700

Equipment G3/300, 192 MB RAM, 6 GB IDE G4/400, 64 MB RAM, 10 GB IDE G3/250, 13.3" TFT, 96 MB RAM 10 GB IDE PPC604e/375, 1 GB RAM, 2x18 GB UW-SCSI PPC604/120, 48 MB RAM, 1 GB SCSI HD PPC604/120, 64 MB RAM, 2 GB SCSI HD PPC604/400 MHz, 64 MB RAM, 4 GB SCSI HD G3/367 MHz, 256 MB RAM, 2 GB SCSI HD 5 · 2001 LINUX MAGAZINE 55


ON TEST

LINUX ON PPC

created for installation via dd or the DOS program rawrite.exe. We were amused by the following sentence in the manual: "If you chose to install KDE instead of GNOME, you'll have the GNOME desktop. This works very much like GNOME, but looks slightly different". Hmmm.

The future of LinuxPPC? Shortly before finishing this article we were informed that a new Beta version of LinuxPPC was available: LinuxPPC 2000 Q3. Along with this announcement LinuxPPC.com published a statement that Q3 would be the last LinuxPPC release and after that they will be concentrating on other areas of business, whatever that might mean. So there's still something to look forward to.

SuSE Linux 7.0 SuSE's PowerPC Edition is the latest representative of PowerPC Linux distributions. Following 6.4, this is SuSE's second PowerPC release

and is supplied along with a manual of the usual SuSE quality having some 530 pages. The manual is – as to be expected – the x86 version adapted for PowerPC. For newcomers, the section on the preparations for installation on various PowerPC-based systems is, in our opinion, a bit brief – a little over half a page in each case for installation on CHRP- and Motorola PRePsystems respectively would surely save a few questions to the hotline (which by the way is available free for 60 days with the PowerPC version). Incidentally, there is no distinction between "Professional" and "Personal" versions in the PowerPC edition. The PowerPC version is similar (apart from unavailable commercial packages, which unfortunately includes StarOffice) to the x86 version. A few additional programs, such as perhaps the virtual MacOS machine mol (Mac On Linux) are also provided. Installation of SuSE is generally accomplished using yast2, which normally runs on a framebufferbased X-server. Users familiar with SuSE on other systems are going to feel right at home. Our PowerBook G3 Wallstreet acted (while equipped with SuSE 7.0 PowerPC Edition Release Candidate 5) as presentation computer and applications server for a web server training course. Booting of the system can be done on Macs either using BootX or yaboot, so beginners aren't encumbered with the cryptic OpenFirmware. The CD is also bootable on PreP-systems like the Motorola MTX, but for CHRPsystems like the RS/6000 B50 a boot diskette needs to be created. The installation of SuSE went smoothly, quickly and simply on all the machines tested. The only problem which arose was that the Matrox Millennium PCI-graphics card integrated in the Motorola MTX+ would only run unaccelerated. Otherwise the automatic hardware recognition functioned impeccably. But there is still one problem with PCMCIA cards. More on that later. SuSE gives the positive impression that they have gone to the trouble of getting all possible drivers (mostly for PCI cards) on PowerPCs to co-operate. So for example diverse PCI-ISDN cards, Ethernet cards and a BT848 framegrabber card all run under SuSE 7.0. Unlike SuSE 6.4 there is even an accelerated X-server. With SuSE one can safely presume that installation on a Mac will be no more difficult than on a PC.

Yellow Dog Linux

IBMs B50s can easily be stacked into a cluster system 56 LINUX MAGAZINE 5 · 2001

With Yellowdog Linux Champion Server Version 1.2 TerraSoft Solutions has released the third version of its Linux distribution for PowerPC systems. The marketing department at


LINUX ON PPC

ON TEST

Yellow Dog Linux is inventively packaged

TerraSoft has dreamt up a real plus for this distribution: YDL comes in a chic black and yellow bag which contains a ring binder holding the 80 page documentation and three CD-ROMs. Yellow Dog has gone to a lot of trouble to give a clear description of the options for booting using OpenFirmware. Despite the manual which has been kept really short (despite a lot of very sparselyprinted pages) there is room for such details. In other words, you'll learn something! Yellow Dog's installer is text-based and familiar from older versions of Red Hat Linux. The whole thing is Red Hat 6.2-based. Given today's penchant for graphical installers this looks a bit antiquated, but it doesn't impair the functionality. Quite the contrary: if you have a serial console there is no need to mess around with sparsely documented parameters to configure it (text-based installation is an option, though, for all the distributions presented here). Both BootX and yaboot can be used for booting on Macs. Apart from the IBM models B50 and F50 (in single-processor configuration) only systems from

Apple are supported. This brings us almost as far as the current Apple hardware development. The new Apple computers G4-Cube and the multiprocessor G4 systems are not in fact officially supported, but according to a statement from TerraSoft they should work (for the SMP-G4 computer there is an experimental kernel).

Problems There were amazingly few problems: we expected a lot worse. On a machine that isn't officially supported like an IBM RS/6000 43P Model 120 the distributions could be installed using tricks and boot

Unlike the B50, the IBM RS/6000 43P Model 120 is a workstation class computer 5 路 2001 LINUX MAGAZINE 57


ON TEST

LINUX ON PPC

diskettes. An X-server, though, could only be made to run using very obscure kernel patches. On "mainstream systems" like modern iMacs, PowerMacs, PowerBooks and IBM's B50 there are no problems, but special cases like Motorola's MTX+ or the BeBox need a bit more care. We were unable to get a current machine from the Bull company in time for the test. Many of Bull's machines, though, are compatible with IBM's RS/6000 systems (for example 43P Model 140 and 150 respectively). That doesn't mean there can't be problems with somewhat more exotic hardware. We had a chance to try out a Lucent Wavelan network card in the Wallstreet Powerbook with SuSE Linux 7.0 installed. In the lower PCMCIA slot the card was recognised by the cardmgr, but then the syslog recorded a terse "card initialisation failed". There wasn't enough time to determine the cause. The behaviour in the upper PCMCIA slot was worse – the Powerbook repeatedly crashed without comment. Unfortunately, unlike x86 users, you'll have to forgo ReiserFS support and the use of StarOffice. Whether ReiserFS will ever run on non-x86

[left] Motorola’s VME PowerPC board is a good basis for process control andtelco system [right] The Motorola MTX mainboard series is mostly intended for industrial applications. 58 LINUX MAGAZINE 5 · 2001

systems is written in the stars. As alternatives, hopefully in the not too distant future, there will be IBM's JFS and SGI's XFS – at least JFS is tested explicitly with respect to PowerPC compatibility. Work is already proceeding apace on porting OpenOffice to LinuxPPC. Support for older machines such as NuBusbased Macs or Microchannel-based RS/6000s is and remains a problem. Much of the documentation is now no longer available. A few of these machines are based, not on PowerPC processors but on the old POWER chipset from IBM. And yet, as one more or less expects with Linux, support for some of these "old dears" is being worked on by experienced Linux hackers. The fact that this is very time-consuming is something that will be understood by anyone who has ever tried to get Linux to run on an undocumented machine. Something we were unable to test due to the lack of peripherals is support for FireWire devices. Rudimentary driver support for the TI chipset used in all new PowerMacs does however exist in current 2.4.0-test kernel versions, so there should be no obstacle to providing complete support in the next PowerPC Linux versions. It was encouraging that many non-Apple USB devices worked anyway, such as a Logitech 3-button USB mouse with scroll wheel or a KeySpan USB PDA-Adapter.

Conclusion Linux distributions for PowerPC-systems now have something for everyone. For the beginner who is entering unknown territory with Linux we can unreservedly recommend SuSE Linux 7.0 PowerPC Edition. The little bugs from version 6.4 have been exterminated and the system gives a very good and reliable impression. Due to the fact that SuSE has put a great deal of work into driver and platform support, it is usable for migrants from the x86domain with old hardware. Also, SuSE comes with a huge range of packages, so users will be saved the trouble of compiling the software. Nice work, SuSE! For migrants from Red Hat-based systems, both LinuxPPC and Yellow Dog Linux should be considered. Both are derived from Red Hat and it's easy to get to grips with them. The graphical


LINUX ON PPC

ON TEST

Apple G4 desktop computer: power inside, art design outside

The desktop version of the Apple G3 series – shown here in classic blue

installer makes LinuxPPC easier to install for not quite so experienced users. Otherwise there isn't much difference between these two distributions. Finally, Debian on PowerPC is just what the professional user has been waiting for. Anyone wanting to use robust PowerPC hardware who at the same time cannot do without the Debian environment will like this distribution. A bit of up-to-date information on the hardware supported wouldn't go amiss on the websites. However, it's understandable that the maintainers of a free distribution would prefer tinkering with the software to updating websites. A Motorola MVME2700 VME bus system provided for testing was left out of this test due to lack of time. A few distributions also support some other PowerPC systems – for example certain CompactPCI boards – and there is also support from Motorola for the more common systems based on PowerPC (and x86). This interesting field will also be the subject of a further article.

everything from the Darwin source code from Apple. Despite this, the PowerPC Linux developers nevertheless managed, four hours before the announcement of the Public Beta of MacOS X by Steve Jobs at the MacWorld Expo in Paris (the first operating system version from Apple to support several processors apart from AIX on Apple workgroup server) to present a functioning Linux kernel for the new multiprocessor G4 system. Last but not least, it would be nice to have a truly affordable, modular PowerPC system, which in the manner of PCs made for ordinary users can easily be put together and expanded with standard components. It should have a 700 MHz or faster G4+ processor and the whole thing should sell at normal PC prices. This should all have long since been possible, but all earlier announcements failed to materialise, including unfortunately the POP reference design from IBM.

Wishes It would be nice if all the improvements (which are at present found somewhere in some kernel versions) find their way into kernel 2.4 for PowerPC. Support for Macs is naturally the best (because of the number of installed systems) but the owners of PReP-, CHRP- and other PowerPC systems should be treated to something more than just a few little lines on their special hardware configuration. It would also be nice if system manufacturers released the specifications to Linux developers as far as possible before the system is launched onto the market. That way, developers don't have to read out Table 3: Information on porting System MicroChannel RS/6000-systems Motorola MVME-systems Amiga PPC Motorola MBX

Too beautifull to be a mere reference system: Apple’s Powerbook G3

URL http://www.vmelinux.org http://www.debian.org/ports/powerpc/inst/apus http://www.debian.org/ports/powerpc/inst/mbx 5 · 2001 LINUX MAGAZINE 59


ON TEST

LINUX ON PPC

Unsupported systems

Thank you ...

Owners of systems that aren't officially supported should not give up hope. For a few systems there are unofficial patches. For others, ports are being worked on. The installation of Linux on these systems, though, requires a bit of work and know-how. Information on various unofficial patches and ports can be found in Table 3.

Anyone who might now be thinking, the test that this splendid horde of PowerPC systems would make a very nice Beowulf cluster must be informed that this is sadly not the case. A few of the computers unfortunately had to go back to their owners. For this reason, our special thanks to Apple Computer, AID Computers and IBM, which provided the test systems. ■

URLs

The author Michael Engel has been working for several years now with RISC processors and Linux. His most recent interests encompass embedded Linux and especially use for Linux in mobile devices.

[1] Linux CD-Images (among others, from Debian PPC): ftp.debian.org [2] Debian for PowerPC: http://www.debian.org/ports/powerpc/ [3] LinuxPPC: http://www.linuxppc.com [4] SuSE PowerPC Edition: http://www.suse.de/uk/produkte/susesoft/ppc/index.html [5] Yellow Dog Linux: http://www.yellowdoglinux.com [6] LinuxPPC Q3 Beta: ftp://ftp.linuxppc.com/linuxppc-halloween/install/updates/upgrade [7] Yellow Dog SMP-Kernel: FTP-Server for Yellow Dog SMP-Kernel ■

Table 2: Overview of PowerPC distributions Distribution

SuSE Linux 7.0 PowerPC Edition

Yellow Dog Linux Champion Server 1.1

LinuxPPC 2000

URLs

http://www.suse.de/uk

http://www.yellowdoglinux.com

http://www.linuxppc.com

Package includes:

5 CDs Manual (approx. 530 pp.)

3 CDs manual (approx. 130 S.) YellowDog bag 2 CDs

Reference source

SuSE GmbH

Tux plug Geeko sticker

Debian Potato for PowerPC http://www.debian.org rmanual (approx. 100 pp.) T-shirt 3 CDs

J. F. Lehmanns

J. F. Lehmanns

ftp.debian.org and mirrors, CD-Set von J. F. Lehmanns

Support

60 days installation support (telephone) (for extra charge and via website)

Installation

X-based (Yast 2)

text-based

30 days installation support (e-mail) X-based

text-based

Kernel

2.2.16

2.2.15

2.2.14

2.2.15 + 2.2.17

glibc-Version

2.1.3

2.1.3

2.1.3

2.1.3

graphical interfaces

KDE (2.0 available as update), GNOME KDE, GNOME

KDE, GNOME

GNOME

Hardware-Support

first value: Manufacturer's specification / (optional) second value: tested * = functions, + = functions, but not supported, - = not tested /

PowerMac 6100/7100/8100

-

-

-

-

PM 4400, 72xx, 7300, 7500,

*

*

*

*

*

*

*

-

(KDE as update) does not funct

7600, 8500, 8600, 9500, 9600 PM 5400, 5500, 6360, 6400, 6500 PM G3

*

*

*

-

PM G3 b&w, G3, iMac, iBook

*/*

*/*

*/*

-/*

PowerBook 2400, 3400

*

*

*

-

PowerBook G3

*/*

*/*

*/*

-/*

20th Anniversary Mac

*

*

*

-

PowerMac G4 Cube

-

-

-

-

PowerMac G4 SMP

-

-

-

-

Performa 52xx, 53xx,

-

-

-

-

62xx, 63xx (except 6360) IBM RS/6000 B50

*/*

*/*

-/*

-/*

IBM RS/6000 43P 120

-

-

- / * (no X)

-

IBM RS/6000 43P 133,150

*

*

-

-

IBM MicroChannel

-

-

-

-

Motorola PowerStack (II)

-/*

-

*

-

Motorola MTX, MTX+

*/*

-/-

-/-

-/*

Motorola MVME

-/

-

-

-

BeBox

-

-

*

-

Amiga PPC

-

-

-

*

60 LINUX MAGAZINE 5 · 2001


DEVICES

ON TEST

USB-Storage devices under Linux

BITS ARE BLUE It can be easier to get some USB devices to work under Linux than others. In this feature we’ll look at seven

USB-based mass-storage devices and see how well, or how badly, they like speaking Penguin.

BY CHRISTIAN REISER

USB mass storage devices are particularly useful because they can easily be connected and disconnected from a computer. This makes physical installation very easy, and allows you to transfer data from one PC to the next very quickly, without resorting to network connections. Of course, all this is also possible using parallel port storage devices, but this isn’t the most flexible way of doing things under Linux. In any case, even modern EPP and ECP parallel ports can’t match the data transfer rates that are possible over a USB interface. USB devices and Linux have not always seen eye to eye, though, and in fact Linux’s USB support is still very much experimental. This is something that was reflected in the fact that during our tests we experienced quite a few crashes, many of which required a complete system restart to recover from. Thanks to our decision to use ReiserFS on the system this was always a quick process, mind you. Another wise decision on our part was to do most of our USB CD burner testing using CD-RW disks, as otherwise the entire editorial team would probably have new silver coasters on their desks. Having said all that, it is possible to get some USB mass storage devices to work well and even reasonably reliably under Linux. We would recommend the latest developer kernel with the current pre-patches for best results, though, and be warned that mission-critical use of USB devices is something to be avoided, at least until kernel 2.4 has matured by a couple of patch levels. At the time of writing, Linux-2.4.0-test10-pre6 was the latest Kernel version available. This kernel also appears to be the most stable yet seen, when it comes to USB devices, but you shouldn’t expect miracles. In version 2.4.0-test9, by the way, very few of the devices we looked at worked at all. Not everybody will want to use 2.4, of course, so we have put together a small table for users of the USB backport patch for kernel 2.2, showing which devices should function with the old kernel, though there are no guarantees.

Freecom Traveller As its name implies, this CD burner is specifically designed for mobile use and can even be operated with batteries if need be. Its snazzy blue housing hides a 4x/4x/20x CD-RW drive with a proprietary DSub interface connection. Adapters for Firewire, PCMCIA, parallel port and USB can be attached to this, the latter being the one used during our testing. Unfortunately the driver for this device is still at an early phase of development, so that it was not found even with the latest developer kernel with ”prompt for development and/or incomplete code/drivers” option selected. In fact, after configuring the kernel, the .config file has to be edited so that after the CONFIG_USB_STORAGE=m line CONFIG_USB_ STORAGE_FREECOM=y has to be added. However, after doing so on our test system, the drive was recognised as ”CDR/RW RW8040A”, and all was well. Or rather all was not well, as the driver turned out, as expected for an early development version, to be highly unstable. For this reason it was not possible to conduct performance tests on this drive, and indeed the only thing we could get the drive to do even slightly reliably was to display the contents of a CD. Unsurprisingly, it wasn’t possible to write CDs

Freecom Traveller: cool, but not stable under Linux

5 · 2001 LINUX MAGAZINE 61


TEST

MASS STORAGE

[left] Stable and reliable with Linux: Iomega’s CD burner [right] Access to ZIP diskettes via USB

Great idea - Iomega’s Click!40 media

with this device, although it is recognised by cdrecord (see http://www.fokus.gmd.de/research/cc/glone/ employees/joerg.schilling/private/cdrecord.html) as SCSI-3/mmc-compatible.

Iomega Zip CD 650 The Iomega Zip CD 650 worked very reliably in our tests. In fact it was the only USB CD burner whose driver never caused our test computer to crash at all. The fact that the burner is also suitable for writing to CD blanks under Linux, appears to be something Iomega is not aware of. In their Linux support forum (http://forums.iomega.com/), when questions were

USB Storage architecture in the Linux kernel All the drives we looked at require the usb-storage.o kernel module, which emulates a SCSI host adapter. This means the attached USB mass storage devices present themselves to the user as SCSI devices. As a result, CD drives can be addressed via /dev/scd[0-9] and hard disks/diskettes as /dev/sd[a-z]. All hard disks and removable drives nearly always have a partition sector. This would not be absolutely necessary for operation under Linux, but it does allow the exchange of data with external operating systems (if the file system in use is recognised, that is). In the case of preformatted media, in most cases the last of four physical partitions is DOS-compatible and so be handled with VFAT \#208 all computers and operating systems ought to be able to cope with this. For usb-storage to be loaded, the SCSI subsystem has to be in the kernel: either permanently compiled in, or as a loadable module scsi_mod.o. For CD-ROM drives the module sr_mod.o is also required. CD burners need sg.o, and hard disks (also including all diskette and removable media drives) rely on sd_mod.o..

62 LINUX MAGAZINE 5 · 2001

asked about burn suitability, the reply was that they were ”working on it”. But by specifying the device type as generic-mmc-raw, the drive functioned perfectly with cdrdao (http://cdrdao.sourceforge.net/). It can even burn quite happily at 4x speed, and, very impressively, we experienced no problems at all using it with the software-intensive UHCI controller, even though some 600 kilobytes per second are transferred at this write speed.

Iomega Zip 250 USB Unlike the external parallel port and SCSI variants of the drive, the USB version of the Iomega Zip 250 is a real beauty; in a similar way to the Freecom drive, it has obviously taken its design cues from Apple’s iMac (and incidentally is also iMac compatible). Unfortunately, because its case is so small, there’s no room left for an internal power supply. The drive is also rather noisy when in use – something we found a little irritating. Under Linux the Zip drive is recognised as a removable hard disk, so preformatted media can easily be integrated into the system using mount /dev/sda4 /mnt/zip. The stability of the drive under Kernel 2.2.17 using the backport patch leaves something to be desired due to system freezes. But under 2.4.0-test10-pre5 the device ran perfectly, happily reading and writing both 250Mbyte and 100Mbyte media.

Iomega Clik! 40 As well as Zip diskettes, Iomega also manufactures other removable media, such as its Clik!40 diskettes


MASS STORAGE

which have a capacity of 40 Mbytes. With dimensions of about 5x5cm the diskettes can fit into a PC card adapter for use with notebook PCs. Users of more conventional systems can still use the media, however, using Iomega’s Clik! Dock PC, which connects via a USB interface. On each of the Clik!40 diskettes there is a partition table, the fourth partition usually having been pre-formatted with a DOS-compatible file system. The drive is therefore addressed in the same way as similar devices such as SCSI hard disks, and so on a normal system a mount /dev/sda4 /mnt/click (or similar) ought to suffice. Unfortunately we found that there was a lot of room for improvement on the stability front when using the drive with Linux. Indeed, after some intensive file copying and deleting it would refuse to respond until the USB sub-system had been unloaded and then reloaded.

LaCie Housed in a dark blue case, LaCie’s transportable drive contains a 20 GByte hard disk – a Seagate Barracuda ST32042A. After some experimentation, however, we discovered that any other hard disk could also be used as long as care was taken to ensure that the new disk requires no more power and produces no more waste heat than the Seagate drive. In other words, you don’t have to throw the entire unit away when you find you need a larger capacity device. The unit’s cooling fan, which is hidden behind some rounded ventilation slots, at first out of order on our review model, leading to the drive getting much hotter than it should. After quickly reaching for the screwdriver the problem became clear, though; one of the power cables had become caught in the fan’s blades. This was easily fixed, and all was then well. Although the transfer rate provided by the unit – almost one megabyte per second – is relatively high for USB, it would take over five hours to read the entire contents of a full drive. This is significantly slower than a conventional hard disk, so this drive is not suitable as a complete replacement for your system disk. It was never designed for such a purpose in the first place, of course, instead being aimed more at transporting multimedia data like

TEST

films, music and images from PC to PC, or indeed just for adding some extra storage capacity to a single system. Compatibility with Linux is, at least with Kernel 2.4.0-test10-pre5, very good. Indeed, during our testing we encountered no serious problems, though the disk was not automatically recognised when connected. By removing and then reconnecting the USB cable, however, this problem could very quickly be solved. Disappointingly, though, this device cannot be used with the backport patch.

Mitsumi USB CR 4804 TU The only product in this test not to boast a blue case, the Mitsumi external CD burner is fully CD-RW compatible and offers 4x CD-R and CD-RW write speeds and 8x CD-ROM read speeds. As a CD-ROM the Mitsumi didn’t do too badly, but when writing to blank media we encountered problems; quite often it simply stopped working. What’s more, the device could often only be persuaded to start working again after a complete system re-start.

[top] Transportable hard drive from LaCia [above] The Mitsumi drive – not particularly stable with Linux.

Adaptec USB-X-Change Adaptec’s USB-X-Change is a very interesting product, but one that will have to go without more than a mention here as it simply refused to work with Linux; for reasons know only to itself, Adaptec decided to develop its own protocol for this product, without giving any thought to Linux drivers.

Conclusion So, although things have improved in leaps and bounds, there are still some issues to be addressed when it comes to using USB mass storage devices under Linux. Still, since this is an area that has been getting a lot of developer attention of late, it won’t be too long before things will improve even more, eventually taking the sting out of the USB tail altogether. Finally note how using OHCI controller architecture consistently produced better results than UHCI in our tests. ■

The devices and their transfer rates at a glance Manufacturer Product UHCI [KByte/s] Adaptec USB-X-Change Freecom Traveller Iomega ZIP CD 650 606 Iomega ZIP 250 400 Iomega Clik! Dock 200 LaCie 20GB Drive 583 Mitsumi USB CR 4804 TU 615 (All performance tests under Kernel 2.4.0-test10-pre5)

OHCI [KByte/s] 926 833 274 866 913

functions with backport-patch No No Yes Yes No No No

media size SCSI-Port CD-RW CD-R 100/250 MB 40 MB 20 GB CD-RW

5 · 2001 LINUX MAGAZINE 63


FEATURE

NETWORK SECURITY

Attacks on firewalls

ONCE UPON A TIME IN THE WILD WEST FRANK BERNARD

To defend against the digital bows and arrows of the Internet, you need a firewall. But when you’ve gone to the trouble of installing one and find nothing happens, you may be tempted to think that all that stuff about hackers we’ve been warning you about is all a load of rubbish, and you’ve wasted a lot of time and effort. You’d be wrong though.

As the new, involuntarily Open Source (following the recent high-profile attack on its systems) Microsoft illustrates (see https://www.linuxcommunity.de/News/story?storyid=531), hackers are a threat that must be taken seriously. But the attack on Microsoft merely exposed the loopholes that were already there, and out of idleness, or to avoid interrupting workflow, were not closed. The fact is that Microsoft, and most other sensible companies, have firewalls installed, but this fact alone is obviously not adequate for Internet security. The combination of several (in themselves harmless) individual security defects creates a security loophole. In the Microsoft case, this involved a 64 LINUX MAGAZINE 5 · 2001

Trojan horse on an employee’s home PC that allowed a hacker access to Microsoft’s internal network by stealing passwords. Several things could have stopped this attack, or at least reduced its impact: • Had the Trojan horse been discovered by an upto-date virus scanner, the passwords necessary for the break-in would not have been stolen in the first place. • Had the firewall prevented a direct access to the computer, the passwords that were passed on would have been of no use. • Had the analysis of existing system logs been better, the damage could have discovered earlier.


NETWORK SECURITY

But what lessons can be drawn from this and what does it have to do with our topic? • Security costs money. Nobody likes to leave large amounts of money in a desk drawer, so they lock it in a safe. Data is the most valuable asset a company can have nowadays. So computers containing this data must be protected. • Security costs money on a permanent basis: Even a safe with lots of money may not be guarded at night, and a safe built in 1870 may be heavy and look solid, but probably isn’t as secure as a more modern one. Security therefore needs to be constant, and must be adapted to thwart new break-in techniques. • Security should overlap itself: double locks rather than single ones, infra red and microwave motion detectors – virus protection plus a firewall. • Security and openness are mutually exclusive: This is the central tenet of an Internet security solution. The more information an attacker gets, the more weak points he can discover and exploit.

Restriction of information – divide and rule Many attacks on a company network are planned in advance. The first thing the enemy needs is knowledge about the structure and possible weaknesses of the network. If this is made very difficult for the attacker to start with, it may be that he will lose interest in breaking in, or try the company next door. For a LAN with Internet connection, true high security means: • An external DNS server should not administer any internal names or addresses. • Information, for example on the operating system (which the attacker finds out on log-in), version status and email system in use (by the SMTP greeting) should be suppressed if possible. An attacker could exploit these pieces of information for targeted attacks on known loopholes. • Not even the DNS name firewall.company.com should be announced externally – even if it is obvious. Select a neutral name, for example mail.company.com if the firewall is also a mail exchanger. • Also, if the firewall is scanned, no information should be revealed which could be useful for an attack. See the ”Portscan” box for more on this.

Mastery lies in (access) restriction Frequently, due to idleness, lack of staff and money, or simple pressure of time, compromises are accepted in Internet security. It can turn out to be almost impossible to implement changes later because of the structures that have been created. A more secure protection of the total network is usually possible only as the result of fundamental restructuring.

FEATURE

Portscan – right or wrong This is how an nmap output ought to look if your system is reasonably secure (LinuxWall V2, Linux-Kernel 2.4.0-test10). Starting nmap V. 2.53 by fyodor@insecure.org ( www.insecure.org/nmap/ ) Interesting ports on ([Internet address deleted]): (The 1520 ports scanned but not shown below are in state: filtered) Port State Service 22/tcp open ssh 25/tcp open smtp 113/tcp open auth TCP Sequence Prediction: Class=random positive increments Difficulty=1580537 (Good luck!) No OS matches for host (If you know what OS is running on it, see http://www.insecure.org/cgi-bin/nmap-submit.cgi). An example of system wide open to attack: Starting nmap V. 2.53 by fyodor@insecure.org ( www.insecure.org/nmap/ ) Interesting ports on [Name deleted] ([Internet-Address deleted]): (The 1511 ports scanned but not shown below are in state: closed) Port State Service 7/tcp open echo 9/tcp open discard 13/tcp open daytime 17/tcp open qotd 19/tcp open chargen 21/tcp filtered ftp 135/tcp open loc-srv 139/tcp open netbios-ssn 158/tcp open pcmail-srv 427/tcp open svrloc 5631/tcp open pcanywheredata 65301/tcp open pcanywhere TCP Sequence Prediction: Class=trivial time dependency Difficulty=16 (Easy) Remote operating system guess: Windows NT4 / Win95 / Win98 Nmap run completed – 1 IP address (1 host up) scanned in 19 seconds

• There should be only one transition point between internal and external network, ISDNcards or modems should be banned. • A firewall should only open the services (ports) to the computers that are absolutely necessary. • If possible, accesses should be permitted only from the LAN into the Internet, as these can be controlled more easily. • Computers that are to be accessible from the Internet (or from an ISDN- or analogue line) should be placed in separate segments (so-called demilitarised zones, DMZs). • The bandwidth for a specified service should be set to a minimum value, which limits the possibility of Distributed-Denial-of-Service attacks. A clear network topology also creates the precondition for a transparent firewall policy. ”Security by obscurity” just does not exist.

What is an Internet attack? The answer to this simple question is extremely difficult. In certain cases this cannot be answered in a general way, and can even vary from system to system. Linux 2.4 with netfilter has received some 5 · 2001 LINUX MAGAZINE 65


FEATURE

NETWORK SECURITY

crucial improvements which both increase security, and, in cases of doubt, at least allow a classification. Almost everyone would agree with me if I were to claim that a ping (ICMP echo request) was harmless from the point of view of technical security. A ping on several IP addresses in succession could, however, be a host-scan (to determine which hosts are in fact accessible from the Internet, but are not registered in the DNS). A ping on a broadcast address (255.255.255.255) is a so-called Smurf attack, which can unleash veritable storms of packets. Many Windows computers are pre-configured so that when online they try to make contact and exchange information with all computers that reply to the target ports 137-139. Windows computers also have 137-139 as source port. But there are implementations that use other, usually unprivileged source ports (for example Samba). So, if a cowboy computer rides up on the Internet and tries to access the SMP ports, the source port of the spy computer is then, too, often in the unprivileged domain. This is obviously not a configuration error, but a spy mission. One question of particular interest involves computers that don’t even ”exist” yet. One of my customers was assigned a Class-C block of network addresses, with only the firewall and the router using any of them in the first few days, yet all addresses were probed during that time Many packets use security loopholes which have been known and dealt with for years, such as so-called XMAS-packets (special TCP-packets, in which all flags are set) or packets with a prohibited destination TCP port (for example Port 0). These are generally used in ”Denial-of-service” (Dos) attacks, as they make the firewall (temporarily) unusable, therefore allowing no traffic at all to get into the network. But much more common are the attacks that collect information. Once this has taken place, the information is then used for targeted attacks.

Spotting an attack – the needle in the haystack Many administrators shy away from implementing a paranoid security policy, especially one that reports every suspect packet, since this will, of course, make their logs a great deal larger (at least at first). However, this is the only option open to you if you want to tell if a presumed attack is real or not, and learn from the experience. Being careful can mean that it can be easier to spot and fix configuration errors (such as incorrect network masks) on PCs. What’s more, administrators will know in far greater detail what’s really going on on their networks. Any change to the LAN infrastructure will be clearly visible. So, after a few days of problem solving, all that should remain are packets that could launch potential attacks. Indeed, a nmap scan, as shown in the two 66 LINUX MAGAZINE 5 · 2001

tables, gives rise to about 1 MB of log. The size of the log file alone ought to sound alarm bells. Naturally netfilter has some advantages over its predecessor ipchains, in that such packets can be reported but only for a certain time. Remember, a hacker will want to be as inconspicuous as possible, which is why it is bad policy to suppress the packets completely.

Cops and robbers – Prosecuting hackers Let’s reverse the tables now, turning the hunter into the hunted. Using his IP address (which we will already have tracked) we can identify the attacker. This is because the hacker’s IP address isn’t normally false, as he’ll want to get a response to his attacks or probes. In theory then, all we need is a quick nslookup and we’ll be able to determine who his ISP is in order to send them e-mail about the antics of their customer. Unfortunately this is only successful in very rare cases. The big providers are certainly able to say when and who was active with which Dial-Up addresses and can therefore identify the customer. This costs money though, so it doesn’t always get done. Computers with fixed (and consequently easily traceable IP addresses) on the other hand, are often not the originators. Instead, they are more often victims (usually of Trojans) themselves. In the end, then, due to the difficulty in tracking an attack, and the large number of attacks that generally occur, it is usually pointless to try to find and prosecute attackers.

Outlook – much better with 2.4! Quite apart from improved packet filtering, Kernel 2.4 offers additional options and countermeasures against SYN flooding and IP spoofing. Through Traffic Shaping (bandwidth restriction), for example, it is possible to guarantee that even if there is a ”Denial-of-service” Dos attack, business will carry on as usual. This is something to look forward to, but even so, you must remember that no matter what security measures you implement, hackers will find a way around eventually. Indeed, no firewall is completely secure, and it is only through a secure configuration and permanent monitoring that attacks can be spotted and potential new (or old) security loopholes can be closed. This is where an analysis of the situation demands very good knowledge of IP protocols. And one of the best ways to get started on the right road is to conduct an attack on your own systems using one of the many tools available. In all, then, yes, Internet security costs money, more money than many IT managers want to spend. But by ignoring the ever present, ever increasing problem of hackers, in the long term your company stands to lose much more money than a good security policy could ever cost. ■


FEATURE

TRIPWIRE

Tripwire - an integrity checker, Part 1

SAFETY FIRST! KLAUS BOSAU

Tripwire has developed into a highly-regarded instrument for administrative investigation. It's hardly surprising. The advanced concepts employed by this security tool provide opportunities that go far beyond those of its various competitors.

You don't have to be paranoid to be concerned about the subject of data security in these times of universal networking and multi-user operating systems. Woeful experiences with love-crazed email viruses and Trojan horses that are all too eager for knowledge leave many a computer user calling for a powerful weapon. Unfortunately, in reality some popular aids aren't really worth very much. Which is why it's worth taking a look at a special kind of tool that, though primarily intended for administrators, can certainly be put to use by ambitious private users of UNIX-compatible operating systems.

Built on sand Despite their popularity, conventional protective shields found in the PC domain, such as virus scanners or signature scanners, suffer from weaknesses. One example is the fact that the properties of new viruses – the so-called virus signatures – have to be determined by the manufacturer and incorporated into the customer's database before the virus scanner can detect the threat. In view of the number of attack points (which even operating systems like Linux offer) and the creativity of resourceful attackers this isn't an easy problem to resolve. 68 LINUX MAGAZINE 5 · 2001

A different approach to the problem would be a tool that quickly detects the damage caused by a security attack. Changes to the file system as a consequence of viral or human activity may be too non-specific to be recognised on the basis of documented virus signatures. In many cases the only change consists of a hidden back door that a successful hacker has left behind in the system for further visits.

Security through inventory Because these dangerous extras are easy to camouflage as regular system files, a search can only be successful given precise knowledge of the original state of the file system. This is something that has been known for years. It has led to the development of tools that take an approach known as integrity checking. One example that runs in the UNIX environment is Tripwire. Tripwire was developed as part of the COAST Project (Computer Operations, Audit and Security Technology) of Purdue University, located in West Lafayette (Indiana). The launch at the start of 1994 (described in the online issue of the business magazine Forbes) was followed by a victory parade through the world of UNIX-type operating systems. This reached a peak of over 300,000 installations


TRIPWIRE

and the winning of the "Editors' Choice Award '99" of the web magazine Linux-World. The claim made by its developers, Gene Kim and Eugene Spafford was not exactly modest. The intention was to provide administrators with a tool that was as simple as possible to manage but nevertheless flexible, and which would make it possible to reliably and rapidly trace any kind of unauthorised or unintentional intrusion into the file system.

Conception The difference in principle between an integrity checker and a signature scanner is evident even from the name. Whilst the latter aims to detect already-known programs, integrity checkers are designed to protect the integrity of data in the filesystem. They are able to detect any change, not just the documented changes that are produced

FEATURE

when a known virus attacks a system. In the simplest case, an integrity checker could make a backup of the entire filesystem and periodically compare it with the current content. However, this isn't really practical. Fortunately, there is a more elegant method. For effective identification of a change, a copy of the original isn't needed. Knowledge of a few special characteristics of the filesystem is perfectly adequate. The task when developing Tripwire consisted of extracting these pieces of data in a way that would facilitate subsequent monitoring. Other design aims included a reduction in volume of the recorded data, and the use of a process that was not too computation-intensive. Kim found these properties combined in signature functions which were until then the domain of message encryption (so-called One-Way Hash Functions or Message-Digest Functions) like MD5

The Arsenal: Comparison of various hash algorithms for Tripwire Algorithm MD5 (R)

Data throughput

Security

(Pentum/200 MHz)

approximate checkpoint

7.2 MB/s

+++++

Comments Message-Digest 5 Algorithm by Ronald Rivest (advanced development of MD4) -- a more powerful and currently the most-used hash algorithm. As with MD4, pseudocollisions (collisions for the Compression Function) are found, but to date its fundamental effectiveness has not yet been refuted.

Snefru (R)

1.4 MB/s

++++

This algorithm, conceived by Ralf Merkle at Xerox PARC, has rapidly become suspect in the four-stage variant used here despite its so-far undisputed effectiveness, since the two-stage version turned out to be unusable very early on. The large 128-bit signature should still, however, guarantee good security performance. (The latest variant to date with 8 rounds is deemed secure.)

CRC-32/CRC-16

9.3/16.2 MB/s

++/+

Both of these robust and fast algorithms were actually designed to detect transmission errors due to hardware. The size of the signature alone, with just 16 and 32 bit, prohibits any use with large or important files. But since a spurious file, apart from the appropriate signature, also has to bring with it the intended functionality to be of any use, it's certainly worth risking its use for less critical objects.

MD4

14.4 MB/s

+++

Introduced in 1990 and very fast on RISC processors. It wasn't until 1998 that disenchantment set in: an easily modified version proved to be reversible. MD4 is now seen as disproved and should therefore no longer be used to protect important objects.

MD2

300 KB/s

++++

Unusually slow, since it was the only one designed for antiquated 8-bit processors. Although MD2 is the oldest of the three message-digest algorithms from RSA, until now its effectiveness has been unquestioned. However, for a modified version the principal risk was revealed to be a constructive (and thus time-saving) determination of cases of collisions.

SHA

5.4 MB/s

+++++

The "Secure-Hash-Algorithm" from NIST [11] is, like most hash algorithms, structurally related to MD4. It was superseded in 1994 by SHA-1, which was supposed to correct an undocumented weak point. The large 160-bit signature nevertheless still makes this a good choice, even for security-critical objects. (The persistent rumours about a deliberately-implanted weak point, in view of the paltry state of knowledge in the theory of hash functions, are somewhat impudent. NASA, by the way, prefers this in its in-house Tripwire installation to the originally more popular Snefru. [12])

Haval

10.7 MB/s

++++

Was created in 1992 at the University of Wollongong by Yuliang Zheng [13] . It is the only one to hold both a variable signature size (128, 160, 192, 224 or 256 bit), as well as a variable number of work steps (3, 4 or 5). (The message is split into blocks of 1024 bits which are then processed in 3, 4 or 5 rounds by the Compression Function.) This means a total of 15 different variants of the algorithm are available for practical applications. In the Academic Source Release the 4-stage variant with 128-bit signature format is used.

RIPEMD-160 (Tripwire-De-Luxe)

4.9 MB/s

++++++

The "RACE Integrity Primitives Evaluation" algorithm [14] from the EU project of the same name is the offspring of a collaboration by well-known European cryptographers (Hans Dobbertin, Antoon Bosselaers and Bart Preneel) from 1996. The unconventional idea of two pipelines working in parallel after the MD4 model was first realised in RIPEMD (3 rounds, 128 bit). RIPEMD-160 represents a massive advance, which is also intended to take into account the most extreme demands made on collision freedom. In a total of five rounds each with 16 individual operations, a hash value of 160 bits is calculated. Together with SHA-1, RIPEMD-160 is currently viewed as the most powerful hash algorithm in existence.

5 路 2001 LINUX MAGAZINE 69


FEATURE

TRIPWIRE

Figure 1: Block diagram of the basic functionality

from RSA Data Security, Inc. or Snefru from Xerox PARC. The departure from the intended use of such algorithms for effective protection of a filesystem is a central component of Tripwire.

Some advantages An attractive quality of the integrity checker is the ability of the user to exert control over the process. It is easy to adjust the security performance according to your preference or need. There is no need to go to great lengths to maintain as complete as possible a library of virus signatures, as is necessary with a signature scanner. An integrity checker demands little attention. Once installed, maintenance is limited to a few actions that need only be performed when software is added or removed. The performance of current signature algorithms turns the integrity checker into the ideal instrument for perpetuation of evidence. This is something that could open up entire new perspectives in the near future, especially in the corporate environment where the economic damage caused by a hacker attack could be considerable. A One-Way Hash Function has all the qualities of a piece of evidence that could be used in court. (Note: usually the Message-Digest of a message encoded using a private code is known as the "signature" . The term "signature" here has the same meaning.)

Step by step The procedure for use can be broken into three parts: initialisation, integrity test and maintenance. For initialisation, a reference database tw.db_hostname is created in accordance with parameters in the configuration file tw. config. This database contains an exact description of all security-relevant objects in the local filesystem. Each object, together with attributes such as the modification timestamp, is assigned its own "fingerprint" in the form of a freely definable 70 LINUX MAGAZINE 5 路 2001

signature cocktail. The choice of information to be recorded for each object is made in tw.config. This is done by means of assigning so-called selectmasks, which allows the extent of monitoring to be tailored to the respective importance and task of each object and the individual security requirements of the administrator. It is of crucial importance at this stage that no viruses or other rogue software components are present in the filesystem. This is tricky, but not impossible to ensure, even for ageing systems. A preliminary manual check of critical files such as passwd or inetd.conf can assure their future integrity and erect a first barrier against incursion, which can be successively reinforced. The evaluation of the current security situation is ultimately the reserve of the administrator.

Integrity test In accordance with the configuration laid down in tw.config a second databank is calculated. This, like a snapshot, describes the current status of the filesystems which can be referred to at any desired date. By comparing this with the reference database, information about added or deleted objects will come to light. Listing 1: output example of an altered file changed: -rw-r--r-- root 788 Aug 1 16:49:52 2000 /etc/hosts ### Attr Observed (what it is) Expected (what it should be) ### =========== ============================= ============================= /etc/hosts st_mtime: Tue Aug 1 16:49:52 2000 Tue Aug 1 16:31:21 2000 st_ctime: Tue Aug 1 16:49:52 2000 Tue Aug 1 16:31:21 2000 md5 (sig1): 1gLd3EYIaQg04IweV.AMJS 3zbqWhNQTo.9Wytoqhgxik snefru (sig2): 0BfGPDfQVve2bm7VbHYD4S 0JCn1vTUQ8apn漏eQ:Gc5x


TRIPWIRE

Steps for use of Tripwire Initialization (single user mode!)

Integrity test

Maintenance (single user mode!)

Interactive updating

FEATURE

tripwire --initialize Creates the reference database. This is placed in the sub-directory./databases and must be moved by hand to DATADIR because Tripwire expects a read-only medium here. tripwire Prints a report of all inconsistencies detected on the screen. If the output is large, or in case of use as a cron job it is advisable to divert the output to a file. The display of information can be regulated using -quiet (single-line outputs) and --verbose (isochronous output). All signatures are usually output in Base64 notation. --print-hex forces the output as a hexadecimal number, which becomes necessary if signature comparisons between incompatible systems are required. tripwire --update [path] Updates the reference database if the content of a specified directory has been changed as the result of administrative operations such as installation, uninstallation etc. Individual files or entire directories can be specified as arguments. Since this means the entire content of a directory can be declared as safe, great care is recommended when using this command! (In an emergency the old database, which Tripwire archives after each update as tw.db_hostname.old in ./databases , can be restored.) tripwire --interactive Interactive updating of the reference database is the most common maintenance method. Any inconsistencies which have been detected result in a prompt for updating. This requires the presence of the administrator, of course, but in the end it is a better solution, since each case can be dealt with individually.

Changes to individual objects are detected by comparing the corresponding entries from both. Unlike added or deleted objects, which the integrity report clearly identifies, changes only appear in the report if specified in the corresponding select mask. This allows the administrator to distinguish between changes that are potentially dangerous and legitimate changes which are the result of normal use of the system. Items are logged in the integrity report using the comments added, deleted and changed (Fig. 1). Listing 1 shows a case where both modification timestamp and inode timestamp (st_mtime and st_ctime), as well as both associated signatures (md5 and snefru) differ from the original. This could occur if a text file was loaded into an editor, changed and saved using the same name with the same size. The integrity test should be performed automatically, at regular intervals of hours or days, using a cron job. By means of command line options the time-consuming calculation of signatures can be omitted. This makes it possible, in situations such as the deletion of an application, to obtain a rapid overview of any irregularities in the filesystem.

Maintenance Changing requirements can make restructuring of the filesystem necessary. In this event the reference database must also be updated. Tripwire incorporates the necessary functionality. The addition or removal of even complex packages is a simple exercise.

Installation The source code of Tripwire version 1.2 from 1994, which is free, is still to be found on the website of the COAST Project as a compressed TAR archive. At the end of 1997 Gene Kim's company, Tripwire Security Systems, Inc. received an exclusive licence

for advanced development and marketing from Purdue University. Apart from the product line intended for commercial marketing ("HQ Connector Bundle") TSS also offers on its website the so-called "Academic Source Release" (Version 1.3.1) as source code. This differs from the aforementioned COAST version mainly in a few detail improvements. This version, which is adequate for most uses, has been released for use on single-user systems. This is the version to which we will be referring in the following. Anyone who would prefer to avoid handling the source code may download the free binaries for the prize-winning Linux version 2.2.1. What TSS claims Table 1: Tripwire platforms 386BSD 0.1 Apple A/UX 3.x AT\&T System V BSDI BSD/386 beta ConvexOS 9.1 DC/OSx (SVR4) 1.1 OSx 5.1 Domain/OS SR10.x AIX 3.x dynix/PTX 2.0.x Dynix 3.x EP/IX 1.4.3 FPX 4.3.3 HP/UX 8.x, 9.x IRIX 4.x Linux 0.99.14 und newer Mach (NeXtstep) 2.x, 3.x OSF/1 1.0.4 Mach 2.x SunOS 4.0.3 SunOS 5.x (Solaris 2.x) Ultrix 4.x Umax V 2.4.1P3 Unicos 6.1.6 OSF/1 (alpha) Xenix 2.2.4 Xenix System V 386 5 路 2001 LINUX MAGAZINE 71


FEATURE

TRIPWIRE

to be a "functionally compatible" variant of the source code has been freely available since October of last year. This is subject to the GPL and is available for downloading from VA Linux Systems. Any interested C expert is welcome to participate in further development. With this departure from its previous corporate policy TSS is promising a considerable additional development push. The prestige of taking part in the development of a market-leading, even trailblazing security tool, ought to attract quite a few ambitious developers from all over the world. The binaries for this version will be available from the still dew-fresh website of the Tripwire Open Source Project, which is also to function as a central starting point for all collaborators. Users of other operating systems can only dream of this utopia. Buying the commercial full version represents an investment of around 拢400 per host. A few Linux distributors such as SuSE have already taken into account the growing security awareness of their clientele and included versions of Tripwire on their CDs. A glance into the file jungle of your Linux distribution might therefore save you some download time! Tripwire has been written in portable C. It can run on more than twenty UNIX derivatives. The procedure for installation of the package is standard and should pose no insoluble problems. For rapid installation on a Linux platform a bullet-point type brief introduction is given.

A bit of manual labour The basic installation requirement is the presence of the well-known packages "Flex" (production of lexical scanner) and "Bison" (parser generator). All system-specific alterations are made in the two following and largely selfexplanatory files: Makefile: Here, the destination DESTDIR (tw.config and binaries), DATADIR (tw.db_hostname), MANDIR (Manpages) locations should be entered. For DESTDIR and DATADIR, for security reasons, only directories requiring root permission can be considered! (The access rights defined under install could be made a bit more restrictive: 400 for tw.config, 500 for DESTDIR, 600 for DATADIR.) Also, by uncommenting LEX = flex and YACC = bison -y both packages mentioned will be used. include/config.h: Because, in the integrity test, there is a risk that spurious data could be used simply by changing two paths, the destinations of tw.config and tw.db_hostname are compiled into the executable file. The directories already selected, DESTDIR and DATADIR must therefore also be made known as CONFIG_PATH and DATABASE_PATH prior to conversion at this point. No further entries need be made here. The standard example 72 LINUX MAGAZINE 5 路 2001

configs/conf-svr4.h, which provides for further alterations required by some operating systems, should be suitable for most Linux distributions. After changing to single user mode (which prevents any unauthorised accesses in this delicate phase) it should be sufficient to run make && make test. This should leave two executable files tripwire and siggen in the directory src, and then start a test of the binaries created. In the test phase, which takes a few minutes, the largely selfexplanatory test report (Listing 2) should be watched closely. Compilation errors, which could occur as a result of incompatible libraries or compilers, could critically affect the security performance in later operation. make test &>~/TestProt would not be a bad idea! Unfortunately the value of this test is limited by the fact that there is no adequate way to check the authenticity of the source text. The "original" COAST version shows how it's done: add the Message-Digest of the package, encrypted with the private cipher of a guarantor, as a separate file. The MAC (Message Authentication Code) must be put on at this point, and should for a company such as TSS, which wants to prove high standards in matters of data security, really be more than pure theory! The manipulation of the source code of a security tool by rogues could have unimaginable consequences. If there is doubt as to the authenticity of the code, the only way to lay your worries to rest is a time-consuming one. Sifting through ten thousand lines of source text may not be to everyone's taste. Using make install eliminates the tedious installation of the two binaries, the Manpages, and an admittedly rudimentary model for tw.config. All remaining traces of the test run, which Tripwire tends to leave in the /tmp directory, should then be removed. Any concerns may be mollified with the help of the attached FAQ (see also Points 2.0 and 2.1 in the README). NB: contrib/README.linux is obsolete and therefore misleading! Installation should not be difficult even in other environments. Ported contains ready-made entries and recommendations concerning the most suitable compiler options for a whole range of known platforms. Additional information can be found in configs/, which contains a wide selection of preprepared INCLUDE-files and a few somewhat basic models for tw.config .

Rehearsing alert One further comment on the test report. In the final test phase (TSS-Shellscript test1.sh) numerous inconsistencies are shown which give the impression that an undesirable change might have occurred. In fact, this is a true blue integrity test of the distribution against a reference database which is included in the package. This occurs not so much to check the integrity of the distribution, but rather


TRIPWIRE

FEATURE

Listing 2: Self test === test0.sh: DESCRIPTION This shell script exercises all the signature routines included in the Tripwire distribution. This suite is run on a series of files created by the authors of the signature routines. === test0.sh: BEGIN === === test0.sh: PASS === === test.twpre.sh: DESCRIPTION This script exercises the Tripwire preprocessor, testing correctness variable expansion and include files. === test.twpre.sh: BEGIN === Tripwire(tm) ASR (Academic Source Release) 1.3.1 File Integrity Assessment Software ©1992, Purdue Research Foundation, ©1997, 1999 Tripwire Security Systems, Inc. All Rights Reserved. Use Restricted to Authorized Licensees. === test.twpre.sh: PASS === === test.update.sh: DESCRIPTION This shell script exercises all the Tripwire integrity checking and database update functionalities. === test.update.sh: Setting up auxiliary scripts === === test.update.sh: BEGIN === ../src/tripwire -loosedir -c /tmp/twtest/tw.config -d /tmp/twtest/tw.db -i all === test.update.sh: testing GROWING (safe) files === === test.update.sh: testing GROWING (unsafe) files === === test.update.sh: testing ADDED files === === test.update.sh: testing DELETED files === === test.update.sh: testing CHANGED files === === test.update.sh: testing input schemes === === test.update.sh: tw.config from stdin === test.update.sh: database from stdin === test.update.sh: testing complex UPDATE cases === test.update.sh: changed ignore-mask (UPDATE file) === test.update.sh: changed ignore-mask (UPDATE entry) === test.update.sh: testing UPDATED files (7 cases) === test.update.sh: case 1: update: add new file === === test.update.sh: case 2: update: delete file === === test.update.sh: case 3: update: update file === === test.update.sh: case 4: nonsense case (skipping) === === test.update.sh: case 6: update: delete entry === === test.update.sh: case 5: update: add entry === === test.update.sh: case 7: update: update entry === === test.update.sh: PASS === === test.inter.sh: DESCRIPTION This shell script exercises all the interactive update of Tripwire databases. === test.inter.sh: Setting up auxiliary scripts === === test.inter.sh: BEGIN === ../src/tripwire -loosedir -c /tmp/twtest/tw.config -d /tmp/twtest/tw.db -i all === test.inter.sh: testing interactive update === === test.inter.sh: testing complex UPDATE cases === test.inter.sh: changed ignore-mask (UPDATE file) === test.inter.sh: changed ignore-mask (UPDATE entry) === test.inter.sh: testing UPDATED files (7 cases) === test.inter.sh: case 1: update: add new file === === test.inter.sh: case 2: update: delete file === === test.inter.sh: case 3: update: update file === === test.inter.sh: case 4: nonsense case (skipping) === === test.inter.sh: case 6: update: delete entry === === test.inter.sh: case 5: update: add entry === === test.inter.sh: case 7: update: update entry === === test.inter.sh: PASS === === test.escape.sh: DESCRIPTION This is similar to the Tripwire update tests, but escaped filenames are specifically exercised. === test.escape.sh: Setting up auxiliary scripts === === test.escape.sh: BEGIN === ../src/tripwire -loosedir -c /tmp/twtest/tw.config -d /tmp/twtest/tw.db -i all === test.escape.sh: testing complex UPDATE cases === test.escape.sh: changed ignore-mask (UPDATE file) === test.escape.sh: changed ignore-mask (UPDATE entry) === test.escape.sh: testing UPDATED files (7 cases)

5 · 2001 LINUX MAGAZINE 73


FEATURE

TRIPWIRE

=== === === ... === ===

Info [1] The "Tripwire-Story": http://www.forbes.com/tool/ht ml/toolbox.htm [2] Gene Spafford's Homepage: http://www.cerias.purdue.edu/ homes/spaf [3] "RSA Data Security, Inc.": http://www.rsasecurity.com [4] "Xerox Palo Alto Research Center": http://www.parc.xerox.com/pa rc-go.html [5] Snefru and accessories (Xerox): ftp://arisia.xerox.com/pub/hash [6] "COAST Project": http://www.cerias.purdue.edu/ coast [7] "Tripwire Security Systems Inc.": http://www.tripwiresecurity.com [8] Future "Tripwire-forge": http://sourceforge.net/projects /tripwire [9] "Tripwire Open Source Project": http://www.tripwire.org ■

test.escape.sh: case 1: update: add new file === test.escape.sh: case 2: update: delete file === test.escape.sh: case 3: update: update file ===

test.escape.sh: PASS === test1.sh: DESCRIPTION This shell script tests all the Tripwire signature routines. Consequently, this test may take a while to complete, because even the slowest signature routines are exercised. On a 200 MHz Intel Pentium machine, this test takes 15 seconds to complete. This test suite will ascertain whether the byte-ordering and machine-dependent routines are working correctly. === test1.sh: BEGIN === creating: ./tw.db_TEST.@ creating: ./@tw.config Tripwire(tm) ASR (Academic Source Release) 1.3.1 File Integrity Assessment Software © 1992, Purdue Research Foundation, © 1997, 1999 Tripwire Security Systems, Inc. All Rights Reserved. Use Restricted to Authorized Licensees. ### Phase 1: Reading configuration file ### Phase 2: Generating file list ### Phase 3: Creating file information database ### Phase 4: Searching for inconsistencies ### ### Total files scanned: 161 ### Files added: 0 ### Files deleted: 0 ### Files changed: 161 ### ### Total file violations: 161 ### changed: drwxr-xr-x root 1024 Sep 27 23:00:31 2000 /root/tw_ASR_1.3.1_src changed: -rw-r----- root 2201 May 4 10:31:00 1999 /root/tw_ASR_1.3.1_src/COAST.info changed: -rw-r----- root 5441 May 4 10:31:00 1999 /root/tw_ASR_1.3.1_src/FAQ ... ### Phase 5: Generating observed/expected pairs for changed files ### ### Attr Observed (what it is) Expected (what it should be) ### =========== ============================= ============================= /root/tw_ASR_1.3.1_src st_ino: 128630 605814 st_uid: 0 1016 st_size: 1024 0 st_mtime: Wed Sep 27 23:00:31 2000 Fri Apr 30 23:03:53 1999 st_ctime: Wed Sep 27 23:00:31 2000 Fri Apr 30 23:03:53 1999 /root/tw_ASR_1.3.1_src/COAST.info st_ino: 128632 605816 st_ctime: Wed Sep 27 22:51:45 2000 Tue May 4 15:20:44 1999 /root/tw_ASR_1.3.1_src/FAQ st_ino: 161308 st_ctime: Wed Sep 27 22:51:45 2000 ... === test1.sh: END === removing: ./tests/tw.db_TEST.@ removing: @tw.config ...

605817 Tue May 4 15:20:44 1999

to ensure that the signature functions work correctly. Since the reference database supplied by TSS was not encrypted, it would be an easy task for a hacker to change the signatures concerned in the reference databank! The report quite correctly shows all 161 files of the distribution as "changed" , because inode number (st_ino) and inode timestamp (st_ctime) in the filesystem of the destination computer don't match their original values, which were valid at the time of creation of the reference

74 LINUX MAGAZINE 5 · 2001

databank by TSS. Changed signatures should, on the other hand, certainly give you something to think about, since only arithmetic errors could have caused them. This can be clarified using grep -n "md5" ~/TestProt . In the next article we will examine the potentially problematic configuration of Tripwire . Unlike a virus scanner, which makes few demands in this respect (but is also scarcely any use) an integrity checker demands a lot of effort on the part of the user. The use of this unusual set of tools will be explained later. ■


KNOW-HOW

BOOTDISK

Creating and Using Linux Emergency Recovery Disks

BETTER SAFE THAN SORRY MARTIN MILNER

What would you do if the Linux system you spent many hours building suddenly wouldn’t load? – due to a mistake during configuration? Re-install? What about your precious data? In this article, we’ll explain the steps necessary to create a complete Linux system which will boot from floppy disks and allow you to perform essential recovery work like restoring a backup of your root filesystem. (You have got one, haven’t you?)

So your Linux system is broken. Maybe you had problems with the hard disk or a power cut and then the fsck (filesystem check) of the root filesystem came up with loads of errors. If you’re used to using Windows 9x, you’ll probably know about the Windows emergency boot disk you can create, but it doesn’t allow you to do a great deal and it certainly won’t load and run Windows. However, a basic Linux system can run off one or more floppy disks – yet still provide a basic set of essential tools. If you bought an official Linux distribution from one of the main suppliers you may have received a recovery disk with it. Lucky you. If however, like many people you built a system off a magazine CD or similar, then you most certainly won’t have one. The disk set described here consists of a boot disk, a disk containing a root filesystem with a small set of tools and a utility disk to hold a number of additional utilities. The article assumes you have ramdisk support enabled in your kernel. If you haven’t, then you will need to enable it.

Making a boot disk The first disk we need to create is the boot disk. This contains a Linux kernel and the kernel loader LILO. It is possible to create a boot disk which also contains 76 LINUX MAGAZINE 5 · 2001

a root filesystem, (a ‘boot/root’ disk), but because of the small size of even HD floppy disks, the resulting system will be severely lacking in essential utilities. By far the easiest way of creating a boot disk is by using the command mkbootdisk (see figure 1) like this: mkbootdisk —verbose kernelversion (eg:- 2.2.16) This command creates a stand-alone boot floppy for your running system. The most important parameter is the last one, which is the kernel version. Note that there are (at least) two versions of mkbootdisk, one which doesn’t add the rescue option to /etc/lilo.conf. Whichever version you’ve got after it finishes, mount the disk and edit the lilo.conf file until it looks similar to that in figure 2 and then rerun LILO like this: mount -t ext2 /dev/fd0 /mnt/floppy (/mnt/U floppy must already exist) vi /mnt/floppy/etc/lilo.conf /sbin/lilo -v -r /mnt/floppy umount /mnt/floppy The ‘ramdisk’ option in lilo.conf ensures the ramdisk is big enough for the root filesystem we’ll be


BOOTDISK

Figure 1 - Using mkbootdisk to make the boot floppy

creating below. The compact option speeds up the loading process and the append line tells the kernel to prompt for a root filesystem and load it into the ramdisk. Once finished, you will have a floppy disk containing your current kernel, LILO and a number of other system files (see figure 3). When you reboot your machine with this disk inserted, LILO will give you the choice of booting up off your hard disk or typing in rescue to boot from floppy. After choosing rescue, you will eventually be asked for a disk containing a root filesystem, which is what we’ll create next.

Creating a root filesystem The root filesystem must contain everything needed to support a full Linux system. In other words: 1. The basic filesystem structure. 2. A minimum set of directories. (/dev, /proc, /bin, /etc, /lib, /usr, /tmp, etc.) 3. A basic set of utilities. (bash, ls, cp, mv, etc.) 4. A minimum set of config files. (inittab, fstab, etc.) 5. Devices. (/dev/hd*, /dev/tty*, /dev/fd0, etc.) 6. Runtime libraries to provide basic functions used by utilities. To allow us to have as many files, utilities, etc. as possible in our root filesystem, we’ll build a compressed filesystem. Obviously, this means we’ll have to build it elsewhere. There are a number of ways of doing this. 1. Use a ramdisk. (/dev/ramdisk or /dev/ram0). 2. Use an unused hard disk partition. 3. Use a loopback device, which allows a disk file to be treated as a device. (For which you need specially modified mount and unmount commands.) For this excercise, we’ll assume you haven’t got an unused partition or the disk space to create one and use a ramdisk. First, prepare the ramdisk: dd if=/dev/zero of=/dev/ramdisk bs=1k count=U 4000 (approx. 4Mb.)

KNOW-HOW

Figure 2 - How /etc/lilo.conf should look

Next, create the filesystem: mke2fs -m 0 -i 2000 /dev/ramdisk mke2fs will automatically detect the space available. The -i 2000 is to increase the amount of inodes to make sure we don’t run out. Now make an appropriately named mount point (if you haven’t done so before) and mount the new filesystem: mkdir /mnt/ramdisk mount -t ext2 /dev/ramdisk /mnt/ramdisk Copy over the appropriate device files from the /dev directory like this: mkdir /mnt/floppy/dev cp -dpR /dev/hda? /mnt/ramdisk/dev Repeat the above for all the devices you might need. Next create the other directories on the floppy and then copy all the other files into them. See the boxout for an example of the required files and directories. Be especially careful that symbolic links are preserved. (Many of the library files in /lib are links.)

Config files and finishing off Some of the config files will need changing to reflect their intended use. See figure 4 for the contents of the files that will require editing. When you’ve done all that and are reasonably happy that all is well, do the following: umount /mnt/ramdisk dd if=/dev/ramdisk of=rootfs bs=1k gzip -v9 rootfs When gzip is finished, rootfs.gz contains the compressed root filesystem. Make sure that rootfs.gz will fit on a floppy disk. If it’s too big unzip it, remount the filesystem as before, delete some stuff out of it and try the above again. Finally, it’s time to write it to floppy disk, dd if=rootfs.gz of=/dev/fd0 bs=1k 5 · 2001 LINUX MAGAZINE 77


KNOW-HOW

BOOTDISK

Example of contents of a floppy root filesystem /mnt/ramdisk: bin dev

etc

lib

mnt

mnt2

proc

root

sbin

tmp

usr

var

/mnt/ramdisk/bin: bash cat chmod id ln login pwd rm rmdir

chown ls sh

cp mkdir stty

date mknod su

dd more sync

df mount touch

echo mt true

false mv umount

grep ps uname

hostname

/mnt/ramdisk/dev: cdrom cdu31a console hda9 hdb1 hdb2 hdc2 hdc3 hdc4 hdd5 hdd6 hdd7 sda2 sda3 sda4 sdb5 sdb6 sdb7

fd0 hdb3 hdc5 hdd8 sda5 sdb8

hda1 hdb4 hdc6 hdd9 sda6 sdb9

hda2 hdb5 hdc7 kmem sda7 tty0

hda3 hdb6 hdc8 mem sda8 tty1

hda4 hdb7 hdc9 null sda9 tty2

hda5 hdb8 hdd1 ram sdb1 ttyS1

hda6 hdb9 hdd2 ram0 sdb2 zero

hda7 hdc hdd3 ramdisk sdb3

hda8 hdc1 hdd4 sda1 sdb4

/mnt/ramdisk/etc: conf.modules fstab nsswitch.conf pam.d

gettydefs group passwd profile

inittab rc

issue shadow

ld.so.cache shells termcap

utmp

wtmp

/mnt/ramdisk/etc/pam.d:

other

/mnt/ramdisk/lib: ld-2.1.1.so libcom_err.so.2 libdl-2.1.1.so libext2fs.so.2 libnss_files-2.1.1.so libpam.so.0.66 libpam_misc.so.0.66 libpwdb.so.0.58 libutil.so.1

ld-linux.so.2 libcom_err.so.2.0 libdl.so.1 libext2fs.so.2.4 libnss_files.so.2 libpam_misc.a libproc.so.2.0.0 libtermcap.so.2 libuuid.so.1

libc-2.1.1.so libcrypt-2.1.1.so libdl.so.1.9.5 libnsl-2.1.1.so libpam.so libpam_misc.so libpwdb.so libtermcap.so.2.0.8 libuuid.so.1.2

/mnt/ramdisk/lib/modules/2.2.12-10/block:

loop.o

/mnt/ramdisk/lib/modules/2.2.12-10/cdrom:

cdu31a.o

/mnt/ramdisk/lib/security:

pam_permit.so

/mnt/ramdisk/mnt:

cdrom

libc.so.6 libcrypt.so.1 libdl.so.2 libnsl.so.1 libpam.so.0 libpam_misc.so.0 libpwdb.so.0 libutil-2.1.1.so

floppy

/mnt/ramdisk/sbin: depmod fdisk halt mkswap modprobe rmmod

head init shutdown sulogin

/mnt/ramdisk/var: log

run

tmp

/mnt/ramdisk/var/log: /mnt/ramdisk/var/run: /mnt/ramdisk/var/tmp:

wtmp utmp tmp

insmod swapoff

kerneld swapon

lsmod tail

Example contents of a Utility disk mnt/floppy: bin lib lost+found /mnt/floppy/bin: cut diff du find /mnt/floppy/sbin: chroot fuser

78 LINUX MAGAZINE 5 路 2001

motd ttys

man

sbin

share

gunzip lilo

gzip mke2fs

passwd mkfs

tar vi mkfs.ext2

mingetty update


AD G. Matter

Figure 3 - The contents of a typical boot disk

Creating an Utility disk The Utility disk is a disk full of extra programs which wouldn’t have fitted on the root filesystem, things like such as vi, tar, etc. and maybe programs that reside in /usr/bin and /usr/sbin. These give you the ability to perform many more activities than would otherwise be the case. (See boxout for example.) Simply follow the steps below, and that´s it! Insert a blank formatted floppy and type, mkfs -t ext2 /dev/fd0 mount -t ext2 /dev/fd0 /mnt/floppy cd /mnt/floppy mkdir bin;mkdir sbin copy (using cp) the programs you think will bU e useful to these directories. cd /;umount /mnt/floppy

Using the Emergency disk set On rebooting the machine, follow the steps below, 1. Insert the emergency boot disk and wait for the LILO prompt. 2. At the prompt, you can either boot from the hard disk as normal (if the Linux system isn’t broken) or you can type rescue to boot from the floppy. 3. After a while a prompt will appear asking you to insert the root filesystem disk. Do so and press enter. 4. Wait for the login prompt and login as root. If you want to use programs off your utility disk, insert it and call: mount -t ext2 /dev/fd0 /usr You can then mount your hard drive filesystems and/or do whatever needs doing.

Figure 4 - The edited config files for the root filesystem

In Conclusion There are many, many more aspects of the above than can be gone into in a magazine such as this. The essential read is the ‘Linux Bootdisk HOWTO’, which can usually be found in /usr/doc/HOWTO or /usr/share/doc/HOWTO on your system.(Bootdisk-HOWTO.) It contains a large amount of detailed information on this subject and more importantly, what to check if you run into problems. However, the above should give you a good idea of what’s involved and may even help you get a login prompt first time! Good luck. ■


KNOW-HOW

CONNECTIVITY

Turning PDAs into Linux terminals

BRAINSWAP THE SECOND CLEMENS RUDOLPH

PDAs are undoubtedly invaluable gadgets and have all sorts of uses. Using Linux as a gateway, they can even be used for surfing the Web, reading emails or administering a server via Telnet. This feature will tell you exactly how to do all this using a Psion PDA. However, the basic principles we’ll cover will point you in the right direction when it comes to using other types of client computer too.

PDAs worth their salt have a serial interface of some kind that lets them communicate with the outside world. Most modern PDAs also include a range of Internet applications as standard, so all you need to get online is a modem. Alternatively, you can simply link them via a null modem cable to a Linux system that has an Internet connection. You’ll need to know the secrets of mgetty and pppd in order to do so, but these (and how a Psion PDA can make use of them) 80 LINUX MAGAZINE 5 · 2001

are exactly what we’ll reveal in this feature. Almost everything we’ll cover can be applied to any system capable of connecting to a Linux box using a serial link, including old Atari, Amiga and even Intel 80286-based systems.

Preparing the Psion Before we do anything else, we have to make the client computer – in our case the Psion organiser – Internet-capable. A glance in the Psion’s system


CONNECTIVITY

KNOW-HOW

Fig. 1: Communication menus in the Psion’s control panel

control panel (see Figure 1) reveals three icons used to configure connections with the outside world: Dialling, Modems and Internet. But since we’ll be using a fixed connection, we’ll ignore Dialling. We’ll start with the Modem configuration option. All we need to do is select ”Direct connection” for the ”Current modem” option. Next, turning to the Internet configuration option, we need to use the ”New” option to make a new profile based on ”Default settings”, then give it an appropriate name – we’ll use ”Intranet”, but anything will do. The settings that appear when you select the ”Edit” option are shown in the screenshots in Figure 2. These are pretty straightforward to configure as needed. At this point there is just one other step to complete on the Psion; as paradoxical as it may sound, in the PDA’s main menu, under ”Extras”, we have to change the ”Link” option to ”OFF” in the ”Communication” section. This is the only way to get the little organiser to perform purely TCP communication and to stop it acting as a PsiWin client. The next step is to start configuring our Linux box

Configuration of the gateway Two basic types of connection are possible between a client and our Linux system. The first is a simple console connection, in which only a log-in (thus a console) is opened. The second type of connection makes use of the Point-to-Point Protocol, or PPP for short. Using these two types of connection, the link between the Psion and the Internet can be made, the Psion’s ”Comms” terminal program making use of the console connection, and its ”Web” and ”Mail” programs making use of a ”Point-to-Point” connection.

Port monitoring with mgetty In order to build our communications framework, we first n

5 · 2001 LINUX MAGAZINE 81


KNOW-HOW

Fig. 2: Configuring an Internet service

82 LINUX MAGAZINE 5 路 2001

CONNECTIVITY


CONNECTIVITY

KNOW-HOW

Espionage with logwin When using a high debuglevel, as we have done in our examples, it makes sense to keep a close eye on the outputs of the services in order to see if anything is wrong. To do so, when working under X, you can use xterm (or similar) and an appropriate console to look at any interesting logfiles. To achieve this for xterm (and its variants) we need to change to root mode using ‘su -l’, and then type xterm -e tail -f /var/log/messages /var/log/warn /var/log/mgetty.ttyS[0-9] The regular expression ”[0-9]” at the end is necessary to capture only files ending in a number and not, for example, an old log file already automatically grabbed by the system. This would obviously cause some confusion in the case of tail.

Figure 3: Console log-in with Comms

5 · 2001 LINUX MAGAZINE 83


KNOW-HOW

CONNECTIVITY

Transport of configuration files One option for transferring the configuration files required to give a Psion Internet access from one PC onto another would be to save the data to floppy disk. However, a much more elegant solution is to store the configuration onto the Psion itself and transfer it to the host as required. This does necessitate a program to be run on the host that allows a serial data transfer for files. This is where the almost ubiquitous minicom, which acts as a terminal emulator, comes in handy. By linking this with the Psion’s Comms program it is very simple to exchange files between the two systems. The y-modem protocol comes in vary handy here. A few tips on how all this works can be found at http://www.mda.de/homes/tron5/ psilink.html.

Table 1: The pppd-options and their effect pppd-Option Description crtscts This activates hardware flow control. lock This parameter serves to hang a UUCP-conform lock in front of the device in use. In other words an exclusive user right to the COM-port is established for the process accessing it at that moment (/var/lock/...). noauth With this option, authentication (which in our case would cause interference) is suppressed. noccp This option ensures that no CCP (Compression Control Protocol) negotiation occurs during the connection. The Linux machine and the Psion negotiate about compression at start of the connection process (whether wanted or not), but the pppd, which stems from a time in which telephone lines were even more unreliable than they are today, normally tries to keep negotiating every 10 seconds. nopersist This parameter is not absolutely necessary, as it applies by default. We have included it for completeness and security reasons though (see ‘Read sequence of configs of pppd’ in the text). In any case, it makes sure that the pppd stops when a serial connection (from the Psion) is closed. This, of course, only makes sense if an existing connection is checked by LCP (Line Control Protocol) silent Silent serves to ensure that the daemon continues to wait patiently until something stirs on the line. It instructs the daemon to wait, ”silently” for whatever comes in and do nothing until then. proxyarp Using this parameter, an entry containing the IP address that we need for the Psion is added to the ARP table (or Address Resolution Protocol Table to give its proper name). Effectively, it means something like ”It is now one of us”. local This tells the daemon that it doesn’t need to worry about a modem on the serial line, and so it

84 LINUX MAGAZINE 5 · 2001


CONNECTIVITY

KNOW-HOW

About the author Clemens Rudolph is a programmer for an ISP, and specializes in PHP and Perl. He never tires of poking around in the bowels of his system.

”Comms versus Hermes” Hermes, a Telnet client and terminal emulation program for the Psion (available from http://www.iota.demon.co.uk/psion/hermes/hermes.html), is a really amazing application that can provide a pure serial console connection as easily as a PPP-connection. In contrast, Comms is ”only” a terminal and so can only be persuaded to work with the likes of login or minicom. This means that Hermes is really great when you need to log in to a Linux box on which you don’t have root privileges. You can start pppd as normal user, provided the rights have been set accordingly and on call up the path is given as /usr/sbin/pppd .... You will need to make some configuration changes in Hermes in order to do so though. In the ”Connection” menu, look for the ”Connection” option and switch it to ”TCP-Connection”. Now all you need to do is enter the IP address of the destination system and you’ll have a Telnet log-in in seconds.

5 · 2001 LINUX MAGAZINE 85


PROGRAMMING

GNOME

Source code trees

IN THE VALLEY OF THE CODE THORSTEN FISCHER

So you’ve just written yet another terrific GNOME program. Great! But does it, like so many other great programs, lack something in terms of ease of installation? Even the best and easiest to use programs will cause headaches if you have to type in lines like this,

With the help of Automake and Autoconf, you can create easily installed source code text trees. Read on to find out how.

gcc -c sourcee.c gnome-config —libs —cflags gnome gnomeui gnomecanvaspixbuf -o sourcee.o perhaps repeated for each of the files, and maybe with additional compiler flags too, only to then demand that everything is linked. And at the end, do you then also have to copy the finished binary manually into the destination directory? Instead, wouldn’t you rather have an easy, portable and quick installation process? Well, you can – if you know how.

Front end The complicated installation scenario we described above is of course a bit of an exaggeration, since Makefiles are not hard to write. Using these, all you need to do is type make in the source text directory, and the program is created. A ”simple” Makefile for a short C-program in GNOME can look something 86 LINUX MAGAZINE 5 · 2001

like the one in Listing 1. Not too complex, eh? Unfortunately, creating a Makefile isn’t always the best solution, as assumptions on programs locations, path names and others things may not be true in all cases, forcing the user to edit the file in order to get it to work properly. Listing 1: A simple Makefile for a GNOME 1: CC=/usr/bin/gcc 2: CFLAGS=`gnome-config —cflags gnome gnomeui` 3: LDFLAGS=`gnome-config —libs gnome gnomeui` 4: OBJ=example.o one.o two.o 5: BINARIES=example 6: 7: all: $(BINARIES) 8: 9: example: $(OBJ) 10: $(CC) $(LDFLAGS) -o $@ $(OBJ) 11: 12: .c.o: 13: $(CC) $(CFLAGS) -c $< 14: 15: clean: 16: rm -rf $(OBJ) $(BINARIES) That’s not what you wanted, is it? No, what you wanted is something much simpler. Something like this, perhaps? ./configure make make install But hang on, we’re getting ahead of ourselves. First we need to deal with the source text tree and the


GNOME

GNOME-specific properties that must be taken into account when building one.

Structure It is important to have a structure for the source text tree. The source code itself should be located separately from other things such as the documentation or the files for configuration – doing so makes it easier to get an overview. So the first thing we’ll do is to create a directory called example, which will be the site for our tree, then create a src within it for our code and throw everything we need in there. To stick with the files used in the Makefile example in Listing 1, this means the files example.c, one.c, one.h, two.c and two.h. The first of these files is shown in Listing 2, while the other four are empty and are only included as an example. Listing 2: example.c 1: #include <gnome.h> 2: #include "one.h" 3: #include "two.h" 4: 5: int main (int argc, char *argv []) 6: { 7: GtkWidget *app; 8: 9: gnome_init ("example", "0.0.1", argU c, argv); 10: app = gnome_app_new ("example", "ExaU mple"); 11: 12: gtk_widget_show_all (app); 13: gtk_main (); 14: return TRUE; 15: } Documentation: A tiresome step for every programmer, but one that co-developers and users will be grateful for. The following files are the done thing to put in a source directory: * * e * * * *

Authors: The authors are listed here ReadMe: Everything worth reading on thU program News: News concerning the program ChangeLog: Documentation of all changes Copying: A copy of the GNU GPL Install: Installation instructions

These are the most important files, but there are others too. Where do these files come from? The first three are obviously ones you have to make yourself, while the last two should preferably be copied from the automake directory.

Automake automake and autoconf are two small GNU tools, which can be obtained from ftp.cs.tuberlin.de/pub/gnu/. These tools create your configuration files for you, which then only have to be executed by the user in order to get everything done for them. Users don’t have to have installed

PROGRAMMING

the aforementioned programs themselves, mind you, as the source text package from our application is all that is needed for this procedure. How the two programs should be installed (if you can’t simply take them from the developer section of your distribution CD that is) is something you can probably guess at. But before we attach automake and autoconf to our sources, there is still some preparatory work to be done. We need to create two more files – namely configure.in and Makefile.am – examples of which can be seen in Listings 3 and 4. Listing 3: configure.in 1: AC_INIT(src/example.c) 2: 3: AM_CONFIG_HEADER(config.h) 4: 5: AM_INIT_AUTOMAKE(Example, 0.1.0) 6: 7: AM_MAINTAINER_MODE 8: 9: AM_ACLOCAL_INCLUDE(macros) 10: 11: GNOME_INIT 12: 13: AC_PROG_CC 14: AC_ISC_POSIX 15: AC_HEADER_STDC 16: AC_ARG_PROGRAM 17: AM_PROG_LIBTOOL 18: 19: GNOME_COMPILE_WARNINGS 20: 21: ALL_LINGUAS="de" 22: AM_GNU_GETTEXT 23: 24: AC_SUBST(CFLAGS) 25: AC_SUBST(CPPFLAGS) 26: AC_SUBST(LDFLAGS) 27: 28: AC_OUTPUT( 29: Makefile, 30: macros/Makefile, 31: src/Makefile, 32: intl/Makefile, 33: po/Makefile.in 34: ) Listing 4: Makefile.am 1: SUBDIRS=macros po intl src 2: 3: Applicationsdir=$(datadir)/gnome/apps/ApU plications 4: Applications_DATA=example.desktop The two files are basically easy to explain. We’ll start with configure.in. In the first line autoconf is initialised, with the name in brackets of any existing file. The main source file is ideal for this. AM_CONFIG_HEADER specifies a header file, which is intended later to carry the specific information for the configured package and which must also be integrated into the source text – but more on that later. Note the different prefixes that the macro names carry: AC_ designates a macro for autoconf, and AM_ (hardly surprisingly) refers to automake. automake will also 5 · 2001 LINUX MAGAZINE 87


PROGRAMMING

GNOME

be concerned with the content of this file, but again more on that later. It will be initialised in line 5 complete with the name of the package and its version number. If, during the course of development, you feel enough has happened to push this number up a notch, then don’t forget to note the fact here as well as elsewhere. In the ninth line, the macros directory is added to the aclocal search path. This is yet another thing we haven’t mentioned yet, and it won’t be the last. It deals with the administration of the macros which are called up in configure.in (macros can be copied from the gnome-libs source package, by the way). This is then followed by the initialisation of GNOME, various standard macros to search and test a Ccompiler, some header files, POSIX-conformity of the system and so on. Then in line 19 compiler warnings are switched on. Line 21 is concerned with localisations of the program; our example assumes the existence of ”de” translations, but any supported locale can be used. The next line, gettext, is also necessary for localisation. You don’t have to create international installations, of course, but it really does add a touch of professionalism – and is also a great way to show off your language skills. The lines 24, 25 and 26 export the variables, compiler and linker flags, which have been defined during the processing of the file, so that they can actually be used in the program. The last lines following AC_OUTPUT finally specify where Makefiles should be created. Line 33 is not a typo, by the way.

One more item of importance now is the Makefile.am in the subdirectory src, containing the actual sources of the program. An example can be seen in Listing 5. I have adapted this example from Havoc Pennington’s ‘Gtk+/GNOME Application Development’. Firstly, the Include-Directories are defined, and then the source files for the finished program are named. Finally the flags for the linker are set, which should amalgamate the compiled object files.

Et voila And now it’s almost done! The following commands now deal with the creation of our configuration scripts, Makefiles and so on: frog@verlaine:~/code/example --copy --force frog@verlaine:~/code/example opy —force frog@verlaine:~/code/example frog@verlaine:~/code/example frog@verlaine:~/code/example d-missing —copy frog@verlaine:~/code/example

# libtoolize U # gettextize —cU # aclocal # autoheader # automake —adU # autoconf

This is a template file, to create – via an intermediate step when it will be called Makefile.in – an individual or all completed Makefiles respectively. The first line lists all subdirectories in which additional templates are located and/or in which Makefiles should be created. Lines three and four specify the directory in which our program should place its Desktop file, with the aid of which it will later pop up in the GNOME menus.

The first command is necessary mainly for creating libraries. It also copies scripts into the directory, which are needed elsewhere. —copy requests copying rather than the creation of Symlinks – the normal default setting – and —force creates the files again, even when they already exist. gettextize gives the package the necessary files for internationalisation and localisation. aclocal edits the macros and autoheader makes a file config.h.in, which is then created by automake and autoconf. Now, for package creation, we just have the easy target dist: after calling up configure a make dist produces a ready-wrapped parcel, in our example called example0.1.0.tar.gz. In the macros directory, you’ll find a little script called autogen.sh, which can take over these calls for you. You don’t have to keep executing these by hand once you have added a source text file.

Listing 5: src/Makefile.am 1: INCLUDES=$(top_srcdir) -I$(includedir)$U (GNOME_INCLUDEDIR) \ 2: -DG_LOG_DOMAIN=\"Example\" \ 3: -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \ 4: -I../intl -I$(top_srcdir)/intl 5: 6: bin_PROGRAMS=example 7: 8: example_SOURCES=example.c \ 9: one.h \ 10: two.h \ 11: one.c \ 12: two.c 13: 14: example_LDADD=$(GNOMEUILIBS) $(GNOME_LIBU DIR) $(INTLLIBS)

Listing 6: src/example.c 1: #include <gnome.h> 2: #include <config.h> 3: #include "one.h" 4: #include "two.h" 5: int main (int argc, char *argv []) 6: { 7: GtkWidget *app; 8: 9: gnome_init (PACKAGE, VERSION, argc, argv); 10: app = gnome_app_new (PACKAGE, _(”ExampleU ”)); 11: 12: gtk_widget_show_all (app); 13: gtk_main (); 14: return TRUE; 15: }

Makefile.am

88 LINUX MAGAZINE 5 · 2001


GNOME

Changes in the sources As the result of the creation of the file config.h there may be some other changes to the source text. In particular details of the name of the package and the version number can now be accessed more easily. Listing 6 shows the code for the example file after the changes. The macro _() in the tenth line is needed because of our desire to internationalise our package.

The desktop file In our main source directory, the empty file example.desktop will still be lurking around. If this is filled with content, as can be seen from Listing 7, and if the line EXTRA_DIST = example.desktop is entered in its main Makefile.am, then when the Listing 7: example.desktop 1: [Desktop Entry] 2: Name=Example program 3: Name[de]=Beispielprogramm 4: Comment=An example 5: Comment[de]=Ein Beispiel 6: Exec=example 7: Terminal=0 8: Type=Application

PROGRAMMING

completed program is installed a Desktop entry will be added to the GNOME menu hierarchy. This entry may contain localised names – such as in German as shown here–, a comment – again localised –, the name of the executed file, the file type and the fact that the application should not be executed in a terminal.

Glade I shouldn’t really be telling you this right at the end, but a program called Glade (see glade.pn.org/) can create complete source text trees for you at the push of a button. This doesn’t mean you shouldn’t bother working ”by hand”, as described in this article, though. Why? Well, primarily because Glade can only create a quite rudimentary tree. As soon as you want more than Glade has to offer, you have to get to work by hand anyway, and this will only makes sense to you if you have some prior knowledge of doing so, which we’ve just given you. Indeed, having created your own source tree, you can sleep soundly at night in the knowledge that if there is ever any problem then you can make your own changes in no time, without having to throw yourself on the mercy of a graphical user interface. So there you have it – how to create easily installed packages in a nutshell. Do please give it a try – you’ll be making the Linux world a better place for everybody if you do. ■

Length 3.5 pages 1/page ad across bottom right

5 · 2001 LINUX MAGAZINE 89


PROGRAMMING

GAME-BLENDER

Workshop â&#x20AC;&#x201C; Game prototyping with Blender

CHILDSPLAY MARTIN STRUBEL

Blender, the well-known freeware modeller, now has some additional talents. Version 2.0, also known as "Game-Blender", includes special functions that allow you to create complete 3D games in next to no time.

Fig.1: Snapshot of a test level created with Blender

Blender 2.0 was released at the Siggraph event in July 2000 by the Dutch firm Not a Number (NaN). A significant new release, it includes some quite stunning new features that many a Blender fan had been awaiting feverishly, including a built-in game engine allowing for fast drafting of games models. The initial release of this new version does have one or two problems, a slightly wonky physics engine and missing Linux sound support being the most significant. The package is undergoing very rapid development, though, and a new version appears on the Internet (http://www.blender.nl) pretty much on a monthly basis. This is a good thing, but because things are changing so quickly you should expect some compatibility issues to arise. Collision detection and game dynamics are likely to work differently before too long, for example, and a new physics engine is currently being worked on. Also in the development phase is a new Python-API, with which allows even more complex game actions and object types to be defined.

90 LINUX MAGAZINE 5 ¡ 2001

Having said all this, the most current version at the time of writing, version 2.04, works very well indeed. It is extremely simple to create interactive environments without even having to write a single line of code. More complex game concepts can also be created with ease too, but doing so does require a little bit more time and effort. You should be aware, though, that you won't have much fun with Blender 2.x without 3D hardware support. I use a nVidia TNT2 under XFree86 4.0, but other cards will work too.

How do I produce a game? This feature is aimed at those who are already familiar with Blender and virtual reality. We will still go through a very quick overview of the individual steps in the creation of a Blender game environment though, just in case you are a bit rusty. Create the level: Blender usually organises a game level in a Scene. This, in turn, is split up into


GAME-BLENDER

sectors, for which transparency tests are performed. In order to be able play a level at a reasonable speed (in other words at a high framerate) you should give a lot of thought to the subdivision of a level into sectors using polygon complexities. • Add moving objects: Generally, animated or moving objects are called Props (short for properties – i.e. characteristics). Moving objects, which should be subject to the laws of physics – such as the player, monsters, or bullets, are regarded as actors. The engine evaluates collisions between these objects and other objects. • Interactivity: Certain events trigger actions, which are defined in Blender using what's known as a SCA mechanism. SCA stands for Sensor-ControllerActuator. This is when an object (Prop or Actor) is assigned one or more sensors. These react to certain events such as key actuations and are linked logically with other events by Controllers. They can, using Actuators, trigger an action such as an animation. The method will be explained later using the example of a Switch-object. • Process and refine dynamics: The materials menu in version 2.0 has been expanded, a DYN (for dynamic materials) option having been added. This makes it possible to define physical properties of a surface (such as friction, elastic reflection, etc.). In addition, global parameters apply to the player object, such as general friction, gravitation and so forth.

An example

Ok, now that you have the basics under your belt, let's go on to create a simple environment. 1. First create a plane. Now scale it through EditMode to the desired size – Blender always sets object scaling to (1.0,1.0,1.0) for sectors as soon as the engine is started. Extrude a point in the Z-direction as can be seen in the picture. Especially important is the direction of the area normals, which are displayed via the Edit button ([F9]) by Draw Normals – if applicable increase NSize. Inverting the direction of normals is done via W and Flip Normals.

PROGRAMMING

2. Leave Edit mode and activate the Sector option in the RealTime menu (lilac Pac-Man). 3. The sector thus created is drawn with Bounding Box. Copy this sector using Shift+D several times (while holding down Ctrl), so that they join together as in Figure (c). Now add, on top of the ground you've just created, an additional mesh and activate the Actor attribute for this, followed by the Dynamic and MainActor options. You guessed it – this is our player. Dynamic actors possess additional attributes too – see Table 1. We'll tell you more about attributes later – first we need to define a few sensors for the object, which for the purposes of our example, we've now renamed as player. The link of the signal channels occurs via the yellow blobs by clicking the mouse on the output-blob, holding it down, and drawing the line to the input-ring. The signal channel is

removed by clicking on this. Now create an SCA combination as in Fig. 2 by adding a Keyboard type sensor, clicking in the Key field and pressing the desired key – for an up-arrow select Uparrow, for example. For the actuator, select an Object with a Force of 1.0 in Y-direction. Now try to add rotation-actions by registering suitable sensors to the left and right arrow keys. For Torque use a value of around 0.4 (left rotation) and -0.4 (right rotation) in the third co-ordinate field (Z). You should also activate the axis display of the object ([F9]): Axis. Also take note of the L (for local) button nearby. When activated, movement occurs with respect to the local coordinate system of the actor – if not then the global or superordinate co-ordinate system is used. You can test the control straight away by pressing the hot key to start the engine: P for

Fig. 2: Creating a sensor for forward movement Using Add, a new sensor, controller or actuator can be added. Via the selection menu, the type of sensor (Always, Keyboard, etc.), or the logical link of the controller or the action of the actuator is selected. In addition to this any drawing can be entered. With the orange triangle you can pack in the input form respectively. You can find additional details about the display options in Table 2.

Table 1: Actor attributes Do Fh Activate Normal force Rot Fh Align on the level (e.g. for car on racetrack) Mass Mass Size Radius of collision sphere Damp Damping of movement RotDamp Damping of rotation Table 2: Display options Sel Display all selected objects Act Display only active object (pale-lilac) Link Show links too 5 · 2001 LINUX MAGAZINE 91


PROGRAMMING

Fig. 3: Visibility of sectors

GAME-BLENDER

Play! If you press Esc, play-mode will be ended and the position of the player will be reset. The space bar also ends play mode, but in this case retains the current position of the player. In the next step we want to test the sector configuration. Use the space bar to add a camera, position it at the site of the player. Make the latter the camera's parent by selecting first the camera, then the player while at the same time holding down Shift and then the key combination Ctrl+P for Make Parent. Rotate the camera so that it's facing the Y-direction (forwards) of the player. Now make this camera active by selecting it and pressing Ctrl+Num+0 (that's 0 on the numeric keypad). Now switch to TopView with Num+7. Press P, control the player, and observe the automatic revealing and masking of the sectors, depending on visibility, as in Fig. 3. The player mesh here is in the form of an arrow for the sake of greater clarity. When handling sectors there are a few important details to be noted: • Always process sectors in edit mode; scaling and rotation in object mode leads to undesired effects. • Sectors can and should overlap somewhat, although interlacing should be avoided. • Do not apply parenting hierarchies of sectors – this often causes strange behaviour in the visibility test. • The lilac centre point should lie within the bounding box. • Visibility is computed using the viewfinder of the camera, taking into account the clipping values. Covering areas are not (yet) evaluated; if you want to suppress the visibility of an adjacent sector, a gap between the sectors larger than 0.5 units has to be created. Table 3: Mapping options Cube Cylinder Sphere Bounds to 64/128 Bounds to 128 Standard 64/128/256 From Window Table 4: Draw modes Tex Tiles Light Invisible Collision Shared Twoside ObColor Halo Opaque Add Alpha

92 LINUX MAGAZINE 5 · 2001

Fig. 4: Simple passage system

The secret is in the optics – UV mapping If you switch the current 3D window into camera view using Num+0, our test level looks rather bland – it lacks texture. Nor does our terrain have any sensible boundary. Like the old idea of a flat Earth, we fall off the edge of the world as soon as we leave a marginal sector. For this reason it is best to create a few level elements in order to add a little more spice. The simplest option is labyrinthine systems of passages and underground spaces, which require little planning from the point of view of sector organisation. We'll start with simple passage elements as shown in Figure 4. To do this, download the demofile from http://www.section5.de/game/demos/. This contains what you might call a mini-adventure in which a goal has to be reached. You should be careful though, as you could get yourself killed. Select one of the passage elements and press the / key on the numeric keypad. This switches you to LocalView, which means that only selected objects are displayed. Now press F for Face Select

cubic mapping cylindrical mapping spherical mapping Use current view for projection, adjust boundaries to 64x64 or 128x128 respectively As above, boundaries 128x128 Quadratic mapping 64x64/128x128/256x256 Use current view for projection

Textured areas Tile image for animated or combined textures Area uses dynamic lighting Cannot be seen Collision detection Share vertex colours Double-sided area Use object colour (material) Halos, always turned towards the camera Covering texture Adding texture (halos) Alpha texture (water, pane of glass, etc.)


GAME-BLENDER

PROGRAMMING

[top] Fig. 5: UV mapping (assigning) [above] Fig. 6: The paint buttons: Draw modes [left] Fig. 7: Image window: tile mode

mode, in which UV texturing is performed. To do this, open a second window with the Image Window (Shift+[F10]). If you select the front door of the level (entrance) for instance, the UV mapping looks like Fig. 5. In Face Select mode, areas are selected with the right mouse button (cross-wire selection via B also works). The associated UV co-ordinates of the areas selected are displayed on the right in the Image Window and can be moved, scaled and rotated with the normal Blender commands. But this mapping is a tedious task, especially with multi-surface objects. Luckily, Blender offers the option of automatic mapping. Position the mouse cursor over the 3D Window (Fig. 6 left) and press U. When you do this, the options described in Table 3 will be offered. For the passage system, cube mapping with a size of 0.60 has been used throughout. Take note of the red and green edge marking of the active areas. These help in orientation. For the active areas, Draw modes (view attributes) are displayed under the paint buttons (see Fig. 6) You will normally use options selected in the picture. The ceiling light fitted at the entrance (lantern) also uses the Tiles, Twoside and Alpha options, as well as Halo and Add for the middle areas. If you want to change the Draw Modes of several areas at once, select the desired faces, select Draw Mode and then use Copy Draw Mode. This will copy the attributes of the active areas onto the selection. In the same way, Copy UV+tex copies the texture plus mapping, and Copy VertCol copies the vertex colours. Areas without any texture assigned are displayed in the texture view in a hideous pink. In this view the direction of the area normals is also relevant, which means the faces are visible only from the outer side (to which the normal is pointing). The direction of the area normals of a fairly uncomplicated or closed object can be oriented automatically by selecting the desired vertices or areas via Ctrl+N (or Shift+Ctrl+N). If this

fails, the object might possess overlapping or superfluous areas internally (as can sometimes arise with extrusion).

Textures For each area, an image can be selected or loaded into the image window using Load. When you do this, note that the dimensions of the texture must correspond to a power of two, for example 128x128 or 512x64. It won't be shown in the texture view otherwise. In the image window header further options are shown which activate tile mode for animation (see Fig. 7). Subdivision is done with the left number buttons. For an animated texture, which can also be put together rather elegantly from a sequence using the montage ImageMagick tool, activate Anim and set start and end frames with the number buttons on the right. The Cycle option has no effect for the moment. The partial image in the activated tile mode is selected by holding down Shift then clicking the left mouse button on the image. For tiled textures, such as the torch texture in our mini-adventure, the rule is that the dimension of the subdivision in tile mode (see Draw Modes) must correspond to a power of two, but not the total dimension. For a 5x5 subdivision, then, with a tile size of 32x32 this therefore gives the total quadratic dimension of the texture image of 5 x 32 = 160.

A bit of dynamics â&#x20AC;&#x201C; the physics engine The current physics engine evaluates collisions of actor-objects with areas over a sphere with a radius Size (see actor attributes in Table 1). In the case of actors such as deformed Kraken monsters, this naturally leads to a problem when it comes to collision detection. The solution to this will have to wait until Blender 2.1 (with its improved engine) appears. If we limit ourselves to a first-person shoot'em-up there is no need for us to worry too much 5 ¡ 2001 LINUX MAGAZINE 93


PROGRAMMING

GAME-BLENDER

[top] Fig. 8: Dynamic materials [above] Fig. 9: Normal forces to actors [right] Fig. 10: Bob run with various materials

about our own appearance. A spherical shape will suffice for simple prototyping. What is interesting though, is the ground and the movement of the player. In our first test for the sectors you will certainly have been bemoaning the all-too smooth movement. The reason for this lies in the fact that the value for Damp or RotDamp may be too low – which applies globally for the associated actor (see Table 1). If you increase the damp values, forward and turning movements are braked more quickly regardless of the ground. Another globally-applicable value can be found under the World Buttons: Gravitational acceleration, with the standard value of 9.81 m/s≤ is the default.

But by experimenting with various masses you will find a fault in the engine: Heavy bodies fall faster than light ones. This is due to the fact that Newtonian physics (f = m * a) has not been correctly implemented.

Ground material Each surface can be assigned a so-called dynamic material: If you use the Material button ([F5]), as well as the RGB / HSV colour choices, you'll also find a DYN option (see Fig. 8). Selecting this will reveal sliders for various parameters, whose functions we'll explain in a moment. But first here's a useful snippet of information on physics on an oblique

Table 5: Overview of the parameters of dynamic materials Fh Norm Fh in normals direction of the ground area Reflect Reflection/elasticity of the ground Fh Dist Distance of the "soft" or elastic surface from the actual area Fh Damp Damping of the soft surface (elasticity) Fh Frict Friction components parallel to the surface Fh Force Resistance force of the elastic surface Table 6: Actuator features object Apply force etc to object Constraint Restrict place/orientation to one area Ipo Play Ipo animation Camera External camera flying alongside Sound Play sound unfortunately does not yet function under Linux Property Change user-defined attribute of an object Edit Object Change, add, remove or track objects (tracking) Scene Change scene, restart or change camera 94 LINUX MAGAZINE 5 · 2001


GAME-BLENDER

plane: if a body is on a slope, it will obviously slide downwards (provided static friction is overcome). In Blender, unfortunately, static friction does not exist yet, so it is only possible to work with sliding friction, which is usually dependent on the rate of slide. We are not going to explain in detail how downward movement comes about, as we hope you remember some physics lessons. However, the key here is normal force (the force which exerts resistance to the gravitational force of a body on a surface). In Blender this resistance force is referred to as Fh. To make an elastic surface possible, this force is effective from a certain distance, namely Fh Dist, from the surface. If this distance between actor and plane reduces, a force of elasticity also acts (Fh Force). Finally, with Fh Damp the damping of the elastic resilient movement is controlled. Regardless of this, using Reflect, a hard elasticity of the surface at Fh Dist = 0.0 can be set. Often sliding on a slope is not desirable, especially in an adventure game with a walking player. For this reason the resistance force Fh can be laid in the Z direction by switching off the Fh Norm option, which cuts out the downwards movement – see Fig. 9, left. In the case on the right, the Fh Rot option for the actor has been activated, whereby it orients itself to the plane. You'll find another demofile, bob.blend, at http://www.section5.de/game/demos/. This shows a bobsled run. It has been assigned several different materials, each with different friction forces Fh Frict – see the shaded image (by Z) in Fig. 10: yellow means Fh Norm is switched off, high Fh Frict. Green means Fh Norm on, low Fh Frict and blue means average Fh Frict. Play around a bit with the dynamics. Also try switching into camera view with Num+0 and show textures by using Alt+Z.

Interactivity – GamePlay Let's get back to our adventure. Perhaps you have already discovered the switch in one of the back passages, or even solved the puzzle already. As well as the simple, pre-applied SCA actions such as moving objects by forces, animations and other things can be played back using an IPO curve. You will find additional features in the short overview in Table 6. Let's examine the example of a switch in the adventure. When the player stands close enough to the switch and presses the "operate" key, an animation of the switch should be played and the action should be triggered (in this case the light switching on). To do this, you must be able to assign status to an object. This is achieved by means of self-defined property attributes. With the real time buttons ([F8]) in Fig. 11, a self-defined attribute can be added using ADD property; enter type, name and initial value in the corresponding fields. Property-attributes are also used to define certain object classes, for example bad, good, etc. Let's look at the switch in more detail: Select the

PROGRAMMING

switch object – this gives an SCA combination as in Fig. 11. Note the property attribute called on. The D ("debug") means that in wireframe mode the value is displayed in the 3D window. Let's follow the signal paths: When E is pressed and the Near condition is met, an Ipo animation is played with the option PingPong, which means that if tripped again the switch will reset itself. The property attribute on is also set to the value 1. This activates an animation for the lamp Lamp.004. Switching on lamps unfortunately does not yet occur via Energy-IpoCurve. The near check functions as follows: If an object with the property attribute player comes nearer than a distance of Dist (2.20) this condition is met. If it moves away further than the Reset distance (2.30) the condition is reset. Check to see if the player really does have the property player, and test the near check in the wire mesh view. When the near event is triggered, the switch lights up in blue. The switch object can be more easily achieved with Collision-Sensor. When playing our mini-adventure, you will already have discovered which objects have interactivity, and how the portcullis can be opened. Take a look at the associated SCAs at your leisure.

Fig. 11: Switch concatenation

Let there be light The correct lighting of a scene is really the key to a good atmosphere. This is difficult to achieve within the game engine, since as yet not all light sources react exactly as they do in the rendering part. Also, you have to activate the Light option for each area, which might have the effect of slowing down the view. So, if dynamic lighting is not absolutely necessary, lighting conditions can be simulated by vertex colours. To do this, position the light sources as usual, select the desired mesh object and, under the edit buttons, use Vertcol Make. This will transfer the lighting conditions as vertex colours onto the object, which can be checked in the vertex paint mode (V). This means that additional shade effects or colourings can be added by reprocessing with the paintbrush (see also paint buttons). Reprocessing in vertex paint mode is usually necessary to make the colour shadings between the areas slighlty more subtle. Blender pros might also like to make use of the radiosity method to generate a realistic lighting model. But if you do, bear in mind that existing UV-texturing gets lost during the radiosity process in the current 5 · 2001 LINUX MAGAZINE 95


PROGRAMMING

GAME-BLENDER

version (2.04) of Blender. Also, if the areas have too high a level of subdivision in the radiosity resolution, a level may well look optically perfect, but from the point of view of speed it can easily become unplayable. For dynamic lighting you must, as explained above, activate the light option for the corresponding areas. The rule here is that only lamps that are in the same layer as the mesh object contribute to the lighting. But previously only lamps of the type Lamp, Spot and Sun functioned as desired. In the case of the Lamp type, the sphere option has no effect yet, but better light attenuation can be achieved by increasing the value for Quad1, which controls the, physically more correct, quadratic attenuation of the intensity of a point light source.

Tips and tricks

The author Martin Strubel has been an enthusiastic Blender fan for two years and is currently developing games environments for NaN.

Whew! If you've followed us this far you must be eager to create your own level by now. Before you do though, keep the following tips in mind: • Number of polygons: Always keep the number of polygons as low as possible. For characters in particular you should not need more than 500 faces. The number of vertices or faces of an object or a scene can be read from the status line (normally top right in the window), e.g. Ve: 287, Fa: 458. For an object, switch into LocalView using Num-[/]. If you want to risk a more complex game, subdivide the Important key combinations RealTime P Esc Spacebar View Num+0 Ctrl+Num+0 Z Shift+Z Alt+Z Modelling (Edit mode) B, B twice E P Ctrl Ctrl+N General object processing G/S/R Shift+D Alt+D Ctrl+J Ctrl+P Texturing, colours F U V Shift+K

96 LINUX MAGAZINE 5 · 2001

sector groups into scenes, which should not contain more than 5000-8000 polygons in total (depending on the graphics card used). • Modelling: You can safely model and texture a level as a whole within an object, and later split it into individual objects in edit mode with P – the texturing will not get lost. The same applies for merging objects using Ctrl+J. What counts most when modelling is the direction of the area normals for collision and visibility, otherwise your player might fall through the floor. • Texture: Keep the textures in as small a format as possible. Texture-Mipmapping (automatic scaling/filtering) will be used only in later versions. • Clipping/Popping: If your game is played in an outdoor environment (countryside, motor racing, etc.), an unwanted side-effect called popping (a sector appearing suddenly) might occur depending on the camera clipping used. Eliminate this by creating some Mist under the world buttons. To do this, set the initial mist value Sta a bit lower than the clipping value set using ClipSta for the camera (the latter can be found among the edit buttons). Dist may also be fairly small. In future Blender versions, you can expect a few new features such as automatic sector optimisation, better visibility tests and a bit more automation, especially for simulation of lighting conditions. The latest news can of course be found on the Blender Web site. Of course, you can bet we'll report on any significant developments here. ■

Play mode, start game Stop Play mode, reset positions (within Play mode) As above, but retain positions Camera-view Activate selected camera Toggle wire mesh/ area view As above, with shaded area view Textured view Cross-wires-/circle selector Extrude Split selection as object (separate) Snap vertices onto grid or gradually scale/rotate Reorient normals outwards (Shift = inwards) Displace (grab), scale, rotate copy object or vertex Linked copy: copy object linked Merge objects (join) Make Parent FaceSelect mode Automatic UV-Mapping VertexPaint colour whole object with current vertex colour


BEGINNERS

GNOMOGRAM

News and Programs around GNOME

GNOMOGRAM BY BJÖRN GANSLANDT

GNOME and GTK are getting more and more popular all the time. New features, tools and utilities for them seem to appear on an almost daily basis. If you count yourself as a GNOMEophile then read on, as the Gnomogram column is where you’ll find the latest news, info, hints and tips on these very subjects.

GNOME Foundation Board selection

The AquaOS Look

At the time of writing, the very first GNOME Foundation Board is set to be elected. This new committee will supersede the GNOME Steering Committee and, as far as possible, in a distributed project like GNOME, try to steer its future

development. The Board will also co-operate with other free projects and firms, manage funds, organise conferences and form a contact point for the press. There will be eleven GNOME Foundation Board directors in all, and they will be elected via email from members of the GNOME community. No more than four directors will be allowed to belong to any one firm. So far there have been very few surprises among the nominations, although there has been some criticism that there are too few real experts to choose from. More comprehensive information on the GNOME Foundation can be found at foundation.gnome.org/charter.html.

Installing themes More and more programs seem to support themes these days. If you’ve been on the moon for the last few years, themes basically allow you to redesign a program’s user interface to a certain extent. All this can make programs look very nice, but if every program ends up with an individual theme (and therefore its own individual Look-and-Feel) the end result will be more confusion than user-friendliness. The way around this is to get all programs to use the same theme. This has always been the case with GNOME, of course, as all its programs are based on the GTK library. It is well worth trying themes out if you’ve not done so already. The current GTK theme can be altered via the control centre using the Workstation/Select themes option. And if you don’t like any of the standard themes, you can always 98 LINUX MAGAZINE 5 · 2001


GNOMOGRAM

download some new ones. Some of the best are available at gtk.themes.org/. Once downloaded, you can install them with the install new theme option found under the above-mentioned Workstation/Select themes. It’s worth noting that a separate window manager is responsible for the design and behaviour of windows under GNOME. Consequently, the GTKtheme selected has no effect on these. GNOME is actually capable of working with many different window managers, but Sawfish, formerly Sawmill, is by far the most popular. Sawfish’s themes can be changed in the control centre under Window manager Sawfish/ Appearance. Other window managers can, incidentally, be selected using the Window manager option and then configured with Call up configuration tool for windowmanagername. Sawfish themes can easily be downloaded from sawmill.themes.org/, but then have to be manually copied to ~/.sawmill/ themes/ or /usr/share/sawmill/themes/. The latter directory is where the theme for all users is installed. For all screenshots in this article, by the way, the Sawfish theme Blue-steel and the GTK theme Coolness are used.

Gnofract 4D Gnofract 4D (gnofract4d.sourceforge.net/) is a program that renders four dimensional fractals that represent a mixture of Mandelbrot and Julia fractals. In this four dimensional system one can not only move in four directions, but also turn about six planes. The proportion of Julia or Mandelbrot fractals in the fractal displayed varies depending on the position in this system. In addition to these functions, Gnofract 4D also supports colormaps (which are, incidentally, in the same format as used by Fractint). These colour in the fractals in various ways. You can also enlarge a fractal, at least as far as computing depth allows. Apart from the normal mode, an explorer mode is also available that is strongly reminiscent of Kai’s Power Tools and allows the fractal settings to be mutated at random. A slider controls how much the settings should be mutated. All fractals generated can be stored either as a standard image file or as a set of parameters for the fractal.

BEGINNERS

GnomePM GnomePM (www.geocities.com/lordzephyroth/ gnome-pm.html) is designed to replace the Yahoo! Java Portfolio Manager, and provides the latest price information on shares in an online portfolio. Anyone who has ever tried to execute Java applets under Netscape will certainly welcome this alternative. GnomePM can manage several portfolios for which it displays the price, volume and lots of other interesting information on each individual share contained in it. Using the More Info menu option, it is also possible to load charts, headlines, valuations and other data for the shares into a standard browser. Even if you don’t know the symbol for a share, GnomePM can find it if you state the name of the company. All the data used is normally gathered from the American Yahoo! Finance site, although it is also possible to specify a different Yahoo! Host under Program/Preferences. As is often the case for such tools, all prices GnomePM gets from Yahoo are delayed, trailing the markets by 15 to 20 minutes or so. Talking of delays, GnomePM updates its data every 5 minutes by default – far too slowly for many users – but this can be changed under the Program/Preferences menu option. ■

[top] Linux IPOs versus technology blue chips [above] Gnofract 4D in explorer mode

The author Björn Ganslandt is a student and a passionate bandwidth squanderer. He can often be found at irc.gnome.org under the nickname ”Ansimorph”.

5 · 2001 LINUX MAGAZINE 99


BEGINNERS

OUT OF THE BOX

Out of the box

SOUND RESEARCH BY CHRISTIAN PERLE

There are thousands upon thousands of tools and utilities for Linux. This is great, but it makes finding the real gems rather difficult. To save you time and effort, »Out of the box« does the job for you, each month highlighting a particularly interesting or useful program that you might otherwise have overlooked. This month we’d like to introduce you to the SpiralSynth synthesiser. When Kraftwerk – one of the pioneers of electronic music – was formed, a synthesiser was still a huge and clumsy analog device overloaded with knobs and slide controls and costing tens of thousands of pounds. Synthesisers are much more compact and affordable these days, of course, and with the computing power available today it is now even possible to simulate such devices on a relatively basic PC. Indeed, this is exactly what SpiralSynth, developed in the UK by Dave Griffiths, does.

Prerequisites A graphical user interface of some form is required in order to give the SpiralSynth user the ability to change its settings and configure its options, as well as to provide a visual display of the audio signal created. SpiralSynth makes use of the FLTK Library for this purpose, so before you do anything else you’ll have to obtain and install this. We got our FLTK (Version 1.0.9 or higher is required) from http://www.fltk.org/ and SpiralSynth itself from

Library: A file containing a collection of useful C-functions for specific purposes. Examples include libm, which provides mathematical functions, and libXt, which contains functions for programming the X11 window system. Libraries are often shared by several programs. FLTK: The »Fast Light ToolKit« (pronounced: »Fulltick«) is a very compact library for easy programming of the X11window system. Compiling: In its source text form, a program is not usually executable by the operating system. It is only by compiling (converting) this source code that it can be turned into something that can be executed by a PC’s processor. RPM: With the »Red Hat Package Manager« software packages can be quickly and easily installed or removed. ■ 100 LINUX MAGAZINE 5 · 2001

http://www.blueammonite.f9.co.uk/SpiralSynth/. Be sure to download version 0.1.5 rather than a more current version such as 0.1.6, however. There is no functional difference between these two versions, but they do use different file formats. You’ll discover the importance of this a little later on.

Installation Once you have the two necessary components on your hard disk, it’s time to compile. FLTK needs to be compiled and installed first, the latter step requiring root privileges: tar xzf fltk-1.0.9-source.tar.gz cd fltk-1.0.9 ./configure make su (enter root-password) make install ; exit Anyone who wants to avoid compiling FLTK can install the rpm package version. To do this you need two files which can be found at ftp://rpmfind.net/ linux/Mandrakedevel/7.2beta/i586/Mandrake/RPMS /fltk-1.0.9-2mdk.i586.rpm and ftp://rpmfind.net/ linux/Mandrakedevel/7.2beta/i586/Mandrake/RPMS /fltk-devel-1.0.9-2mdk.i586.rpm. The installation of the rpm packages should be done as follows: su (enter root-password) rpm -Uvh fltk-1.0.9-2mdk.i586.rpm rpm -Uvh fltk-devel-1.0.9-2mdk.i586.rpm exit Now it’s the turn of the actual SpiralSynth program itself: tar xzf SpiralSynth-0.1.5.tar.gz cd SpiralSynth-0.1.5


OUT OF THE BOX

BEGINNERS

./configure make su ( enter root-password) make install ; exit If errors arise when compiling SpiralSynth you can try installing a pre-compiled version. The program’s author recommends http://www.blueammonite.f9.co.uk/SpiralSynth/dl oad/SpiralSynth-i386Linux-0.1.5.gz. There is actually very little you need to do in order to install this version: gunzip SpiralSynth-i386Linux-0.1.5.gz chmod 755 SpiralSynth-i386Linux-0.1.5 su (enter root password) cp SpiralSynth-i386Linux-0.1.5 U /usr/local/bin/SpiralSynth exit

Sound off! So much installation work should be rewarded. From the terminal emulator of your choice (xterm, kvt or Gnome-Terminal, for example) start the program with the command SpiralSynth &, at which point a window similar to that shown in Figure 1 should appear. The window is split into three main areas. On the left are the oscillators, on the right the mixers and effects devices and at the bottom the knobs with which stored settings (Patches) can be retrieved. There is also a graphical display of the audio signal (Scope). Each of the three basic oscillators has the same setting options: wave form (square wave, sawtooth or noise), pulse width (PW), noise generator setting (SH), Portamento (PM) and controllers to tune and adjust the modulation depth. On top of everything else, an Envelope can be adjusted for each oscillator. This determines the attack and fade-out behaviour of the signal. Using the two mixers, signals from the oscillators are linked together. As with all other settings in SpiralSynth the word here is Experiment! Nothing bad will happen. Finally, you can give a tone a »finishing touch« with the LFG (»Low Frequency Generator«), the low-pass filter and the delay effect Delay). Anyone who finds this is all too much trouble can press the Rand button in the Patch Bank area, which sets all the controls randomly. The actual triggering of the sounds occurs via the keyboard, where the rows of keys y to m and q to p are assigned as »white keys«, and the rows a to j and 2 to 0 as »black keys«. Once you have created an interesting sound, you can save it by clicking on the Save button and then selecting one of the blue shaded buttons in the Patch Bank. In the Output field, the sound produced can be saved in a WAV file by clicking on Record. Brilliant!

Fig. 1: SpiralSynth main window

Tuning SpiralSynth will create two hidden files in your home directory, in which the basic settings (.Spiralrc) and the stored patches (.SpiralPatches.bank) are located. Let’s just take a closer look at the first file. In order to do this you’ll first have to shut SpiralSynth down. Having done so, fire up your favourite text editor and point it at .Spiralrc. Not everyone has a MIDI keyboard. The WantMidi entry can be set to zero if this applies to you. The KeyMap entry contains a listing of the keyboard keys SpiralSynth uses, and can be changed if required – essential if you aren’t using a standard UK or US keyboard. Listing 1 shows an example .Spiralrc file with MIDI disabled. Listing 1:.Spiralrc with MIDI disabled. SpiralSynth resource file BufferSize = 512 Samplerate = 44100 WantMidi = 0 FilterGranularity = 50 Output = /dev/dsp Midi = /dev/midi WantRealtimeOut = 1 KeyMap = U zsxdcvgbhnjmq2w3er5t6z7ui9o0p[

Sound samples If, despite the very useful random function, you are still unable to produce any interesting sounds from SpiralSynth, all is not lost. Our coverdisc this month contains a pre-set patch bank called mypatches.bank, which you can rename as .SpiralPatches.bank and copy into your home directory. This file can also be found on the Web at http://home.tu-clausthal.de/~ incp/mypatches.bank. There shouldn’t be anything standing between you and some exciting synthesiser sound research, unless you have installed Version 0.1.6 (against our advice). This uses a binary format for the patches file that is incompatible with the format used in version 0.1.5, which is what we used to create the coverdisc file. ■

Portamento: With this effect the pitch selected is not attained immediately, but is »drawn out« from the previous sound. WAV: A common and usually uncompressed audio format, first implemented in Windows. MIDI: »Musical Instruments Digital Interface«, a standard for controlling electronic musical instruments. ■

5 · 2001 LINUX MAGAZINE 101


BEGINNERS

DESKTOPIA

Jo’s alternative desktop

DESKTOPFILE-MANAGER BY JO MOSKALEWSKI

Only you can decide how your Linux desktop looks. With desktopia we regularly take you with us on a journey into the land of window managers and desktop environments, presenting the useful and the colourful, viewers and pretty toys. Now that various window managers have been presented here, it’s time to add to these with a feature that is important to many people: Desktop icons.

Window-Manager: The main task of this is to equip applications with frames and then to manage these on the desktop. They sit on an active X-server, which provides the graphical output. KDE and GNOME are so-called environments, which take care of all sorts of more or less interchangeable ingredients of the window manager. BASH script: BASH is the standard text console under Linux. You can create so-called scripts for this, whose content will be interpreted as a list of instructions and executed line by line. ■

You can certainly use the icon functions of these environments even without a started environment – provided KDE or GNOME in addition to the implemented Window-Manager are already on your hard disk. The KDE icons appear after the first retrieval of the file manager kfm. This alone is not the end of it – KDE has a manager of its own, which extends these icons by the corresponding configuration menu: krootwm. The action of this manager is unfortunately unnoticed by most people, because it needs both the middle and the right hand mouse button, which in general, a window manager can use at least equally efficiently.

Second attempt Just as in KDE, the file manager in GNOME also holds main responsibility for the function of the desktop icons, called up via gmc —nowindows. But here again, one soon comes up against the limitations of this variant (which depend upon the window manager being used). The right mouse button, together with a GNOMEcompatible window manager, is necessary to manage the icons on the desktop. And so in both cases, it is usually only icons that are already configured which can be clicked on. The considerable trouble of adding new ones cannot be justified. And yet, this is where your own attempts can be successful.

102 LINUX MAGAZINE 5 · 2001

All good things come in threes Following tradition, here is one more file manager, which is dedicated to this task: DFM, the ”Desktop File Manager”. This is usually already included on CDs from distributors. But anyone who would like a more up-to-date version can find it at http://dfm.online.de/dfm.html or on the attached coverdisc. DFM was not developed for a specific environment such as KDE or GNOME, which is why it manages to solve the problem of peaceful co-existence with a window manager much more elegantly. Instead of wanting to take complete possession of a mouse button, this one works with one or more transparent windows, in the defined areas of which any window manager assigns mouse actions to the application (and thus to our DFM) instead of itself.

The little manpage Regardless of the ”big” Manpage (man dfm) the basics of DFM are a piece of cake. It answers to the command dfm, and when this is called up for the first time a standard configuration is undertaken. From now on a double click on an icon is rewarded by the start of the respective program. Pressing the right mouse button once, brings up the context menu (see also Figure 1). Opening a folder will immediately take you back to the file manager. As one would expect, this supports Drag and Drop, (the picking up and dropping of icons). Those who don’t like the yellow


DESKTOPIA

BEGINNERS

[Left] Fig. 1: DFM and its basic configuration [Right] Fig. 2: File manager with desktop icons

folder can simply replace it with a more attractive one. The nice thing about this is that DFM does not need icons of a specific size. Whether 16x16 pixel or 60x60 pixel, it still co-operates (even if no optical gain can be expected with such differences). Not so nice, on the other hand, is that all the graphics used in DFM have to be present in the ”xpm” format. But the conversion of other graphics into this format should not pose too high a hurdle – the recently introduced packet ”ImageMagick” deals with this with a simple convert graphic.jpg graphic.xpm.

Forever and ever Now that the program has emerged from its chrysalis and is suitable for everyday use, it should now grace the desktop permanently. Now let’s rig up, following the best example of KDE, what amounts to almost a new window manager. It consists of a simple BASH script, in which we will first set the environment variable, then start DFM, and only then allow a window manager to come into play: #!/bin/sh LC_ALL=”de_DE”; export LC_ALL dfm & my_windowmanager Stored under dfmdesktop , this file must still be marked as executable – a chmod 777 dfmdesktop covers that satisfactorily. The ideal location for home mades of this type is the directory /usr/local/bin, into which the ”User” root ought now to move the file:

mv dfmdesktop /usr/local/bin/. This simple script can be called up instead of the window manager from now on. Our window manager will in future appear, together with icons on the desktop.

Gone fishing ... The catch? Of course there’s a catch. Drag and Drop is certainly very nice, but of course that does not work here. On the other hand, it is possible, from file manager, to drag a file onto the desktop, or a text file onto an editor icon (or an HTML file onto a browser icon), to be opened immediately. Some people will be amazed to discover that their window manager does not react in the usual way to mouse clicks in the open desktop. The remedy for this is to deactivate the desktop context menu – found not in the options, but under the menu item DFM for X11 immediately above the options. To save this setting, it has to be explicitly saved again in the same menu. Anyone who has, (because of high screen resolution) reset the X-server to 100dpi characters, will not find the configuration interface so tidy as the one shown in Figure 1. The texts no longer fit in because of the font size and have to be estimated. But this should neither cause any problem nor interfere with the implementation of the program. ■ jo@planet ~> su Password: root@planet:~> tar -xvzf dfm-0.99.7.tar.gz root@planet:~> cd dfm root@planet:~/dfm> ./configure root@planet:~/dfm> make root@planet:~/dfm> make install root@planet:~/dfm> logout jo@planet ~>

dfm 0.99.7 LinuxMagazin/desktopia

About the author Jo Moskalewski ekes out his living as a tiling foreman and stumbled across computers by way of a miraculous conception. When he is not sizing up his next loudspeaker cabinets, he is either sitting around with friends, or accepting constructive criticism at the editorial address redaktion@linuxmagazin.de .

DFM for home-workers If DFM cannot be found on your distribution’s CD as a finished packet (or you would prefer the latest version) you will have to make do with the tar.gz archive attached to this magazine. But this too, is easily installed: In addition to the packets usually required for compiling (make, gcc, xdevel) the Devel-packets of GTK+ and libXpm are required. All are included with the usual distributions. If these are already installed, the archive is unpacked as ”User” root, at which point a ./configure checks the system and a so-called ”Makefile” is created. With the help of this the tool make then compiles a program which is ready to run. All that remains to be done is to copy (install) the newly-created files made during compilation, and to set the necessary file rights – which a make install does for us:

5 · 2001 LINUX MAGAZINE 103


BEGINNERS

PROGRAMMING CORNER

Part 1: Principles of BASH

HELLO WORLD BY MIRKO DÖLLE

Have you ever sat in front of your computer and been irritated by having to perform some annoyingly repetitive task? Many such tasks can be automated by writing a simple program, and in the first feature we’ll give you just an introducton into the world of programming.

Many of you will be asking yourselves why you should even have to start writing programs. After all, there seems to be a tool or utility for Linux that does just about anything you can imagine. The problem is, of course, that while lots of programs and utilities work fine in theory, some are just too complicated or don’t meet your exact needs. Learning to program will solve these problems by allowing you to create customised tools and utilities. These can be created either from scratch or by modifying something someone else has written. Since this feature is aimed at beginners, we’ll stick to the very basics and limit ourselves to quite simple programs. In doing so, our aim is to give you enough of a glimpse into the wonderful world of programming to encourage you to delve much deeper.

BASH programming language The Bourne-Again Shell – BASH for short, has established itself as the standard shell for most Linux distributions, so you’ll almost certainly find it ready and waiting for you on your Linux system. But BASH is more than just a command line for starting programs. In fact, it is almost a complete 104 LINUX MAGAZINE 5 · 2001

programming language. For this reason we’ll use BASH as the programming basis of this feature. We’ll also touch on one or two other useful programs in passing. And while the examples we’ll be giving are BASH-specific, the programming techniques have been kept as universal as possible, helping you get to grips with other languages should you want to progress to more advanced programming tools and techniques.

First steps BASH programs are also called ”scripts”. Scripts should always begin by describing the shell to be used, then go on to list commands to be executed (which you could also enter manually outside the program). Traditionally, the first program new programmers write is one that prints ”Hello world” on screen. Here’s how a BASH script to do just that (twice) looks: #!/bin/bash echo Hello world echo Hello world The first line is strictly speaking a commentary line, since it begins with a hash ”#”. Generally the rule is


PROGRAMMING CORNER

BEGINNERS

Version conflict The examples shown here in this feature all relate to Version 2 of BASH, and are at best only partly applicable with the old Version 1. Although Version 2 has now been in use for over two years and has so far shown no significant problems, some distribution manufacturers, such as Red Hat and Caldera, are still installing the old Version 1.4 under /bin/bash as well as Version 2 under /bin/bash2. For this reason, the first thing you must do if you have any problems with entering our code examples is to check which version you are addressing via /bin/bash by entering the following command: /bin/bash -c ’echo $BASH_VERSION’ If the result is Version 1, you must hunt down Version 2 – it will probably be lying around in bin and be called bash2. Enter the following command to find out: ls /bin/bash2 If ls reports that it is unable to find /bin/bash2, you should look on the installation CD of your distribution and if necessary install the package from there. If the ls command does find /bin/bash2, then when entering any of our program examples you must then always use /bin/bash2 instead of /bin/bash. As an alternative, you could completely convert your system to BASH 2. To do so, first copy /bin/bash into /bin/bash1. Next copy /bin/bash2 to /bin/bash. In fact renaming is also sufficient, but then programs which use /bin/bash2 would no longer function, which is why /bin/bash2 should be retained. The real problem is that you cannot overwrite or move a file which is in use – and as you are using normal /bin/bash as root, before you can follow our instructions you must first release /bin/bash using a handy little trick. First log in as root and again ensure that there really is a /bin/bash2. If there isn’t then you must not perform the following steps under any circumstances unless you want to run the risk of never being able to log in again as root! Whatever the case, though, you should launch an (extra) text console and log in there as root. We will refer to this console for the sake of simplicity as ”emergency console”. At first you won’t need to enter anything on this emergency console, so you should now change back to your (normal) work console. Here we need to alter the default shell for the user root using the following command: chsh -s /bin/bash2 root Next, switch to yet another text console and log in there again as root. If everything has gone well, echo $BASH_VERSION will now report that it is Version 2 on this console. If you are unable to log in, something has gone wrong and you absolutely must now restore the former status. To do so, change to the emergency console and enter: chsh -s /bin/bash root This will set the log-in shell back to the initial value. If the new log-in worked, treat this as a new emergency console and log out of the old one and out of all other consoles. It may also become necessary to close KDE or GNOME. All that should now remain is the new emergency console. The next step is to convert from BASH 1 to BASH 2. To do this, log in again to a new console as root and copy bash to bash1 and then bash2 to bash as we outlined when we started using the following commands: cp /bin/bash /bin/bash1 cp /bin/bash2 /bin/bash The last step is then to reset the log-in shell from root : chsh -l /bin/bash root If you can log in again on another console as root and see Version 2 of BASH displayed, the conversion has worked, and Version 2 is now your standard shell. Congratulations!

5 · 2001 LINUX MAGAZINE 105


BEGINNERS

PROGRAMMING CORNER

Meta character: Character interpreted in a special way. Escape character: Cancels the effects of meta-, controland escape-characters. Quotes: Double quotes, single quotes and reverted single quotes. These ensure that most meta and control characters are no longer interpreted as such. These must always be used in pairs. Script: Generally used to refer to shell and sometimes also Perl programs. The script is always a text file that can be displayed directly. ■

that only comments should stand between the hash sign and the end of that line. You can have comment lines without any commentary if you wish – to break apart code sections, for example – but blank lines can also be used for this purpose and are a better choice. The first line in our example tells you which program this script should be processed with (BASH in this case) though it could be Perl or TCL/TK for instance, which is why this line is so important. The next two lines both cause ”Hello world” to be outputed onto the screen, followed by a line break.

Meta-characters and Escapes Despite the variation in the text following the echo command, the result of BASH processing lines two and three are identical. This is because BASH interprets what are known as control symbols (also known as meta-characters and control characters), in a special way. The spaces character is one such control symbol, and is used as a separator between parameters of a command, where a sequence of space characters is interpreded as one parameter separation. The command in question here is echo, which simply prints all parameters (the things following the echo command) in sequence, each one separated by a space. In our example both line two and line three therefore have the same effect. echo simply sees two parameters ”Hello” and ”world”.

Table 1: Control- and special characters in BASH Character Function Space Separator between program parameters Tabulator (tab) Separator between program parameters Enter (newline) Enter command \ (backslash) Escape character | (pipe) Concatenation of input/output of several programs & (ampersand) Start program as background process, input-/output redirect ; (semicolon) Separator between two program calls ( ) (braces) Grouping, calculation < (input redirect) > (output redirect) || (logical or) Link two commands with ”OR” && (logical and) Link two commands with ”AND” ;; End of a case Table 2: BASH Operators Operator Assignment Operator +, -, *, / +=, -=, *=, /= % %= ! && || ==, != <=, >=, <, > ~ & |

&= |= 106 LINUX MAGAZINE 5 · 2001

Function basic types of arithmetic Remainder from whole number division (5%2=1) Logic negation (!1 = 0, !0 = 1) Logic AND (a and b) Logic OR (a or b) equality, inequality comparison larger/smaller Binary inversion (~1101 = 0010) Binary AND (1011 & 1101 = 1001) Binary OR (1100 | 0101 = 1101)

There are quite a few of these special characters, and the most important ones are listed in Table 1. To get more than one space between ”Hello” and ”world” we have to use another special character, escape. This character informs BASH that the next character isn’t a special character – a true space and not a separator between parameters in our case. In BASH, and many other tools and languages, the escape symbol is represented by the backslash ”\” character. So, to print ”Hello”, three spaces, then ”world” we’d have to use the following command. echo Hello\ \ \ world Of course there will be times when we actually want to print a backslash. To do so, we have to ”escape the escape” by typing ”\\”. Alternatively, you can use single or double quotes to demote spaces and most other special characters into simple text, such as in the following example: echo "Hello world" The use of quotes in this way is, however, best employed infrequently. They are far more effective when used for other purposes, as we’ll see later on.

Variables It would be boring to only be able to print fixed, unchanging text. This is where things known as variables come into the equation. These are simply named containers for text or numbers. Unlike more sophisticated languages, BASH does not differentiate between different types of variable, so you can store whole numbers (in principle decimal numbers are not allowed), letters, words or whole sentences in a BASH variable without first having to tell it which of these you want the variable to store. What’s more – again unlike some other programming languages – a variable does not have to be declared (”registered”) before you can use it; it simply comes into existence automatically as the result of the first value assignment. Something well worth watching out for is the fact that variable names are case sensitive. In the following example we’ll give the same variable five completely different values using the ”=” operator, whose use should be pretty much self-evident: #!/bin/bash var=2 var=a var=Hello var=Hello\ world var="Hello world" To find out a variable’s contents (also known as its value), you simply use its name preceded by a dollar symbol – ”$” (another one of these special characters). You can also optionally enclose the name of the variable in curly brackets. This variant is used when a letter immediately follows the variable


PROGRAMMING CORNER

name. To better understand what we’re talking about here, have a look at the following example: Cost=100 echo $Cost Euros echo ${Cost}Euros The second line would print ”100 Euros”, while the third prints ”100Euros” without a space between the amount and the unit of currency. Without curly brackets in the third line, we would have got the content of the (non-existent) variable $CostEuros. Non-existent variables always have no value, they are simply empty, and echo $CostEuros would therefore print out a blank line. BASH, by the way, replaces the variable names at almost every point by the value of the variable, a process called variable resolution. The only exception to this rule occurs when inverted commas ” ‘ ” are used. Anything between these is never replaced with a value. To use the name of a variable, including the dollar sign, for printing (or for other functions), we can also escape the ”$” as an alternative. Here are some examples of what we mean: Cost=100 Cost="$Cost Euros" echo Content of the variable ’$Cost’: $Cost echo Content of the variable \$Cost: $Cost Note that in the second line we have assigned Cost a character string in which the variable itself occurs. In this case, BASH first evaluates the part to the right of the equals sign, therefore substituting ”100” for $Cost. To BASH, then, the right hand side of the equals sign is therefore ”100 Euros”. Once the right-hand side of the equation has been evaluated (to form what’s known as the r-value), it then assigns it to the variable on the left-hand side (the l-value). Don’t worry if you don’t understand this yet, though, as we’ll be coming back to this in another example later on.

Arithmetical operations and zero-function Assigning values to variables is all very well, but they only come into their own when manipulated, compared or used in computations. BASH provides quite a few operators to do this, including arithmetic, logic and binary ones. When using these, though, with the exception of logical operators (which can be used with variables containing absolutely anything) you must make sure that you work with variables containing only numbers. Remember, BASH can store both text and numbers in a variable. It is your job to make sure you aren’t trying to calculate with letters at any time. To understand this better, take another look at the first two lines of our last example. In the first line there was still just a number in Cost (100), but in the second line we added on ”Euros”. In other

BEGINNERS

words the Cost variable has suddenly turned into a character string rather than a number. This means we can no longer do calculations with the Cost variable. If you try to do so, BASH will abort your program with an error message. There are two notations for calculations; the instruction is either enclosed in square brackets or in double rounded brackets. In both cases it is preceded by a dollar sign. Both notations can be seen in the next example:

r-value: The result of the instructions to the right of the equals sign l-value: Variable to the left of the equals sign, in which the rvalue is stored ■

Value=$[$Value+1] Value=$(($Value+1)) : $[Value+=1] : $((Value+=1)) In the end all four lines do exactly the same thing, which is to increase the content of Value by one. Lines one and two are the easiest to understand here, as usual the R-Value is evaluated first and then assigned to the L-Value. Lines three and four work on the same principle, because the operation ”a+=b” is defined as ”a=$a+b” – internally, BASH converts the short notation into the full one. What is unusual here is the colon before the calculation instruction. This is a zero function, a command that does nothing. What matters to us here is that BASH evaluates the parameter after it in exactly the same way as it would when calling up any other command, such as echo, thus calculating the result for us. The colon is necessary because the calculation operations are always replaced by the result, namely $Value, and without the colon this would be interpreted as a command for BASH, which it would then try to call up and undoubtedly fail. As we’ve already said, as well as basic types of arithmetic, BASH also offers logic and binary operators, though these are only used rarely. Whatever operators are used, though, additional assignment operators are usually also available – such as the ”+=” we used in our example and which can make reading programs a great deal simpler. You can find an overview of the operators in Table 2.

Until next time This brings us to the end of the first installment; next time we’ll tell you about processing character strings, introduce you to arrays and explain their use by means of a few more examples. ■ Quick glossary echo : (colon)

$[..] $((..))

Outputs all parameters separated from each other by a space. Zero-function, has no direct effect. Is sometimes used for arithmetical operations or variable manipulations. The actual operations are stated as parameters of the ”:” function. Calculates the arithmetical expression in brackets and delivers the result. Calculates the arithmetical expression in brackets and delivers the result. 5 · 2001 LINUX MAGAZINE 107


BEGINNERS

KDE THEMES

KDE Themes Workshop – Part 3++

PLAYING DRESS UP BY HAGEN HOEPFNER

Most of us know that KDE has the ability to alter its appearance very rapidly by means of so-called ‘themes’. This series describes how to create your own.

This workshop was conceived as a three part series. I now find myself compelled to add a fourth. The notation 3++ is appropriate. This last part takes over where the third one left off – with manual work. In particular, it describes how to port icon themes from KDE 1.1.2 to KDE 2 without having to alter all the icons by hand.

Porting icons by machine Fig. 1: Icon 32x32 in size

Fig. 2: Icon 32x32 in size enlarged to 48x48

A few things have been happening at KDE. The new version uses .xpm, instead of .png files as standard for the icons. It no longer stores these by crudely shoving them all into one directory, but into several. Each directory has five subdirectories. The icons must already be classified if an icon set is to be altered via dialog. To do this, we must firstly use mkdir eclipse2

108 LINUX MAGAZINE 5 · 2001

to make a directory with the name of the icon theme. After that we make subdirectories, the names of which reflect the size of the icons. KDE 2 standard icon sizes are 16x16, 22x22, 32x32 and 48x48. As our icons are 32x32 we will now create the directories for icons of this size or smaller (enlarging them would effect their quality). mkdir eclipse2/16x16 mkdir eclipse2/22x22 mkdir eclipse2/32x32 In these subdirectories, which classify the icons according to their use, additional subdirectories should now be made. The five classes are: • actions • apps • devices • filesystems • mimetypes


KDE THEMES

That’s the long and the short of it. Here are the commands: mkdir mkdir mkdir mkdir mkdir

eclipse2/GR÷flE/actions eclipse2/GR÷flE/apps eclipse2/GR÷flE/devices eclipse2/GR÷flE/filesystems eclipse2/GR÷flE/mimetypes

Now, to convert our .xpm files into .png files we will need a temporary directory. We create this with mkdir xpm2png_temp Listing 1: Script to convert from .xpm- into .png-files # convert_it for XPM_FILE in "$@"; do PNG_FILE=$(basename $XPM_FILE .xpm) convert "$XPM_FILE" "$PNG_FILE".png; done

BEGINNERS

The directory name in this case can be anything you like. That completes the basic framework of the icon theme. Next, we copy, using copy ~/eclipse/*.xpm xpm2png_temp Table 1: Differing file names Filename in KDE 1.1.2 applications_package.png editors_package.png games_package.png graphics_package.png multimedia_package.png network_package.png settings_package.png system_package.png utilities_package.png kfm_fulltrash.png kfm_trash.png

Filename in KDE 2 package_applications.png package_editors.png package_games.png package_graphics.png package_multimedia.png package_network.png package_settings.png package_system.png package_utilities.png trashcan_full.png trashcan_empty.png

Listing 2: Script for classifying icons #!/bin/sh #classify it DEFAULT_KDE_ICON_TREE=/opt/kde2/share/icons/hicolor THEME_PATH=../eclipse2 for I in "$@"; do convert $I -geometry 16x16 __TEMP_FILE16.png convert $I -geometry 22x22 __TEMP_FILE22.png DEFAULT_FILE="$DEFAULT_KDE_ICON_TREE/32x32/actions/$I" if test -f $DEFAULT_FILE; then cp $I $THEME_PATH/32x32/actions/ 2> /dev/null cp __TEMP_FILE16.png $THEME_PATH/16x16/actions/$I 2> /dev/null cp __TEMP_FILE22.png $THEME_PATH/22x22/actions/$I 2> /dev/null else DEFAULT_FILE="$DEFAULT_KDE_ICON_TREE/32x32/apps/$I" if test -f $DEFAULT_FILE; then cp $I $THEME_PATH/32x32/apps/ 2> /dev/null cp __TEMP_FILE16.png $THEME_PATH/16x16/apps/$I 2> /dev/null cp __TEMP_FILE22.png $THEME_PATH/22x22/apps/$I 2> /dev/null else DEFAULT_FILE="$DEFAULT_KDE_ICON_TREE/32x32/devices/$I" if test -f $DEFAULT_FILE; then cp $I $THEME_PATH/32x32/devices/ 2> /dev/null cp __TEMP_FILE16.png $THEME_PATH/16x16/devices/$I 2> /dev/null cp __TEMP_FILE22.png $THEME_PATH/22x22/devices/$I 2> /dev/null else DEFAULT_FILE="$DEFAULT_KDE_ICON_TREE/32x32/filesystems/$I" if test -f $DEFAULT_FILE; then cp $I $THEME_PATH/32x32/filesystems/ 2> /dev/null cp __TEMP_FILE16.png $THEME_PATH/16x16/filesystems/$I 2> /dev/null cp __TEMP_FILE22.png $THEME_PATH/22x22/filesystems/$I 2> /dev/null else DEFAULT_FILE="$DEFAULT_KDE_ICON_TREE/32x32/mimetypes/$I" if test -f $DEFAULT_FILE; then cp $I $THEME_PATH/32x32/mimetypes/ 2> /dev/null cp __TEMP_FILE16.png $THEME_PATH/16x16/mimetypes/$I 2> /dev/null cp __TEMP_FILE22.png $THEME_PATH/22x22/mimetypes/$I 2> /dev/null else echo "File could not be classified: $I"; fi fi fi fi fi done 5 · 2001 LINUX MAGAZINE 109


BEGINNERS

KDE THEMES

the old files into the temporary directory and change, using

chmod +x classify_it

cd xpm2png_temp

has been released for execution, the script is started with

to this. The actual conversion functions almost ridiculously simply. We merely write a little script, using our favourite editor (convert_it) and release this for execution with Listings from the article LinuxMagazine/kthemes/

./classify_it *.png

Once Listing 2 has been typed, stored in the file classify_it and, using

After that, the names of the files are displayed which could not be classified in any of the above five classes. These are mainly icons which either belong to an application not yet known to KDE 2 or do not in fact fit into these classes (window icons etc). The script in Listing 2 also ensures that the icons, correspondingly reduced in size, are sorted into the 16x16 and the 22x22 subdirectory. The scripts may not be resolved in the most elegant way. But they do work. So we now have our icons in the necessarily structured directory tree. All that remains is to create the configuration file index.desktop in the eclipse2-directory. This has a similar syntax to eclipse.themerc and is shown in Listing 3. The entries were obtained by re-engineering the ”penguin” theme by Ilona Melis (listed as item 4 below). They are consequently not based on ”substantiated” research. The individual parameters must therefore not be speculated upon. The ambitious reader should investigate further.

Listing 3: index.desktop [KDE Icon Theme] Name=Eclipse Description=Eclipse Icons by Hagen Hoepfner DisplayDepth=32 Example=exec Inherits=hicolor DesktopDefault=32 DesktopSizes=16,22,32 SmallDefault=16 SmallSizes=16 Directories=16x16/apps,16x16/actions,16x16/dU evices,16x16/filesystems,16x16/mimetypes,22xU 22/apps,22x22/actions,22x22/devices,22x22/fiU lesystems,22x22/mimetypes,32x32/apps,32x32/acU tions,32x32/devices,32x32/filesystems,32x32U/ mimetypes, [16x16/apps] SIZE=16 Context=Applications Type=Fixed [16x16/actions] SIZE=16 Context=Actionsd Type=Fixed [16x16/devices] SIZE=16 Context=Devices Type=Fixed [16x16/filesystems] SIZE=16 Context=FileSystems Type=Fixed [16x16/mimetypes] SIZE=16 Context=MimeTypes Type=Fixed [22x22/apps] SIZE=22

Context=Applications Type=Fixed [22x22/actions] SIZE=22 Context=Actionsd Type=Fixed [22x22/devices] SIZE=22 Context=Devices Type=Fixed [22x22/filesystems] SIZE=22 Context=FileSystems Type=Fixed [22x22/mimetypes] SIZE=22 Context=MimeTypes Type=Fixed [32x32/apps] Size=32 Context=Applications Type=Fixed [32x32/actions] Size=32 Context=Actionsd Type=Fixed [32x32/devices] Size=32 Context=Devices Type=Fixed [32x32/filesystems] Size=32 Context=FileSystems Type=Fixed [32x32/mimetypes] Size=32 Context=MimeTypes Type=Fixed

chmod +x convert_it and call it up with ./convert_it *.xpm After a short time all the .xpm files have been converted into .pngs. We can also leave the classification of the files to a script (cf. Listing 2). This gleans the necessary information from the standard icon directory of KDE 2 and classifies our icons. The prerequisite for this is that we are still in the temporary directory when we do it. Take care here, as a few file names have changed. The differences in Table 1 have been found by testing. These need to be corrected before calling up the classify_it scripts by mv old_filename new_filename

110 LINUX MAGAZINE 5 · 2001


KDE THEMES

Using the icons Once the icons have been converted and classified, they have to be copied to the right place and then activated. The first is done via a simple copy command. As we are indeed still in the theme directory, we first have to leave this with

BEGINNERS

After the dialog has been called up, the icon theme to be used is selected by a left click on the name and confirmed by a left click on the OK button. ■

cd .. Then we send it with cp eclipse2/ ~/.kde2/share/icons/ -rf

The author

to where it belongs. Changing an icon theme in KDE 2 works on a dialog basis. The corresponding dialog is in the start menu under Settings/Display/Design/Symbols and is shown in Figure 3.

Hagen Hoepfner studies computer science at Otto-vonGuericke-Universit‰t in Magdeburg.

Info [1] KDE Homepage:http://www.kde.org [2] The example of an icon theme "eclipse2": http://kde.themes.org/themes.phtml?cattype=inc&disptype=trad&numthemes=0&boxhide=1&the metxt=eclipse [3] KDE Themes Homepage: http://kde.themes.org [4] penguin theme : http://www.ilicon.com ■

Fig. 3: Changing icon themes under KDE 2

5 · 2001 LINUX MAGAZINE 111


BEGINNERS

KORNER

K-tools

DIFFERENT VIEWS BY STEFANIE TEUFEL

This column is where, every month, we tell you about particularly useful KDE tools of all kinds – from essential problem solvers to things that just make life more interesting.

FTP: Abbreviation for "File Transfer Protocol", a protocol governing the transfer of data in the Internet. Once you have logged onto a remote host computer, FTP allows comprehensive file management; depending on your access rights. Files and directories can be transferred, deleted, copied or moved. ■

There are now plenty of graphical FTP clients for Linux. What makes KBear, our K-tool of the month, different from the rest is its somewhat unusual appearance and basic design, which allows you to simultaneously browse through several FTP-sites. Before we go any further, we have to warn you of a slight catch involved in running KBear – it requires KDE 2.0 (or at least a Beta version of it) and Qt-2.2.0 in order to run smoothly. This means that the traditionalists among you, who still don't want to be parted from your KDE 1.1.2, can't try it out. Those of you who are more open-minded will find the very latest version of the program at http://www.kbear.org/.

On your marks, download, go... Once you've downloaded and installed the program, use kbear & in the terminal emulation window of your choice to get started. Doing so will start to reveal that Kbear isn't quite like an

112 LINUX MAGAZINE 5 · 2001

ordinary FTP client, and launches a configuration wizard with which you can define the program's appearance – see Figure 1. You can happily leave everything at its default setting by just clicking on the Next button until the final screen, at which point you'll need to click on Finish. If you aren't in a hurry, exploring the options is well worth the effort. However, the wizard itself and any of its component pages can be called up again later via the Settings--> General Settings or Settings-->Run Wizard... menu items. A quick glance at Figure 2 seems to indicate that Kbear doesn't split its main display window in two as other FTP clients normally do (with the home directory on one side and the window for the FTP server on the other side). Your home directory is actually shown here, it’s just that the rest of the space is currently free and waiting to display the various FTP servers which you will be linking to once you contact them.


KORNER

Fig. 1: The Kbear wizard says hello

BEGINNERS

Fig. 2: A little unfamiliar

Fig. 3: Which server should it be?

Contacted What's the use of the smartest FTP client if it has no connection to an FTP server? Not much. This is why Kbear offers you two different options for making contact with a server. The simplest to use is activated by a click on the FTP-->Quick Connect option (also accessible with a Ctrl-N key combination). This displays a dialog box into which you can enter the address of the desired server (see Figure 3). If this is a public FTP server you'll need to activate the Anonymous Login option in order to be able to log in. In any case, the next step is to click on the Connect button (always assuming you are now online). The Kbear will then make the connection and off you'll go. Do note though, that sometimes a public server will ask for a password, even though you selected the Anonymous Login option. If this happens, enter your own email address in the dialog box which pops open – the problem will be solved. Incidentally, the little box labelled Save to Sitemanager in the dialog box refers to the second of the two connection options – Sitemanager, a sort of FTP phone book. Sitemanager, which can be accessed directly through FTP-->Open Sitemanager or the key combination Ctrl-O, comes preconfigured with a few of the main FTP servers

Fig. 4: Adding servers to Sitemanager

together with Login etc. See Figure 4 for what this looks like. When using Sitemanager, all you have to do to get started is select the appropriate FTP server from those displayed, click on Connect and off it goes. If you would like to include other servers in this list, simply activate the box we mentioned earlier (Save to Sitemanager). Then let Kbear do the rest. Alternatively, use the New option in Sitemanager itself. The Remove option allows you to remove any sites you no longer want to use. Fanatics of tidiness can go even further, with New Group and allocate new main folders to the ones already defined (which include General and KDE), doing so permits you to separate and classify addresses by subject if need be.

Hand it over! As soon as you have made a connection to one or more FTP servers, you're almost there in terms of a download. But perhaps just a few words first about the arrangement of the windows is in order before we leave you to it. 5 · 2001 LINUX MAGAZINE 113


BEGINNERS

KORNER

Fig. 8: Caution is better than interrupted downloads...

Fig. 5: Vertical...

Fig. 6: ... or do you prefer horizontal?

Fig. 7: It's making progress 114 LINUX MAGAZINE 5 · 2001

You can change the window configuration very easily. Start by clicking on the Window--> Placing item, then select from one of the options displayed. For a traditional FTP client look and feel, the Tile vertically option (see Figure 5) will be the best choice. If you prefer things split horizontally, try Anodine's tile (Figure 6) instead. If neither of these appeals to you, then simply try whichever of the other settings suits you best. You can also define whether you want the files in the directories displayed simply as icons or in the more detail, with rights, time stamp and so on shown. You can do this via the menu Settings--> General Settings-->View Settings menu item. This is also where you can define whether this should be a tree view, or whether or not the taskbar and other things should be shown. But back to the nitty-gritty – actually downloading a file. This can be done, like so many other things in KDE, via drag and drop. Just click on the file you want to download from the FTP server's directory, then drag it with the mouse into the destination directory on your own hard drive. When you let go of the mouse button a context menu will appear. Then select Copy – and that's it. You can now simply lean back satisfied and watch the progress of the transfer in the lower Kbear window (Figure 7). Before we finish, we'd like to tell you about two more Kbear features. The first allows you to view a file prior to downloading it. To do so, click on the file you want to view with the right mouse button, and in the context menu that appears, select Open in standard browser. Kbear then calls up Konqueror, in which you can look at the file at your leisure – file type permitting, of course. The second and final feature we want to mention is an emergency brake. Kbear provides this feature for scatter-brained folk. On selecting Quit, which normally closes the program down, Kbear will let you know about any ongoing transfers that would be ruined if you were to actually shut the program down at that point (see Figure 8). Anyone who finds that this features gets on their nerves can switch it off by clicking on the Don't ask me again box. On doing so, Kbear will let you exit the program without any warning no matter what files you might be downloading at the time. ■


KONQUEROR

SOFTWARE

Universal File Manager Konqueror

FLEXIBLE CONQUEROR

TORSTEN RAHN

The acquisition of new territory always follows the same pattern. Once it has been discovered by the navigator, it is explored by the explorer in order to be taken by the conqueror. So the name given to the program which replaces the KFM ("K FileManager") from KDE 1.x is quite logical. It is the Konqueror.

Konqueror itself is basically a small and lean program, which can if required load in additional subprograms ("components"), in order to offer extended functionality. So, to display a Web site the KHTML components are loaded, or to show images, the kview components.

So where is he then? When KDE 2 is started for the first time the Konqueror introduces itself as file manager and displays the home directory. If not, you can call up Konqueror via the panel at the bottom of the screen. One click on the house-icon is all it takes to get a quick overview of your files. If there are a great many files, you will immediately notice that Konqueror has become much faster compared with KFM. Anyone who has ever got lost with the old KFM in the /dev directory will know that it sometimes took more than half a minute to construct the entire directory, with its 2000 files. Using Konqueror this takes just a moment.

It all depends on your view And now it is possible to alter the view precisely according to your own wishes. On the symbol bar on the right you can toggle back and forth between Symbol view, Multi-column view, Tree view, Detailed directory view and Text view. The tree-view (Fig. 1) is a great inside tip, if, when moving files to various places in the file system, you want to observe the overview. It displays the directory structure and the precise properties for all open folders at the same time. Via View/Display details it is possible to set which properties are shown and their sequence can be defined by drag and dropping the column headers. Since the directory tree over on the left in the tree view is superfluous, this can be cut off via the menu entry Window/Display directory tree. Those who prefer a perfectly normal symbol view have not been forgotten. If you frequently work with images, you will certainly want to switch on the image preview, in which a reduced version of the images is used as icon. (View/image preview).

[left] Fig. 1: Practical when dealing with files: the tree view of Konqueror: [right] Fig. 2: Konqueror with various sub-windows â&#x20AC;&#x201C; a console is embedded at the bottom. 5 ¡ 2001 LINUX MAGAZINE 115


SOFTWARE

KONQUEROR

The size of these thumbnails can be changed together with the icon size via View/Symbolmode.

Divide and rule!

Fig. 5: Documents can now be assigned much more simply to the respective application responsible for them.

As an advanced user you will certainly discover many additional interesting features in the Window menu. You can break the window into as many horizontal and vertical areas as you like via View ... split. This is similar to the classic Norton Commander, in which one can then deal with completely different things. The Konqueror window can be split in two vertically (Split view into left and right halves). This makes it easy to move or copy files. Another example can be found in Figure 3, where work is going on in a Konqueror window on a Web site. On the left at the top the files are displayed, from which the Web site is composed and on the right, the current version of the Web site can be shown at all times. On the bottom margin you will discover a console window, in which work is being done via the text editor vi on the Web site. Such a console window can be added via window/display terminal-emulator.

Symbols and profiles But how do you know in which window section you are actively working? This is made clear by the green LED, which lights up in the respective active window at the bottom left. The checkbox at the bottom right, on the other hand makes it possible to link or decouple various views by means of a chain symbol. So it is possible to ensure that two different window Fig. 3: With KGhostview a document is displayed here in Konqueror

Fig. 4: Flash-Plugins also function in Konqueror.

116 LINUX MAGAZINE 5 ¡ 2001

sections always show the same directory. For example the window sections can be removed, by clicking with the right mouse button on the bottom grey edge of the window section and selecting Remove active view. There are various combinations of the window sections on offer for different purposes. Therefore, you can load and store the "Layout" of the window section via so-called Profiles in the menu window.

File, open sesame! As with starting programs, opening documents is done with a click of the left mouse button on the associated icon, although you can set a double click via KControl, the KDE-Control centre. As a rule this does not start an independent application, but only those parts of the program ("components") embedded in Konqueror and needed to display the corresponding documents. When clicking on a graphics file, for example, the file is displayed in Konqueror as an image and the menus and symbol bars are simply altered so that all necessary functions are available. If on the other hand one clicks with the right mouse button on the document, it is possible to select the application with which the document should be opened. It is either listed directly in the context menu or you select the Open with entry, via which the desired application can be entered as appropriate. In addition, though, it is possible via Settings /Install/ File allocations to set, easily and permanently, which document type should be opened with which program and whether the application for this should be embedded or started completely normally (Fig. 5).

An alternative to Netscape? As already indicated, there are numerous other components in KDE 2, including the KHTML components to display Web sites. This means that you can also use Konqueror as a fully-capable browser, since with KHTML it can master all current standards necessary for the viewing of Web sites: HTML4, CSS1/2 in part, Javascript, Java and even Netscape-Plugins. Since Konqueror is very fast, uses few resources and still copes with all current standards, it's a good idea to use it rather than your previous browser. To do this, type the desired web address in the URL-line directly into the opened Konqueror or else start it via the globe icon in the panel. You should first tell Konqueror whether you wish to use a proxy â&#x20AC;&#x201C; such a proxy can considerably speed up the loading of Web sites. If you have been using Netscape until now, you can also check there under Edit/Settings/Extended/ Proxies/Manual proxy configuration, whether you have previously been making use of a proxy and, if so, what the proxy and port numbers are. You can then take over these settings for Konqueror under Settings/install/ Proxies. For some sites it may still be necessary to activate Javascript- or Java support, under Settings/Install/Browser.


KONQUEROR

SOFTWARE

Pure surfing pleasure Now you can get started surfing the Internet. Begin for example with http://www.konqueror.org, where you can find out if there is any news about your new favourite browser. Another very easy one is the history function, which guesses the complete address just by typing in the URL. Should this guesswork prove unsuccessful, simply carry on cheerfully typing until the correct address appears. Then you can make Konqueror display the desired Web site by pressing the Enter key, in full image mode if you like. When you have installed OpenSSL, secure connections of up to 168 bit encryption cause no problems for Konqueror. Some KDE developers are now even using Konqueror for their home banking.

Abbreviations and foreign languages One additional and extraordinarily helpful feature is Internet keywords. If you enter gg: KDE in the URL box for instance, the search engine "Google" is automatically called up. This then shows you all the Web sites in the Internet in which the word KDE is mentioned. Other Internet keywords make it possible, for example, to translate texts from other languages, search for RPMs or look up terms in lexicons or dictionaries (Fig. 6). By making your own definitions you can extend this functionality to completely match your own taste. Beyond everyday surfing, the fun is practically unlimited. KHTML also supports characters whose character set goes beyond the Latin alphabet (the magic phrase here is "bidirectional Unicode support"), so that for example you can look at Japanese Web sites (Fig. 7). But to do this, the corresponding characters also have to be installed.

probably already created a bookmark collection by tedious, fiddly work. But here, too, Konqueror meets the user halfway, by taking over the existing bookmark under bookmark/Netscape bookmark. Anyone who wants to reach his absolutely favourite sites almost at the touch of a button can do so via bookmark/bookmark list/add bookmark. Then the bookmark is specifically included in a special symbol bar, which can be activated via Settings/display bookmark list. As in all other KDE-applications, the composition of these symbol bars can be configured more precisely via Settings/Install/toolbar.

[top left] Fig. 6: translating with konqueror .... [top right] Fig. 7: Konqueror in FVWM2: Obviously, Japanese Web sites can also be displayed.

And the download session? Obviously Konqueror can also be used for FTPdownloading, and the downloading of many packets at the same time is completely unproblematic. In order to retain an overview when doing so, it can be advantageous to ensure (via Settings/Install/File manager/Other) that status information on all network connections is displayed together in one window.

A glimpse of the future Sight for sore eyes Apropos: If the font on the Web sites is too small, this can also be remedied, by making the appropriate adjustments under Settings/ Install/ Browser/ Appearance. And a minimum size for fonts can also be specified in order to avoid the text being so small as to be illegible. For temporary changes in text size it is a good idea to use the corresponding entries from the symbol bar to enlarge or reduce the text on the Web site.

Where was it now ...? Sites of especial interest can be provided with a bookmark: After a click on bookmark/add bookmark the corresponding URL is included in the bookmark menu. The bookmark functionality is not, however, limited to Web sites, but can also be used for FTP download addresses and directories on your own computer. All entries can obviously be divided by folder into subject areas. If you have been using Netscape or Mozilla until now, then you have

Beyond the standard protocols HTTP and FTP already mentioned, Konqueror also has some other common protocols available, such as for NFS- and SMB-Shares, and LDAP-directories. In principle these services are made available throughout KDE. So, for example, you can use FTP not only in Konqueror, but also with other programs which make use of it. Because of the modular architecture of KDE 2, it is easy for the developers to add additional protocols. The result of this will be that in future you will also be able, via the URL line in Konqueror, to read your e-mails and/or newsgroups or can download the images from your digital camera. A refinement of the functionality and appearance of History- and Bookmarks is planned. So there is also a prospect of a better view of icons and a preview for text files. In addition to increased stability there is thus some additional attention to detail in the pipeline. Because it is mainly the many useful details, which make KDE and also Konqueror so popular. In the meantime the KDE team wishes you lots of fun with KDE 2 and Konqueror! â&#x2013;

Fig. 8: The toolbar, too, can be configured freely in any KDE program.

5 ¡ 2001 LINUX MAGAZINE 117


SOFTWARE

PHOTOPAINT WORKSHOP

Corel PhotoPaint 9 – first steps

PAINTING BY NUMBERS BY TIM SCHÜRMANN

In true Linux tradition, Corel is giving away copies of its ”PhotoPaint 9” image editor for Linux. This alternative to GIMP is absolutely brimming with useful features, but isn’t particularly beginner-friendly. So, for those who think they might get lost in the PhotoPaint jungle, in this feature we’ll introduce you to this very useful program and some of its most important features. Having made any configuration changes necessary, after starting PhotoPaint 9 it should, all being well, display a ”Welcome” screen. In the background, you should also see what appears at first glance to be a somewhat overcrowded work area. To shed some light on this jungle of icon bars, we’ll explore them one by one. To do so without boring you silly, we’ll use an example task, in which we will place good old ”Tux”, the Linux mascot, into a pretty picture frame. The main focus will be on handling masking tools and layering technique, but we’ll explore other areas along the way too. Before we get down to the nitty-gritty, though, we need to cover a few theoretical principles first.

Basics PhotoPaint is a pixel-oriented image processing program. All images are composed of individual points arranged in a rectangular matrix. By assigning colours to these individual points, which are known as pixels (an abbreviation for ”picture element”), an image can then be created. The representation of such a graphic image becomes more detailed as more pixels are used. The number of pixels used is referred to as the resolution. An alternative to this form of image representation (referred to as raster) is what’s known as vector representation. Here, and image is made up from a number of individual geometric 118 LINUX MAGAZINE 5 · 2001

shapes that can be manipulated individually or as groups and is ideal for technical drawings or illustrations. PhotoPaint doesn’t support this type of image directly, though, instead leaving this to packages such as CorelDraw. Having dealt with the very basics, before you go on to follow the steps required to enhance Tux in our example, it is well worth having a look at PhotoPaint’s built-in tutorial. You can start this either via Help/CorelTUTOR... or by selecting the relevant option in the ”Welcome” screen.

Desktop As we’ve already mentioned, to help you get to grips with PhotoPaint this tutorial will involve adding a frame to Tux. In order to do so we will, of course, need a suitable image of the little fellow before we can continue. Just such an image is included on our coverdisc. To open this, if you haven’t already done so, launch Corel PhotoPaint 9 and, from the top right corner of the ”Welcome” screen, select Open Image. If you have already shut this window by deselecting the little tick in the box at the bottom of the window, you can use the File/Open... option from the main screen. In either case, when the file open dialog box pops up, select the file tux.cpt. Let’s now take a closer look at the desktop. At the top of the screen you’ll see three toolbars under the main menu bar. The first is the ”standard” toolbar. This includes a few basic icons used for purposes such as loading and saving files. Beneath this you will find a toolbar with various masking


PHOTOPAINT WORKSHOP

SOFTWARE

Installation Before you do anything else, you should first check whether your computer is up to the rather high minimum system requirement of the program. These are a 200MHz Pentium processor or faster, 64 MB RAM or more (128 MB RAM recommended), no less than 170 MB of free hard disk space, a mouse, and last but not least SVGA monitor and graphics card. You’ll also need Kernel release 2.2 or higher, glibc libraries 2.0, 2.1 or compatible, X-Windows and Package management software for RPM or Debian Packages (dpkg/apt-get). Keep in mind, though, that trying to run it on anything less than a Pentium II will result in very slow response when dealing with larger images, or more than a handful of smaller ones at once. Although Corel is giving the software away free, you can’t, of course, just call them up and ask for one. Instead you’d normally need to download it from http://linux.corel.com, and at over 90Mb this is no quick process. We’ve included a copy on this month’s coverdisc, though, which means you don’t even have to spend a second online to download it. To get the installation process under way, first unpack the PhotoPaint archive with a suitable program. You can use something like ”Ark” under KDE, or you can use ”tar xvfz <Filename>” in a terminal window. After that you need to invoke the installation utility by launching the ”install” program that will have been unpacked along with everything else. Annoyingly, you won’t be given a choice of installation directory – this has to be /usr/lib/corel. Under some distributions (including SuSE) a KDE menu item then has to be installed manually. To do this you can either make the links yourself or install two RPM format packages from the sub-directory /dists/redhat. Both of the archives necessary for this begin their file names with ”menu-” or ”menusupport-redhat”. If in doubt, you should read the readme.htm file provided. Alternatively, if you want to avoid all this, PhotoPaint 9 can be started at any time via a terminal window just by typing in photopaint and then pressing the enter key. Incidentally, fonts must be registered before they are used, but as with WordPerfect Office 2000, an easy to use font manager is provided as part of the package that can be used for this very purpose.

functions, which we’ll be making extensive use of shortly. As well as providing access to certain other functions, the third toolbar keeps certain setting options easily to hand for whichever drawing tool has been selected, and so constantly alters its appearance. Obviously you will find (almost) all of the functions available in these three bars are also available from the normal menus. A toolbar can be shown or hidden very easily. All you have to do is click on any toolbar, then select or deselect the appropriate toolbar from the menu that pops up. You can also alter the positions of any of the toolbars and even completely ”detach” them from the desktop so that they are then in their own, free-floating, window. To move or detach them, simply drag them and drop them by clicking on the double vertical or horizontal lines you’ll see at one end of the bar. In addition to the toolbars we’ve just mentioned, on the left side of the main PhotoPaint

Window you’ll see what’s called the ”tool palette”, and on the far right you’ll see a ”colour palette”. A status bar, which always keeps a few very helpful details handy, is visible at the bottom of the main window. An additional window, just to the left of the colour palette, is part of the family known as ”dockers”. These are normally free-floating windows and are used for a wide variety of purposes. As the name ”dockers” suggests, these windows can ”dock” anywhere. A few of these windows can even be hung inside each other. By default, the docker displayed to the left of the colour palette displays a list of layers. By using Window/Dockers, the various windows available as dockers can be maximised and minimised, which is very handy. This and other options to do with dockers and toolbars are well worth experimenting with if you are working with PhotoPaint for the first time. When doing so, be

[left] Figure 1: Corel PhotoPaint 9 after starting [right] Figure 2: ”tux.cpt” has been opened

5 · 2001 LINUX MAGAZINE 119


SOFTWARE

PHOTOPAINT WORKSHOP

PhotoPaint and WordPerfect Office 2000 As you may be aware, some problems arise when you have both PhotoPaint 9 and WordPerfect Office 2000 installed on a system at the same time. Some of these problems can be avoided by always installing WordPerfect Office 2000 before PhotoPaint 9 and saying yes when PhotoPaint asks if you want to install an update for WordPerfect Office. This will avoid compatibility problems that result from PhotoPaint over-writing Office 2000’s font manager. Incidentally, when asked for the path to the CD-ROM by PhotoPaint, simply specify the directory in which you unpacked the program in the first place. You should also note that any font types you installed yourself have to be registered again in the font manager in order to work. Even after doing all this, all will not yet be plain sailing. In order to prevent Office 2000 from suddenly becoming unable to find its spellchecker, you’ll need to copy all files from the directory /usr/lib/corel/shared/Writing Tools/9.0/ into /usr/lib/corel/Shared/Writing Tools/9.0/ – note the capital S in the second path.

sure to experiment with the little double arrows that are displayed in the corners of some windows. You might also want to look out for small black triangles in the bottom right corner of some of the tool palette icons. These indicate that more objects from this family of tools are available but are currently hidden. You will find, for example, tools to draw circles and polygons hidden underneath the rectangle drawing tool in the tool palette. To reach these hidden tools, move the mouse cursor over the rectangle symbol and hold down the left mouse button for a couple of seconds. A menu will then pop up from which you can choose the additional tools. Note the double lines displayed to the left of the extra options – clicking and holding on here will allow you to detach the menu and drop it anywhere on the screen, just like normal toolbars. Is that great or what?

Get set, go [left] Figure 3: The desktop with free-floating symbol bars

[right] Figure 4: Creating an empty image

For all those who are impatient and want to get started with their painting immediately, try this: Click with the left mouse button on a colour from the colour palette. This then becomes the current drawing colour (a click with the right mouse button, on the other hand, would re-define the fill colour). Now select the bottom symbol in the toolbar, the ”Paint Tool”. This will allow you to paint directly

120 LINUX MAGAZINE 5 · 2001

onto the image. When you do, note the way the property bar, (the full name for the last of the three toolbars at the top of the screen) changes. Also note that using this toolbar you can, among other things, alternate between various paint tools (the first icon from left) or define the shading depth (the slide controller). Feel free to experiment in order to become familiar with the various settings and what they do. If you make a mistake or do something particularly stupid, you can always reverse your action or actions via the Edit/Undo menu options or the backward curving arrow button on the first toolbar. If you do experiment and end up saving any changes to Tux by mistake at this point, reload him from the CD.

Tux – you’ve been framed Leaving Tux alone for a moment, using File/New... , create a new image. In the window that pops up, there are a few settings we need to change, and which need a little explanation. As we’ve already mentioned, a colour is associated with each pixel in an image. The colour value can be based on the intensity of the colours red, green and blue (”RGB”), or cyan, magenta, yellow and black (”CMYK”). RGB colours are used in monitors and TV sets, while CMYK is used in most inkjet printers.


PHOTOPAINT WORKSHOP

In the type of RGB-images used on PCs, when you want to display ”true colour” 16.7 million colour images, you have to specify three values for each pixel, between 0 and 255, one for the red, one for the green and one for the blue component. This means that each pixel requires 24 Bits (3 Bytes) of memory in order to store it. If such a wide range of colours aren’t needed, you can conserve space by creating images where less memory is used to define the colour. You could use just one byte (8 Bits), for example, but then the image could consist of no more than 256 colours. In a case like this, where only a small number of colours are used, it is possible to define exactly which colours these are, out of the full 16.7 million colours most computers can deal with. The required colours are defined in a table known as a colour palette, and each entry is assigned a number or an index. In the image itself, you then only need to store the corresponding colour index for each pixel. With viewing or creating images based on palettes, it is important that the correct palette is used at all times, as otherwise the colours won’t look right. For our new image we’ll leave the setting as ”24-Bit RGB” in the dialog box. Underneath this drop-down box you’ll see an option that allows you to set the background colour of the new image – select White. ”No Background”, incidentally means that the background remains transparent. In the ”Image Size” group of options you can specify the dimensions of your image. Here it is possible to specify a fixed size from the drop-down box, or to adjust the borders to your exact requirements. If you choose the latter method, you should define, in the area to the right, the yardstick you want to use. In general this should be left as ”Pixel”, but you may want to choose other options on other occasions. Note how, in the lower area of the new image window, you are always shown how much memory space the new image will require if created using the current settings. For the purposes of our tutorial, select 640x480 in landscape format.

SOFTWARE

Scene-setting Once the new image has been created, the first thing to do is switch on the ruler, using View/Rulers. With this it is very simple to create the ”guidelines” we’ll add next. First, click on the horizontal ruler, hold down the mouse button and drag the guideline that will appear to roughly the centre of the image, then release the mouse button. Next, do almost exactly the same thing, but this time create a vertical guideline. Arrange this new guideline so that the two form a cross. You can move either guideline by dragging them and dropping them if you need to. Note that the selection tool, or ”Object Picker Tool” as Corel calls it (which is at the top icon in the tool palette) must be activated in order to do so. Worth knowing is that guidelines can be adjusted much more precisely by entering numerical values directly via the View/Grid and Ruler Set-up menu. Having set up the guidelines, in the View menu activate Snap to Guidelines. In this way you make a guideline act as a sort of magnet to any objects which come close to it. This allows much greater accuracy in the orientation of objects. In the next step, we’ll create a frame for our penguin. To do this we’ll need to create a rectangle in which we’ll then have to stamp a hole. First, though, we’ll pick a colour for the frame from the colour palette on the right hand side of the screen. Click with the left mouse button on a colour - any colour you like except white will do. As we’ve already mentioned, this allows you to define the drawing colour, while a right click will define the fill colour. Your selections are displayed in the status bar at the bottom of the screen as ”Paint” and ”Fill”). If you don’t see a colour you like in the palette, double click on one of these two symbols, which makes a colour window appear – you can make much more comprehensive colour choices here. After you have decided on a colour, click on the rectangle tool – sixth symbol from the bottom on

[left] Figure 5: Showing ruler and two guidelines [right] Figure 6: The finished rectangle

5 · 2001 LINUX MAGAZINE 121


SOFTWARE

PHOTOPAINT WORKSHOP

the Tool Palette. Now move the mouse cursor to roughly the point in the image at which the two guidelines cross. Next, click and hold the left mouse button, then move the mouse. You’ll see a rectangle appear on the screen, the size and format of which you can control. Note how the guidelines have ”sucked” the starting corner of the rectangle exactly onto the crossing point. Without letting go of the mouse button, press and hold the Shift key. This tells PhotoPaint that the point at which you began the drawing process should be the centre of the rectangle, and not the corner. Finally, drag the rectangle so that it covers the entire background and let go of the mouse button then the Shift key. Pressing the Ctrl key, by the way, makes all the edges of the rectangle equal, in other words allowing you to draw perfect squares. Your image should now look something like that shown in Fig. 6. If it is not already displayed on screen, you should now open the Objects docker by selecting it in the Windows/Dockers menu. It is normally shown by default on the left next to the colour palette on the right side of the screen, though. The Objects docker displays all objects contained in the currently active image. In our case you should see the rectangle object and the background, which is itself treated as an object, listed. Each object lies on its own layer. A layer can be thought of as being a transparent sheet, many such sheets being arranged on top of each other. In our case the rectangle object is on a sheet lying over the background sheet. The rectangle object should be surrounded by a red border in the list, which indicates that it the currently selected object.

Holes [left] Figure 7: The cut-out circle [right] Figure 8: Selection of paper fill

Our next step is to stamp an oval hole out of the rectangle. This is where we’ll put Tux. To do this, click on the second symbol from the top in the tool palette (the ”Rectangle Mask Tool”) and hold down the left mouse button until the tool sub-menu pops

122 LINUX MAGAZINE 5 · 2001

up. From this, select the ”Circle Mask Tool”. Now move back to the centre of the image over the previously created rectangle, hold down the shift key and, with the left mouse button pressed, draw an oval that does not touch the edges of the rectangle. Next, select Object: Cut Selectionfrom the Object/Create menu. Cut Selection will do just what it says it will, cutting out the oval from the rectangle, but not actually moving it anywhere so you won’t be able to tell that anything has happened at first glance. But if you now look at the dockers window, you’ll see the stamped out oval has appeared as a new object on a new layer. To move this unwanted object out of our way, click on the oval in the middle of the image and move it using drag and drop. The white oval area which you can now see in the centre of the rectangle is not a collection of white pixels within the rectangle. Rather, it is the background showing through. In the dockers window, the oval should now be highlighted black. If this is not the case, click once on its name (with a double click you would open a dialog window with additional settings). Since we no longer need this stamped out oval, we can erase it using Object/Delete.

Fills A basic, one colour frame does not look particularly attractive, and certainly isn’t good enough for our friend Tux. For this reason we’ll now go on to give both background and the frame a ”fill”. To do this, first select the background object from the layers list. Then select the paint pot from the tool palette (the ”Fill Tool”). This will make some colourful icons appear on the property toolbar (the third and last of the toolbars at the top of the screen). The first four of the new icons represent the fill types you can use a solid colour, a shading, a bitmap (i.e. a pixel image) or a texture. Via the fifth button, ”Edit Fill” you can then make extended adjustments to the fill action.


PHOTOPAINT WORKSHOP

For our image, click on the fourth icon, ”Texture Fill”, and then on ”Edit Fill”. From the ”Texture List”, select ”Recycled Paper” and then click on ”OK”. Move the mouse cursor to an area where the background is visible and press the left mouse button; this will give you a paper fill. Next, in the layers docker, select the rectangle object, then click on the third colourful icon on the properties toolbar (bitmap fill). Click on ”Edit Fill” and, in the window that pops up, then click on the down arrow next to the large button showing a preview of the bitmap currently selected. This brings up a scrollable preview of more bitmaps you can use. Select the fourth image from the top in the left hand column. Incidentally, using ”Load” you could also use one of your own images as fill object. Select ”OK” and fill the rectangle with the bitmap by clicking on it. Although it isn’t too bad, our current arrangement isn’t particularly good either. To spice it up and give it a feeling of depth, select the Effects/Texture/Plastic option. Leave the default values in this setting window and click ”OK”, and watch what happens. Isn’t it great? Please note that this kind of effect can take a long time to complete on slow computers.

Frame program Now, finally, we are at the stage were we can put Tux in his new frame. To do this, select the window with the Tux image. As we only want to insert Tux and not the entire image in the frame, we must first cut out the little chap from his background. PhotoPaint helps here with its intelligent masking function: click on the second icon from the top in the tool palette and hold down the mouse button until the sub-menu appears and select the ”Magic Wand Mask Tool”. After you’ve done that, click on the area around Tux. The magic wand will then automatically and precisely mask that area and all areas of the same colour. However, what we’ve just done is select Tux’s background, and not Tux himself. We therefore need to invert the mark in order to select Tux – you can do this effortlessly using the Mask/Invert option. By the way, as an alternative to the magic wand you could also use the lasso. With this you only

SOFTWARE

need to roughly encircle the penguin. Once you’ve done this, PhotoPaint will attempt to find the edges of the encircled object and mask it. However you decide to do it, our marked Tux can now be copied from his present location using Edit/Copy and inserted into the image with the frame using Edit/Paste/As New Object. Activate the selection tool again (”Object Picker Tool”) and then move the penguin to the right spot in the frame using drag and drop. If the penguin is too big for the opening, you can place the layers on which it lies behind those of the rectangle: To do so, with the penguin selected, choose Object/Arrange/Order/Back One, which moved him back one layer and therefore behind the frame. Alternatively, you can also pick up and change the order of the objects in the layers docker using drag and drop – try it! We’ve just about finished, so we can now get rid of the guidelines we created right at the start. To do so, just click on them with the mouse and then, with the mouse button pressed, drag them back to the ruler, at which point they will vanish! All you have to do now is store the image. Use the File/Save as... option to do this. When you do so, note how you can select from various file formats for the file. The options displayed depend on the colour model used (RGB, CMYK etc), and also on whether or not there are objects in the image. You cannot save an image with objects in BMP format, for example, unless you merge all the objects into the background layer first. You can do this using Object/Combine/Combine All Objects With Background. Worth noting, though, is the fact that you’ll not have the option of separating the objects from each other again once you’ve done this and saved the file. Well, here ends our introduction to Corel PhotoPaint 9. It hasn’t been possible to show you absolutely everything. Indeed, we’ve only scratched the surface, so some exploration of your own would be very worth while. In particular, the effects (in the Effects menu) are something you should try out on a test image. When you do, though, note that some of the effects can only be applied to objects already selected. For more information, you can turn to PhotoPaint’s online help, or to one of the many books covering the subject. ■

[left] Figure 9: The completed frame with the plastic filter effect [middle] Figure 10: Selected Tux [right] Figure 11: The complete image: Tux in the frame

5 · 2001 LINUX MAGAZINE 123


COMMUNITY

BRAVE GNU WORLD

The monthly GNU Column

BRAVE GNU WORLD GEORG C. F. GREVE

Welcome to Georg's Brave GNU World. Although I'm new to you guys in the English edition of Linux Magazine, I've been writing for the German edition for two full years now. As a kind of birthday present to you all I've put together two features that explain what I have been working on for the last year. This will also help my new found audience catch-up.

CD burning is easy with CGIBurn

CGIBurn [5] by Scott Gifford is a web-based front-end for writing CDs. It is meant to allow several users on one or several machines to share a single CD writer. Since CD writing is rather susceptible to problems, the CD writer is traditionally put into a dedicated machine or the file server. Most CD burning software front-ends are not designed to be used by several users. Additionally they very often create problems when the display is being exported to some other machine over the network. In the case of a flaky network the writing process is

124 LINUX MAGAZINE 5 路 2001

inadequately insulated against network outages. Problems with the desktop machine also can lead to the production of wasted CDs. Fortunately, webbased front-ends do not have these problems. Additionally CGIBurn offers advantages in terms of usability. On a computer used by several people, one user can trigger writing a CD and then free up the workspace for someone else. Also, in heterogeneous networks this method offers several advantages. If the CD writer is housed in the machine that also hosts the SAMBA server then users can drop files into certain directories and use their favourite web browser to start writing them to CD. According to Scott Gifford, one of the program's big advantages is its modular concept. The first public release already supports copying from CD to CD, between CDs and directories, as well as writing ISO images. Since the configuration files define certain actions and the modules used for them, it is rather easy to implement new functionality. The look and feel of CGIBurn can also be catered to personal taste by HTML templates. As the previous paragraph perhaps implied, CGIBurn is still rather young. The current version is the first one publicly available. Not surprisingly the list of planned features is rather long. The next step will be copying music CDs to and from MP3 and WAV files. Also on the list is an option to erase CDRWs, directories or ISO images. If there is enough interest, Scott will consider rewriting the template system to


BRAVE GNU WORLD

COMMUNITY

CGIBurn also supports copying between directories and CDs

become more flexible and versatile as well as adding support for locking directories. And finally he can imagine writing front-ends for the command line, ASCII interfaces and even an LCD display with buttons. The biggest weakness currently is the lack of audio support although Scott is certain to have that included within a few weeks. But despite the early version he already considers it to be quite stable. Interested developers and HTML designers should feel encouraged to get in touch with him. Help is very much welcome and Scott has documented the concepts and backgrounds rather well. Personally I think one thing can be improved – the installation. Newbies or more basic users should take heed and not attempt the job unless you have sufficient nails to chew through and hair to pull out. Nevertheless CGIBurn has a great potential and is definitely worth taking a look at. By the way, this project has quite an interesting history. Scott and his fiancé went to buy a CD writer

to go into his GNU/Linux machine. But as his fiancé has limited knowledge of GNU/Linux she wouldn't be able to use the new drive. Scott looked on the FTP sites for a solution and didn't find anything that satisfied him so began writing CGIBurn. When he realized that this might also be of interest to other people he began to clean up the code and released it under the GNU General Public License.

Multiple Multiple [6] is a small command line tool by Oliver Bandel which was released under the GNU General Public License. Its function is to find identical files and get rid of duplicates. Home directories in particular tend to collect quite a bit of saved news and mail as well as other files so duplicates are a relatively common thing. Finding duplicates in particular in saved news and mail was the very reason Oliver wrote the program.

[left] Diff2html shows in combination with dv the difference between files with similar content [right] Just starting: The Free Software Foundation Europe

5 · 2001 LINUX MAGAZINE 125


COMMUNITY

BRAVE GNU WORLD

In order to do the task better than similar programs it offers the option to ignore everything before the first empty line in order to avoid problems with different time/date stamps in the saved mail. Multiple can get rid of all duplicates, printing the name of the remaining files to stdout because deleting all files can hardly be what the user wants. Unlike diff it can compare an unlimited amount of files and it is also not based upon md5 checksums which makes it relatively fast and efficient. People with a certain tendency of accumulating things might find this a useful tool. According to Oliver, the big weakness of multiple is that in taking the files to compare from find, if anybody activates the find option to follow symbolic links this might result in deleting all files. This problem arises whenever files are given to the program multiple times. To avoid this, he's considering writing his own routine to search directory structures. At the moment he feels that writing proper documentation and a manpage would be more important, however.

diff2html and dv Diff2html [7] and dv [8] are two interlinked programs from Daniel E. Singer. They come from the category of what you could call "something2html" programs. As the name already indicates, diff2html is a program to present the output of the diff program in an HTML document. The output is colour coded and lists both versions next to each other in a pretty nice way. The colours can be defined by environment variables. Dv stands for "diff viewer" and is essentially a wrapper for diff2html that starts a browser to show its output. Being BASH shell-scripts, both programs are very portable which makes them useable on any Unix machine. Unfortunately the author did not specify a license for them since he did not consider this to be necessary as he has no wish to control them in any way. This is a disadvantage but the programs might be helpful for some users.

GNU GRUB The GNU "GRand Unified Bootloader" (GRUB) [9] is an official part of the GNU Project and is of course published under the terms of the GNU General Public License. GNU GRUB is quite probably the most powerful bootloader for i386 based machines. It has its origin in 1995 when Erich Boleyn began working on it. From 1999 Gordon Matzigkeit became the official maintainer and Okuji Yoshinori, a former Japanese translator of the Brave GNU World, has become the most active developer. But of course these aren't the only developers. A lot of people have 126 LINUX MAGAZINE 5 ¡ 2001

contributed to GNU GRUB over the years and, unfortunately, the list is too long to be quoted here. The capabilities of GNU GRUB are rather astonishing. It has a nice menu for an interface and even supports operating over a serial console. Additionally it has the capability to boot over the network via TFTP or NFS so workstations can be configured to pull their kernels off some central server. At boot time GRUB can already deal with a lot of file systems (Ext2fs, ReiserFS, BSD UFS, MS-DOS FAT16 & FAT32 and Minix) in order to be able to load kernels or files for booting. This comes in very handy when trying out new kernels without having to reconfigure GRUB, not to mention troubleshooting, where it can be real life-saver. Should something special be missing or not be supported, GRUB can chain-load another boot loader. Of course all these features can be password-protected if so desired. The GRUB shell is a Unix program that emulates the GRUB bootcode under another operating system like GNU/HURD, GNU/Linux or *BSD. This makes it possible to test features without having to reboot the machine. Right now GRUB is teetering on the brink of its 1.0 release and most of the work will be done in eliminating the last bugs and increasing stability â&#x20AC;&#x201C; new features are not to be added. However, after the 1.0 release a new infrastructure for GRUB called Figure [10], which is already being developed by Gordon Matzigkeit, will be tried out. Should this prove to be a good idea it would essentially give GNU GRUB the capabilities of a mini operating system with compiler, memory management and so on. Independently of Figure everything seems to indicate that the GRUB is headed towards becoming a kernel in its own right. The main reason is that it does make a lot of sense to have a tiny boot loader that extends itself by loading modules or a kernel that completely replaces the bootstrap environment. But those plans are almost pipe-dreams compared to the here and now. It is much more important that with GNU GRUB we get a boot loader that can boot GNU/HURD and has features that could only be dreamt of so far. Knowing this it makes a lot of sense that several GNU/Linux distributions like OpenLinux, Plamo Linux, Mandrake, BestLinux and Conectiva Linux use it by default. But now we stop discussing technical stuff and come to the special features.

FSF Europe Founding a European sister organization of the Free Software Foundation is an idea I had over a year ago. Richard M. Stallman considered this a good thing and together we agreed that Werner Koch, author of the GNU Privacy Guard (GPG), and Peter Gerwinski, maintainer of GNU Pascal, would be ideal people to do this with. After an initial brainstorming phase we asked Bernhard Reiter, co-


BRAVE GNU WORLD

founder of the FreeGIS project and board member of the FFII, to join us. The four of us have discussed advantages and possible pitfalls as well as really got to know each other and our respective views on things we brought the discussion out in the open. In November 2000 it was finally time. The main task of the Free Software Foundation in the United States is to provide a certain technical and organizational infrastructure as well as gathering, bundling and distributing funds. All these parts were underrepresented in Europe until now since in every day work, the United States is sometimes rather far away. Additionally the tax-deductibility of donations is an important point that was not possible so far. The declared goal of the FSF Europe is to support the technical and organizational side of the GNU Project as well as other useful Free Software projects just like the original FSF does. Furthermore we want to maintain the financial side in Europe to provide better and more effective funding. And finally we seek to become a competent political partner in order to lay sound fundamentals for Free Software in Europe. Together we have created a core concept and built up mutual trust in this closed group since discussing these things in public normally leads to very emotional debates that have the tendency to cloud the core issues. From the political side, this often looks like there is no consensus in the Free Software scene, which has proven to be pretty counterproductive. Now we feel that we have found a sound basis to provide a lasting reference point. To assure longevity is our goal and for this the help of the whole community is desired. As points of reference for those interested we prepared the a fairly minimalist web page [11] and some public mailing lists [12]. But there is also a fourth job that the FSF Europe will be doing – it will maintain and organize the GNU Business Network.

COMMUNITY

Software community in some way. This way everyone can indirectly strengthen the community with the money spent. The second functionality it provides is a business to business contact platform for companies involved in Free Software around the world. This way companies can find possible distribution contractors, local support providers or build cooperations in software development. The last part especially does have a huge potential that is untapped. We hope to change this. And finally we wish to encourage companies to reduce their proprietary activities in order to gain a better position in the GNU Business Network – membership in the GNU Business Network is not based on financial contributions but solely on the business activities of the company concerned. Furthermore it is planned to offer a kind of certification for Free Software projects that will become a branding which can be used by companies to display their affinity to Free Software to customers and the community. The core document of the GNU Business Network will be the "GNU Business Network Definition" that is being developed by the protagonists of the FSF Europe in permanent dialog with Richard M. Stallman. We are currently at about the 20th iteration and believe to have found a point that allows this to become a reality too. Interested people and especially companies are very much encouraged to discuss the concepts and ideas on the public mailing lists [13].

that's it That's the Brave GNU World for this month. I hope to get a lot of feedback [1] from what I've been discussing (both technical and political), and, of course I'll bring updates about the FSF Europe and the GNU Business Network in the future. ■

GNU Business Network Creating a "GNU Business Network" occurred to me when we were still discussing the FSF Europe prior to Bernhard arriving. It Network has become much more definite following the LinuxTag in Stuttgart when organizations and companies asked the LinuxTag for something like it. As an additional test I have talked about it with several people at the Linux Expo in San Jose and got positive feedback. The idea is to have the GNU Business Network bring companies and the GNU Project closer together and to offer an additional incentive for companies to commit to deals according to the GNU philosophy. Its focus will be the web site that acts as a central hub with a worldwide list of all participants. This list serves essentially three purposes. First of all it allows customers to specifically prefer companies that contribute to the Free

Info [1] Send ideas, comments and questions to Brave GNU World <mailto:column@brave-gnu-world.org> [2] Home page of the GNU Project: http://www.gnu.org/" [3] Home page of Georg's Brave GNU World: http://brave-gnu-world.org" [4] "We run GNU" initiative: http://www.gnu.org/brave-gnu-world/rungnu/rungnu.en.html [5] CGIBurn home page: http://www.tir.com/~sgifford/cgiburn/ [6] Multiple: ftp://www.belug.org/pub/user/ob/Programs/Tools/ [7] Diff2html: ftp://ftp.cs.duke.edu/pub/des/scripts/diff2html [8] Dv: ftp://ftp.cs.duke.edu/pub/des/scripts/dv [9] GNU GRUB home page: http://www.gnu.org/software/grub/ [10] Figure home page: http://fig.org/figure/" [11] Free Software Foundation Europe home page: http://www.fsfeurope.org [12] Free Software Foundation Europe mailing lists: http://mailman.fsfeurope.org [13] GNU Business Network mailing lists: http://mailman.gnubiz.org ■ 5 · 2001 LINUX MAGAZINE 127

Linux Magazine UK 005  

Linux Magazine UK 005

Read more
Read more
Similar to
Popular now
Just for you