Archive for the ‘Puppy’ Category

Auto-indentation in Geany: made for programmers, great for writers

September 18, 2008

Not that anything approaching brain-surgery-level thinking was in any way involved here, but I figured out why and how it’s easy to get paragraphs to automatically indent when writing in the Geany text editor.

First of all, it’s not called automatic tabbing or paragraph inentation. The correct term for what I’m enjoying so much is auto-indentation and it can be turned on and off under the Document menu in Geany. The defaults for auto-indentation can also be set in the Edit menu under Preferences–Editor.

When writing for print, where I don’t need — and can’t stand — having two returns between paragraphs. After transferring the file from this laptop to my newspaper’s print publishing system, those double-returns demand that I delete one of them. That’s because in most non-Web publishing, indented first lines make paragraphs distinct from one another, not extra linefeeds.

So having the indents on the first line of every paragraph helps me seen where each paragraph begins.

I know that programmers use indents to help structure their code. But when something so right for coding in C also helps hacks like me, making traditional word processing applications less needed, everybody wins.

Long-lost Click: 64 MB to 144 MB — will it make a difference?

September 16, 2008

(This post was originally written on May 22, 2008; since that time, I’ve added the RAM, and it does indeed make a difference. It’s still not easy to live with 144 MB of RAM and 233 MHz of CPU, but it’s easier than having less than half of that M. What I can say is that 500 MHz of CPU and 256 MB of RAM is positively picnic-ish. Also, I finally did the OpenBSD 4.2-to-4.3 upgrade on the VIA box. It wasn’t easy, but I did get it done.)

If the question is “how low can you go” in terms of computer memory, it’s all about applications.

If you stayed in the Linux console and never ran X, just about anybody could be happy with 32 MB of RAM. It might be hard to actually run Linux or a BSD in 16 MB, but I’ve heard of Linux distributions that will do it, Damn Small Linux, Tom’s RtBt (is that the right spelling?) and DeLi Linux among them.

But as much as the hard-core users talk about how they stay at the command line all the time, it’s hard to get much done strictly in a console when you’re a regular person. Sure you can use Lynx for text-only Web browsing, you can set up Mutt (and Postfix/Sendmail/msmtp/esmtp, Procmail and whatever other helper apps are needed) with highly customized configuration files designed to handle and filter multiple mail accounts, use Vi or Emacs for text editing and all that.

But the bottom line for me is that I need a Web browser. A “real” Web browser, something that works with Movable Type and Google Docs, and that pretty much means Firefox or some Iceweaselish derivative.

I don’t tend to use OpenOffice very much (although it runs better in Debian with 64 MB that you’d think), I barely even use AbiWord these days. I’m not saying that I won’t need OpenOffice in the future, but at present I’m most comfortable using various X text editors, including Geany in most Linuxes and BSDs, Gedit when I’m in GNOME, and Google Docs half the time just for the easy portability of my copy.

