mersenneforum.org  

Go Back   mersenneforum.org > Extra Stuff > Blogorrhea > EdH

Reply
 
Thread Tools
Old 2018-02-25, 14:40   #1
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

3,347 Posts
Default How I Install CADO-NFS onto my Ubuntu Machines

(Note: I expect to keep the first post of each of these "How I Install..." threads up-to-date with the latest version. Please read the rest of each thread to see what may have led to the current set of instructions.)

This thread will explain the steps I use to install* CADO-NFS onto a computer which is already running Ubuntu. This procedure should work for other linux distributions as well but the only other one I've currently tested is Debain. In my case I needed to install python3 from the repository on my Debian based machines. More details about CADO-NFS and my early experiments can be found in the CADO-NFS thread.

*In this instance "install" is referring to the acquiring and compilation of the CADO-NFS package only. The binaries will have to be called using their respective paths.

I will expect the user of these steps to be able to use the sudo command.

I will use a directory called Math for these installations. You may elect to replace "Math" with your own choice.

These instructions can be used as a reference only, if you want, but I will provide specifics that work for me. If you follow these steps as I provide them, you should end up with a working installation.

Ubuntu 18.04 Special Note: I've recently upgraded some 16.04 machines to 18.04 and have found that Python was removed, which caused CADO-NFS to crash. Simply using "sudo apt install python" resolved the issue. Because of this, I have added "python" to the below list of packages to install.

First, follow the procedure in:

How I Install GMP on my Ubuntu Machines

or, install GMP from the repositories.

If you have already installed most of the following packages, you can skip them, however, notice I have added the packages python and git to the list. You will now need git to retrieve the latest version of CADO-NFS using my steps, and if you are using Ubuntu 18.04, you may need to install python.

Open a terminal and enter:
Code:
sudo apt-get update
You should be prompted for your password. This prompt should only appear once for your terminal session, unless you leave it idle for a long time.

After the update completes and the user prompt reappears, enter:
Code:
sudo apt-get install g++ m4 zlib1g-dev make python git
Accept the prompt.

In your terminal, enter :
Code:
cd Math
git clone https://gitlab.inria.fr/cado-nfs/cado-nfs.git
cd cado-nfs
make
If prompted to download CMAke, choose y.

Note: The step above and the next step are described in the README file within the cado-nfs folder. It is recommended that it and the other READMEs referenced within be read for further details.

After CADO-NFS finishes compiling, its basic operation can be tested (per the README) by entering:
Code:
./cado-nfs.py 90377629292003121684002147101760858109247336549001090677693
You should see lots of activity similar to:
Code:
Info:root: Using default parameter file ./parameters/factor/params.c60
Info:root: No database exists yet
Info:root: Created temporary directory /tmp/cado.1lafrwdi
Info:Database: Opened connection to database /tmp/cado.1lafrwdi/c60.db
Info:root: Set tasks.threads=8 based on detected logical cpus
Info:root: tasks.polyselect.threads = 2
Info:root: tasks.sieve.las.threads = 2
...
Info:Quadratic Characters: Total cpu/real time for characters: 0.16/0.0801561
Info:Square Root: Total cpu/real time for sqrt: 2.07/0.413262
Info:HTTP server: Shutting down HTTP server
Info:Complete Factorization: Total cpu/elapsed time for entire factorization: 47.08/38.8295
Info:root: Cleaning up computation data in /tmp/cado.1lafrwdi
760926063870977 773951836515617 260938498861057 588120598053661

Last fiddled with by EdH on 2020-09-21 at 11:46
EdH is offline   Reply With Quote
Old 2019-06-24, 02:24   #2
scole
 
Dec 2017
Goldsboro, NC

2·3·7 Posts
Default

What is the minimum Ubuntu version? Can this be installed on Ubuntu 14.04?
scole is offline   Reply With Quote
Old 2019-06-24, 03:23   #3
VBCurtis
 
VBCurtis's Avatar
 
"Curtis"
Feb 2005
Riverside, CA

22·23·47 Posts
Default

I am no linux expert, but I believe I ran it on 14.04 a few yrs ago. I believe you'll need python3, but the CADO installer may adapt to environments with only python.
Edit: The cado-nfs site states gcc 4.7 or newer is required.

Last fiddled with by VBCurtis on 2019-06-24 at 03:24
VBCurtis is online now   Reply With Quote
Old 2019-06-24, 03:42   #4
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

3,347 Posts
Default

Quote:
Originally Posted by scole View Post
What is the minimum Ubuntu version? Can this be installed on Ubuntu 14.04?
Yes, 14.04 runs fine. I don't think I had to install python3, as I did with the Debian machines.


Edit: My 14.04 machine had gcc 4.8.4.

Last fiddled with by EdH on 2019-06-24 at 03:44
EdH is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
How I install YAFU onto my Ubuntu Machines EdH EdH 95 2020-09-04 18:32
How I Install GMP-ECM onto my Ubuntu Machines EdH EdH 12 2019-04-16 09:28
How I Install msieve onto my Ubuntu Machines EdH EdH 0 2018-02-23 14:43
How I Install ggnfs onto my Ubuntu Machines EdH EdH 0 2018-02-22 03:31
How I Install GMP onto my Ubuntu Machines EdH EdH 0 2018-02-21 23:48

All times are UTC. The time now is 23:48.

Sat Sep 26 23:48:47 UTC 2020 up 16 days, 20:59, 0 users, load averages: 1.28, 1.26, 1.35

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

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.