Category Archives: Linux

Restore an old Mac

In 1995-1996 I ran a Macintosh GUI BBS on a computer I rescued from the trash. The Macintosh SE/30 was prized for its ability as a server, and at one point mine had four external SCSI drives attached to it, two Hayes Accura V.92 14.4K Modems, and the 40MB built-in drive running System 7. With the RAM maxed out to 8MB and an external monitor card, this build was a top notch machine of its day. If you’re going to restore an old 16bit PC, why not make it the last of the V8 interceptors.

Before I get too far, let me declare that this is not a “how to”. There are far more traveled forums than the comment section of planetkris, and there are many hundreds of articles, and thousands of different things to try to get your retro hardware working. Only one of which will be covered here.

In a box, in a bin, in the last three houses my parents have owned, and saved from a flood, was a couple of my old Macintosh Computers. I think I have mentioned that I would pay to ship these out to me over a dozen times in last 10 years. I have a significant pile of keyboards, mice, cables, and adapters that go along with them. In October of 2018 they arrived in the back of the car that my parents took on their post-retirement cross country trip.

Yes, of course “leaking capacitors.” 15 years of electrolytic goop has been corroding the motherboard. I powered it on anyway just to see what I had gotten myself into, and it actually booted off a floppy that I made on my Windows 10 desktop. The fact that I was able to do THAT MUCH was particularly amazing considering the hardware/software emulation chain that was taking place: Windows 10 driver to access emulated floppy over USB writing bits from a 1990’s .img file using a 32bit Macintosh floppy conversion software on a 64bit multi-core machine. I wasn’t remotely running this on a VM desktop at the time – FYI.

Restoration VS. Nostalgia: I did NOT want this build to turn into a Raspberry Pi attached to a 7″ LCD monitor grafted into the case. I get why people do that, but it’s not at all true to the design of the machine, and it really cheapens the feeling one gets when they see an old computer they used in High School or College with the side hacked open and USB hubs sticking out. I looked into driving the original monitor with a Pi, and it has been done, but emulating hardware in Linux is not something I have any experience with. I decided that I would at least replace the spinny disk with an SD card (SCSI2SD). This alone would make the computer 10 times faster, and I could run real software on a real Macintosh from 1989.

I also experimented with powering the motherboard separate from the monitor. This would allow me to turn the original high voltage power supply off and “save it” should I want to fool around with keeping this machine on the internet or running a terminal, etc. That brushless fan – while still working great – is louder than my dishwasher.

I’m going to keep a Raspberry Pi OUT of the case. My plan is to connect to the Mac over 56K BPS serial with a modem cable connected to an external Pi. Use actual Macintosh terminal / BBS software to do fun and interesting internet stuff. The Pi will negotiate all the Ethernet and TCP/IP Internet heavy lifting. They DO make an Ethernet board for this machine, but I really (really, really) want to keep my external monitor board in there.


RestOBrite
: Removing the nasty orange color is pretty easy with SoCal sun and some Hydrogen Peroxide. I tested my method on my older SE first, and then did a carefully controlled amount of whitening to the SE/30. I think I found the balance between “this is still a 20 year old computer” and “bleach all the old things”. There are 1000 formulas for this on the net. I used Oxyclean and “off-the-shelf brown bottle from CVS” hydrogen peroxide.

Once the replacement capacitors arrived, I had to clean the motherboard in the garage sink with soap and water. It’s a little surreal dunking a motherboard into soapy water, but yes, this is the method. A mac bomb error code had cropped up after this and I went back and cleaned again. Now the caps were never going to be a problem, but the damage they caused to the SCSI chip was worse than I thought.

Not Booting: So, what’s wrong with your computer that won’t see a SCSI emulator SD card loaded with an image from some website? How about that 50 pin cable that’s older than your first car. Is the bus terminated correctly? Did that .img file copy okay with the USB loader? Did you assign the right address? I want to give a shout out to “David and Steve’s Blog” who really detailed the process of setting up SCSI2SD.

