Forward to the 32-bit past

April 5, 2008

After wrestling with incompatibilities of 64-bit Linux for a while, I finally downgraded my home PC to 32-bit Ubuntu 7.10 (Gutsy). I found some nice and less nice workarounds, like running the Windows version of Firefox under Wine in order to get Flash to work. I hadn’t found a workaround for the Java browser plugin, or for Skype, and was considering a 32-bit chroot environment.

Finally one of those automatic updates decided it for me. You know the ones, the  messages offering later versions of software, critical security updates and recommended updates. Being able to just click OK to automatically be upgraded to the latest software is part of what makes Ubuntu so friendly. But this time it wasn’t so friendly. Something left my PC unable to boot to multi-user, unable to start networking, and unable to start graphics. I don’t know what because I didn’t keep the disk image around for a post-mortem. It was much much faster simply to blow away my root partition with a complete new OS installation. So while I was at it, I dropped down to 32-bit.

Lots of things started working, but some got worse. I had always had a problem on Gutsy that after suspend/resume the Ethernet driver would get a reversed MAC address, complain that it was invalid, and switch to a new eth instance with a random MAC. Of course this played havoc with my router trying to keep track of where my PC was in order to provide DNS. This problem occurs in the forcedeth driver, reverse engineered for the nForce chipset. Some people worked around the problem with limited success by adding commands in the suspend/resume scripts to stop and restart networking.

But now on 32-bit Gutsy it got worse. Upon resuming the screen stayed black, and since the network seemed to be down I couldn’t remotely login to find out what was wrong. I found lots of reports on the web about suspend/resume problems with the same error message in my .xsession-errors

Gtk-WARNING **: This process is currently running setuid or setgid.

 

This seems related to my NVIDIA GeForce 6150 LE graphics. Like many others who posted their experiences, the problem occurred for me both with the generic open source driver and with the Nvidia proprietary accelerated driver. One person mentioned a workaround by logging out, logging in to a failsafe X-terminal, and suspending manually from there.

Irony: The main reason I’m running Ubuntu instead of Solaris is that Solaris doesn’t yet have power management, and for a home PC, suspend and resume are essential. I’ve been eagerly watching the power mangement project Tesla at opensolaris.org, wondering why it’s taking so long. I guess like most things it’s easier to do, than it is to do right. By comparison, my PC’s when running Windows 98SE often fail to wake up at all, and those running Windows XP tend to wake up by themselves, unbidden. The only systems where suspend/resume always worked were Linspire and, of course, MacOS.

Neither workaround by itself would work for me, but putting them both together I end up with a clumsy workaround that lets me suspend/resume, and may possibly point the way towards a less cumbersome workaround.

  1. Disable networking via gnome panel
  2. Logout
  3. Select failsafe X-terminal session
  4. Login
  5. sudo /etc/acpi/sleep.sh
  6. (system sleeps)
  7. (normal wakeup by pressing ENTER)
  8. Logout
  9. Select normal gnome session
  10. Login
  11. Enable networking via gnome panel

 


more on 64-bit Linux

January 4, 2008

I’ve found good information by searching blogs, but never before had the information just come to me – in the form of comments on my blog. Thanks to everyone who offered advice! Mikael Gueck’s fix sounds intriguing, but after blowing away one installation I’m hesitant to mess with the 64-bit libraries.

 Georgez is right that I’m not at all doing a feature to feature comparison of Solaris and Linux. I’m just trying to use my PC. And yes, my problems are mostly due to proprietary software.You guessed right that the VPN software is Cisco. I just hadn’t wanted to single them out for criticism. It’s their right to decide not to open source their software, and to decide which platforms to support and not to support. And yes, it was their decision not to support Solaris that moved me onto punchin, for which I’m grateful because I like it a lot better. I’ll investigate vpnc to see if it’s compatible with the VPN servers on the other end. I guess it ought to be if they’re both implementations of a standard protocol (ipsec), but sometimes there’s a gap between theory and practice.

