Sunday, April 26, 2015

Debian Jessie Turns Stable

I know it's hard to hear me over the din of the roof-raising Debian release parties, but I'll try.

Debian Jessie turned stable today, so what does it mean for PowerPC users? It's been a two-year, sometimes harrowing ride for Jessie, but now that it's turned Stable, I think it's... okay. On Mac models where it works well, like my aluminum Powerbook, it's great and a nice improvement over Wheezy. Unfortunately some models experience serious bugs out of the box, but the good news is there are workarounds. On that subject, I've just updated my Debian install guide taken from my own experiences installing on a few different Macs.

Yes, there's a major sound bug affecting my G3 iBook, and according to reports, several other models, but there's a workaround. There are some severe graphics bugs, but there are workarounds. I'm hoping this is a time of transition for PowerPC Linux, where the right bug reports and testing will lead to a better-out-of-the-box experience around the corner.

I've seen people write that we shouldn't bother filing bug reports on KMS because KMS on PowerPC will never be fixed. I'm going to test that theory. I have a black screen of death issue with my iBook that requires disabling KMS, so I'll file a bug report on that and see where it goes (UPDATE: here's the bug report). On the sound bug front, a developer doing I2C work just popped in on the Debian PowerPC mailing list and offered to work on it, with the right assistance. If there's anyone with an afflicted machine who can compile custom kernels, I'm sure he'd appreciate your help. If it's gonna be me, theeeeeeen I guess I better learn how to compile custom kernels (UPDATE: I just compiled a custom kernel and am helping to debug kernel patches. Weeeeeeeeeeeeeeeeeee!).

Also, a shoutout should go to Ubuntu MATE's PPC maintainer for making patched Mesa binaries available that also work on Jessie.

Here are a couple of screenshots of my iBook's Openbox desktop (my Powerbook ain't all purtied up yet):

Openbox menu

Openbox Desktop

Monday, April 6, 2015

Set Up That Server You Always Wanted To

You've probably read about servers, and if you've never run one before, thought it sounds like a cool thing to do. You also may have a spare PowerPC Mac lying around doing nothing, which is why this post is about you (yes, I can see you). I have an old Sawtooth that I just can't quit—they're terrific machines—and I wanted to write a post on how I set it up as a headless file/bittorrent server that's so simple anyone can do it.

The first consideration is the hardware. Electricity consumption is one reason, and hard drive space is another. If you're lucky enough to have a Sawtooth, they offer the best balance of the two. Mac Minis consume the least power but may have limited hard drive space. A laptop with say a broken screen would also be a low-power alternative. Sawtooths use about 50 watts at idle in their basic configuration, and subsequent Power Macs used a bit more until G5s came along idling at 150 watts. So a G5 is a bit impractical for our purposes.

So now that you got the hardware, what do you do with it? You could set up a music server, a print server, or a backup server among other things. I wanted a bittorrent server because I'm on a private tracker for classic films and need to seed a bunch of films long-term without taking up space on my Powerbook. I also wanted something I could sync backups to via Unison. Finally I wanted to sleep the computer at night, so I'll be doing this on OS X and not Linux.

Before you go completely headless, you'll want to set up a few things on your server with a monitor attached. First, give it a static IP address because you'll have to forward ports to it and you don't want your router intermittently changing the server's address. To do this, go into Network Preferences, and under the TCP/IP tab choose "Configure IPv4:" "Manually". Then fill in an IP address your router hasn't already assigned as well as your router address. You can see an example below:


You'll also want to install a VNC server which will let you control your headless Mac from your other computers. VNC stands for Virtual Network Computing, and in practical terms it means you can display your server's desktop on any other computer with a VNC client. So this server business doesn't have to be all SSH commands and terminal outputs. It can be point and click just like any desktop.

OS X's Preferences has something smilar to VNC called Apple Remote Desktop that's compatible with VNC clients, but people complain it's slow and I also don't see any SSH options, so it's not secure. A pure VNC server has a remote login option so your sessions will be secured through SSH. The best server for PowerPC is Vine Server (OSXvnc). There's a slightly updated version at this TestPlant page, and manuals, too.

So once you've installed that and any other software you want to operate, like a bittorrent client, you're all set to go headless.

The next step is to forward ports on your router so it knows which computer to send all the traffic. In your router's administration, forward port 22 to your server's IP address as TCP only. Port 22 is for SSH. For VNC, forward ports 5900 to 5909, also TCP only, to your server's IP address. I've also forwarded a port for my bittorrent client, Transmission (the same port number you set in Transmission's preferences).

Finally it's time to download a VNC client, and the one and only choice is Chicken (formerly Chicken of the Sea VNC). Other clients may be just as good, but none can match its dock icon, a chicken popping out of a tuna can. If you already have Tenfourbird, TenFourFox, and Cyberduck, this will look right at home among them. Don't forget to check Chicken's SSH tunneling option and that Chicken's SSH host is not just the IP address but username@IP address, like dan@192.168.1.160. Also, you should already know to have a strong password, but I'll reiterate it anyway. Especially with port 22 open, you should have a strong password.

Now when you click connect you should see the server's desktop on your client desktop.


(the password is actually longer than that graphical string indicates)

As for putting your new server to sleep on occasion, you can set Energy Saver preferences on some Macs to have the power button sleep the computer, but if your Mac is in a hard-to-reach location there's another alternative. It's called Wake-On-LAN*, and it's a simple packet that sleeps and wakes your computer over the network. There's a WOL utility conveniently called WakeOnLan that works on Tiger through Snow Leopard but reportedly not on Lion. I read there are also several iOS apps for this. I also read, though I haven't tried this, that you can forward port 4343 and sleep/wake your computer from outside your network, assuming you know your network's IP address. In either case, you must check "Wake for Ethernet network administrator access" in your server's Energy Saver preferences.

*I believe this only works on ethernet-connected servers in Tiger and Leopard. Wake-On-Wireless was enabled in Snow Leopard.

Speaking of using servers from outside your network, you can control Transmission remotely as well, but I won't go into that here. Skip over to OS X Daily for more on that.

If you want to do all this on Linux, the good news is there are graphical VNC clients. The bad news is I don't know of any graphical server programs, so you have to set it up through the command line. Also, setting up a static IP address requires editing configuration files, so it's a little more involved. Though hopefully not insurmountable.

That's all, folks!