eBay spares: There are people in other countries that make their living removing old chips off old boards to keep in old boxes. I was able to procure an old NCR SCSI controller chip. I also decided that it would be best for my soldering skills that I socket this chip. The pads on at least 3 of the leads were damaged or missing once I de-soldered, and testing goes a hell of a lot easier if you can remove the chip to fix the traces under it. *thumbnail for scale

Trace twice, solder three times, trace again. This controller has 44 pins. I found that 3 of them were causing problems. Luckily only this chip was damaged. One trace I found before I de-soldered, the second and third one were right next to each other, but used connections that travel under the chip. I broke a fourth trace trying to fix the third, but I knew I was making progress when my SCSI HDD light came on and stayed on. My blind configuration of SCSI2SD worked and I was overjoyed when it FINALLY JUST BOOTED!


The one thing that I love about this machine, is that it does something that we only started taking for granted maybe 5-6 years ago. It drives two monitors, and extends the desktop, IN COLOR. Moving your mouse off of the built in screen with a window of icons over to a second monitor is still delightful. The fact that it was able to do this in 1989 is spectacular. This is not emulation, this is a 1989 video card directly driving an LCD monitor from the 21st century.

I enjoyed the process and encourage my fellow hardware hackers to enjoy restoring some old computer that you thought would never work again. Test your maker, hardware, software, and troubleshooting skills!

My ix2 is EOL and doesn’t finish strong – or secure…

Disappointing finish for my Iomega StorCenter ix2. The second drive failed and it has been replaced with a Synology DiskStation DS212j with WD Red drives. (more on that later) I was doing some consolidation and cleaning of the computer room yesterday and I decided it was time to wipe some hard drives including the ix2 NAS.

The replacement WD Green and the old original 500GB Seagate spin up and after a few minutes I can login via the web interface. I go into the manage disk section and I’m excited to see there is an Erase Disks section under Manage Disks. The first message tells you that you’ll need to delete all the shares (including the built in ones?!) before using the wipe functionality. The second message talks about how securely erased your drives will be. For those of you who don’t know me – here is the setup..

iomega unsecure disk wipeSecure Erase:
All data is permanently erased and overwritten to prevent recovery, user information is removed, and the device is reset to factory defaults. Disk erase is a secure operation to ensure all data on your Iomega StorCenter device is irrecoverably deleted. The disk erase process overwrites all disks with random data to prevent recovery of existing or deleted data, users, and passwords.

…and the outcome? Well I clicked it, confirmed it, and watched as the red light came on and the drives started to chug. Just like when it gets stuck doing a rebuild, I wanted to see what it was up to. I was also curious if this would affect my ability to SSH into the machine. Not only could I still log in to the ix2, I found the program that it was running to wipe the drive:

/usr/bin/shred -v -n 1 /dev/sda2
/usr/bin/shred -v -n 1 /dev/sdb2

I looked quickly at the man page for shred. The default setting is 25 times. Older versions list the default at 3. Iomega changed it to make a single 1 time pass! 🙁

Think you might donate or craigslist your old NAS drive? Well if it’s an Iomega – don’t rely on the built in “Secure Erase” to protect your data! A single pass (while at least random data) is going to be slightly better then a “quick format”. When it finished and re-initialized I restarted it, and I STILL had root access. (read: factory defaults) To which I ran my own shred on both /dev/sda2 and /dev/sdb2.
Ciao ix2!

iomega_shred

ix2 NAS Drive Failure.

I was copying pictures to my network drive and I noticed that it was responding slowly. Taking a good ten seconds to draw a .jpg preview. I logged into my Iomega Storcenter ix2 and the dashboard told me the news: “A drive is missing from the device”

I immediately made a backup to my workstation. Once copied, I completely shutdown the Storcenter, opened it and checked the connections. In order to see that it was a drive that had failed and not the board, I swapped the SATA cables for the two drives, tightened it all up and turned it back on.

What I next learned was that I have little patience for blinking lights. “What are you doing NAS drive?” I asked. “You respond to a ping, but that’s it.” No web interface… Well, let’s see what’s really going on. Connect via SSH and run this command: cat /proc/mdstat You’ll get actual information about what’s going on. At first I saw that the drive was rebuilding and was at 32.4% with 109 minutes remaining. A few minutes later I ran the command and got something like 33.8% with 132 minutes remaining. Okay – time to get dinner and wait for this to finish.