I did try installing the non-Adobe flash (gnash) and the non-Sun Java plugin (Icedtea). Gnash plays youtube videos but the controls don’t work; I have to close the tab or window to make it stop. I haven’t made any Java applet work at all. I haven’t looked yet inside Sun to see what the problem(s) are with providing 64-bit plugin support, and when I do I won’t be able to write about it, assuming anything inside to be company confidential. But since Java is open source I have to think somebody must have gotten the idea they don’t need to wait for Sun, and all the development process is open, so I bet that over in the Java forums I’ll find lots of public information about the issues.

Perhaps the most promising answer to my 64-bit problems is a question. Dmitri asks why anyone would need a 64-bit browser. I’m pretty sure I don’t. That’s just what Ubuntu offered to install. But what about running a 32-bit Firefox on 64-bit Ubuntu? I don’t see any such thing looking in Synaptic, or on mozilla.com. 

Searching around I found this posting by Rhaurison. He runs not only Firefox in 32-bit mode but also Opera, Skype, and other applications. He avoids conflicts by keeping 32-bit applications in a chroot environment, and points to this posting by Crad explaining how to set up such an environment.

When/if I try it I’ll write about it. And if you’ve already done it, please post a comment. I love it when good information just comes right to me. Thanks again, people!
 


Linux 64-bit woes

January 4, 2008

13 years ago I switched from 32-bit Solaris to 64-bit and everything just worked. So when I installed Ubuntu 7.10 on my home PC I never considered installing anything except the "best" 64-bit version. As I noted, most things work, even if you have to beat the package manager into submission, insisting that 64-bit x86 is upwards compatible with 32-bit x86. But you have to be really careful with that –force-architecture flag because Linux doesn’t seem to allow multiple versions of system libraries, and if you overwrite a critical library routine with an incompatible version, you’re hosed.

It turns out that amd64 compatibility on Linux has long been a hot topic, leading some people to debate the merits of falling back to 32-bit Linux. Flash player won’t work. Java browser plugin and web start won’t work. (I’m embarrassed by that one!) My VPN client software won’t work. As someone commented about flash on a discussion forum:

Stop saying something is available on Linux when what you mean is that it is available on Linux, with Intel processor, in 32-bit mode.

But wait, isn’t open source supposed to remove all compatibility issues? Well, after compiling a lot of packages I’d add to the advice above, please say if you mean it works on Red Hat distro only, or if you mean kernel 2.6.9 or later, or if you mean uni-processor only.

I found a great workaround for flash. Simply install the Windows version of Firefox using wine. On Ubuntu 7.10 I didn’t even have to use the command line instructions listed in the howto. The installer just made a desktop icon for me, which I renamed from "Firefox" to "Windows Firefox" and I just click it to run. I haven’t yet found a workaround for the Java plugin, which prevents me from using many web applications like WebEx.

Like flash, the VPN software is proprietary closed source code, so compatibility updates are under sole control of the owner. Using Solaris on the same PC the VPN worked flawlessly. Open source Solaris includes punchin implementing ipsec. So rather than wait for the proprietary VPN vendor to decide amd64 is worthy of their time to do a compilation, I might do better to investigate Linux implementations of ipsec.

So for things I want to use at home, Linux is looking less "open" than Solaris. (See Jim Laurent’s comparison.) But I still love Ubuntu!


taming Ubuntu packages 32/64

December 12, 2007

Thought you had escaped the old package dependency trap? Ubuntu and other Debian derived systems have nice package managers that automate all the dependency checking. But frequently they don’t work because I have a 64-bit AMD Athlon and I get errors like this one for Skype:

package architecture (i386) does not match system (amd64)

Of course amd64 runs i386 just fine, but try telling that to the package manager. Well, if you run dpkg manually you can use the –force-architecture flag, but then it’s up to you to sort out all the package dependencies. Worse, when you seem to have all the required libraries the executable may fail to run because a dynamic library is only available in 64-bit version and it wants 32-bit.

