Living without Windows!by Jos Visser
Well folks, sad as it is, we are living in a Windows world. People using Windows have a vast array of applications and tools available to achieve almost anything they want. Some of these tools have become household names or de-facto industry standards in their fields. When you start Living without Windows you need to find or make replacements for a lot of these. Fortunately, this is not impossible! There is a loot of good software for UNIX/Linux available and using these we can create a superior working environment. However, one needs to find, buy, download. install and configure all of thee. And to be honest, this is more difficult than it usually is in Windows. But then again, once you achieved this, you are truly Playing with Power!
The official "Living Without Windows Solution Catalog" contains an overview of the various packages, programs and utilities I am using in order to achieve a certain result. These might not be the best, most super, most versatile or most user friendly tools for the given job. They were however the packages I happened to stumble on when searching and I have been able to use them to my advantage. Don't forget, I am always open to suggestions!
Category LWW Solution Word processing I basically use three types of solutions here: ApplixWare and LaTeX, and texinfo.
ApplixWare is an Office suite for Unix. It contains a word processor, a spread sheet program, a program to create graphics and presentations, a data manipulatuin tool, an HTML author, an e-mail client and a programming environment for writing macro's in Applix's own programming language ELF. Although not as extensive as Microsoft Office, ApplixWare contains all the features I use on a day by day basis. I find ApplixWare easy to use, straightforward and generally well worth the $99,= I paid for it. ApplixWare does a relatively good job of importing Microsoft Office documents, although I did have some problems with importing a certain Microsoft Word 97 document.
For large scale document development, like (course) books I use LaTeX: a public domain text formatting and type setting program. LaTeX is not certainly not WYSIWYG. Like other text formatters ("nroff", "troff", "DCF/Script", "runoff") you create your document using an ASCII editor. Embedded in the source text are LaTeX instructions that specify how the document is logically structured. The LaTeX text processor reads in your source document, formats each page and writes out a DVI file which contains a printable image of your document. You view or print the document using DVI viewers, such as "xdvi", "dvips" and "dvilj". Being a bit cumbersome, LaTeX is extremely well suited to writing large texts.
In addition to this, I am currently using GNU "texinfo" to develop a product manual for on of our software products (SRAM, a quite nifty system monitoring product, see http://www.osp.nl/sram). Texinfo is based on TeX, you can run TeX on the texinfo sources to obtain a printable version (DVI) of the document. However, when you run "makeinfo" on the source, you get GNU info files which can be browsed with the info viewer program "info". Additionally, from the public domain I downloaded a program called "texi2html" that can turn texinfo sources in HTML pages. So, from one source format to various output formats: paper, HTML and info.
Sound Linux incorporates support for sound cards. Configuring it can be very tiresome, as you have to know a lot of configuration parameters. My LWW article on getting my laptop's sound system running illustrates this very well. Finally, the Linux Open Sound System solved most of my problems. They support a bewildering array of sound cards and chip sets. In my opinion well worth the $20,= they ask for it. (also see this article on how the last few problems where solved).
To play WAV files I use either the "wavplay" tool (which came with SuSE Linux 5.3) or the OSS "play" command. To play MP3 files I use the "xaudio" program. This is essentially a shareware program which sets you back $10,= if you enjoy it. Xaudio is not only a player, but it also contains a software development kit (SDK) that you can use to incorporate sound support in your own applications!
Graphics Manipulation Under Windows I used to use "Paintshop Pro" to do all kinds of graphics manipulation such as converting between various graphics formats, resizing, scaling, changing colour palettes and so forth. I found a brilliant replacement for this in GIMP, the GNU Image Manipulation Program. GIMP does everything I want, and more, including converting an image to a Web optimised colour palette, screen grabs et cetera.
For batch mode conversions I use the PNM/PPM set of tools. They are a set of tools that can be used to convert a graphics file to another format and to manipulate the file (rotate, smooth, shear, ...). Especially handy is that Ghostscript can output to PPM file that can then be manipulated using the PPM tools and finally converted to something like GIF.
Compact Discs To play audio CD's I either use "xmcd" or "tcd". Both came with my SuSE Linux 5.3 Evaluation CD. The former is a graphical CD player which only runs under the X Windows System. The latter is a text mode CD player which runs on the console or through a terminal emulator ("xterm", "telnet", whatever). "xmcd" is more appealing, but requires some configuration (through a configuration script called "config.sh").
To copy audio tracks of an audio CD I use "cdda2wav". This is a very versatile utility that can copy all or part of an audio or multimedia CD and write it out to an industry standard WAV file. To convert a WAV file to MP3 I use the "encoder" utility. This program supports more options than I understand (not uncommon :-) but still produced a workable result when fed with all the defaults. Very commendable. I wrote a small script that I use to copy an entire CD to a bunch of different MP3 file in the current directory.
To exchange data with NT or Windows 9x machines I use either FTP, "smbmount" or "smbclient". The industry standard FTP file transfer is one of the easiest options when moving a few files hence and forth. If the Windows machine is not suitably configured to play FTP server I sometimes switch positions to the Windows console to FTP the other way round.
An alternative to FTP is "smbclient". This is an FTP like client program for moving files between the local system and a Windows file server. "smbclient" uses the Windows SMB protocol to access remote files. The user interface of "smbclient" resembles that of FTP. The advantage of "smbclient" is that the server need not be configured as an FTP server.
If I want to move more than a few files I use the Linux "smbmount" command to mount a Windows shared directory somewhere in my file system tree, e.g.:The problem with this is that you need to execute "smbmount" as "root", and that all file accesses through this mount point are authenticated as one user (the user that executed the "smbmount"). Apart from that there are only advantages here. You can use the files on the Windows server as if they were locally stored.# smbmount //ntserv/home /mnt
Backing up If I ever feel the need to backup the data on my laptop, I do so to a tape drive attached to one or our other Unix systems. I first configure my own "$HOME/.rhosts" file on the target server to allow "rsh" access for "root" and "josv" from jadzia.osp.nl. This facility allows me to login or execute commands on the target server from Jadzia. I then make a backup to that remote tape drive with the following command:This creates a tar archive on the tape drive of the backup server (bkupsrv). The "tar" command writes its archive to "stdout". This is piped to the "rsh" command which transfers its "stdin" to the "stdin" of the "dd" command that is running on the backup server. "dd" takes its input from "stdin" and writes it to the device file "/dev/tape".# cd /
# tar cvf - etc home var root | rsh bkupserv "dd of=/dev/tape"
Internet stuff I use Netscape Communicator 4.5 for web browsing, creating HTML pages (the Netscape Composer) and for reading and writing e-mail.
Normally I connect to networks using my 3COM PCMCIA ethernet adapter which I configure for the local LAN I happen to be connected to. For dialing out to the Internet I use the "pppd" package which sets up a serial connection through my Psion Gold Card PCMCIA fax/modem card and configures the "ppp0" network interface. KDE contains a spiffo "Dial-Up Networking" utility which allows for easy configuration and use of the dial-out facility. If you want to use PPP, you have to reconfigure the kernel to contain the PPP driver.
Linux supports the Advanced Power Management (APM) industry standard. You have to reconfigure the kernel to contain the APM driver. The "apmd" daemon interacts with the APM hardware (BIOS). It sends warnings if the battery is depleted and it resets the internal clock if the computer has been suspended. The "apm" program tells you the current battery status:"xapm" gives a graphical indication of the battery status. "root" can use "apm" to programmatically place the computer in suspend or standby mode (I should lookup the difference somewhere :-).$ apm
AC off-line, battery status high: 87% (2:54)
Rebooting the system Linux (like UNIX) supports the "shutdown" command to halt or reboot the system. When I halt the system, Linux even physically turns of the power thanks to the APM support that I configured in the kernel. However, obviously only the system administrator "root" is allowed to shutdown the system. As a matter of habit I never login as "root" for my day-to-day work: the awesome power of "root" makes even the slightest mistake a major disaster. I therefore have my own userid "josv" that I always use. When I need to do something special, I use the "su" command to start a subshell with a different user, mostly "root".
I find it very tedious to use "su" for common tasks such as a system shutdown. I therefore use the "sudo" facility to allow shutdown of the system by "josv". "Sudo" allows the system adminsitrator to configure that certain commands may be executed with "root" capability by ordinary users. The "/etc/sudoers" configuration file contains an overview of hosts, users, commands and capabilities. In this file I specified that "josv" is allowed to execute the "/sbin/shutdown" command:This settings allows me to use the "sudo" command to executed shutdown:Cmnd_Alias SHUTDOWN=/sbin/shutdown
josv ALL=SHUTDOWNjosv@jadzia:/home/josv > /sbin/shutdown -h"sudo" wants you to enter your user password just to make sure that it is you who is sitting behind the terminal. It caches the knowledge that you have entered the password so that if you use "sudo" again you need not enter the password again. This "cache" expires after a certain period of time. "Sudo" can be used to safely hand out the privilege to perform certain system administration tasks to ordinary users.
shutdown: must be root.
josv@jadzia:/home/josv > sudo /sbin/shutdown -h
We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these two things:
#1) Respect the privacy of others.
#2) Think before you type.
Password: password entry here
Usage: shutdown [-krhfnc] [-t secs] time [warning message]
-k: don't really shutdown, only warn.
-r: reboot after shutdown.
-h: halt after shutdown.
-f: do a 'fast' reboot.
-n: do not go through "init" but go down real fast.
-c: cancel a running shutdown.
-t secs: delay between warning and kill signal.
** the "time" argument is mandatory! (try "now") **
Terminal emulation I sometimes have the need to dial-out to a text based server (such as a Bulletin Board System). For really simple work, the UUCP terminal emulator program "cu" works fine. It is crude, but works quite well. For more complex stuff (including up- and download of files) I use "minicom", which is a full featured terminal emulator. "minicom" is very easy to use. Viewing Postscript PostScript is the "Lingua Franca" of the Unix world. Most utilities that generate output do so in Postscript: Applix, Netscape Communicator et cetera. When you receive a Postscript file you can view and/or print it with the Ghostscript and Ghostview tools. Ghostscript is an interpreter and renderer for Postscript files. Ghostview is a GUI for viewing Postscript files interactively. Highly recommended! Reading Unix
Normally, the "man" command is all you need to read standard Unix manual pages. A few years ago, I ran across "TkMan", a graphical, interactive, manual page viewer written in C and Tcl/Tk. I regularly use it for complex manual page reading which involves a lot of scrolling back and forth and/or looking up other manual pages. PDF - the Portable Document Format To read PDF files, the ubiquitous Acrobat Reader is also available for Linux. No surprises there. To create PDF files I use "ps2pdf" which is a script that starts Ghostscript with enough options to convince it to generate PDF. I wrote a small script which acts as a Unix printer driver, so I can print to PDF directly. More information can be found here.