And while Geany doesn’t load super quickly from a “traditionally” installed distribution (but is quite quick when loaded into memory as it is in Puppy Linux, once it’s loaded it runs very well indeed.

And the Dillo Web browser — which looks better in its OpenBSD incarnation than it does anywhere else — performs quite well in 64 MB of RAM. The only problem is that Dillo can’t do everything I need to do on the Web. At least the Dillo in Puppy and DSL has https support. That’s not turned on in OpenBSD, and the app needs to be recompiled to add it. I can manage to turn on cookies in OpenBSD, which helps me with some sites, but for anything remotely complicated, Firefox is essential.

And while Firefox will run in 64 MB of RAM, it does so very poorly. There just isn’t enough memory to keep the program from swapping to the drive incessantly whenever doing just about anything.

In this very 64 MB, I’ve run just about everything that will load on this Compaq laptop: Puppy, DSL, Debian (the Xfce install, plus a “standard” install with Fluxbox), Slackware (without KDE) and OpenBSD.

Truth be told, Almost all of these OSes run just about the same. Damn Small Linux has a bit of an edge, and if DSL 4.3 ran as well as 4.0, its inclusion of Firefox 2 would put it over the top. As it is, I’ve lost my desktop wallpaper, and I can’t figure out how to display the menu in Fluxbox (even though I prefer to run JWM).

Puppy definitely needs more memory, especially to run the Mozilla-derived Seamonkey Web suite.

Debian Etch was OK. While the Xfce install is odd in many ways, as I say, I was surprised to see OpenOffice run at all — and not too badly at that. Iceweasel was, again, an exercise in frustration. But Debian remains a distinct possibility for this machine.

It’s main OS for awhile has been OpenBSD, with a partition set aside for the Linux files generated by the Puppy and DSL live CDs.

OpenBSD runs pretty well, but as I said, Firefox remains an issue.

The question: Will things improve with the boost of RAM from 64 MB to the Compaq Armada 7770dmt’s maximum 144 MB? From my past experience, I know that Puppy can run in 128 MB if you have swap space, and DSL is certainly comfortable with 128 MB.

To answer the question, I could reduce the memory in my Via test box from 256 MB to 128 MB and see how OpenBSD (now version 4.3) runs in that configuration. But I’d have to pull the cover from my converted thin client and find a 128 MB SIMM. I’ve probably got one … somewhere.

Better to just wait for my Compaq memory to come in the mail (luckily it’s cheap).

I’ve know for awhile that 256 MB is a significant sweet spot for Linux, but I’d love for 144 MB to be just sweet enough to give this laptop a new lease on open-source life.

And while I managed to upgrade my VIA box from OpenBSD 4.2 to 4.3, it takes a lot more work than a simple apt-get, and I’m reluctant to do it

Fsck errors in the Linux filesystem on my OpenBSD laptop NOT caused by OpenBSD

August 30, 2008

I’ve been able to have OpenBSD’s /etc/fstab automatically mount the ext2 filesystem on my Compaq Armada 7770dmt’s hard drive with no difficulty lately, but every couple of days or so I get a message while booting OpenBSD that says the Linux filesystem is not clean and that I should run fsck on it.

I then boot Puppy Linux 2.13, run e2fsck on the partition, the errors are cleared up, and all is well until a few more days pass.

I haven’t lost any data, but I’m going to do a few experiments.

First, I added noauto to the /etc/fstab line so the Linux filesystem will not be automatically mounted. Then I’m going to run Puppy for a few days and check the filesystem with e2fsck.

It could be that the errors are coming from Puppy alone. I think that’s unlikely, but it is a possibility.

Then I’ll experiment with manually mounting (with mount) and unmounting (with umount) the Linux filesystem while in OpenBSD.

That way I can see whether or not automounting and unmounting the ext2 filesystem in OpenBSD is what’s causing the problem.

Hours later: Looks like OpenBSD is NOT responsible. I ran Puppy totally in RAM (using the puppy pfix=ram boot parameter), than ran e2fsck to clean up the filesystem on my ext2 partition. Then I ran Puppy the “normal” way, in which the system mounts the partition to access the pup_save file. I then rebooted and once again ran Puppy without mounting the partition. At no time did I boot OpenBSD or mount the filesystem in that OS.

Once I was back in Puppy, running pfix=ram to keep the partition unmounted, I ran e2fsck and got this message:

/dev/hda3 was not cleanly unmounted, check forced.

I had one more test to do.

Now that I had run e2fsck on the ext2 filesystem, I needed to boot OpenBSD, mount the filesystem, write a file to it, then unmount it. After that, it would be time to boot Puppy Linux again, using the pfix=ram boot parameter again so as not to mount the filesystem in Linux, and then run e2fsck again to check the filesystem and see if mounting, writing to and then unmounting it caused any errors.

So I booted into OpenBSD 4.2, mounted the ext2 filesystem, modified a few files, added a few, then unmounted it. I rebooted and did the same thing again.

Then I booted into Puppy, again with the pfix=ram boot parameter so as not to mount the Linux partition.

I ran e2fsck. After two boots of OpenBSD, during which I modified files in the Linux filesystem both times, there were no errors in the ext2 filesystem.

I said it was “unlikely,” but in fact it’s Puppy Linux, NOT OpenBSD that is not “cleanly” unmounting the Linux filesystem. I truly expected it to be the other way around.

I’ll have to test this with Damn Small Linux, Wolvix and maybe even Slitaz to see if this is a Linux problem, or just a Puppy (or Puppy 2.13, to be more specific) problem. But right now, OpenBSD has absolutely nothing to do with it.

Mounting the filesystem in:

Damn Small Linux 4.3 caused no errors

OpenBSD on the $15 Laptop: The application shuffle

August 27, 2008

I’ve had a bit of a difficult time with my OpenBSD 4.2 installation on the $15 Laptop — a Compaq Armada 7770dmt with 144 MB RAM, a 233 MHz Pentium II CPU and 3 GB hard drive. I use PCMCIA cards for networking, an Orinoco WaveLAN Silver for 802.11b wireless and a TRENDnet TE-100PCBUSR 10/100mbps for wired Ethernet.

Since I upgraded the memory from 64 MB to the 144 MB maximum for this machine, things are running much, much better.

But I’m running out of room in the /usr partition. I’m not sure whether or not OpenBSD can be installed in a single partition, but since the install FAQ tells you to set up separate partitions for everything, that’s what I did.

On this drive, I set aside about 600 MB for Linux filesystems to create swap and a place to store files for Puppy Linux, leaving 2.4 GB for OpenBSD.

At the end of the OpenBSD partitioning, I had 1 GB for /usr, which is where applications are stored in the system.

For awhile things were going fine. I had our daughter’s Gcompris, TuxPaint and Childsplay games on here, Firefox, the Geany text editor, plus a few console apps like nano, mc and mutt.

But it’s not console apps that are taking up all the space.

I pulled the games and their libraries in order to fit the Opera Web browser and the Linux compatibility package needed to run it. That was the best thing I’ve done for this install since I did it. On this old hardware, the Linux build of Opera runs much faster than Firefox.

That speed really shows up when blogging with Movable Type. For some reason, even in Linux, scripts keep timing out in Firefox and the Mozilla-based Seamonkey. Now that I have Opera installed in both OpenBSD and Puppy 2.13, I’m a lot happier on this old laptop, which is about as challenged as it gets when it comes to old hardware working with modern operating systems and applications.

Anyhow, I needed to do some more “formatted” writing, and I did have the Ted word processor installed. But Ted isn’t great when it comes to centering type, print previews or generating PDF output.

I needed Abiword. But I didn’t have enough space.

The only thing big enough: Firefox.

Yep, I got rid of Firefox. One thing about the OpenBSD package manager that isn’t helping me out here is that when you install a package, all the dependencies are checked, and the additional packages needed are downloaded and installed. But when you remove a package, the system doesn’t check its dependencies for whether or not they’re still needed by other applications in the system.

I’m sure there’s a reason for this, and there’s probably even a way around it (like the great deborphan app that I use in Debian), but I know nothing about it.

Anyhow, I managed to get Abiword installed, and I have 500 MB left in my /usr partition. Unfortunately, the spell-check in Abiword doesn’t work in the OpenBSD build. Abiword spell-check doesn’t work in Puppy either.
The spell-check installs and works most of the time in Debian (especially when you install it with Aptitude and get all the packages you need, rather than with apt-get, where at least sometimes you don’t).

I found an old OpenBSD mailing-list hack about how to fix Abiword’s spell-checking capability, but it didn’t have enough information, and it didn’t look like it would work anyway.

But the good news is that with this amount of memory, Abiword 2.4.5 runs extremely well in OpenBSD 4.2. Additionally, for some reason the fonts in Abiword look better in OpenBSD than then do in most other Linux/Unix systems.

So now I have Abiword, Geany, Opera and the Dillo browser as my “main” applications on this system. I don’t want to forget the Rox-filer file manager. I put that on the box awhile ago. I still need space to add the Flash plugin for Abiword, and Rox is a prime target for removal so I can get that space … or the space to install Gaim/Pidgin for IM.

But I just can’t do it. I’ve loved the Rox-filer ever since I first used it in Puppy, and I just can’t give it up.

I probably should. I removed mc (Midnight Commander) for space reasons, even though it probably doesn’t take up all that much space, and since I had Rox. If mc didn’t have problems with the function keys in the console (it misreads the keys for some reason), I’d be able to fit one more app in. (Note: mc works perfectly in an xterm window, just not in the console).

What I’m going to have to do eventually is reinstall OpenBSD. I need a bigger drive so I can have a big /usr partition, install everything I want on it, as well as have room for a full Linux install as well, something I could use in addition to Puppy.

So the OpenBSD install is really tight, in terms of space for applications, but it’s working extremely well. I now have the ability to share files between OpenBSD and Linux via an ext2 partition, and that has added tremendous value to this laptop.

I could be using my Gateway laptop a lot more. It’s got way better specs (1 GB RAM, 1.3 GHz CPU) and runs Linux way faster. But it isn’t so hot with OpenBSD due to the noisy, uncontrollable-by-BSD CPU fan. And its PCMCIA slot still isn’t fixed, so I can’t run wireless with it.

The Compaq may be underpowered, but it has a very clear, very bright screen, an excellent keyboard, working wireless, no ACPI issues (since it has no ACPI), and there’s just something about getting it to work and keeping it working that I find compelling.

And there’s also something about OpenBSD that keeps me coming back to it, even on the desktop.

I bring OpenBSD and Linux together

August 26, 2008

I’ve been trying to mount a Linux filesystem in OpenBSD 4.2 for awhile, and finally I figured out how to do it (and do it automatically at boot) without screwing up either my OpenBSD or Linux partitions.

I have a tutorial on this about 1/2 of the way done, but this was another situation where the excellent OpenBSD FAQ and man pages, as well as a couple of good general Linux/Unix online tutorials gave me all the help I needed. (I can never remember quite how to make chmod do what I want without looking it up.)

Since I installed OpenBSD on the Compaq Armada 7770dmt’s hard drive without fully setting up the Linux partitions (all I have is swap and an ext2 partition for my live CD files), OpenBSD didn’t know how to properly mount the ext2 partition.

Briefly, I needed to run fdisk in OpenBSD, transfer the Linux information to the OpenBSD disklabel, create a directory in which to mount the Linux filesystem, give the wheel group write access to that directory, then edit /etc/fstab to properly mount the ext2 filesystem at boot.

Once I was sure the Linux filesystem was properly mounting and was writable from OpenBSD, I booted Puppy Linux without mounting the partition and then ran e2fsck to clean up any errors (there were some).

Since then, the filesystem has been error-free, and I can easily exchange files between my OpenBSD and Linux installs on this laptop.

It’s nice to solve a problem for a change.

I bring OpenBSD and Linux together

August 26, 2008

I’ve been trying to mount a Linux filesystem in OpenBSD 4.2 for awhile, and finally I figured out how to do it (and do it automatically at boot) without screwing up either my OpenBSD or Linux partitions.

I have a tutorial on this about 1/2 of the way done, but this was another situation where the excellent OpenBSD FAQ and man pages, as well as a couple of good general Linux/Unix online tutorials gave me all the help I needed. (I can never remember quite how to make chmod do what I want without looking it up.)

Since I installed OpenBSD on the Compaq Armada 7770dmt’s hard drive without fully setting up the Linux partitions (all I have is swap and an ext2 partition for my live CD files), OpenBSD didn’t know how to properly mount the ext2 partition.

Briefly, I needed to run fdisk in OpenBSD, transfer the Linux information to the OpenBSD disklabel, create a directory in which to mount the Linux filesystem, give the wheel group write access to that directory, then edit /etc/fstab to properly mount the ext2 filesystem at boot.

Once I was sure the Linux filesystem was properly mounting and was writable from OpenBSD, I booted Puppy Linux without mounting the partition and then ran e2fsck to clean up any errors (there were some).

Since then, the filesystem has been error-free, and I can easily exchange files between my OpenBSD and Linux installs on this laptop.

It’s nice to solve a problem for a change.

X crashes $15 Laptop in Puppy Linux 3.01 — so where do I turn?

August 23, 2008

My exhaustive (and exhausting) eight-part series on what OS to run on the $15 Laptop (Compaq Armada 7770dmt, 233 MHz Pentium II MMX, 144 MB RAM, 3 GB hard drive) spent a good deal of time on how Puppy Linux represented the best combination of quickness and out-of-the-box features of any operating system for this old, underpowered hardware.

I based all of that on running Puppy 2.13. I managed to boot Puppy 4, but the relative slowness of Abiword to start had me pausing about an upgrade from 2.13.

I must’ve forgotten that I couldn’t get X to work in Puppy 3.01 on the Compaq. I might be able to figure out the configuration later. Or I might not.

Sticking with Puppy 2.13 is a distinct possibility, as is going to a later build in the Puppy 2 series (probably 2.17) just to get some newer packages and, more importantly, the ability to encrypt my pup_save file.

Considering the possibility of upgrading to Puppy 4.00, a slow Abiword I can handle, especially because I learned something very helpful about the Geany text editor, at least the version in OpenBSD 4.2 (version 0.11) and not that in Puppy 2.13 (version 0.10). That “valuable” something (meaning valuable to me and my work and likely not to you or yours is this:

When you tab before beginning writing a paragraph, the build of Geany in OpenBSD (and likely in most Linux systems with updated packages) will automatically tab when you hit the return key to begin your next paragraph. That means not needing to continually hit the tab key to make my paragraphs look separate when NOT writing for the Web.

For the Web, there are usually two returns (or the <p> HTML code) between paragraphs. For print, the paragraphs don’t have space between them and can only be told apart by their indents, something which I’ve been relying on word processing programs to do for me and which I now will be able to do in Geany.

The ability to create copy for the Web and for the Daily News print system with the same text editor, and to do it with a minimum of formatting, is a very good thing indeed.

Trying to add Linux partitions to my OpenBSD disklabel

August 22, 2008

The OpenBSD system on the $15 Laptop (Compaq Armada 7770dmt) has a 3 GB hard drive mostly devoted to OpenBSD, with about 600 MB set aside for Linux, about 130 MB as Linux swap and the rest an ext2 filesystem on which I have my pup_save file for Puppy Linux and any other Linux files I’ve generated with other live CDs (Wolvix and Slitaz at the moment).

As I recall, I created the Linux partitions at one end of the drive and reserved the front for OpenBSD.

As a result, OpenBSD wrote its disklabel — the system’s guide to how the drive is partitioned — to include one big Linux partition and not the separate swap and ext2 partitions I later created.

Check your disklabel this way (as root) (and with the name of your drive, mine being wd0):

# disklabel wd0

You should see any non-OpenBSD partitions at the end of the list.

You can edit the disklabel this way:

# disklabel -e wd0

This opens a file in vi (the default editor in OpenBSD, or whatever the $Editor variable is set to; I’d reset it to Nano if only I knew how).

I tried to modify the disklabel to recognize BOTH Linux partitions, but all I got were errors in both OpenBSD and when booting Puppy 2.13.

To figure out how to edit the disklabel, I ran the following command in OpenBSD:

# fdisk wd0

I figured that copying the “start” and “size” info into the disklabel would make my Linux partitions mountable in OpenBSD.

Nope.

I got some fsck errors when I booted Puppy. I fixed them by a) deleting and re-creating the Linux swap file and b) running Puppy in RAM (boot parameter: Puppy pfix=ram) and running e2fsck on my ext2 partition.