When I returned, the missing drive was back online and was crisis averted? Nope. The next morning I checked my email and received this from sohostoarge:
The Iomega StorCenter device is degraded and data protection is at risk. A drive may have either failed or been removed from your Iomega StorCenter device. Visit the Dashboard on the management interface for details. To prevent possible data loss, this issue should be repaired as soon as possible.

Awesome. 😐 Well, at least my email script still works.
Later that afternoon I picked up a 500GB WD Caviar Green from BB for $56. The Green drives are quieter, a little slower, and use less power – great for this application. I took the ix2 apart AGAIN, and removed the barely 3 year old Seagate Barracuda 7200.11 out of the device. I know that people have hardware preferences out there, and I know they differ, but here’s mine: I don’t buy Seagate drives. Ever. I’ve been a computer tech for over ten years. (Of course I bought the ix2 without knowing it comes with 2 of them 🙂 )

After closing up the drive I powered the NAS up and watched the magic. The new drive rebuilt and I got a steady blue light on my ix2 when I checked later the next day. No linux commands, no format, no partition, no RAID – just replaced the dead drive with a new one of the same size and we’re back in business. Am I pissed that this drive failed in 3 years? Sure. Did the Iomega ix2 do its job and kept my data safe? Absolutely!

If I didn’t need this data immediately I might have experimented with bigger drives, but I think I’ll upgrade to the ix4 before I ever try to upgrade the capacity of this little guy.

Transmission, Screen, etc. on your Storcenter NAS.

storcenter ix2 running transmission
As I guessed in a previous ix2 post – there is a better, thinner, BitTorrent client. Abhilash suggested checking out Vladimir Vuksan’s blog post about customizing iomega storcenter with ipkg.

I’m going to do some more research into all of this, but right off the bat I was able to install ‘screen’ and ‘transmission’.
This page on setting up transmission on a headless machine (NSLU2) was the ticket.
The only hard part I had was finding and editing the settings.json – in order to add 10.0.1.* (my local subnet) to ‘rpc-whitelist’ like this: “rpc-whitelist”: “127.0.0.1,10.0.1.*”, The trick is to start the daemon and let it run for a few seconds, then the file will be created.

vi /.config/transmission-daemon/settings.json

Once added, I re-started the daemon and opened http://10.0.1.5:9091 – the web client opened right up. In the preferences I set the directory to: /nfs/public/Media/Torrent/ (an existing share called public where my BitTorrent files are stored on the ix2) I started up a few torrents and checked my CPU with ‘top’. 10% is a lot better then 70%. The interface is much better then the stock ix2 version 2 firmware. You can set limits as well as “Temporary Speed Limits” for making sure your ix2 is in top form when you’re awake.

Further study:
1. I just heard of synology NAS drives this morning. I’m going to take another guess that their related in some way to the Storcenter.
2. Those repositories are from nslu2-linux. Knowing this from the start might have made my mucking about in the SSH a bit better…
Enjoy!

Iomega Storcenter ix2 – SSH, email notifications, and BusyBox init.d

Iomega Storcenter ix2 ssh root access
Iomega Storcenter ix2 SSH access! (for firmware 2+ ; this works for the ix2, ix4, etc.) First – big ups to Christopher Kusek over at pkguild.com for getting this on the web. I’ve already had people comment asking how to do it – so I’ll cover it again here.

Login to your Storcenter with the admin user.
In your browser replace the /home.html?t=1 file at the end of the IP address with /support.html
You will now see the support.html page. There is an icon called Support Access.
Select this link and click the SSH access check box.
Now get on your *nix box or open Putty SSH. Type in your NAS IP address (mine happens to be 10.0.1.5).
Login as root, and the SSH password for your box is: soho[youradminpassword]
That’s “soho” with your current admin password tacked onto the end without brackets.
Thanks again to Christopher Kusek!

