mersenneforum.org

mersenneforum.org (https://www.mersenneforum.org/index.php)
-   Conjectures 'R Us (https://www.mersenneforum.org/forumdisplay.php?f=81)
-   -   Automated primality testing with LLRnet (https://www.mersenneforum.org/showthread.php?t=9911)

mdettweiler 2008-01-25 04:34

Automated primality testing with LLRnet
 
[B]Note: Our two base 16 servers have been shut down. We now have a new Sierp base 6 LLRnet server. Please see [/B][URL="http://www.mersenneforum.org/showthread.php?t=10118"][B]this thread[/B][/URL][B] about the new server.[/B]


Hi all,

We now have an official Conjectures 'R Us LLRnet server! :banana: (Actually we have two of them. More on that later...)

With LLRnet, you can perform primality tests (LLR/Proth/PRP) [B]automatically[/B]. No need to mess with reserving/reporting ranges and all that stuff. No need to worry about whether your machine will run out of work in the middle of the night or while you're on vacation. Just set it and forget it! :smile:

LLRnet is very simple to set up--in less than 5 minutes you can be all set and crunching away! It's perfect for users who just want to donate their spare CPU cycles to a worthy cause without adding a degree of complexity to their computer use. (That's not to say that it isn't great for advanced users, too. :wink:) It's also great for work computers, since you can set it up on a computer and not have to worry about having it run out of work while it's not accessible. (We've set up one of our LLRnet servers on port 443 for just this reason. If this whole "port" thing is just going in one ear and out the other, though, here's essentially what it means: you're still able to use LLRnet at work even if your company has a restrictive firewall. Sorry, there's currently no way to run LLRnet through an HTTP or SOCKS proxy server, however.)

Here's all you need to do:

[B]1.[/B] Download the LLRnet client software for your operating system. LLRnet is available for Windows, Linux, and FreeBSD, in two versions: the "stock" version that only works with work for bases that are powers of 2 (but has a nice GUI), and the SR5 version, which works for all bases (but doesn't have the GUI). If you'd rather not have to worry about using different LLRnet installs for different bases, get the SR5 version. If the GUI is a must-have, though, you'll want to use the stock version for bases that are powers of 2.

Click one of the following links to download LLRnet:

[URL="http://bugmesticky.googlepages.com/LLRnet-win32-sr5-CRUS.zip"]Windows (SR5 version)[/URL] <<--------- Recommended for most users
[URL="http://bugmesticky.googlepages.com/LLRnet-linux-sr5-CRUS.tar.bz2"]Linux (SR5 version)[/URL] <<------------ Recommended for most users

[URL="http://bugmesticky.googlepages.com/LLRnet-win32-CRUS.zip"]Windows (stock version, power-of-2 bases only)[/URL]
[URL="http://bugmesticky.googlepages.com/LLRnet-linux-CRUS.tar.bz2"]Linux (stock version, power-of-2 bases only)[/URL]
[URL="http://bugmesticky.googlepages.com/LLRnet-freebsd-CRUS.tar.gz"]FreeBSD (stock version, power-of-2 bases only)[/URL]

[B]2.[/B] Extract the files from the archive you just downloaded. C:\llrnet is a good choice (or /home/[I]username[/I]/llrnet for Linux users).

[B]3.[/B] Navigate to the folder where you extracted LLRnet. Open up the llr-clientconfig.txt file in your favorite text editor. You'll notice a little ways down from the top a line that says the following:

port = 443

This is the port on the LLRnet server that the client will connect to. Currently, the LLRnet server is set up to answer on two different ports, each with a different type of numbers. Here's what they currently are:

[B][COLOR=seagreen]443 - Sierpinski Base 16 (Team Drive #1) (default)[/COLOR][/B]
[B][COLOR=seagreen]444 - Riesel Base 16 (Team Drive #2)[/COLOR][/B]
[B][COLOR=seagreen](both on server crus.dynip.telepac.pt)[/COLOR][/B]

Simply change the port value to work on different numbers. Please note that if you're behind a corporate firewall, you might only be able to use port 443. (Corporate firewalls usually allow access on port 443.)

A little farther down you'll notice another line that says the following:

username = "nobody"

Change "nobody" to your mersenneforum.org username. For example, I would set this to "Anonymous". This ensures that numbers you work on are credited properly to you in the stats that will be published periodically. (If you'd rather crunch anonymously, i.e. not have your crunching associated with your mersenneforum.org username, simply set this to something different. You can actually punch in anything you want here, though most users will probably want to punch in your mersenneforum username.)

Save the file, and close out your text editor.

[B]4.[/B] Doubleclick on the file named "llrnet.exe" to start LLRnet and get crunching! (On Linux and FreeBSD this will be just "llrnet".) You'll see an LLRnet icon appear in your system tray if you're running Windows, and, if you're using the "stock" version of LLRnet, you can right-click on the icon and click a button to pop up a GUI from which you can monitor your work. If you're using the SR5 version (the recommended version since it works for all bases), you can click another button on the right-click menu to open up a console and monitor your work from there. (Note: When you want to close out the console window, don't just close out the window. Instead, right-click on the LLRnet icon, and click "detach console". Otherwise, you'll close out the LLRnet program, which you probably don't want to do.) You can also use the console with the stock version, just like with the SR5 version. Linux users won't see a system tray icon, but they will get a GUI that pops up if they're using the stock version. (If you want to get the GUI back up after closing it out, navigate to your LLRnet folder and run the remote-gui.sh file.) To see the console, you'll want to start LLRnet from a command window--navigate to the LLRnet folder, and type the command "./llrnet" (without quotes). (With the console open, simply press Ctrl-C to stop LLRnet.)

[B]5.[/B] If you want to have LLRnet run automatically when you start your computer, simply right-click the LLRnet system tray icon and click "Add LLRnet service". Or, if you'd rather only run LLRnet when your username is logged on, click the Start button, and navigate to All Programs, then [B]double-click[/B] on the item named "Startup". A folder window will open. In a separate window, navigate to your LLRnet folder. Drag the llrnet.exe icon, with the right mouse button, to the Startup folder, and let go of the mouse button. Choose "Create Shortcut" from the menu that appears.

For Linux, how you set a program to run at startup depends on your distribution. Just post a message here and someone will try to help. :smile:

That's all!

Please post any questions/comments here, or send a private message to me (Anonymous).

Special thanks to Carlos (em99010pepe) for graciously hosting the LLRnet server for us! :bow:

Let's get crunching! :banana:

mdettweiler 2008-01-25 18:30

LLRnet server FAQ
 
[B]Q: Is there a deadline for returning LLRnet results?[/B]
[I]A: Yes. Currently the deadline is [B][COLOR=blue]7 days[/COLOR][/B] from the time when the number was handed out to your client. After 7 days, if you still haven't finished crunching your number (or simply haven't been able to return it yet even if it is finished), it will be assigned to another person.[/I]

[B]Q: Can I cancel a number that I don't actually want to crunch for whatever reason, or is over deadline?[/B]
[I]A: Yes. Simply open up a command prompt (on Windows it's Start>Run, then type "cmd" and press Enter), navigate to the LLRnet folder (by typing the "cd" command, such as: "cd c:\llrnet"), and type the command "llrnet -c" and press Enter. LLRnet will start, cancel the current number, and close. (Your command window will still be left open.) Note that if you have a cache size greater than 1 (the default is 10), then you'll have to enter that command again for each additional number in the cache that you want to cancel. (LLRnet will say "no numbers left to cancel" if you've canceled them all and you execute the command again.)[/I]

[B]Q: Can I run LLRnet on a multi-core system and still utilize all the cores?[/B]
[I]Yes, though LLRnet by default can only utilize one core. Thus, you'll have to run multiple copies of LLRnet. Simply, when installing, extract the archive you downloaded into as many folders as you have cores (such as c:\llrnet, c:\llrnet2, etc.). Then, configure the llr-clientconfig.txt for each core (you have to configure each installation separately--and if you're using the stock version, [B]make sure to change the GUIPort value to something different on everything except the first installation. You'll also have to change this value in the llr-guiconfig.txt for the installations that have been set to a different GUIPort.[/B]), and run the llrnet.exe (or "llrnet" on Linux/FreeBSD) in each installation. You'll see as many LLRnet icons in your system tray as you have cores--you can control each core's LLRnet separately. (You can also configure one core's GUI, if you're using the stock LLRnet, to control all the other cores, too, though that's a little bit more of an advanced topic--you can either try to figure it out on your own, or just post here begging for help. :wink:)[/I]

[B]Q: Can I switch an LLRnet installation from the Sierpinski server to the Riesel server, or vice versa?[/B]
[I]A: Sort of. You can't just go and change the "port" at a whim; then, any results currently in queue or being crunched will be erroneously returned to the wrong server, and thus rejected, while meanwhile they just sit around on the "real" server until they go past deadline. Thus, you need to clean out your LLRnet client's queue before you switch servers. Yes, you can do this by canceling all numbers that you have in queue, but that's less than optimal--you'll end up wasting some of your work, as well as leaving a mess on the server side for Carlos to have to clean up. Here's how to clean out the client the correct way:
-Close the LLRnet client.
-Open up llr-clientconfig.txt, and scroll down to where it says "WUCacheSize = x". Change x to 1, then save the file and start LLRnet again.
-Let LLRnet run until it's done as many k/n pairs as your queue was set to previously. Check the "workfile.txt" file in the LLRnet folder to verify that there's only one k/n pair left. (Note: the first line is just a header, it doesn't count--so if there's two lines in the file, there's one k/n pair in queue.) If so, then close out LLRnet, and open up llr-clientconfig.txt. Find the line that says "--once = 1" and remove the -- marks. It should just say "once = 1". Save the file, and open up LLRnet. It will work on the current k/n pair, return it to the server, and exit--rather than downloading another pair from the server.
-After LLRnet has exited, open up llr-clientconfig.txt again, set "once = 1" to "--once = 1" again, set "WUCacheSize" to whatever you'd like it to be (probably whatever it was before), and change the "port" value to the one for a different server. Save the file and start LLRnet.
-You've now successfully transferred LLRnet to the other server, with no loss of work whatsoever![/I]

[B]Q: I'm not constantly connected to the Internet. Can I set LLRnet to keep a larger queue to last until the next connect?[/B]
[I]A: Yes. Simply close out LLRnet, open up llr-clientconfig.txt, set the "WUCacheSize" value to however many workunits you want to keep in queue, and restart LLRnet. The maximum is 100, though that should be more than plenty even for the small numbers we're doing right now. :smile:[/I]

If you have any more questions that should be added to this list, please post here. :smile:

mdettweiler 2008-02-05 16:41

We've got teams!
 
Well, over in the LLRnet Stats thread recently, we've had a little discussion about a user who included his team name in his username like at NPLB, even though there were no teams here--and, as we were discussing, I thought, "Hey, why not have teams here, at least for LLRnet?"

So, users will now have the option to join a team for their LLRnet crunching! Just put your team name in front of your username in the llr-clientconfig.txt file, like this: [I]user = "TeamName_Username"

[/I]I'll be posting team stats along with the user stats each time I update them, just like at NPLB. :smile:

I'll leave it up to Gary as to whether to have teams for the non-LLRnet part of the project.

Here's the list of who's on what team (will be updated when necessary):
[B]
Free-DC[/B]
em99010pepe
IronBits
tnerual

em99010pepe 2008-02-09 20:39

Riesel server will be down for the next 24 hours. It's not a big deal because no one requested work for almost a week. Thanks.

gd_barnes 2008-02-10 04:50

[quote=em99010pepe;125314]Riesel server will be down for the next 24 hours. It's not a big deal because no one requested work for almost a week. Thanks.[/quote]


Now that I understand the server stuff a little better, when you get it back up after the NPLB rally, I'll put a core on it for a few weeks. I'd at least like to get us up around n=110K on it.


Gary

em99010pepe 2008-02-10 11:23

Anon will help you because he missed the NPLB rally...:whistle:

em99010pepe 2008-02-10 19:49

Server up again.

tnerual 2008-02-16 19:43

can someone explain me how to start the llrnet application under kubuntu.

i can start it by opening a console and typing "./llrnet"

(double)clicking on it don't give anything ...

in fact if someone can explain me what i have to do to start it as a service ...
my mother computer is waiting for it !

mdettweiler 2008-02-16 19:56

[quote=tnerual;125921]can someone explain me how to start the llrnet application under kubuntu.

i can start it by opening a console and typing "./llrnet"

(double)clicking on it don't give anything ...

in fact if someone can explain me what i have to do to start it as a service ...
my mother computer is waiting for it ![/quote]
When you double click on it, I think it just runs the application in the background (at least on GNOME it does; I don't know what it does on KDE). So, you may have more than one copy of LLRnet running from the same folder (not good). You might want to check whatever KDE has for a system monitor to see how many LLRnet processes you've got running.

As for how to start it as a service--using a method I picked up here on the forums, here's what you need to do:
-Make a text file in your LLRnet folder called "start-llrnet.sh" that contains the following data:
[code]
#!/bin/sh

./llrnet &
[/code]Save the file and close your text editor. Open up a command window, navigate to your LLRnet folder, and type the command "chmod +x start-llrnet.sh".
-Type the command "crontab -e". (Make sure you run that command as whatever user you'd like to run LLRnet as.)
-You'll find yourself in a command-line text editor, probably nano. Use the arrow keys to navigate to the bottom of the file, and enter the following:
[code]@reboot sh /path/to/llrnet/folder/start-llrnet.sh[/code]-Press Ctrl-X. Press the Y key, then press Enter. You will then be returned to the command prompt.
-You're all set! Repeat for each instance of LLRnet you want to run at bootup.

This should also work for any other Linux prime-crunching app, such as LLR, mprime, etc.

Disclaimer: I haven't tried this myself. :wink:

tnerual 2008-02-17 10:26

your trick is not working :sad:
i'm sure that clicking on llrnet don't give anything (1% processor usage)

the only way to start it is open a terminal then ./llrnet but i have the console windows ...

i want it to start automagically at startup and running in hidden mode ... (i'm the legal owner of the computer, but it's my mother's computer so she is ok for llrnet but only if she don't have anything anoying)

em99010pepe 2008-02-17 10:53

tnerual,

The Riesel server is getting a bunch of rejected pairs from you.

Carlos


All times are UTC. The time now is 00:16.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.