I still don’t have my Linux filesystem mountable in OpenBSD, but I didn’t lose any files or filesystems either.

Clearly I need to figure out how to take the information from fdisk and properly write it in the disklabel.

I’m just glad (and very much amazed) that I didn’t lose anything. It’s a tribute of sorts to the OpenBSD system and documentation that I managed not to totally kill the whole installation.

Browser performance: Opera vs. Firefox/Seamonkey in OpenBSD and Puppy

August 21, 2008

I know that application startup time isn’t everything. But it’s definitely something.

Here are the numbers for Puppy 2.13 and OpenBSD 4.2 on the $15 Laptop (Compaq Armada 7770dmt, 233 MHz Pentium II MMX, 144 MB RAM):

OpenBSD
Firefox 2.0.0.6: 120 seconds
Opera 9.22: 37 seconds

Puppy Linux 2.13
Seamonkey (Mozilla-based): 30 seconds
Opera 9.02: 34 seconds

Analysis: Firefox/Mozilla is a fairly heavy application, but the Seamonkey version of Mozilla does quite well in Puppy, where it beats Opera slightly when it comes to start time.

But in OpenBSD, Opera is a standout for some reason, starting in about a third of the time that Firefox takes to start. Opera works with Movable Type much better in OpenBSD, with no stalled-script messages.