We have lift-off. Now what can we do with it? Well, at this point, that depends on how creative you are. So I typed “busybox” at the prompt and a list of currently defined functions came up. If you are handy in Linux you’re probably going to go further and faster then I did. If you have any suggestions after you read what could be a tragic Linux hack – hit up the comments.

How email notification works, why it broke, and how you might fix it.
I was less then excited when I discovered “sendmail” missing from the list of BusyBox functions. How in the hell does this thing send email? I started poking around and the “find -name” command is helpful. I logged into the html settings page on the machine and hit apply to send a test email. At the same time I had “top” running in the shell.

2466 postfix 3744 S smtpd -n smtp -t inet -u
2467 postfix 3492 S proxymap -t unix -u

Okay – smtpd sounded promising. I looked around and found that the Storcenter uses a stripped down version of postfix smtp to send email. Interesting side note: the config files are all there but commented out. As a side project, this device is pretty much ready to be an email server. Postfix uses /usr/local/postfix/main.cf to configure outgoing smtp. The storcenter points to mail.authsmtp.com on the default port smtp 25. It sends the outgoing mail directly to authsmtp.com with a password in the config file.

AuthCheck.exe from authsmtp.comAuthsmtp has a dandy little tester exe for Windows – AuthChk.exe found here http://www.authsmtp.com/support/diag.html This shows me that my Storcenter was not the issue, but it was my ISP (Verizon) blocking port 25 outgoing. This is to be expected, and Iomega should realize that a specified port number in their next release would be a good idea.

How can I fix outgoing email right now? For I AM root.
I first discovered that code in the javascript of the Storcenter’s web interface is what’s dropping any “user@host.com” because of the @ sign. This code is buried in the read only flash and it’s not clear to me how you could change it without breaking open the flash. Probably built with buildroot. I then looked at the port issue and figured that if I could get the NAS to send email out on a different port that mail.authsmtp.com could receive, (25, 26, 2525) I’d be in business. In the postfix main.cf file on this machine it says:

# In the case of SMTP, specify a domain, host, host:port, [host]:port,
# [address] or [address]:port; the form [host] turns off MX lookups.
#
relayhost = [mail.authsmtp.com]

So all we have to do is change this to read:

relayhost = [mail.authsmtp.com]:26

If only it survived a reboot… The main.cf file is located in /usr/local/postfix and symlinked to /tmp – this file gets created and written by the system every time it starts up. I’m pretty sure /sbin/executord -c /etc/sohoConfig.xml is doing it. If you look in sohoConfig.xml you see the mail.authsmtp.com specified. All of this is on the read only flash portion of the unit. I looked into BusyBox some more and found that /etc/init.d is doing the startup work. Long story short, rcS runs all the S?? numbered files one at a time in order. An example: “S20urandom, S39interfaces, S40bond-init, etc, etc…” mounts the drives, starts samba, makes toast, starts interfaces, etc. All I had to do was copy over the main.cf file with an edited one and restart the postfix email service.

What I came up with is a file in /etc/init.d called S73mailport (the 73 is a ham reference, and as long as it’s higher then 60, it runs this last)
Don’t forget to chmod 755 this file to make it executable.

#!/bin/sh
sleep 15
cp /etc/mailport/main.cf /tmp/main.cf
/mnt/apps/usr/sbin/postfix -c /usr/local/postfix reload

As you can see there is a modified main.cf file that I stored in /etc/mailport. I wait for executord to finish writing the config (sleep 6 is too soon) and I copy over it. I then restart the postfix services with the whole command postfix -c /usr/local/postfix reload. If you just type postfix reload it won’t find the config. Now my Iomega Storcenter sends me email on port 26! It survives a reboot, but I’ll admit it’s probably not the sexiest way to do this. Another caveat is that upon a hard shutdown (which I’m not going to test as I have active data on this NAS) I’m willing to bet that it executord will signal the Storcenter to send out an email as soon as it starts up. This will most likely never be sent as it will attempt to go out on the default port 25, before my S73mailport script changes it after waiting 15 seconds. So I won’t get the first email, but I’ll get the “Data Protection Reconstruction Complete: The storage device has completed data protection reconstruction,” once that’s finished. This will clue me into the fact that there is a serious problem on my NAS that needs to be looked at.