I finally got Skype running by tracking down all the required 32-bit libraries from http://packages.ubuntu.com/. But it seems there is a tool to make it much easier to manage a 64-bit Ubuntu in a world of 32-bit applications: getlibs. This utility examines an executable and finds all needed libraries. Thanks to Shameel Arafin for his posting that led me to this valuable information.

Indulging myself in a moment of grumpiness: I never have these problems in Solaris! Not on SPARC, nor on x86, nor on amd64. Indeed I never even have to think about whether I’m on SPARC, x86, amd64, or intel64. Grumpiness over, I still like Ubuntu a lot.


Update: Don’t fool around with –force-architecture too much on system libraries. My PC wouldn’t wake up. Networking and X were trashed, and I reinstalled the OS – quicker fix than troubleshooting. I guess Linux doesn’t keep multiple versions of dynamic libraries like Solaris does, and if you get the wrong one you’re in for trouble. I expect the getlibs utility, had I found it first, would have saved me from this. And yes, I still like Ubuntu.

 

 


MySQL default admin password on Ubuntu 7.10

December 9, 2007

After installing MySQL on Ubuntu 7.10 (Gutsy Gibbon) I couldn’t connect to the database. Usually MySQL is installed with a blank root password which you should immediately change. Here the package I installed already had the password set to something, but what? I found many blog and forum postings telling how to change the password – assuming you already knew it. And I found many saying that you would be prompted for an initial password when you installed it. Not so for me.

 I found the solution that worked at linuxweblog, posted by sandip. You start the safe daemon with an option to disable grant tables, and set the password. Don’t forget to kill the safe daemon and restart MySQL normally.
 


Ubuntu 7.10 on an old PC

November 20, 2007

My little boy kept asking for Ubuntu on his PC, and I finally installed 7.10 Gutsy Gibbon last weekend. I ran into some problems I hadn’t seen installing it on two newer PC’s, so I thought I’d pass along some tips to others who may be making old systems brand new.

The first problem was that the GUI installer would not run on the small memory (256MB) system, so I had to use the alternate text installer. (Actually, as I found later, that may not have really been the problem.) The MD5 signature of the alternate installer ISO file I downloaded matched, and I burned a CD. That CD worked fine up through the point where it repartitioned the disk, blowing away the old working operating systems. But then the installation failed, on a CD read error.

I burned many more CD’s of the older 7.04 Feisty Fawn as well as of 7.10, and all failed. First lesson learned too late: go ahead and spend the extra time letting the installer do the "verify CD" operation before you blow away your old OS. Finally I burned a brand new CD-RW (700MB – small ones won’t hold it) at 4X speed, instead of the default "fastest possible speed" I had used earlier. It may have been the name brand (Maxell) CD-RW. Or it may have been writing at a slow speed (that was fast back in 1999 when the target PC was built). Anyway, that did the trick, and I had no more CD read errors. Maybe the original GUI installer would have worked if it had been burned on a high quality CD at low speed.

Once 700MB of software was installed, it immediately set about downloading updates to replace a great deal of what I had just installed. Sheesh, the OS is only a few weeks old and already everything is outdated. Why do they even bother with the CD image instead of just shipping a net bootloader?

The net update stalled – the screen seemingly frozen. After an hour of uncertain waiting, I broke out of it, killed a runaway process, and looked to see whether enough of the system was stable to allow it to recover. The problem was scrollkeeper. For some reason it causes no trouble on two newer PC’s, but here it prevents software updates from completing.

http://ubuntuforums.org/showthread.php?t=50796

http://ubuntuforums.org/showthread.php?t=596182 

The draconian fix suggested in a forum, to make all scrollkeeper
executables non-executable, took care of the problem and the new system
now works fine. Cool games and all.