Question: Is there any way to run Mozilla browser code faster than Firefox? I need to test Firefox in Puppy (and, if I had the space, Seamonkey in OpenBSD) to fill out the data.

Conclusion: Application startup and response time is extremely critical with older machines. Since most of my computing time is spent in Web browsers, I welcome the speed and functionality of Opera in OpenBSD; it has pretty much given this OS a proverbial “new lease on life.”

In search of the best OS for a 9-year-old laptop: Part VIII — Final thoughts (aka “Why?”)

August 5, 2008

You might ask why I’m spending so much time figuring out how to best configure a Compaq Armada 7770dmt — a laptop with an ancient 233MHz Pentium II MMX processor, feeble 144MB of RAM and smallish 3GB hard drive.

For one thing, I almost never abandon a machine that can be used. And this one definitely can be.

Plus, I like the Compaq. It has a nice screen and keyboard, I like the fact that its power supply is totally contained in the laptop case. The thing’s pretty solid.

And I remember my long search for a laptop. Just about everything I saw on the used market was overpriced and lacking essential parts (hard drive, power brick, CD drive, memory …) but still selling for too much.

When I found this laptop for $15 and only had to add a CD-ROM drive that cost an additional $10 and a WiFi card I already had, I was hooked.

The build quality of this 1999 Compaq is much better than my 2002 Gateway, and I expect the Gateway to die long before the Compaq.