Other observations:
* The torrent downloader seems to be written into appweb and uses 60 – 70% CPU when running. It lags the interface and shell hard. So hard that I thought I broke it poking around. This is probably fine when I want to setup a download while I’m in Tahiti, but no good if I’m actively looking at pictures stored on the device. Is there a tiny linux torrent program that can run on this device in the shell? I’m sure.
* The read only file system is kind of BS. The flash and Iomega stuff is stored here, but the device boots off the physical hard drives… So config changes are overwritten, but if a drive were to die – you’re SOL with the interface. Time for the SATA cables and the Linux box to come out.
* Now that I know that I can, I have access to a little computer that can move files around, run little scripts, and possibly provide other network functions like TFTP PXE boot for some old thin clients I have hanging around.

Got ideas? Got a better implementation? Let me know!
– Kris

Iomega Storcenter ix2 – the update hack.

storcenter ix2I’m posting this basically because I know others are out there on your own. Cold and wandering through the internets looking for something about how to mod and update this device. I’m talking about the (EMC) Iomega Storecenter ix2. I picked up this little guy a little more then a year ago for some cheap money. Then I found out that they were discontinuing the model because of some pretty obvious problems. :|

Pretty obvious problem #1. The fan is horrible and you probably have already done something about it. Along with the fan the airflow through the device is just as bad. You can see that Iomega took a complete 180 when they came out with “the new model“** What I suggest is you get out your Dremel and cut a nice hole in the back panel. I put an over-sized ultra quiet fan with a dust filter on it. It’s already back in the closet, so I’m not getting a picture of it… Hell, you don’t want to see a picture of it. It’s a 80mm PC fan bolted to the back of a $200 NAS drive. It’s goofy looking utilitarian hardware that needs to be in the closet. Let the sexy laptops and iPods take the credit while the hacked Linux device with wires and fans all over it gets the job done. *cough **For reasons of ‘search’ the next model up is the ‘eye ex two hundred’

Problemo #2. I have been looking for a USB aware UPS (Uninterruptible Power Supply) for this device from day one. Having a ‘self aware’ storage device is pretty cool. Enable write caching and don’t worry when the power goes out when your in Tahiti. I finally obtained a Tripp Lite UPS and replaced the battery on it. Fresh USB cable plugged in and – nothing. Then it gets worse. I restart the device and it just hangs. So – Are you having a problem where your Storcenter ix2 won’t recognize your Uninterruptible Power Supply?

Final Problem #3. Every time you try to search for Iomega Storcenter ix2 (or maybe storecenter?) you get a thousand ‘re-view’s’ of how awesome it is and nothing about helping you solve issues or fix problems. Even after you use a crazy Google search like this…

I’m here to help!
Not with the fan though – you’re clever, you’ll come up with something. :p

Iomega Link to all the files and info for the Storcenter ix2

Good news / Bad news. You hit ‘update’ and your device tells you that you have the latest firmware! You don’t. The latest firmware would be 2.0.15.43099 or higher. The good news is that along with potentially fixing the UPS not recognized problem, you will get the torrent downloader. This means that while your desktop is off and not using 500watts an hour your little ix2 can stay busy getting ‘the latest release of Fedora’***.
***or movies and pr0n.

Other bad news is you’re going to have to sign up to the Iomega site with an email. It’s not nearly as bad as Cisco is – but you have to get a valid email. Or an alias that forwards to your real email that you can shut down after you hit accept.

While your doing that – Might as well sign up for the Iomega Support Forums Lots of moderated fun in there… :)

Backup your data. Hack the fan. Load the firmware file and hit update. Wait a while in a panic. Login. Connect your UPS. Hopefully it now recognizes it! Torrent movies and pr0n. Set quotas. Oh – and because it can’t possibly all be good. You will lose the ability to get email updates from the unit… This is a gem – exhange?? :confused:

Update – I got SSH access!
Easy as HTML. Here’s how you get SSH access to your ix2. Now to FIX the email notification port and configuration… Initial look tells me that it doesn’t use sendmail :(