RetroMining Litecoins on an SGI O2

By , January 26, 2014 11:22 am

Part of my reason for doing another RetroChallenge this year was to try something whimsical and lighthearted and those kinds of projects are often hard to plan or come up with in advance.

I've been puttering away slowly at the 2014 Winter Warmup RetroChallenge and I only really discovered what my finale would be during this last week of the competition. I've been hearing about Bitcoins, Litecoins, and Dogecoins in my online circles and I thought I should look into the technology and see if a Silicon Graphics system would be up to the task.

Silicon Graphics systems are some of the most lavish and expensive to operate computers that can generate Litecoins.

Silicon Graphics systems are some of the most lavish and expensive to operate computers that can generate Litecoins.

The first issue was I didn't know what a Litecoin really was or how I would generate them through a "mining" process. I did know it would be an neat project to try a crypto currency mining task on an 18 year old computer. I started by comparing the different mining technologies and decided to go with an open source program called "cpu miner".

I downloaded the cpuminer source code from sourceforge and started the porting process.

At this point I already had a working GCC compiler toolchain on the SGI O2 from my previous RetroChallenge activities. The only major dependencies for cpu miner were listed as the curl library and this didn't sound too bad. Of course in true IRIX style this meant I had to sort out the curl dependencies and install a total of 11 libraries using the IRIX installation manager to get curl up and running.

Installing software on IRIX is all about missing prerequisites.

Installing software on IRIX is all about missing prerequisites.

I ended up adding the following Nekoware compiled packages:

  • neko_curl-7.19.7.tardist
  • neko_cyrus_sasl-2.1.22.tardist
  • neko_db4-4.4.20.tardist
  • neko_gawk-3.1.5.tardist
  • neko_gmp-4.2.1.tardist
  • neko_krb5-1.8.tardist
  • neko_libidn-0.5.4.tardist
  • neko_openldap-2.3.26.tardist
  • neko_openssl-0.9.8x.tardist
  • neko_readline-6.1-4.tardist
  • neko_unixodbc-2.2.10.tardist

The included cpuminer README file suggested the porting task would be easy so I tried the simple 3 step process:

./configure
make
make install

This led to a string of errors and warning that related to the lack of pthread support on IRIX, and a GCC issue with each occurrence of <stdint.h> in the source code.

GCC on IRIX doesn't think to highly of stdinit.h

GCC on IRIX doesn't think to highly of stdinit.h

I searched the Nekochan forum for threads about <stdint.h> problems and came up with a few tips.

Nekochan helped provide a much needed compiling tip.

Nekochan helped provide a much needed compiling tip.

Following this Nekochan suggestion I commented out the references in the cpuminer code to #include <stdint.h> and wrote in #include <inttypes.h> in their place. After the code was updated I then recompiled the source again.

At this point I got a bit further and was presented with a set of of new errors:

This was the final set of GCC compiler warnings.

This was the final set of GCC compiler warnings.

I got a few more GCC warnings like ld32: WARNING 134 weak definition and ld32: WARNING 85 but the compiling process completed anyway. The GCC compiler then blessed me with a shiny new executable called minerd which is the CPU Miner Daemon program.

When I ran make install I was greeted with a ksh[14] gawk not found message that led me to add the IRIX version of AWK to the system using the neko_gawk-3.1.5.tardist file I mentioned above. Once gawk was installed I was able to get minerd copied into the /usr/local/bin folder. Next I added the minerd path to my ~/.profile so it would be easier to launch from the command line.

When I ran the minerd program it listed the available command line options. For some reason the IRIX build accepts command arguments with a single dash - but doesn't recognize inputs with double dashes --. This turned out to be only a minor annoyance because I was able to reformat the commands to start Litecoin mining to use the single dash arguments.

Normally cpuminer would be started using command line args like:

minerd --url=stratum+tcp://mining.usa.hypernova.pw:3333 --userpass=username.computer:password

Since I could only enter options using single dashes I used a command line args like:

minerd -o stratum+tcp://mining.usa.hypernova.pw:3333 -O username.computer:password

To my amazed delight the terminal started outputting the scrypt based mining status and started generating tiny amounts of Litecoins. The SGI O2 system has a 195 MHz R10K processor and generates a blazing 0.08 khash/second ( 80 Scrypt hashes per second).

Let the retromining start!

Let the retromining start!

Download

Do you have an IRIX system? I highly recommend you download a precompiled copy of cpuminer for IRIX 6.5 and play along at home: irix-cpuminer.zip

Benchmarks

For comparison I tested the same cpuminer code on a few computers in my house:

  • 2008 Apple Mac Pro Xeon - 8 core 3.2GHz System (25.6 GHz) = 8 threads x 4.78 khash/s
  • 2006 HP DC5750 Desktop AMD Athlon 64 X2 - 2 core 2.1 Ghz (4.2Ghz) = 2 threads x 1.6 khash/s
  • 2013 Raspberry Pi ARM 700 MHz = 0.33 khash/s
  • 1996 SGI O2 195 MHz MIPS R10K = 0.08 khash/s

Litecoin Mining Benchmarks
For me, the most interesting result was that the Raspberry Pi was 4.1 times faster than the SGI O2, and the SGI O2 ran 60x times slower than the 2008 Mac Pro.

Another benchmark of a RetroChallenge project is the type of humor you can generate. Receiving a Jurassic Park related joke for a retro-computing project has pretty much validated the entire effort for me. :-)

This is a snapshot of my first IRIX Litecoin success tweet.

This is a snapshot of my first IRIX Litecoin success tweet.

There was a great bit of humor from @fleph that joked an IRIX RetroMiner would likely retire to the Jurassic Park beach, Isla Nubar, to live with the other dinosaurs.

There was a great bit of humor from @fleph that joked an IRIX RetroMiner would likely retire to the Jurassic Park beach, Isla Nubar, to live with the other dinosaurs.

Feb 1, 2014 RetroChallenge Wrapup Notes

I posted a thread on the Nekochan SGI forum about Litecoin mining on IRIX. It has been really interesting to see other SGI retro-computer users benchmark their systems. It looks like an Octane2 system narrowly beats the Raspberry Pi with a 0.34 khash/s compared to the Raspberry Pi's 0.33 khash/s mining rate.

The user Nekonoko was really kind and powered up his SGI Onyx2 deskside supercomputer for the cpuminer test. His Onyx2 system had four R14K 500MHz MIPS CPUs along with IR3 graphics. Each cpuminer thread ran at 0.23 khash/sec.

An Onyx2 Deskside System was the ultimate mini-supercomputer in 1997.

An Onyx2 Deskside System was the ultimate mini-supercomputer in 1997.

Here are the results of Nekonoko running cpuminer on IRIX.

Here are the results of Nekonoko running cpuminer on IRIX

Print Friendly

flattr this!

Leave a Reply

Note: Comments will have spelling errors corrected before they are posted. If you have a specific question please provide your email address so I can send you a direct reply.