And with Linux, I’ve learned that a nearly 10-year-old PC can be quite usable. That means This Old PC, with a faster Pentium II processor (333MHz), more RAM (256MB) and which uses cheaper desktop IDE drives — and which at 11 years old is even longer in the tooth than the Compaq — is also still quite usable.

The fact that I searched long and hard for one laptop, came up with nothing from Craigslist and eBay, but then ended up with two laptops within months, getting each for next to nothing, was an opportunity to learn about hardware, software and what it takes to get things done in a variety of operating systems (I’ve run many versions of Linux, plus FreeBSD — including offshoots DesktopBSD and PC-BSD, NetBSD, OpenBSD, a couple of projects based on OpenSolaris, and yes, even Windows).

Even if I had $500 or so to buy new laptops every couple of years — and believe me, I don’t, there’s a lot of nobility, fun and plain old value in keeping these PCs running. And running well.

I guess you could call it a hobby.

I could do a lot worse, no?


Previously:
In search of the best OS for a 9-year-old laptop: Part I — Puppy or Damn Small Linux
In search of the best OS for a 9-year-old laptop: Part II — OpenBSD or Debian?
In search of the best OS for a 9-year-old laptop: Part III — Browsers and wireless
In search of the best OS for a 9-year-old laptop: Part IV — Wolvix Cub is surprisingly strong
In search of the best OS for a 9-year-old laptop: Part V — Where I’m headed
In search of the best OS for a 9-year-old laptop: Part VI — Younger Puppies
In search of the best OS for a 9-year-old laptop: Part VII — Debian with Xfce and Fluxbox calls