View Single Post
Old 2016-07-14, 20:32   #1
GP2
 
GP2's Avatar
 
Sep 2003

5·11·47 Posts
Default How-to guide for running LL tests on the Amazon EC2 cloud

How to search for Mersenne primes using the Amazon EC2 cloud platform (with Elastic File System)

Introduction

The GIMPS project (at http://mersenne.org ) aims to find very large prime numbers; the primes it finds are usually record-breaking. The prime numbers it searches for are of a particular kind known as Mersenne primes.

A program called Prime95 runs on Windows computers and performs a so-called Lucas-Lehmer test ("LL test") on candidates known as Mersenne numbers to see if they are Mersenne primes — the overwhelming majority are not, in fact the odds are maybe one in several hundred thousand. The Linux version of Prime95 is called mprime; it's the same program, but with a command-line interface rather than a GUI. The Prime95/mprime program can be downloaded from http://www.mersenne.org/download/

Some people run Prime95/mprime in the background on their desktop computer or laptop. It does its calculations and communicates the results to a server on the Internet known as PrimeNet. However it uses a computer's computing capabilities rather fully: your electricity bill will go up, your computer fan might start running faster and louder, and the extra heat generated might heat up your room a bit or make your air conditioner work a bit harder.

An alternative to running Prime95/mprime on your own computer is to run it on a server. Some companies have a large array of server computers (aka "the cloud"), and some run a "public cloud" business that allows anyone to log in remotely over the Internet and use their cloud for various purposes (for a fee, of course). Examples of such cloud platforms include Amazon EC2, Google Compute Engine (GCE) and Microsoft Azure.

This thread explains how to use Amazon EC2 to do Lucas-Lehmer testing in the cloud. There is another thread that explains how to use Google Compute Engine for the same purpose.

Costs

Using Amazon EC2 at the cheapest rates, you should be able to do about seven double-check tests a month (of Mersenne exponents in the 37M range) for a cost of roughly $15 a month. This is an estimate: the actual costs are determined by market forces and can fluctuate.

You can easily scale up to whatever your budget allows (fourteen double-check exponents a month for roughly $30, and so forth). First-time LL tests (of exponents in the 67M range) will be about four times more expensive.

You can do LL testing for cheaper than this if you are willing to order parts and wiring and assemble a barebones do-it-yourself compute farm in your basement. But if you want to experiment with the cloud, then read on.

PrimeNet account

You can optionally create a PrimeNet account at http://www.mersenne.org/gettingstarted/

You can contribute to the GIMPS project anonymously if you prefer, but having a PrimeNet account lets you accumulate "GigaHertz-days" credits and keep track of where you rank on a leaderboard compared to other project participants; you can also keep track of your results and your pending work more conveniently.


Next section: Using Amazon EC2 for Lucas-Lehmer testing

Last fiddled with by GP2 on 2017-06-07 at 21:30
GP2 is offline   Reply With Quote