Bitcoin Forum
June 26, 2017, 04:04:40 PM *
News: Latest stable version of Bitcoin Core: 0.14.2  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: 1 2 3 4 5 6 7 [All]
  Print  
Author Topic: How to run your own P2Pool in Ubuntu 14.04 LTS with merged mining  (Read 35947 times)
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 14, 2014, 11:36:02 AM
 #1

Updates:
17-May-2017: Updated guide for Ubuntu 16.04 LTS
15-June-2014: Fixed an error in the i0coin.conf included in p2pool-files.tar.gz
15-June-2014: Added instructions on automatic startup after reboot
15-June-2014: Added fusioncoin (for merge mining) and updated binaries
16-June-2014: Added Lazy guy's installation method
16-June-2014: Added namecoin.conf in p2pool-files.tar.gz and fixed start-p2pool
16-June-2014: Added rpcallowip=127.0.0.1 to all config files
21-June-2014: Added huntercoin to the guide
21-June-2014: Implemented a lot of suggestions from KyrosKrane. Addded a firewall script and reordered the commands for "lazy" installation method.
15-July-2014: Updated huntercoind and added bitcoin 0.9.2.1 in the binaries (I didn't compile it, I just used the 64-bit precompiled binary from bitcoin.org) as PPA has older version.
24-August-2014: Updated namecoind and huntercoind. Note that you might have to download blockchain of namecoin again after updating.
9-September-2014: Updated again namecoind and huntercoind to latest versions.

MAJOR UPDATE:
Please visit KyrosKrane page at: http://bitcoin.kyros.info/
He provides a more complete automated script.

If you still need to read all the details on how everything is done please read on!


IMPORTANT SECURITY NOTE: If you are running your server on a VPS with full internet access make sure you change the rpcpassword or edit your config files and add rpcallowip=127.0.0.1

Announcing: Lazy guy's installation method
So you are too bored to read all this?
This is too technical for you?
Do you want to have P2Pool up and running within 5 minutes with only 2 commands to execute?

After you install Linux Ubuntu 14.04 LTS, login and execute the following commands:
Code:
wget http://pool.nitro.gr/install-p2pool.sh
sudo sh ./install-p2pool.sh
sudo chown -R $(whoami):$(whoami) .*
sudo chown -R $(whoami):$(whoami) *
It will install everything (it will use the binaries not compile everything again) and you just have to wait...
Do a reboot and you are done.

Then jump to "END OF COMPILATION OF FILES"

Some history:
I created this guide to have up to date P2Pool installation instructions on latest version of Ubuntu LTS (currently 14.04).
People may consider it difficult to get a P2Pool node up and running but in fact it's very simple if you have some basic Linux knowledge.
In this guide I will provide BTC and merged mining NMC, DVC and IXC (in order to match GHash.io's offering).
Note that althought BTC mining is distributed among P2Pool miners, merged coins (e.g. NMC and IXC) will not be distributed to others but you will solo mine those. If you mine exclusively with P2Pool you will get the same profit (and a bit more) compared to mining to other pools. In the long run NMC/DVC/IXC profit will be the same.

Install Ubuntu 14.04 LTS Server from here: http://www.ubuntu.com/download/server
(note do not install Ubuntu DESKTOP 14.04 LTS - you need Server version for text only install)

I will not cover instructions on how to do this. You can install it in a virtual machine or a physical machine.
For virtual machine start with 2 Processors and 4GB memory. Suggested disk size is 60GB (that's a lot but you will have room to grow).

Create a user and run all the commands as a user NOT as root.

If you find any mistakes please let me know!

First thing after you install ubuntu is to install all updates for Ubuntu and reboot your machine:
Code:
sudo apt-get dist-upgrade

Grab Bitcoin from repository and install it:
Code:
apt-get -y install software-properties-common aptitude
sudo add-apt-repository ppa:bitcoin/bitcoin
(Press ENTER to accept)
sudo apt-get update

Install the following prerequisites to build NMC,DVC and IXC plus to install the Bitcoin client:

Note - the following is one line and will download and install a lot of packages:
Code:
sudo aptitude install bitcoind python-software-properties screen git python-rrdtool python-pygame python-scipy python-twisted python-twisted-web python-imaging build-essential libglib2.0-dev libglibmm-2.4-dev libqt4-dev python-dev libssl-dev libdb5.1++-dev libboost1.55-all-dev dh-autoreconf libcurl4-openssl-dev libminiupnpc-dev ufw

Grab P2Pool:
Code:
cd ~
sudo git clone git://github.com/forrestv/p2pool.git

For the next part I provide two solutions.
One solution is to compile everything on your own. In that case you need all the prerequisites above.
The other, easier and faster solution is to download the binaries compiled and as a bonus I have all the configuration files mentioned below.

So to grab the precompiled files just do:
Code:
cd ~
wget http://pool.nitro.gr/p2pool-files.tar.gz
tar xvzf p2pool-files.tar.gz

To verify that the file you have downloaded is correct do the following:
Code:
md5sum p2pool-files.tar.gz
You should get:
5f1826181effbd32bd24ce5cb2b713e6 p2pool-files.tar.gz

If all is good - then you can do "rm p2pool-files.tar.gz" to delete the package as everything is already extracted or hang on to it.

If you prefer to compile everything or see what I have included in the p2pool-files.tar.gz please read on:

START OF COMPILATION AND CREATION OF FILES:

Create a directory to install the binaries and the directories for each coin:
Code:
mkdir ~/bin
mkdir ~/.bitcoin
mkdir ~/.namecoin
mkdir ~/.ixcoin
mkdir ~/.devcoin

Grab Namecoin, compile it and copy it to the ~/bin directory:
Code:
cd ~
git clone https://github.com/namecoin/namecoin
cd ~/namecoin/src
make -f Makefile
strip namecoind
cp namecoind ~/bin

Grab IXC, compile it and copy it to the ~/bin directory:
Code:
cd ~
git clone https://github.com/FrictionlessCoin/iXcoin
cd ~/iXcoin/src
make -f makefile.unix
strip ixcoind
cp ixcoind ~/bin

Grab Devcoin, compile it and copy it to the ~/bin directory:
Code:
cd ~
git clone git://gitorious.org/devcoin/devcoin.git
cd ~/devcoin/src
make -f makefile.unix USE_PNP=1 devcoind
strip devcoind
cp devcoind ~/bin

Create the configuration files for each coin (bitcoin.conf,namecoin.conf,ixcoin.conf,devcoin.conf):
Note - copy/paste only the "cat" command, press enter - then copy paste the rest of the commands.
Code:
cat >~/.bitcoin/bitcoin.conf
server=1
daemon=1
rpcuser=bitcoin
rpcpassword=h3wby4zWjGwywZ
rpcallowip=127.0.0.1
Press CTRL-D

Code:
cat >~/.namecoin/namecoin.conf
server=1
daemon=1
rpcuser=namecoin
rpcpassword=e9s4bmEaHvofEZ
rpcport=7333
rpcallowip=127.0.0.1
Press CTRL-D

Code:
cat >~/.ixcoin/ixcoin.conf
server=1
daemon=1
rpcuser=ixcoin
rpcpassword=KouZ4RvmT3WkKZ
port=8337
rpcport=8338
rpcallowip=127.0.0.1
Press CTRL-D

Code:
cat >~/.devcoin/devcoin.conf
server=1
daemon=1
rpcuser=devcoin
rpcpassword=KouZ4RvmT3WkKZ
rpcport=6333
port=6334
rpcallowip=127.0.0.1
Press CTRL-D

END OF COMPILATION OF FILES

You are not ready to start P2Pool just yet. The BTC/NMC/DVC/IXC blockchain has to be downloaded first and it will take about 2 days.
So execute these commands and wait...

Code:
/usr/bin/bitcoind
~/bin/ixcoind
~/bin/namecoind
~/bin/devcoind

Make sure that blockchain has finished downloading for all coins.
You can check that by going into .bitcoin/.namecoin/.ixcoin and do tail -f debug.log.
If you see downloading of old dates then you should wait before even starting P2Pool.

Run this command to start P2Pool:
Code:
screen -d -m -S p2pool ~/p2pool/run_p2pool.py bitcoin h3wby4zWjGwywZ --merged http://ixcoin:KouZ4RvmT3WkKZ@127.0.0.1:8338/ --merged http://namecoin:e9s4bmEaHvofEZ@127.0.0.1:7333 --merged http://devcoin:KouZ4RvmT3WkKZ@127.0.0.1:6333

You can view the P2Pool ouput using
Code:
screen -x p2pool

You disconnect from the P2Pool output by pressing: Ctrl-A and then D (nothing will show on screen)

EXTRA COINS (already available in the precompiled files):

I0C - i0coin

Compile i0coin:
Code:
cd ~
git clone http://github.com/rsnel/i0coin/
cd i0coin/src
make -f makefile.unix i0coind
strip i0coind
cp i0coind ~/bin

Create i0coin configuration file:
Code:
mkdir ~/.i0coin
cat >~/.i0coin/i0coin.conf
server=1
daemon=1
rpcuser=i0coin
rpcpassword=KouZ4RvmT3WkKZ
port=7337
rpcport=7338
rpcallowip=127.0.0.1
Press Ctrl-D

Start ~/bin/i0coind and wait for the blockchain to download as well.
Add it to your startup script if needed and modify P2Pool startup to include it. Just append at the end of the p2pool command:
Code:
--merged http://i0coin:KouZ4RvmT3WkKZ@127.0.0.1:7338
e.g.
Code:
screen -d -m -S p2pool ~/p2pool/run_p2pool.py bitcoin h3wby4zWjGwywZ --merged http://ixcoin:KouZ4RvmT3WkKZ@127.0.0.1:8338/ --merged http://namecoin:e9s4bmEaHvofEZ@127.0.0.1:7333 --merged http://devcoin:KouZ4RvmT3WkKZ@127.0.0.1:6333 --merged http://i0coin:KouZ4RvmT3WkKZ@127.0.0.1:7338

FSC - Fusioncoin (NOT Friendshipcoin)

Don't confuse Fusioncoin with Friendshipcoin. Fusioncoin is SHA-256 while is Frinedshipcoin is Scrypt!

Compile fusioncoin:
Code:
cd ~
git clone https://github.com/fusioncoin/fusioncoin
cd ~/fusioncoin/src
make -f makefile.unix
strip fusioncoind
cp fusioncoind ~/bin

Create fusioncoin configuration file:
Code:
mkdir ~/.fusioncoin
cat >~/.fusioncoin/fusioncoin.conf
server=1
daemon=1
rpcuser=fusioncoin
rpcpassword=KouZ4RvmT3WkKZ
port=8492
rpcport=18491
rpcallowip=127.0.0.1
Press Ctrl-D

Start ~/bin/fusioncoin and wait for the blockchain to download as well.
Add it to your startup script if needed and modify P2Pool startup to include it. Just append at the end of the p2pool command:
Code:
--merged http://fusioncoin:KouZ4RvmT3WkKZ@127.0.0.1:18491
e.g.
Code:
screen -d -m -S p2pool ~/p2pool/run_p2pool.py bitcoin h3wby4zWjGwywZ --merged http://ixcoin:KouZ4RvmT3WkKZ@127.0.0.1:8338/ --merged http://namecoin:e9s4bmEaHvofEZ@127.0.0.1:7333 --merged http://devcoin:KouZ4RvmT3WkKZ@127.0.0.1:6333 --merged http://i0coin:KouZ4RvmT3WkKZ@127.0.0.1:7338 --merged http://fusioncoin:KouZ4RvmT3WkKZ@127.0.0.1:18491

HUC - Huntercoin

Note that Huntercoin drains a lot of resources to sync. Syncing of the blockchain may also take a week before you can start merge mining it.
After syncing CPU/memory usage is normal.


Compile huntercoin:
Code:
cd ~
git clone https://github.com/chronokings/huntercoin
cd ~/huntercoin/src
make -f Makefile
strip huntercoind
cp huntercoind ~/bin

Create huntercoin configuration file:
Code:
mkdir ~/.huntercoin
cat >~/.huntercoin/huntercoin.conf
server=1
daemon=1
rpcuser=huntercoin
rpcpassword=KouZ4RvmT3WkKZ
port=8398
rpcport=8399
rpcallowip=127.0.0.1
Press Ctrl-D

Start ~/bin/huntercoin and wait for the blockchain to download as well.
Add it to your startup script if needed and modify P2Pool startup to include it. Just append at the end of the p2pool command:
Code:
--merged http://huntercoin:KouZ4RvmT3WkKZ@127.0.0.1:8399

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
1498493080
Hero Member
*
Offline Offline

Posts: 1498493080

View Profile Personal Message (Offline)

Ignore
1498493080
Reply with quote  #2

1498493080
Report to moderator
There are several different types of Bitcoin clients. Header-only clients like MultiBit trust that the majority of mining power is honest for the purposes of enforcing network rules such as the 21 million BTC limit. Full clients do not trust miners in this way.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1498493080
Hero Member
*
Offline Offline

Posts: 1498493080

View Profile Personal Message (Offline)

Ignore
1498493080
Reply with quote  #2

1498493080
Report to moderator
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 14, 2014, 11:38:12 AM
 #2

START P2POOL AFTER BOOT:

So you have your pool up and running and you want to create a "batch" file to start everything after a reboot.
Then do this:
Code:
cat >~/start-p2pool
/usr/bin/bitcoind
/home/mine/bin/ixcoind
/home/mine/bin/namecoind
/home/mine/bin/devcoind
sleep 200
screen -d -m -S p2pool ~/p2pool/run_p2pool.py bitcoin h3wby4zWjGwywZ --merged http://ixcoin:KouZ4RvmT3WkKZ@127.0.0.1:8338/ --merged http://namecoin:e9s4bmEaHvofEZ@127.0.0.1:7333 --merged http://devcoin:KouZ4RvmT3WkKZ@127.0.0.1:6333
[PRESS CTRL-D to exit]
Code:
chmod +x start-p2pool

When you want to start P2Pool after a reboot you just do:
Code:
~/start-p2pool
and you are good to go. Note there is a command that says "sleep 200". This means to wait 200 seconds before starting P2Pool. The reason for this is because it takes time to verify and sync the blockchain. Remember that during your reboot/downtime - transactions were going on and you are not up to sync. So depending on how fast your connection/server is you might have to adjust this value up or down.

If you want to setup automatic startup of P2Pool after a reboot do the following (after you have created the script above):
crontab -e -u (YOUR USER)
e.g.
Code:
crontab -e -u murdof
An editor will open. Add to the end the command:
@reboot /home/(YOUR USER)/start-p2pool
e.g.
Code:
@reboot /home/murdof/start-p2pool

LIST LOCAL WALLETS - VALUE:

Create a file called "listallcoins":
Code:
cat >~/listallcoins
echo BTC
/usr/bin/bitcoind -rpcpassword=h3wby4zWjGwywZ listaccounts
echo IXC
~/bin/ixcoind -rpcpassword=KouZ4RvmT3WkKZ listaccounts
echo NMC
~/bin/namecoind -rpcpassword=e9s4bmEaHvofEZ listaccounts
echo DVC
~/bin/devcoind -rpcpassword=KouZ4RvmT3WkKZ listaccounts
echo I0C
~/bin/i0coind -rpcpassword=KouZ4RvmT3WkKZ listaccounts
PRESS CTRL-D
Code:
chmod +x listallcoins
Make sure you replace the rpcpasswords if you have changed them and only list the coins you have.

ENABLE FIREWALL ON YOUR SERVER:
If you are running on a hosted linux system, there is usually no firewall so your server is open to the internet.
It is a good measure to lock down everything except the things we need. Credits to KyrosKrane:
Execute the following commands only once. The settings are saved and you don't need to execute them again. If you are running other services on the same server (e.g. http/ftp) make sure you enable those ports as well

Code:
# Set up and configure a firewall
# Note that we do NOT enable the RPC port for any coins!
sudo ufw default deny    # Deny everything unless expressly permitted
sudo ufw allow 22/tcp    # SSH
sudo ufw allow 8333/tcp  # bitcoin peer to peer
sudo ufw allow 8334/tcp  # namecoin peer to peer
sudo ufw allow 8337/tcp  # ixcoin peer to peer
sudo ufw allow 6334/tcp  # devcoin peer to peer
sudo ufw allow 7337/tcp  # i0coin peer to peer
sudo ufw allow 8492/tcp  # fusioncoin peer to peer
sudo ufw allow 9333/tcp  # P2pool peer to peer
sudo ufw allow 9332/tcp  # P2Pool connections and Web interface
sudo ufw --force enable  # Turn it on

Alternatively just do:
Code:
wget http://pool.nitro.gr/install-p2pool-firewall.sh
sudo sh ./install-p2pool-firewall.sh


List of ports used by coins for reference:

Coin / Listen Port / RPC Port
Bitcoin: 8333 / 8332
Devcoin: 6334 / 6333
Fusioncoin: 8492 / 18491
Huntercoin: 8398 / 8399
i0coin: 7337 / 7338
iXcoin: 8337 / 8338
namecoin: 8334 / 7333

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
IYFTech
Hero Member
*****
Offline Offline

Activity: 686


WANTED: Active dev to fix & re-write p2pool in C


View Profile
June 14, 2014, 11:48:17 AM
 #3

Nice work Murdof - the old guide was in desperate need of updating - kudos  Smiley

Not sure if it's worth it, but maybe add HUC & FSC to the mix? Just in case users want that little bit extra......although HUC can be a bit of a resource hog.

-- Smiley  Thank you for smoking  Smiley --  If you paid VAT to dogie for items you should read this thread:  https://bitcointalk.org/index.php?topic=1018906.0
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 14, 2014, 11:54:24 AM
 #4

Nice work Murdof - the old guide was in desperate need of updating - kudos  Smiley

Not sure if it's worth it, but maybe add HUC & FSC to the mix? Just in case users want that little bit extra......although HUC can be a bit of a resource hog.

Will update it with I0Coin and Fusioncoin. HUC never compiled it - never heard of it Tongue Will google and see what I find to add it as well.
Any other SHA256 coins that might be interesting?

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 14, 2014, 12:18:29 PM
 #5

I updated the guide with i0coin.

Fusioncoin - there was some issue with the rpc ports - should be my fault with the config that i have to check
huntercoin - i get error at linking. will look into this as well [update: i see in huntercoin forums that others have issues compiling under 14.04 but there is no solution that I found yet. They say if you compile namecoin you are good to go. We apparently compile namecoin OK but doesn't work]

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 14, 2014, 07:13:48 PM
 #6

I added binaries and the config files so that you don't have to go through all the compilation process.

This makes installation much faster and easier.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
PatMan
Hero Member
*****
Offline Offline

Activity: 924


Watch out for the "Neg-Rep-Dogie-Police".....


View Profile WWW
June 14, 2014, 07:44:04 PM
 #7

I would also include "strip *coind" (without the "'s) after compiling each coin daemon - this reduces the size of each *coind by a considerable amount. ie: strip bitcoind or strip namecoind, etc.

Peace  Smiley

"When one person is deluded it is called insanity - when many people are deluded it is called religion" - Robert M. Pirsig.  I don't want your coins, I want change.
Amazon UK BTC payment service - https://bitcointalk.org/index.php?topic=301229.0 - with FREE delivery!
http://www.ae911truth.org/ - http://rethink911.org/ - http://rememberbuilding7.org/
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 14, 2014, 07:49:27 PM
 #8

I would also include "strip *coind" (without the "'s) after compiling each coin daemon - this reduces the size of each *coind by a considerable amount. ie: strip bitcoind or strip namecoind, etc.

Peace  Smiley

Thanks for the tip!

Added to the guide and updated the binaries.

Note I don't compile bitcoind - I use the binaries from PPA Smiley

Indeed now the tar with the binaries is down to 7MB!

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
PatMan
Hero Member
*****
Offline Offline

Activity: 924


Watch out for the "Neg-Rep-Dogie-Police".....


View Profile WWW
June 14, 2014, 08:02:57 PM
 #9

The git link to ixcoin is not for the latest version.

The latest ixcoin client is https://github.com/FrictionlessCoin/iXcoin

Notice also the capital "X" in iXcoin that is also used in the folder name - but not the daemon itself.

Peace (again)  Wink

"When one person is deluded it is called insanity - when many people are deluded it is called religion" - Robert M. Pirsig.  I don't want your coins, I want change.
Amazon UK BTC payment service - https://bitcointalk.org/index.php?topic=301229.0 - with FREE delivery!
http://www.ae911truth.org/ - http://rethink911.org/ - http://rememberbuilding7.org/
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 14, 2014, 08:36:01 PM
 #10

The git link to ixcoin is not for the latest version.

The latest ixcoin client is https://github.com/FrictionlessCoin/iXcoin

Notice also the capital "X" in iXcoin that is also used in the folder name - but not the daemon itself.

Peace (again)  Wink

Done! Updated documentation and binaries.

Thanks for all your help. Let me know if you find something else!

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
cathoderay
Sr. Member
****
Offline Offline

Activity: 379


Welcome to dogietalk.bs


View Profile
June 15, 2014, 11:30:50 AM
 #11

huntercoin - i get error at linking. will look into this as well [update: i see in huntercoin forums that others have issues compiling under 14.04 but there is no solution that I found yet. They say if you compile namecoin you are good to go. We apparently compile namecoin OK but doesn't work]

I had the same problem with HUC on 14.04 - I've quoted this on the HUC thread in the hope they get the problem sorted  Wink

Have you been a victim of dogie insults, neg-rep'd for no reason or been falsely accused by him? If so, air your experiences here:  https://bitcointalk.org/index.php?topic=905210.0
Avoid manipulative Exchanges - Localbitcoins.com
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 15, 2014, 07:13:39 PM
 #12

Added instructions on how to start P2Pool after a reboot automatically.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 15, 2014, 07:41:33 PM
 #13

Added information to merge mine Fusioncoin as well.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 15, 2014, 07:53:32 PM
 #14

huntercoin - i get error at linking. will look into this as well [update: i see in huntercoin forums that others have issues compiling under 14.04 but there is no solution that I found yet. They say if you compile namecoin you are good to go. We apparently compile namecoin OK but doesn't work]

I had the same problem with HUC on 14.04 - I've quoted this on the HUC thread in the hope they get the problem sorted  Wink

I pulled updates from git today as they were some available but still it doesn't work....

Any other SHA-256 merge-minable coins I could add?

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
PatMan
Hero Member
*****
Offline Offline

Activity: 924


Watch out for the "Neg-Rep-Dogie-Police".....


View Profile WWW
June 15, 2014, 09:43:30 PM
 #15

I also merge mine GRouPcoin (GRP) - there's no exchange that I know of, but hey - why not?

https://github.com/RoadTrain/groupcoin

"When one person is deluded it is called insanity - when many people are deluded it is called religion" - Robert M. Pirsig.  I don't want your coins, I want change.
Amazon UK BTC payment service - https://bitcointalk.org/index.php?topic=301229.0 - with FREE delivery!
http://www.ae911truth.org/ - http://rethink911.org/ - http://rememberbuilding7.org/
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 06:53:55 AM
 #16

I also merge mine GRouPcoin (GRP) - there's no exchange that I know of, but hey - why not?

https://github.com/RoadTrain/groupcoin

No exchange huh?
I did compile it - but since there is no profit currently on it I just confirm that it compiles OK.
Just do:
cd ~
git clone https://github.com/RoadTrain/groupcoin
cd ~/groupcoin/src/
make -f makefile.unix
strip groupcoind
cp groupcoind ~/bin

and then create a config file like you are doing for other coins and start it.

Personally I did compile it only, didn't start it.
Will look into it again when you can find it on an exchange.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 16, 2014, 10:38:30 AM
 #17

hats off to you murdof, many thanks for posting this.

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 11:25:30 AM
 #18

Thanks raskul,

I added to my pool FSC merge mining as well and now I have 11000 FSC Smiley

I just want to ask if anyone finds the idea of providing a VMX image, P2Pool machine interesting.

That way people can just download VMX, grab VMWare Player (free), open the VMX and they are good to go.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 16, 2014, 11:45:45 AM
 #19

Thanks raskul,

I added to my pool FSC merge mining as well and now I have 11000 FSC Smiley

I just want to ask if anyone finds the idea of providing a VMX image, P2Pool machine interesting.

That way people can just download VMX, grab VMWare Player (free), open the VMX and they are good to go.

needless to say, i'm having troubles setting this up on a VPS - but I will not let it beat me  Cool

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 11:52:39 AM
 #20

Thanks raskul,

I added to my pool FSC merge mining as well and now I have 11000 FSC Smiley

I just want to ask if anyone finds the idea of providing a VMX image, P2Pool machine interesting.

That way people can just download VMX, grab VMWare Player (free), open the VMX and they are good to go.

needless to say, i'm having troubles setting this up on a VPS - but I will not let it beat me  Cool

Let me know where you get stuck - maybe I have a mistake somewhere or something is not clear.

Just a side note - I have run the scenario and worked ok with the commands above.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 16, 2014, 12:08:10 PM
 #21

Thanks raskul,

I added to my pool FSC merge mining as well and now I have 11000 FSC Smiley

I just want to ask if anyone finds the idea of providing a VMX image, P2Pool machine interesting.

That way people can just download VMX, grab VMWare Player (free), open the VMX and they are good to go.

needless to say, i'm having troubles setting this up on a VPS - but I will not let it beat me  Cool

Let me know where you get stuck - maybe I have a mistake somewhere or something is not clear.

Just a side note - I have run the scenario and worked ok with the commands above.

i've gone back to scratch twice, each time was my own error and I know where I went wrong... 3rd time lucky - fingers crossed!
if I get totally stuck i'll come begging, as of now the only linux experience I have is building nodes - it sure is a learning curve... i hope to crack this myself, and would rather not come begging lol from the look of it, I shouldn't have a problem; except for stubby fingers and rubbish command line expertise  Grin


ADD: DOH! i did it again. created the user and installed it all in root. someone just shoot me.

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 12:30:02 PM
 #22

You will get pissed off now - but I just added the lazy guy's guide Tongue

Two commands - everything is prepared for you and you are set.

Sorry I made you read all that Tongue

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 16, 2014, 12:45:31 PM
 #23

You will get pissed off now - but I just added the lazy guy's guide Tongue

Two commands - everything is prepared for you and you are set.

Sorry I made you read all that Tongue

no way - i'm doing it myself, if it drives me mad, i'll do it!

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 12:46:18 PM
 #24

You will get pissed off now - but I just added the lazy guy's guide Tongue

Two commands - everything is prepared for you and you are set.

Sorry I made you read all that Tongue

no way - i'm doing it myself, if it drives me mad, i'll do it!

Just make sure you are logged in as a user and not as root!

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 16, 2014, 12:47:18 PM
 #25

You will get pissed off now - but I just added the lazy guy's guide Tongue

Two commands - everything is prepared for you and you are set.

Sorry I made you read all that Tongue

no way - i'm doing it myself, if it drives me mad, i'll do it!

Just make sure you are logged in as a user and not as root!

ha.ha.ha only did that twice already.  Roll Eyes tell me once more, i'll remember this time  Undecided

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
newIndia
Legendary
*
Offline Offline

Activity: 1218


View Profile
June 16, 2014, 03:40:04 PM
 #26

You will get pissed off now - but I just added the lazy guy's guide Tongue

Two commands - everything is prepared for you and you are set.

Sorry I made you read all that Tongue

Can P2Pool be profitable for the one who is setting it up on the web server unless he has his own miners ?

murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 03:41:20 PM
 #27

You will get pissed off now - but I just added the lazy guy's guide Tongue

Two commands - everything is prepared for you and you are set.

Sorry I made you read all that Tongue

Can P2Pool be profitable for the one who is setting it up on the web server unless he has his own miners ?

If you mean not to have miners on your own and charge a fee for people to connect to your server, then i doubt it...

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
newIndia
Legendary
*
Offline Offline

Activity: 1218


View Profile
June 16, 2014, 03:43:34 PM
 #28

You will get pissed off now - but I just added the lazy guy's guide Tongue

Two commands - everything is prepared for you and you are set.

Sorry I made you read all that Tongue

Can P2Pool be profitable for the one who is setting it up on the web server unless he has his own miners ?

If you mean not to have miners on your own and charge a fee for people to connect to your server, then i doubt it...

Does not a normal pool, e.g. Eligius or Slush act like that ?

PatMan
Hero Member
*****
Offline Offline

Activity: 924


Watch out for the "Neg-Rep-Dogie-Police".....


View Profile WWW
June 16, 2014, 03:52:01 PM
 #29

There is now an easy fix for Huntercoin compile issues on 14.04:

Any chance of getting a fix for building the daemon on 14.04?  Wink

does it solve the problem PatMan? Smiley

http://forum.huntercoin.org/index.php?topic=104.0


Copy/paste:

1. Go to huntercoin folder in terminal (this may be different, I don't know where your download went, if it's on the desktop)
$ cd ~/Desktop/huntercoin

2. Go to src folder
$ cd src

3. edit db.cpp
$ nano db.cpp

4. Add #include "auxpow.h" so that it looks somehting like this at the top:

before:
// Copyright (c) 2009-2010 Satoshi Nakamoto
// Distributed under the MIT/X11 software license, see the accompanying
// file license.txt or http://www.opensource.org/licenses/mit-license.php.


#include "headers.h"
#include "db.h"
#include "net.h"
#include <boost/filesystem.hpp>
#include <boost/filesystem/fstream.hpp>

after:
// Copyright (c) 2009-2010 Satoshi Nakamoto
// Distributed under the MIT/X11 software license, see the accompanying
// file license.txt or http://www.opensource.org/licenses/mit-license.php.


#include "headers.h"
#include "db.h"
#include "net.h"
#include "auxpow.h"  //this is new
#include <boost/filesystem.hpp>
#include <boost/filesystem/fstream.hpp>

5. Save and exit.
Press ctrl^x and then enter

6. Try make again.

Kudos to snailbrain,domob & JoeGruff for sorting it out  Smiley

"When one person is deluded it is called insanity - when many people are deluded it is called religion" - Robert M. Pirsig.  I don't want your coins, I want change.
Amazon UK BTC payment service - https://bitcointalk.org/index.php?topic=301229.0 - with FREE delivery!
http://www.ae911truth.org/ - http://rethink911.org/ - http://rememberbuilding7.org/
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 16, 2014, 03:54:21 PM
 #30

Just want to say a big thank you to murdof for the time he has taken today to help me out.
I will be putting an old domain name to use with a 0% p2pool and all murdof's help has been very much appreciated.

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 05:08:42 PM
 #31

Does not a normal pool, e.g. Eligius or Slush act like that ?

Slush charges 2% fees. Eligius 0% fees and you get namecoin as well from both.
So Slush has some income.
Eligius I don't know if they merge mine other coins and keep them or how they work. I'm sure if you ask in their thread they will tell you.

So in other words you have a lot of competition. There are already P2Pool nodes with 0% fees and remember that P2Pool depends on latency as well.
So you can't launch a P2Pool node in India and expect people from Brazil to connect. Latency will be for sure more than 100ms.
Eligius/Slush/BTCGuild don't have that limitation.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 05:16:42 PM
 #32

PatMan it worked!

I will add the huntercoin as binary only for now till they get it sorted in the github in order to have cleaner instructions.

For people that want to try it out do:
cd ~
git clone https://github.com/chronokings/huntercoin
cd ~/huntercoin/src

edit the file as mentioned in PatMan's file.
Then compile it with:
make -f Makefile
strip huntercoind
cp huntercoind ~/bin

Create the config file:
mkdir ~/.huntercoin
cat >~/.huntercoin/huntercoin.conf
server=1
daemon=1
rpcuser=huntercoin
rpcpassword=KouZ4RvmT3WkKZ
port=8398
rpcport=8399
rpcallowip=127.0.0.1

PRESS CTRL-D

start ~/bin/huntercoind - let it sync the blockchain.

append at the end of your p2pool command:
--merged http://huntercoin:KouZ4RvmT3WkKZ@127.0.0.1:8399

Not tried yet fully. Still syncing the blockchain

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
sikke
Sr. Member
****
Offline Offline

Activity: 378


View Profile
June 16, 2014, 05:19:44 PM
 #33

Whats the minimum hw requirements to run a node. Network is 100mbits.
No hope to run it with rapi ?

Looking for somekind of similar integrated hw.

ChipMixer.com.|.Mixing reinvented for your privacy.|.ChipMixerwzxtzbw.onion
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 05:31:56 PM
 #34

Whats the minimum hw requirements to run a node. Network is 100mbits.
No hope to run it with rapi ?

Looking for somekind of similar integrated hw.

You need 4GB ram minimum and about 60-80GB disk space depending on the coins you choose.

This is a guide for Ubuntu. Never used Raspberry Pi so don't know... For sure the commands are not the same.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
warrensgun
Full Member
***
Offline Offline

Activity: 196

Mining since bitcoin was $1


View Profile
June 16, 2014, 05:32:59 PM
 #35

Pardon the noob question -- for mining BTC - is it still connecting with other P2Pool servers?  Or is it waiting to find a block solo?

If the BTC is still mined as part of a bigger collection - then this sounds like a great idea - run your own pool so you can have very low latency (i.e. a server by the miners) - and then the BTC stuff is still merged in.  I've happen to already have old server hardware sitting around anyway that can be reformatted.  Granted they have tiny drives - so I'd need to find something bigger to actually store the block chain.

murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 05:37:23 PM
 #36

Pardon the noob question -- for mining BTC - is it still connecting with other P2Pool servers?  Or is it waiting to find a block solo?

If the BTC is still mined as part of a bigger collection - then this sounds like a great idea - run your own pool so you can have very low latency (i.e. a server by the miners) - and then the BTC stuff is still merged in.  I've happen to already have old server hardware sitting around anyway that can be reformatted.  Granted they have tiny drives - so I'd need to find something bigger to actually store the block chain.

BTC it is connected with other P2Pool servers
All merged coins are solo-mined

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
warrensgun
Full Member
***
Offline Offline

Activity: 196

Mining since bitcoin was $1


View Profile
June 16, 2014, 06:40:22 PM
 #37

Pardon the noob question -- for mining BTC - is it still connecting with other P2Pool servers?  Or is it waiting to find a block solo?

If the BTC is still mined as part of a bigger collection - then this sounds like a great idea - run your own pool so you can have very low latency (i.e. a server by the miners) - and then the BTC stuff is still merged in.  I've happen to already have old server hardware sitting around anyway that can be reformatted.  Granted they have tiny drives - so I'd need to find something bigger to actually store the block chain.

BTC it is connected with other P2Pool servers
All merged coins are solo-mined

so are there enough other p2pool servers out there that it is still similar to mining in a larger pool like btcguild?

murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 16, 2014, 07:37:04 PM
 #38

so are there enough other p2pool servers out there that it is still similar to mining in a larger pool like btcguild?

Yes... there are a couple....
http://p2pool-nodes.info/

The total Pool hashrate is lower than BTCGuild currently.
That's why payouts are bigger and less often than BTCGuild. When more people mine on p2pool then payouts will be more often but smaller.
You still get the same amount in the long run - benchmarks have shown better overall numbers on p2pool.
Just search this forum for benchmark p2pool vs btcguild

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 17, 2014, 07:27:31 PM
 #39

Haven't gone through the whole post yet but I think this is/was EXACTLY what I was looking for- an updated and easy way to setup a p2pool.

I'll start working on this now Wink

good to see more and more p2pool nodes getting set up, best luck with yours waldohoover  Smiley

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 17, 2014, 07:50:34 PM
 #40

Haven't gone through the whole post yet but I think this is/was EXACTLY what I was looking for- an updated and easy way to setup a p2pool.

I'll start working on this now Wink

good to see more and more p2pool nodes getting set up, best luck with yours waldohoover  Smiley

I'm happy to see people wanting to support the network as well and move towards p2pool, thanks Smiley

Setting up the node (in my sig) wasn't too bad with Morblias initial guidance but I def want to get a pool going now. I run /r/TeamRedditMining on reddit and would love to have our own pool going.  Smiley

aha! a US node, i'll direct US friends to it.. my node is also in my sig (Central Cavern - which is an Amsterdam node) - but be careful, the page is noisy  Cheesy

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 17, 2014, 08:15:59 PM
 #41

Haven't gone through the whole post yet but I think this is/was EXACTLY what I was looking for- an updated and easy way to setup a p2pool.

I'll start working on this now Wink

good to see more and more p2pool nodes getting set up, best luck with yours waldohoover  Smiley

I'm happy to see people wanting to support the network as well and move towards p2pool, thanks Smiley

Setting up the node (in my sig) wasn't too bad with Morblias initial guidance but I def want to get a pool going now. I run /r/TeamRedditMining on reddit and would love to have our own pool going.  Smiley

aha! a US node, i'll direct US friends to it.. my node is also in my sig (Central Cavern - which is an Amsterdam node) - but be careful, the page is noisy  Cheesy

Very nice and thank you!

No harm in making mining a bit of fun, and since murdof did hold my hand rather a lot in setting up that node, credit should go to him; he's taught me loads over the past couple of days... my only linux work previously was setting up nodes for coins - what I really want to do is get my head around DGM. Always mined on small DGM pools up 'til now and I'd love to be able to know the ins and outs of it - even if I don't essentially set up a DGM pool, it's all learning huh?

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 17, 2014, 08:23:03 PM
 #42

A few months ago, I was working on a script that would automate the installation and rollout of a VPS with a bitcoind full node and a p2pool install. I never got it finalized with all the bells and whistles that I wanted, nor really polished, but it was good enough that I was able to adapt it for my local and remote p2pool installs, with some obvious changes. I'm posting it here in the hope you (or others) find it useful. I'd encourage you to scavenge whatever bits you can incorporate into your already-excellent guide.

Code:
###############################################################################
# Prerequisites
###############################################################################
#
# Before you run this, do the following:
#   * Log in as root
#   * Be in your home directory
#   * The parent of home directories has to be specified below (e.g., if user home directories are like /home/user1, then HOME_ROOT must be set to /home).
#
#   * (Optional but recommended) Create a file with the name specified below in REGULAR_USER_PUBLIC_KEY_FILE that contains your SSH public key.  This should be in the copy/paste format you get from PuttyGen, not the saved public key file.

# Assumptions:
#   * Running on a relatively recent version of Ubuntu (12.04 or later) -- not tested with anything else, but it might work anyway!
#   * Python is already installed. If not, the script attempts to install Python, but right now I can't guarantee if you'll get Python 2.7 or 3.x.  P2Pool doesn't work with 3.x.
#   * This script was designed for use on a VM or VPS that's basically empty, and only has the root user created.



###############################################################################
# This section has to be run as root
###############################################################################

PrintStatus()
{
    echo
    echo "----- STATUS: $*"
    echo
}

#############
# Script settings - EdIT THESE before running.
#############

HOME_ROOT=/home

# These are general script settings.  Edit these before running the script.
REGULAR_USER_NAME=heybrother  # Randomly inspired by the song on the radio as I wrote this!
REGULAR_USER_PUBLIC_KEY_FILE=$REGULAR_USER_NAME.pub
# @TODO: Prompt the user for these two values.


#############
# System updates and patches
#############

# @TODO: Maybe create a swap file? For now, the script assumes the host system either has enough memory or has swap already set up.
# For a sample command, see:
# https://raw.github.com/XertroV/BitcoinAutoNode/master/bitcoinAutoNode.sh

PrintStatus "Updating the system"
# Update your packages and package list
apt-get update
apt-get -y dist-upgrade # This does the functions of upgrade as well.

PrintStatus "Installing system tools"
# @TODO: To get the add-apt-repository command, we may need to install one of the following, as per:
# https://stackoverflow.com/questions/13018626/add-apt-repository-not-found
# for Ubuntu <= 12.04
# sudo apt-get install python-software-properties
# for Ubuntu >= 12.10
# sudo apt-get install software-properties-common
#
# At some point I'll have to figure out how to distinguish versions and load only the needed one, but for now, just load both.
apt-get -y install python-software-properties software-properties-common


# Add the bitcoin repository - used for some bitcoind dependencies
# So it seems this is an official bitcoin-core repository, or at least, official enough that the devs endorse downloads from it in their readme file.
#So, I'll trust the binary download from here, rather than try to muddle through the insane mess required to build bitcoind cleanly from source on multiple arbitrary target systems.
PrintStatus "Adding bitcoin repository"
add-apt-repository -y ppa:bitcoin/bitcoin
apt-get update


# Install some useful utilities and the pre-reqs for P2Pool and bitcoin
PrintStatus "Installing utilities"
apt-get -y install nano htop ufw monit git p7zip-full screen


#############
# Python & P2Pool dependencies
#############

# Make sure Python is installed
PYTHON="$(which python)"
if [ -z "$PYTHON" ] ; then
    PrintStatus "Installing Python."
    apt-get -y install python
    # @TODO: review this; make sure we don't install Python3 by mistake.
    PYTHON="$(which python)"
fi

if [ -z "$PYTHON" ] ; then
    PrintStatus "WARNING! Failed to install Python. P2Pool may not run."
    # @TODO: Any special handling here for the error?
else
    PYTHON_VERSION="$("$PYTHON" -V 2>&1)"
    PYTHON_26=$(awk 'BEGIN { if ("'"$PYTHON_VERSION"'" ~ /Python 2.6.*/) print "YES";}')
    #PYTHON_27=$(awk 'BEGIN { if ("'"$PYTHON_VERSION"'" ~ /Python 2.7.*/) print "YES";}') # Just for testing
    PYTHON_3x=$(awk 'BEGIN { if ("'"$PYTHON_VERSION"'" ~ /Python 3.*/) print "YES";}')

    if [ -n "$PYTHON_26" ] ; then
        PrintStatus "Python 2.6.* requires an additional dependency, installing."
        apt-get -y install python-argparse
    elif [ -n "$PYTHON_3x" ] ; then
        PrintStatus "WARNING! Python 3.x detected. This may not work with P2Pool."
        # @TODO: Any special handling here for the error?
    elif [ -n "$PYTHON_27" ] ; then
        PrintStatus "Python 2.7 detected, all ok!"
    fi
fi

# Install the pre-reqs for P2Pool
PrintStatus "Installing P2Pool dependencies"
apt-get -y install python-zope.interface python-twisted python-twisted-web


#############
# bitcoind
#############

# For the UI, not strictly needed, but nice to have
PrintStatus "Installing Bitcoin dependencies"
apt-get -y install libqtgui4
# Side note - this installs a metric crapton of dependencies...

# Download and install bitcoind
PrintStatus "Installing bitcoind"
apt-get -y install bitcoind


#############
# User creation
#############

# @TODO: Check if user already exists and skip this step if needed

# Create your regular user
PrintStatus "Creating your regular user $REGULAR_USER_NAME"
useradd $REGULAR_USER_NAME

# Grant your user sudo permission
usermod -a -G sudo $REGULAR_USER_NAME

# Make the user's SSH directory and add the private key
if [ -s "$REGULAR_USER_PUBLIC_KEY_FILE" ] ; then
    PrintStatus "Setting up SSH keys for your user"

    # First ensure the .ssh directory exists.
    if [ ! -d $HOME_ROOT/$REGULAR_USER_NAME/.ssh ] ; then
        mkdir -p $HOME_ROOT/$REGULAR_USER_NAME/.ssh
        chown $REGULAR_USER_NAME $HOME_ROOT/$REGULAR_USER_NAME
        chown $REGULAR_USER_NAME $HOME_ROOT/$REGULAR_USER_NAME/.ssh
        chmod 700 $HOME_ROOT/$REGULAR_USER_NAME/.ssh
    fi

    # Add the key and assign ownership of the file.
    cat ~/$REGULAR_USER_PUBLIC_KEY_FILE >> $HOME_ROOT/$REGULAR_USER_NAME/.ssh/authorized_keys
    chown $REGULAR_USER_NAME $HOME_ROOT/$REGULAR_USER_NAME/.ssh/authorized_keys
    chmod 600 $HOME_ROOT/$REGULAR_USER_NAME/.ssh/authorized_keys
    rm ~/$REGULAR_USER_PUBLIC_KEY_FILE # don't need it any more.

else
    PrintStatus "SSH key NOT found for user $REGULAR_USER_NAME. Please enter a login password."
    passwd $REGULAR_USER_NAME
fi

# PrintStatus "Locking out root password."
# @TODO


#############
# Firewall setup
#############

# Next, let's set up a firewall
PrintStatus "Setting up the firewall"
ufw default deny    # Deny everything unless expressly permitted
ufw allow 22/tcp    # SSH
ufw allow 8333/tcp  # Bitcoind peer to peer
    # Note that we do NOT enable the Bitcoind RPC port!
ufw allow 9333/tcp  # P2pool peer to peer
ufw allow 9332/tcp  # P2Pool connections and Web interface
ufw --force enable  # Turn it on


#############
# Monit setup
#############

# set up monit, a monitoring tool.
PrintStatus "Configuring Monit"
# @TODO

# @TODO: Also check out Zabbix as per:
# https://bitcointalk.org/index.php?topic=153232.0
# http://www.zabbix.com/


#############
# Ideas for future growth:
#############

# Log rotation: http://manpages.ubuntu.com/manpages/jaunty/man8/logrotate.8.html
# Also https://bitcoin.stackexchange.com/questions/18857/how-to-limit-the-debug-log-file-while-running-bitcoind



###############################################################################
# This section has to be run as your regular user
###############################################################################

# @TODO: Maybe run this directly as the user?
# http://www.cyberciti.biz/open-source/command-line-hacks/linux-run-command-as-different-user/



PrintStatus()
{
    echo
    echo "----- STATUS: $*"
    echo
}



#############
# Bitcoind setup
#############

# Create the bitcoind configuration file
PrintStatus "Creating the bitcoind configuration file"
mkdir -p $HOME/.bitcoin
config="$HOME/.bitcoin/bitcoin.conf"
randUser=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
randPass=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`

cat <<EOF > $config
server=1
daemon=1

rpcuser=$randUser
rpcpassword=$randPass
connections=40

blockmaxsize=1000000
mintxfee=0.00001
minrelaytxfee=0.00001
EOF


# Download the bitcoin bootstrap file. This saves a massive amount of time when starting bitcoind the first time - literally days.
# The right way to do this is via bittorrent - the seed file is at:

# Torrent info hash: 2d4e6c1f96c5d5fb260dff92aea4e600227f1aea
# Torrent magnet link:
# magnet:?xt=urn:btih:2d4e6c1f96c5d5fb260dff92aea4e600227f1aea&dn=bootstrap.dat&tr=udp://tracker.openbittorrent.com:80&tr=udp://tracker.publicbt.com:80&tr=udp://tracker.ccc.de:80&tr=udp://tracker.istole.it:80

# Details: https://bitcointalk.org/index.php?topic=145386.0  (Check here for more recent versions every few months.)

# However, most VPS providers don't allow torrents.  So alternately, we'll download using http. Not nearly as efficient, but still faster than syncing with the network.
PrintStatus "Downloading Bitcoin bootstrap.dat file.  This could take a while..."
cd $HOME/.bitcoin

#wget https://bitfetch.com/static/bootstrap.7z
# Note: as of this writing, the SSL certificate for bitfetch.com has expired.
# If you just try to wget the file, wget will fail, complaining about it.
# So, we have to force wget to ignore the expired certificate. Once the
# certificate on the site has been properly renewed, delete the line below
# and uncomment the line above.
wget --no-check-certificate https://bitfetch.com/static/bootstrap.7z


PrintStatus "Uncompressing Bitcoin bootstrap.dat file."
7z x bootstrap.7z

# Start bitcoind so that it can begin processing the bootstrap and syncing with the network
# actually don't do this; instead force a reboot at the end of the script.
# PrintStatus "Starting bitcoind"
# bitcoind -daemon


#############
# P2Pool setup
#############

# Download and install p2pool
cd
git clone https://github.com/forrestv/p2pool.git
# no actual install needed

# Start P2pool in the background.
# Note that if you enable this in this script, P2Pool will spit out a few hundred errors until bitcoind is caught up.
# So, disabling this here.
# nohup python $HOME/p2pool/run_p2pool.py &

#############
# cron setup
#############

# Add the entries for the cron jobs
PrintStatus "Setting up cron jobs"
crontab -l > $HOME/Old_cron.txt
echo "@reboot bitcoind -daemon" >> $HOME/Old_cron.txt
echo "@reboot python $HOME/p2pool/run_p2pool.py" >> $HOME/Old_cron.txt
crontab $HOME/Old_cron.txt
rm $HOME/Old_cron.txt


# @TODO: Auto update and restart P2Pool (may or may not be desirable)
# http://pastebin.com/HtD0uku4

EDIT 2014-06-20: I just noticed that the download of the blockchain file was disabled. That's because I was futzing around with the script the last time I used it, and I forgot to re-enable that line. Sad It's corrected now.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 17, 2014, 08:41:40 PM
 #43

breakthrough moment.

I used to get all confused and dizzy when I looked at code. scanning through that box, Kyros, it would seem I may very well have 'learned a new language'
I'll devote some time over the weekend to look into this in more depth.

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 17, 2014, 08:52:03 PM
 #44

This is also very help and really great, thanks for the contribution!

(Were you the guy who posted something similar about this on reddit?)
No, but I remember that post. It inspired me to create this script, and in fact, the section for setting up the bitcoin configuration file was adapted from that post.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 18, 2014, 07:06:16 AM
 #45

Good stuff Kyros!

I don't have in the guide any information about firewalling - so I guess this could be in the extras.
I did add rpcallow=127.0.0.1 - but still people could find an exploit to that - so firewalling will be the best way to go.

What I understand is that people want to just get on a Linux box and just type 2 commands and set up everything.
I don't think that people prefer to build things (I don't personally but I have to).
So that's why I went with the binaries and a mini script to execute all the commands to have you up and running ASAP.
I have tried the script in 3 scenarios already and works great.
The only thing that I found is that when tar extracts some files are created with root as owner. Maybe I'm missing a tar option to use current user? Haven't checked.

All in all I invite you to try it out the 2 line script (you can just wget the script and check the contents) and let me know what you think.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
nreal
Full Member
***
Offline Offline

Activity: 186


View Profile
June 18, 2014, 09:27:14 AM
 #46

All make commands could go like make -j12.... if you have lets say 8 cores, it makes it alot faster that way... time is coins Smiley


make -j12 -f makefile.unix
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 18, 2014, 08:37:04 PM
 #47

huntercoin is fixed and compiles ok

still though downloading the blockchain so haven't tried it (for some reason downloading is very slow)

so when it has finished and i confirm it works with merge mining I will add it to the guide.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
jonnybravo0311
Legendary
*
Offline Offline

Activity: 1134


Mine at Jonny's Pool


View Profile WWW
June 18, 2014, 09:44:09 PM
 #48

Hey murdof... just wanted to say good job on this - especially the "Lazy Man's" version.  Personally, I hacked my way through setting everything up (Disclaimer: I have everything running natively on OSX Mavericks).  The work you've done to compress the installation on Ubuntu 14.04LTS down to two commands is impressive.  Nicely done!

Jonny's Pool - Mine with us and help us grow!  Support a pool that supports Bitcoin, not a hardware manufacturer's pockets!  No SPV cheats.  No empty blocks.
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 19, 2014, 12:58:23 PM
 #49

Something I just noticed:

Install Ubuntu 14.04 LTS Server from here: http://www.ubuntu.com/download/server
(note do not install Ubuntu 14.04 LTS - you need Server version for text only install)

I think in the second sentence, you meant to say, "do not install Ubuntu Desktop 14.04 LTS" -- but either way, this setup should work just fine even on a Desktop install of Ubuntu. You'd just need more disk space for the graphical stuff. In the past, I've run plenty of server-type software (including bitcoind and p2pool) on the Desktop versions of Ubuntu.

I'll spin up a VM with Ubuntu Desktop 14.04 installed and see how the script runs.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 19, 2014, 01:42:18 PM
 #50

Thanks Kyros,

fixed.

I don't think there is a point to run a server with GUI.
Some people might want to run it on their main desktop on the other hand - so yes it would be good to know if you tried it and worked.
Normally it should work ok.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
Collider
Sr. Member
****
Offline Offline

Activity: 350


View Profile
June 19, 2014, 01:56:53 PM
 #51

Murdof, how much of your RAM are you actually using on p2pool and Bitcoin client (aswell as the server OS)?


 
 
           ▄████▄
         ▄████████▄
       ▄████████████▄
     ▄████████████████▄
    ████████████████████      ▄█▄                 ▄███▄                 ▄███▄                 ▄████████████████▀   ▄██████████

  ▄▄▄▀█████▀▄▄▄▄▀█████▀▄▄▄     ▀██▄             ▄██▀ ▀██▄             ▄██▀ ▀██▄             ▄██▀                   ██
▄█████▄▀▀▀▄██████▄▀▀▀▄█████▄     ▀██▄         ▄██▀     ▀██▄         ▄██▀     ▀██▄         ▄██▀        ▄█▄          ▀██████████████▄
████████████████████████████       ▀██▄     ▄██▀         ▀██▄     ▄██▀         ▀██▄     ▄██▀          ▀█▀                        ██
 ▀████████████████████████▀          ▀██▄ ▄██▀             ▀██▄ ▄██▀     ▄█▄     ▀██▄ ▄██▀                                       ██
   ▀████████████████████▀              ▀███▀                 ▀███▀       ▀█▀       ▀███▀      ▄███████████████████████████████████▀
     ▀████████████████▀
       ▀████████████▀
         ▀████████▀
           ▀████▀
║║


║║
.
.

║║
██
║║
.
.

║║
██
║║
.
║║


║║
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 19, 2014, 02:16:34 PM
 #52

Murdof, how much of your RAM are you actually using on p2pool and Bitcoin client (aswell as the server OS)?

I'm running with 4GB and it utilizes about 2.5GB.
Huntercoin is something that takes up all CPU + Memory so I stopped it cause anyway I found it useless. Too slow and too many resources.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
wknight
Legendary
*
Offline Offline

Activity: 889


Bitcoin calls me an Orphan


View Profile WWW
June 19, 2014, 03:35:34 PM
 #53

With memory being so cheap now I found 8 Gigs to be VERY comfortable running my p2pool node. no need to pop into swap file EVER!

Mining Both Bitcoin and Litecoin.
Collider
Sr. Member
****
Offline Offline

Activity: 350


View Profile
June 19, 2014, 04:03:09 PM
 #54

While memory used to be more expensive, it is stil nice to know what the actual requirements are.

I would therefore think it is fair to say that you should get away with a 3 GB Ram VPS safely.

Most VPS providers allow you to exceed the allocated memory by atleast 10-20% anyway Wink


 
 
           ▄████▄
         ▄████████▄
       ▄████████████▄
     ▄████████████████▄
    ████████████████████      ▄█▄                 ▄███▄                 ▄███▄                 ▄████████████████▀   ▄██████████

  ▄▄▄▀█████▀▄▄▄▄▀█████▀▄▄▄     ▀██▄             ▄██▀ ▀██▄             ▄██▀ ▀██▄             ▄██▀                   ██
▄█████▄▀▀▀▄██████▄▀▀▀▄█████▄     ▀██▄         ▄██▀     ▀██▄         ▄██▀     ▀██▄         ▄██▀        ▄█▄          ▀██████████████▄
████████████████████████████       ▀██▄     ▄██▀         ▀██▄     ▄██▀         ▀██▄     ▄██▀          ▀█▀                        ██
 ▀████████████████████████▀          ▀██▄ ▄██▀             ▀██▄ ▄██▀     ▄█▄     ▀██▄ ▄██▀                                       ██
   ▀████████████████████▀              ▀███▀                 ▀███▀       ▀█▀       ▀███▀      ▄███████████████████████████████████▀
     ▀████████████████▀
       ▀████████████▀
         ▀████████▀
           ▀████▀
║║


║║
.
.

║║
██
║║
.
.

║║
██
║║
.
║║


║║
wknight
Legendary
*
Offline Offline

Activity: 889


Bitcoin calls me an Orphan


View Profile WWW
June 19, 2014, 04:24:46 PM
 #55

While memory used to be more expensive, it is stil nice to know what the actual requirements are.

I would therefore think it is fair to say that you should get away with a 3 GB Ram VPS safely.

Most VPS providers allow you to exceed the allocated memory by atleast 10-20% anyway Wink

Totally passed up the idea of a VPS concept.. good point.. though i like to keep my memory on a even number Smiley call me old fashioned. 4GB Ram would be ideal and yes I have run it on a vps at 4GB and no problems.. course it was for litecoin

The only reason I stay away from VPS is i want something local. Local is always the best results with p2pool shares

Mining Both Bitcoin and Litecoin.
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 19, 2014, 04:34:30 PM
 #56

While memory used to be more expensive, it is stil nice to know what the actual requirements are.

I would therefore think it is fair to say that you should get away with a 3 GB Ram VPS safely.

Most VPS providers allow you to exceed the allocated memory by atleast 10-20% anyway Wink

Totally passed up the idea of a VPS concept.. good point.. though i like to keep my memory on a even number Smiley call me old fashioned. 4GB Ram would be ideal and yes I have run it on a vps at 4GB and no problems.. course it was for litecoin

The only reason I stay away from VPS is i want something local. Local is always the best results with p2pool shares

definitely, 100% agree, unfortunately I don't have the ability to run a local node, so VPS is a good option for folks like me.
and with murdof's guide and how-to, those who can, can, and those who can't, can too!

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
wknight
Legendary
*
Offline Offline

Activity: 889


Bitcoin calls me an Orphan


View Profile WWW
June 19, 2014, 04:49:58 PM
 #57


definitely, 100% agree, unfortunately I don't have the ability to run a local node, so VPS is a good option for folks like me.
and with murdof's guide and how-to, those who can, can, and those who can't, can too!

Since i have no done it with bitcoin on a VPS.. how are the results? Are you seeing a lot more stales/DOA?

Mining Both Bitcoin and Litecoin.
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 19, 2014, 04:51:07 PM
 #58

see for yourself; http://pool.centralcavern.uk:9332/

 Smiley

looks ok to me.. how is yours locally?

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
wknight
Legendary
*
Offline Offline

Activity: 889


Bitcoin calls me an Orphan


View Profile WWW
June 19, 2014, 05:25:57 PM
 #59

see for yourself; http://pool.centralcavern.uk:9332/

 Smiley

looks ok to me.. how is yours locally?

3.18TH/s (1.7% DOA)

so that is a bit of difference

Mining Both Bitcoin and Litecoin.
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 19, 2014, 05:28:29 PM
 #60

see for yourself; http://pool.centralcavern.uk:9332/

 Smiley

looks ok to me.. how is yours locally?

3.18TH/s (1.7% DOA)

so that is a bit of difference

very good indeed.please always mine p2pool  Grin

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 19, 2014, 10:23:00 PM
 #61

OK, so I threw together a VM and loaded Ubuntu Desktop 14.04 on it.

Next I ran the two "lazy install" commands -- but they failed.

Code:
./install-p2pool.sh: 5: ./install-p2pool.sh: aptitude: not found
./install-p2pool.sh: 6: ./install-p2pool.sh: git: not found

So, two things.

First, use apt-get, not aptitude.  apt-get will work fine on both server and desktop versions of Ubuntu. (I'm guessing that aptitude is installed by default on the server version; but it's not on the desktop version.)

Second, I'd suggest reordering the commands in the script as follows. Yes, I added comments. Smiley

Code:
#!/bin/bash

# Install the pre-req for add-apt-repository
apt-get -y install software-properties-common

# Add the bitcoin repository
add-apt-repository -y ppa:bitcoin/bitcoin

# Update installed packages
apt-get -y update
apt-get -y dist-upgrade

# Install bitcoind and other needed prerequisites
apt-get -y install bitcoind python-software-properties screen git python-rrdtool python-pygame python-scipy python-twisted python-twisted-web python-imaging build-essential libglib2.0-dev libglibmm-2.4-dev libqt4-dev python-dev libssl-dev libdb5.1++-dev libboost1.55-all-dev dh-autoreconf libcurl4-openssl-dev libminiupnpc-dev

# Install p2pool
git clone git://github.com/forrestv/p2pool.git

# Download and unpack scripts and binaries for other coins
wget http://pool.nitro.gr/p2pool-files.tar.gz
tar xvzf p2pool-files.tar.gz
rm p2pool-files.tar.gz

My one biggest concern is that the RPC passwords are hardcoded in your config files. While it's true you limit connections to 127.0.0.1, that still makes me nervous. I really suggest randomizing the passwords.  You can use something similar to what I have in my script; I'd be happy to adapt the logic for your script if you like.

I'd also strongly suggest that you incorporate the bootstrap download logic I have in my script -- that will shave off days of download time for the bitcoin blockchain. I'd even suggest you consider setting it up as a bittorrent download, although if someone uses this script on a VPS, they could get in trouble if their VPS provider doesn't allow torrents.  Http is safer in that sense, but less "polite" on the network.  Maybe prompt the user whether they'd like to download the blockchain via torrent, via http, or via the normal bitcoind client download?  And set the client download as the default option, as that's the "safest."

Finally, I'd suggest putting the "screen" commands and other useful scripts you mention later in your guide into shell scripts that are also included in the tar file.  Essentially you want it to be similar to a Windows install -- download the installer, run it, and magically p2pool works, with easy-to-use commands all ready to use.

More as I play further with this setup.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 20, 2014, 04:28:00 AM
 #62

Thanks Kyros!

Please do go ahead and make the changes.

Post them here and I will be happy to integrate them!

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
Acejam
Sr. Member
****
Offline Offline

Activity: 286


View Profile
June 20, 2014, 03:32:29 PM
 #63

Murdof, how much of your RAM are you actually using on p2pool and Bitcoin client (aswell as the server OS)?

If you plan to run a P2Pool node with merged mining that actually gets a decent amount of traffic, plan on at least 4GB, minimum. In fact, you might out of memory on that pretty easily. I know I certainly have.


Most VPS providers allow you to exceed the allocated memory by atleast 10-20% anyway Wink

If you're using a VPS provider that allows you to go over your set RAM limit, I would stay far far away from them.
PatMan
Hero Member
*****
Offline Offline

Activity: 924


Watch out for the "Neg-Rep-Dogie-Police".....


View Profile WWW
June 20, 2014, 04:10:29 PM
 #64

I was merge mining BTC, NMC, FSC, DVC, I0C, IXC, GRP & HUC using 16GB RAM on a unlocked & OC'd 65W Phenom Quad-core quite comfortably with a constant 0.2 sec bitcoind latency.

I say "was" because I have recently sold my last remaining p2pool compatible hardware (S1's) due to the cost of electricity here in the UK making them non profitable at the current BTC rate. All my remaining hardware - S2's, Dragons etc don't work with p2pool - so I am now forced to ditch running my node after nearly 3 years of p2pool mining.......

Sad days indeed  Embarrassed

I suggest inserting "--give-author 0" into the code on this guide, as it is because of the lack of development that I am forced to quit mining with p2pool after all this time. Unless Kano can work his magic, or something remarkable happens to the p2pool code, it's not looking like I or many others will be able to get back to supporting & mining with p2pool.

Peace.

"When one person is deluded it is called insanity - when many people are deluded it is called religion" - Robert M. Pirsig.  I don't want your coins, I want change.
Amazon UK BTC payment service - https://bitcointalk.org/index.php?topic=301229.0 - with FREE delivery!
http://www.ae911truth.org/ - http://rethink911.org/ - http://rememberbuilding7.org/
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 20, 2014, 06:46:39 PM
 #65

Caught another error.  In the section for creating start-p2pool, you have this:

Code:
cat >~/start-p2pool
/usr/bin/bitcoind
/home/mine/bin/ixcoind
/home/mine/bin/namecoind
/home/mine/bin/devcoind

You should change the paths from /home/mine to ~.  Also you should add -daemon after each one; otherwise the process will terminate as soon as you log out of that machine.  Finally, you forgot to start i0coin. So, something like this:

Code:
/usr/bin/bitcoind -daemon
~/bin/namecoind -daemon
~/bin/ixcoind -daemon
~/bin/devcoind -daemon
~/bin/i0coind -daemon
~/bin/fusioncoind -daemon # only if you enabled that too

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 20, 2014, 07:04:52 PM
 #66

Also just noticed you added a section on the firewall.  Two things there.

1) You never actually install ufw.  You have to add it to the apt-get line.
2) You don't open ports for any of the alt-coins.  They won't connect to peers if you don't do that.  Here's the revised list.

Code:
# Set up and configure a firewall
# Note that we do NOT enable the RPC port for any coins!
sudo ufw default deny    # Deny everything unless expressly permitted
sudo ufw allow 22/tcp    # SSH
sudo ufw allow 8333/tcp  # bitcoin peer to peer
sudo ufw allow 8334/tcp  # namecoin peer to peer
sudo ufw allow 8337/tcp  # ixcoin peer to peer
sudo ufw allow 6334/tcp  # devcoin peer to peer
sudo ufw allow 7337/tcp  # i0coin peer to peer
sudo ufw allow 8492/tcp  # fusioncoin peer to peer
sudo ufw allow 9333/tcp  # P2pool peer to peer
sudo ufw allow 9332/tcp  # P2Pool connections and Web interface
sudo ufw --force enable  # Turn it on

That said, you might want to consider sticking all that in a shell script and calling that with sudo, rather than using sudo on each individual command.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 21, 2014, 09:31:47 AM
 #67

Hey KyrosKrane,

i integrated your suggestions.

About daemon i don't think it is needed cause i declare it in the config files.
I've been using it like that and of course i'm not logged in all day long Smiley

Thanks for the feedback - keep it coming.

Also about the rpcpasswords since this is something that is used only locally i don't think it really matters.
But on the other hands everyone can just edit the password and set up their own.
So I don't know if it is worth it to add randomized passwords.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
zvs
Legendary
*
Offline Offline

Activity: 1456


Bogleg.


View Profile WWW
June 21, 2014, 11:20:33 AM
 #68

You could run it on a VPS w/ 2 GB of (dedicated, not shared) RAM, but I suspect you'd have to edit the source to block all transactions, or set the correct variables (limitfreerelay in bitcoin?)....   limitfreerelay I believe is what would stop the transactions from even entering memory, unlike maxblocksize.

Dacentec, best deals for US dedicated servers. They regularly restock $20-$25 Opterons with 8-16GB RAM & 2x1-2TB HDD's (ofc, usually lots of other good stuff to choose from).  I did a Serverbear benchmark of one of my $20/mo Opteron (June last year), it's here.  Have had about a half dozen different servers with Dacentec, & none have failed to sustain at least 40MB/s (burst higher). My favorite is a 12-month rent-to-own ZT Systems 2XL5520 16GB 2x2TB SATA for $40/month (got lucky with the 'off-brand', haven't seen a RTO 2xL5520 for under $50/mo since -- at least for monthly contracts).  wholesaleinternet.com has some ancient 2-core intel CPUs @ $10/mo sometimes (I got an Intel Core 2 6300 @ 1.86GHz, with a 250GB HDD with 46000 hours on it, LOL. $20 @ Dacentec is much better, if you can grab one). joesdatacenter.com (same location as Wholesale Internet) also occasionally has specials (or if you don't want to wait, it has an AMD Opteron 170 @ $16/mo).
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 21, 2014, 12:08:25 PM
 #69

The huntercoin bug appears to be fixed in git.  I cloned the repository, and the missing include file is now in there.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
Stery
Full Member
***
Offline Offline

Activity: 120


View Profile
June 21, 2014, 12:15:01 PM
 #70

Do you need miners to run this ?
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 21, 2014, 12:16:41 PM
 #71

The huntercoin bug appears to be fixed in git.  I cloned the repository, and the missing include file is now in there.

Year already have updated binaries and included the guise how to compile it.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 21, 2014, 12:38:41 PM
 #72

And behold! The entire guide, compressed into one install script. Smiley

Murdof, this basically replaces your download script.  It doesn't need sudo to run; instead, it handles the sudo requirement inside the script itself, and only for the system update portion. I also put all the source code downloads for the various daemons into a subdirectory, so they don't clutter the user's home dir.

You can also update your .gz file to only include the compiled binaries.  The "batch files" and config files are created by this script; they'll overwrite what's in your archive.

It's self-documenting, and fairly clear.  I've been using it over and over on a VM I made, to test different configurations, and I can't find any bugs.

Code:
#!/bin/bash

# A function to display help and exit.
Usage()
{
echo "$(basename $0): Downloads and installs bitcoind, p2pool, and other coins for merged mining." >&2
echo "Usage:" >&2
echo "To download precompiled binaries (faster but less secure):" >&2
echo "        $(basename $0) --download" >&2
echo "To download the source code and compile yourself (slower but more secure):" >&2
echo "        $(basename $0) --compile" >&2
echo "You may also choose to download the bitcoin blockchain via http. Add the following to the command line:" >&2
echo "        --http" >&2
echo "If you don't use this, the blockchain will instead download using the (much slower) built-in peer-to-peer process." >&2
echo >&2
exit 1
}

# Determine what the user wants to do, or display help
if [ $# -eq 0 ] ; then
Usage
else
while [ $# -gt 0 ] ; do
if [ "--download" = "$1" ] ; then
Method="download"
elif [ "--compile" = "$1" ] ; then
Method="compile"
# elif [ "--torrent" = "$1" ] ; then
# Blockchain="torrent"
elif [ "--http" = "$1" ] ; then
Blockchain="http"
else
echo "Error: Unrecognized parameter on command line. Aborting" >2
Usage
fi
shift
done
fi

# Make sure the user specified where to compile or download
if [ -z "$Method" ] ; then
echo "Error: No installation method specified (compile or download). Aborting" >2
Usage
fi

# Create a script to update the system.  This requires sudo, so we can't run it directly.

cat <<EOF >~/sudoscript.sh
#!/bin/sh

# Install the pre-req for add-apt-repository
apt-get -y install software-properties-common

# Add the bitcoin repository
add-apt-repository -y ppa:bitcoin/bitcoin

# Update installed packages
apt-get -y update
apt-get -y dist-upgrade

# Install the needed prerequisites
# Note that bitcoind is always installed as a binary, not compiled.
apt-get -y install bitcoind python-software-properties screen git python-rrdtool python-pygame python-scipy python-twisted python-twisted-web python-imaging build-essential libglib2.0-dev libglibmm-2.4-dev libqt4-dev python-dev libssl-dev libdb5.1++-dev libboost1.55-all-dev dh-autoreconf libcurl4-openssl-dev libminiupnpc-dev ufw p7zip-full

# Set up and configure a firewall
# Note that we do NOT enable the RPC port for any coins!
ufw default deny    # Deny everything unless expressly permitted
ufw allow 22/tcp    # SSH
ufw allow 8333/tcp  # bitcoin peer to peer
ufw allow 8334/tcp  # namecoin peer to peer
ufw allow 8337/tcp  # ixcoin peer to peer
ufw allow 6334/tcp  # devcoin peer to peer
ufw allow 7337/tcp  # i0coin peer to peer
ufw allow 8492/tcp  # fusioncoin peer to peer
ufw allow 8398/tcp  # huntercoin peer to peer
ufw allow 9333/tcp  # P2pool peer to peer
ufw allow 9332/tcp  # P2Pool connections and Web interface
ufw --force enable  # Turn it on

EOF

echo "About to update your system.  This requires elevated privileges. Please enter your password when prompted."
sleep 3 # pause so the user has a chance to see and read the message.
sudo sh ~/sudoscript.sh
rm ~/sudoscript.sh

# Install p2pool
git clone git://github.com/forrestv/p2pool.git

# Now either download or compile the binaries.
if [ "$Method" = "download" ] ; then
# Download and unpack scripts and binaries for other coins
wget http://pool.nitro.gr/p2pool-files.tar.gz

# Ensure the compiled binaries archive is valid! This checksum has to be updated each time the binaries are repackaged.
# Too much manual work, Murdof can enable this if he wants to maintain it. (Switch "false" to "true")
if false; then
checksum="$(md5sum p2pool-files.tar.gz | awk '{print $1;}')"
if [ "$checksum" != "0e35d6a1ee234b1a90975588917275eb" ] ;  then
echo "ERROR: Downloaded binaries are corrupt or have been tampered with! Please try running this script again.  If this error repeats, please contact the script author here:" >&2
echo "https://bitcointalk.org/index.php?topic=651819.0" >&2
exit 3
fi
fi

Status="$Status\nDownload succeeded."

# Unpack the binaries and delete the downloaded archive.
tar xvzf p2pool-files.tar.gz
rm p2pool-files.tar.gz

elif [ "$Method" = "compile" ] ; then
# Make the local binaries directory
mkdir -p ~/bin

# Make a directory to download and store all the alt-coin sources
mkdir -p ~/coin_source

# Download and compile Namecoin.
cd ~/coin_source
git clone https://github.com/namecoin/namecoin
cd ~/coin_source/namecoin/src
make -f Makefile
if [ -f namecoind ] ; then
Status="$Status\nNamecoin compilation succeeded."
strip namecoind
cp namecoind ~/bin
else
Status="$Status\nNamecoin compilation FAILED."
fi

# Download and compile iXcoin.
cd ~/coin_source
git clone https://github.com/FrictionlessCoin/iXcoin
cd ~/coin_source/iXcoin/src
make -f makefile.unix
if [ -f ixcoind ] ; then
Status="$Status\nIxcoin compilation succeeded."
strip ixcoind
cp ixcoind ~/bin
else
Status="$Status\nIxcoin compilation FAILED."
fi

# Download and compile Devcoin.
cd ~/coin_source
git clone git://gitorious.org/devcoin/devcoin.git
cd ~/coin_source/devcoin/src
make -f makefile.unix USE_PNP=1 devcoind
if [ -f devcoind ] ; then
Status="$Status\nDevcoin compilation succeeded."
strip devcoind
cp devcoind ~/bin
else
Status="$Status\nDevcoin compilation FAILED."
fi

# Download and compile i0coin.
cd ~/coin_source
git clone http://github.com/rsnel/i0coin/
cd ~/coin_source/i0coin/src
make -f makefile.unix i0coind
if [ -f i0coind ] ; then
Status="$Status\ni0coin compilation succeeded."
strip i0coind
cp i0coind ~/bin
else
Status="$Status\ni0coin compilation FAILED."
fi

# Download and compile Fusioncoin.
cd ~/coin_source
git clone https://github.com/fusioncoin/fusioncoin
cd ~/coin_source/fusioncoin/src
make -f makefile.unix
if [ -f fusioncoind ] ; then
Status="$Status\nFusioncoin compilation succeeded."
strip fusioncoind
cp fusioncoind ~/bin
else
Status="$Status\nFusioncoin compilation FAILED."
fi

# Download and compile Huntercoin.
cd ~/coin_source
git clone https://github.com/chronokings/huntercoin
cd ~/coin_source/huntercoin/src
make -f Makefile
if [ -f huntercoind ] ; then
Status="$Status\nHuntercoin compilation succeeded."
strip huntercoind
cp huntercoind ~/bin
else
Status="$Status\nHuntercoin compilation FAILED."
fi

else
# This should never happen! It means there's an error in this script itself.
echo "Unhandled error! Bad programmer! No cookie!" >&2
exit 2
fi


# Make directories for everything
mkdir -p ~/.bitcoin
mkdir -p ~/.namecoin
mkdir -p ~/.ixcoin
mkdir -p ~/.devcoin
mkdir -p ~/.i0coin
mkdir -p ~/.fusioncoin
mkdir -p ~/.huntercoin

# Set up the various RPC usernames and passwords. Note that you never need to remember these; they just have to exist and be unguessable.
Bitcoin_User=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
Bitcoin_Password=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`

Namecoin_User=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
Namecoin_Password=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`

Ixcoin_User=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
Ixcoin_Password=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`

Devcoin_User=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
Devcoin_Password=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`

i0coin_User=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
i0coin_Password=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`

Fusioncoin_User=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
Fusioncoin_Password=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`

Huntercoin_User=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
Huntercoin_Password=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`


# Create the various configuration files
cat >~/.bitcoin/bitcoin.conf <<EOF
server=1
daemon=1
rpcuser=$Bitcoin_User
rpcpassword=$Bitcoin_Password
rpcallowip=127.0.0.1

EOF

cat >~/.namecoin/namecoin.conf <<EOF
server=1
daemon=1
rpcuser=$Namecoin_User
rpcpassword=$Namecoin_Password
port=8334
rpcport=7333
rpcallowip=127.0.0.1

EOF

cat >~/.ixcoin/ixcoin.conf <<EOF
server=1
daemon=1
rpcuser=$Ixcoin_User
rpcpassword=$Ixcoin_Password
port=8337
rpcport=8338
rpcallowip=127.0.0.1

EOF

cat >~/.devcoin/devcoin.conf <<EOF
server=1
daemon=1
rpcuser=$Devcoin_User
rpcpassword=$Devcoin_Password
rpcport=6333
port=6334
rpcallowip=127.0.0.1

EOF

cat >~/.i0coin/i0coin.conf <<EOF
server=1
daemon=1
rpcuser=$i0coin_User
rpcpassword=$i0coin_Password
port=7337
rpcport=7338
rpcallowip=127.0.0.1

EOF

cat >~/.fusioncoin/fusioncoin.conf <<EOF
server=1
daemon=1
rpcuser=$Fusioncoin_User
rpcpassword=$Fusioncoin_Password
port=8492
rpcport=18491
rpcallowip=127.0.0.1

EOF

cat >~/.huntercoin/huntercoin.conf <<EOF
server=1
daemon=1
rpcuser=$Huntercoin_User
rpcpassword=$Huntercoin_Password
port=8398
rpcport=8399
rpcallowip=127.0.0.1

EOF


# Create the startup script for all coins and p2pool.
cat >~/start-p2pool <<EOF
#!/bin/sh
/usr/bin/bitcoind -daemon
~/bin/namecoind -daemon
~/bin/ixcoind -daemon
~/bin/devcoind -daemon >/dev/null # For some reason, devcoin writes to the terminal, even when started as a daemon.
~/bin/i0coind -daemon
~/bin/fusioncoind -daemon
~/bin/huntercoind -daemon
screen -d -m -S p2pool \
~/p2pool/run_p2pool.py $Bitcoin_User $Bitcoin_Password \
--merged http://$Namecoin_User:$Namecoin_Password@127.0.0.1:7333 \
--merged http://$Ixcoin_User:$Ixcoin_Password@127.0.0.1:8338 \
--merged http://$Devcoin_User:$Devcoin_Password@127.0.0.1:6333 \
--merged http://$i0coin_User:$i0coin_Password@127.0.0.1:7338 \
--merged http://$Fusioncoin_User:$Fusioncoin_Password@127.0.0.1:18491 \
--merged http://$Huntercoin_User:$Huntercoin_Password@127.0.0.1:8399

EOF
chmod 755 ~/start-p2pool


# Create a script to list the value of all coin wallets.
cat >~/listallcoins <<EOF
#!/bin/sh
echo "BTC: \$(/usr/bin/bitcoind -rpcpassword=$Bitcoin_Password listaccounts | awk '{getline; print \$NF;exit;}')"
echo "NMC: \$(~/bin/namecoind -rpcpassword=$Namecoin_Password listaccounts | awk '{getline; print \$NF;exit;}')"
echo "IXC: \$(~/bin/ixcoind -rpcpassword=$Ixcoin_Password listaccounts | awk '{getline; print \$NF;exit;}')"
echo "DVC: \$(~/bin/devcoind -rpcpassword=$Devcoin_Password listaccounts | awk '{getline; print \$NF;exit;}')"
echo "I0C: \$(~/bin/i0coind -rpcpassword=$i0coin_Password listaccounts | awk '{getline; print \$NF;exit;}')"
echo "FSC: \$(~/bin/fusioncoind -rpcpassword=$Fusioncoin_Password listaccounts | awk '{getline; print \$NF;exit;}')"
echo "Huntercoin: \$(~/bin/huntercoind -rpcpassword=$Huntercoin_Password listaccounts | awk '{getline; print \$NF;exit;}')"

EOF
chmod 755 ~/listallcoins


# If requested, download the blockchain.
if [ "$Blockchain" = "http" ] ; then
cd ~/.bitcoin

#wget https://bitfetch.com/static/bootstrap.7z
# Note: as of this writing, the SSL certificate for bitfetch.com has expired.
# If you just try to wget the file, wget will fail, complaining about it.
# So, we have to force wget to ignore the expired certificate. Once the
# certificate on the site has been properly renewed, delete the line below
# and uncomment the line above.
wget --no-check-certificate https://bitfetch.com/static/bootstrap.7z

# unzip it.
7z x bootstrap.7z
#elif [ "$Blockchain" = "torrent" ] ; then
# @TODO: No clue how torrenting works on Unix. Someone else can fill this in.
fi


# Wrap up; tell the user we succeeded, and ask him to reboot.
echo
echo
echo
echo "Installation results:"
echo -e "$Status"
echo
echo "It is strongly advised that you reboot at this point. After rebooting,"
echo "start p2pool and all the coin daemons with this command:"
echo "      ~/start-p2pool"
echo
echo "You may also add this line to your cron so it starts automatically:"
echo "      @reboot $HOME/start-p2pool"
echo
echo "You may check your coin balances at any time with this command:"
echo "      ~/listallcoins"
echo
echo "Thank you for helping to protect the bitcoin network by participating"
echo "in p2pool, and good luck with your mining!"



Edit: This script also removes the need for the chmod commands you added to the lazy install.
Edit 2: I've been testing this with Ubuntu 14.04 desktop, so yup, it does work with that. Smiley It should be identical on a server install, too.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 21, 2014, 12:50:54 PM
 #73

Great stuff Kyros!

Will update the guide with your script sometime tomorrow!

Thanks for all your feedback.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 21, 2014, 04:48:02 PM
 #74

*sigh* I'm really starting to get irritated at the taste of humble pie ... fixed some display bugs in the script's output. New code in my post above.

Also, I just realized I can make this script work for updates, not just the initial installation. That is, if you run it a second time, it will just download and process updates, instead of resetting everything.  I'll start working on that too.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 22, 2014, 09:15:26 PM
 #75

I've finished the revisions to the script.  I've made it much more modular, and it's now easy to expand it for any future merge-mined coins.

It's majorly revised from the last version.  It can now be used to both download for the first time, or to update an existing install.  I put in some logic in there to preserve the RPC username and password for the various coins, too, in case you have other tools that need to use them.

Murdof, if you do adopt this version of the script, you'll have to remove the config files from your download archive (or at least the username and password lines).  The script will add them back in.

Feedback greatly appreciated! This one isn't as thoroughly bug-tested as my last script, but I've squashed all the bugs I was able to find.

Code:
#!/bin/bash

# A function to display help and exit.
Usage()
{
echo "$(basename $0): Downloads and installs bitcoind, p2pool, and other coins for merged mining." >&2
echo "Usage:" >&2
echo "To download precompiled binaries (faster but less secure):" >&2
echo "        $(basename $0) --download" >&2
echo "To download the source code and compile yourself (slower but more secure):" >&2
echo "        $(basename $0) --compile" >&2
echo "You may also choose to download the bitcoin blockchain via http. Add the following to the command line:" >&2
echo "        --http" >&2
echo "If you don't use this, the blockchain will instead download using the (much slower) built-in peer-to-peer process." >&2
echo >&2
exit 1
} # Usage()


################################################
# Coin Settings
################################################


# Create arrays for storing the various coin RPC usernames, passwords, and other settings.
declare -A CoinUser
declare -A CoinPassword
declare -A CoinPort
declare -A CoinRPCPort
declare -A CoinSourceDownload
declare -A CoinSourceUpdate
declare -A CoinCompileCommand
declare -A CoinSymbol

# Set the default values for all the coins.
# These will be overridden by existing values in the config files.
# Note that you never need to remember the various RPC usernames and passwords; they just have to exist and be unguessable.
# Also note that the path to the config file is always of the form ~/coinname/coinname.conf. If you ever add a coin that doesn't meet this assumption, you'll have to add another array to track the config file location.
CoinUser["bitcoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPassword["bitcoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPort["bitcoin"]=8333
CoinRPCPort["bitcoin"]=8332
CoinSourceDownload["bitcoin"]="" # @TODO: Fill this out.
CoinSourceUpdate["bitcoin"]="" # @TODO: Fill this out.
CoinCompileCommand["bitcoin"]="" # @TODO: Fill this out.
CoinSymbol["bitcoin"]=BTC

CoinUser["namecoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPassword["namecoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPort["namecoin"]=8334
CoinRPCPort["namecoin"]=7333
CoinSourceDownload["namecoin"]="git clone https://github.com/namecoin/namecoin"
CoinSourceUpdate["namecoin"]="git pull"
CoinCompileCommand["namecoin"]="make -f Makefile"
CoinSymbol["namecoin"]=NMC

CoinUser["ixcoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPassword["ixcoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPort["ixcoin"]=8337
CoinRPCPort["ixcoin"]=8338
CoinSourceDownload["ixcoin"]="git clone https://github.com/FrictionlessCoin/iXcoin ixcoin"
CoinSourceUpdate["ixcoin"]="git pull"
CoinCompileCommand["ixcoin"]="make -f makefile.unix"
CoinSymbol["ixcoin"]=IXC

CoinUser["devcoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPassword["devcoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPort["devcoin"]=6334
CoinRPCPort["devcoin"]=6333
CoinSourceDownload["devcoin"]="git clone git://gitorious.org/devcoin/devcoin.git"
CoinSourceUpdate["devcoin"]="git pull"
CoinCompileCommand["devcoin"]="make -f makefile.unix USE_PNP=1 devcoind"
CoinSymbol["devcoin"]=DVC

CoinUser["i0coin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPassword["i0coin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPort["i0coin"]=7337
CoinRPCPort["i0coin"]=7338
CoinSourceDownload["i0coin"]="git clone http://github.com/rsnel/i0coin/"
CoinSourceUpdate["i0coin"]="git pull"
CoinCompileCommand["i0coin"]="make -f makefile.unix i0coind"
CoinSymbol["i0coin"]=I0C

CoinUser["fusioncoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPassword["fusioncoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPort["fusioncoin"]=8492
CoinRPCPort["fusioncoin"]=18491
CoinSourceDownload["fusioncoin"]="git clone https://github.com/fusioncoin/fusioncoin"
CoinSourceUpdate["fusioncoin"]="git pull"
CoinCompileCommand["fusioncoin"]="make -f makefile.unix"
CoinSymbol["fusioncoin"]=FSC

CoinUser["huntercoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPassword["huntercoin"]=`< /dev/urandom tr -dc A-Za-z0-9 | head -c40`
CoinPort["huntercoin"]=8398
CoinRPCPort["huntercoin"]=8399
CoinSourceDownload["huntercoin"]="git clone https://github.com/chronokings/huntercoin"
CoinSourceUpdate["huntercoin"]="git pull"
CoinCompileCommand["huntercoin"]="make -f Makefile"
CoinSymbol["huntercoin"]=HUC


# This is the list of coins that should be compiled (if the user selects that option) -- this should be all coins except Bitcoin.
CompileCoins="namecoin ixcoin devcoin i0coin fusioncoin huntercoin"

# This is the list of all coins, both compiled and non-compiled. Generally this should be only Bitcoin that's unique here.
AllCoins="bitcoin $CompileCoins"


################################################
# Utility functions
################################################


#
# Gets the settings for a given coin and adds them to the Coin*[] global arrays.
#
# Parameters:
# $1: Coin name (string literal, used in the associative array. No spaces.)
# $2: (optional) Path and filename of the config file. If not specified, the default path is used.
#
# Return value:
# 0: Settings already exist, retrieved and added to global arrays.
# 1: One or more settings do not exist in the file.
# Settings that do exist were retrieved and added to global arrays.
# 98: Parameter error.
# 99: Error in reading file (not found or no read permission).
#
# Output:
# None
#
GetSettings()
{
# Make sure we have the right number of parameters, and that a coin name is specified.
if [ $# -lt 1 -o $# -gt 2 -o -z "$1" ] ; then
return 98
fi

# Get the path and filename of the config file
local filepath
if [ -n "$2" ] ; then
filepath="$2"
else
filepath="$HOME/.$1/$1.conf"
fi

# Make sure the config file exists and is readable.
if [ ! -r "$filepath" ] ; then
return 99
fi

# Read the values from the file.
local user password port rpcport retval
user="$(grep -i "rpcuser" "$filepath" | awk -F= '{print $2}')"
password="$(grep -i "rpcpassword" "$filepath" | awk -F= '{print $2}')"
port="$(grep -ie "^port" "$filepath" | awk -F= '{print $2}')"
rpcport="$(grep -i "rpcport" "$filepath" | awk -F= '{print $2}')"

# Update the appropriate arrays, if the value was read from the file.
[ -n "$user" ] && CoinUser["$1"]="$user"
[ -n "$password" ] && CoinPassword["$1"]="$password"
[ -n "$port" ] && CoinPort["$1"]="$port"
[ -n "$rpcport" ] && CoinRPCPort["$1"]="$rpcport"

# The global arrays now contain all the settings, either read from the file or the global defaults, for the given coin.

# Return the appropriate value.
[ -z "$user" -o -z "$password" -o -z "$port" -o -z "$rpcport" ] && return 1
return 0
} # GetSettings()



#
# Adds a line to a settings file if it doesn't already exist.
#
# Parameters:
# $1: Coin name (string literal, used in the associative array. No spaces.)
# $2: The line to add.
# $3: (optional) Path and filename of the config file. If not specified, the default path is used.
#
# Return value:
# 0: Line added.
# 1: Line already exists.
# 98: Parameter error.
# 99: Error in reading file (not found or no read permission).
#
# Output:
# None
#
AddLine()
{
# Make sure we have the right number of parameters, and that a coin name is specified.
if [ $# -lt 1 -o $# -gt 3 -o -z "$1" -o -z "$2" ] ; then
return 98
fi

# Get the path and filename of the config file
local filepath
if [ -n "$3" ] ; then
filepath="$3"
else
filepath="$HOME/.$1/$1.conf"
fi

# Make sure the config file exists and is readable.
if [ ! -r "$filepath" ] ; then
return 99
fi

# Add the line if it doesn't already exist.
local matchstring=$(echo "$2" | sed -e 's/[]\/$*.^|[]/\\&/g')
if ! grep -qe "^$matchstring\$" "$filepath" ; then
echo "$2" >> "$filepath"
return 0
fi
return 1
} # AddLine()



#
# Updates the settings file for a given coin.
#
# Parameters:
# $1: Coin name (string literal, used in the associative array. No spaces.)
# $2: (optional) Path and filename of the config file. If not specified, the default path is used.
#
# Return value:
# 0: Settings updated.
# 98: Parameter error.
# 99: Error in reading file (not found or no read permission).
#
# Output:
# None
#
UpdateSettings()
{
# Make sure we have the right number of parameters, and that a coin name is specified.
if [ $# -lt 1 -o $# -gt 2 -o -z "$1" ] ; then
return 98
fi

# Get the path and filename of the config file
local filepath
if [ -n "$2" ] ; then
filepath="$2"
else
filepath="$HOME/.$1/$1.conf"
fi

# Make sure the config file exists and is readable.
if [ ! -r "$filepath" ] ; then
return 99
fi

# Make sure the three static lines always exist in the file
local Line
for Line in "server=1" "daemon=1" "rpcallowip=127.0.0.1"
do
AddLine "$1" "$Line" "$filepath"
done

# Remove the four parametric lines, then add in the correct values
grep -ve "^rpcuser=" "$filepath" | grep -ve "^rpcpassword="  | grep -ve "^port="  | grep -ve "^rpcport=" > "$filepath.tmp"
mv "$filepath.tmp" "$filepath"
AddLine "$1" "rpcuser=${CoinUser[$1]}" "$filepath"
AddLine "$1" "rpcpassword=${CoinPassword[$1]}" "$filepath"
AddLine "$1" "port=${CoinPort[$1]}" "$filepath"
AddLine "$1" "rpcport=${CoinRPCPort[$1]}" "$filepath"
echo "" >> "$filepath"

} # UpdateSettings()



################################################
# Main Script Start
################################################


# Determine what the user wants to do, or display help
if [ $# -eq 0 ] ; then
Usage
else
while [ $# -gt 0 ] ; do
if [ "--download" = "$1" ] ; then
Method="download"
elif [ "--compile" = "$1" ] ; then
Method="compile"
# elif [ "--torrent" = "$1" ] ; then
# Blockchain="torrent"
elif [ "--http" = "$1" ] ; then
Blockchain="http"
else
echo "Error: Unrecognized parameter on command line. Aborting" >2
Usage
fi
shift
done
fi

# Make sure the user specified where to compile or download
if [ -z "$Method" ] ; then
echo "Error: No installation method specified (compile or download). Aborting" >2
Usage
fi



################################################
# Sudo Script Creation and Run
################################################


# Create a script to update the system.  This requires sudo, so we can't run it directly.
cat <<EOF >~/sudoscript.sh
#!/bin/sh

# Install the pre-req for add-apt-repository
apt-get -y install software-properties-common

# Add the bitcoin repository
add-apt-repository -y ppa:bitcoin/bitcoin

# Update installed packages
apt-get -y update
apt-get -y dist-upgrade

# Install the needed prerequisites
# Note that bitcoind is always installed as a binary, not compiled.
apt-get -y install bitcoind python-software-properties screen git python-rrdtool python-pygame python-scipy python-twisted python-twisted-web python-imaging build-essential libglib2.0-dev libglibmm-2.4-dev libqt4-dev python-dev libssl-dev libdb5.1++-dev libboost1.55-all-dev dh-autoreconf libcurl4-openssl-dev libminiupnpc-dev ufw p7zip-full

# Set up and configure a firewall, if it isn't already there.
# Note that we do NOT enable the RPC port for any coins!
ufw default deny    # Deny everything unless expressly permitted
ufw allow 22/tcp    # SSH
ufw allow 8333/tcp  # bitcoin peer to peer
ufw allow 8334/tcp  # namecoin peer to peer
ufw allow 8337/tcp  # ixcoin peer to peer
ufw allow 6334/tcp  # devcoin peer to peer
ufw allow 7337/tcp  # i0coin peer to peer
ufw allow 8492/tcp  # fusioncoin peer to peer
ufw allow 8398/tcp  # huntercoin peer to peer
ufw allow 9333/tcp  # P2pool peer to peer
ufw allow 9332/tcp  # P2Pool connections and Web interface
ufw --force enable  # Turn it on

EOF

echo "About to update your system.  This requires elevated privileges. Please enter your password when prompted."
sleep  2 # pause so the user has a chance to see and read the message.
sudo sh ~/sudoscript.sh
rm ~/sudoscript.sh



################################################
# P2Pool Installation or Update
################################################


# Install p2pool
if [ -d ~/p2pool/ ] ; then
cd ~/p2pool
git pull
else
cd
git clone git://github.com/forrestv/p2pool.git
fi



################################################
# Coin Binaries Setup
################################################


# Now either download or compile the binaries.
if [ "$Method" = "download" ] ; then


################################################
# Binary Download
################################################

# Download and unpack scripts and binaries for other coins
cd
wget http://pool.nitro.gr/p2pool-files.tar.gz

# Ensure the compiled binaries archive is valid! This checksum has to be updated each time the binaries are repackaged.
# Too much manual work, Murdof can enable this if he wants to maintain it. (Switch "false" to "true")
if false; then
checksum="$(md5sum p2pool-files.tar.gz | awk '{print $1;}')"
if [ "$checksum" != "0e35d6a1ee234b1a90975588917275eb" ] ;  then
echo "ERROR: Downloaded binaries are corrupt or have been tampered with! Please try running this script again.  If this error repeats, please contact the script author here:" >&2
echo "https://bitcointalk.org/index.php?topic=651819.0" >&2
exit 3
fi
fi

Status="$Status\nDownload succeeded."

# Unpack the binaries and delete the downloaded archive.
tar xvzf p2pool-files.tar.gz
rm p2pool-files.tar.gz

elif [ "$Method" = "compile" ] ; then


################################################
# Compile from Coin Source
################################################

# Make the local binaries directory
mkdir -p ~/bin

# Make a directory to download and store all the alt-coin sources
mkdir -p ~/coin_source

for Coin in $CompileCoins ; do

cd ~/coin_source
if [ -d ~/coin_source/$Coin/ ] ; then
cd ~/coin_source/$Coin
${CoinSourceUpdate[$Coin]}
else
${CoinSourceDownload[$Coin]}
fi
cd ~/coin_source/$Coin/src
${CoinCompileCommand[$Coin]}
if [ -f ${Coin}d ] ; then
Status="$Status\n${Coin} compilation succeeded."
strip ${Coin}d
cp ${Coin}d ~/bin
else
Status="$Status\n${Coin} compilation FAILED."
fi
done

else
# This should never happen! It means there's an error in this script itself.
echo "Unhandled error! Bad programmer! No cookie!" >&2
exit 2
fi


################################################
# Script settings creation
################################################


for Coin in $AllCoins ; do

# Make directories for everything
mkdir -p ~/.${Coin}

# Create an empty config file, if it doesn't already exist.
ConfigFile=$HOME/.${Coin}/${Coin}.conf
touch "$ConfigFile"

# Read the old settings from the config file, if any.
GetSettings "$Coin" "$ConfigFile"

# Update the settings.
UpdateSettings "$Coin" "$ConfigFile"
done



################################################
# "Batch Files" Creation
################################################


# Create the startup script for all coins and p2pool.
cat >~/start-p2pool <<EOF
#!/bin/sh
/usr/bin/bitcoind -daemon
~/bin/namecoind -daemon
~/bin/ixcoind -daemon
~/bin/devcoind -daemon >/dev/null # For some reason, devcoin writes to the terminal, even when started as a daemon.
~/bin/i0coind -daemon
~/bin/fusioncoind -daemon
~/bin/huntercoind -daemon
screen -d -m -S p2pool \\
~/p2pool/run_p2pool.py ${CoinUser["bitcoin"]} ${CoinPassword["bitcoin"]} \\
EOF


for Coin in $CompileCoins
do
echo " --merged http://${CoinUser[$Coin]}:${CoinPassword[$Coin]}@127.0.0.1:${CoinRPCPort[$Coin]} \\" >>~/start-p2pool
done
echo "" >>~/start-p2pool
echo "" >>~/start-p2pool
chmod 755 ~/start-p2pool


# Create a script to list the value of all coin wallets.
cat >~/listallcoins <<EOF
#!/bin/sh
echo "BTC: \$(/usr/bin/bitcoind -rpcpassword=${CoinPassword[bitcoin]} listaccounts | awk '{getline; print \$NF;exit;}')"
EOF

for Coin in $CompileCoins
do
cat >>~/listallcoins <<EOF
echo "${CoinSymbol[$Coin]}: \$($HOME/bin/${Coin}d -rpcpassword=${CoinPassword[$Coin]} listaccounts | awk '{getline; print \$NF; exit;}')"
EOF

done

chmod 755 ~/listallcoins



################################################
# Bitcoin Blockchain Download
################################################


# If requested, download the blockchain.
if [ "$Blockchain" = "http" ] ; then
cd ~/.bitcoin

#wget https://bitfetch.com/static/bootstrap.7z
# Note: as of this writing, the SSL certificate for bitfetch.com has expired.
# If you just try to wget the file, wget will fail, complaining about it.
# So, we have to force wget to ignore the expired certificate. Once the
# certificate on the site has been properly renewed, delete the line below
# and uncomment the line above.
wget --no-check-certificate https://bitfetch.com/static/bootstrap.7z

# unzip it.
7z x bootstrap.7z
#elif [ "$Blockchain" = "torrent" ] ; then
# @TODO: No clue how torrenting works on Unix. Someone else can fill this in.
fi


################################################
# Wrap up and exit
################################################


# Wrap up; tell the user we succeeded, and ask him to reboot.
echo
echo
echo
echo "Installation results:"
echo -e "$Status"
echo
echo "It is strongly advised that you reboot at this point. After rebooting,"
echo "start p2pool and all the coin daemons with this command:"
echo "      ~/start-p2pool"
echo
echo "You may also add this line to your cron so it starts automatically:"
echo "      @reboot $HOME/start-p2pool"
echo
echo "You may check your coin balances at any time with this command:"
echo "      ~/listallcoins"
echo
echo "Thank you for helping to protect the bitcoin network by participating"
echo "in p2pool, and good luck with your mining!"


Edit: v1.1 - Fixed a bug with listallcoins, and a potential bug in AddLines. Also documentation updates.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 23, 2014, 08:16:53 AM
 #76

KyrosKrane this is great stuff!

I haven't updated the guide yet cause I want to try it on a fresh vps in order to see the experience to update the guide.

One other solution is to start a new thread with you taking over since most of the work is yours now and we point people to the new thread so you can update it.

What do you think?

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 24, 2014, 05:51:03 AM
 #77

I've been thinking about your proposal for the last day or so. In that time, I've come to realize a few things.

1) Your guide is still necessary. My script is the technical solution, but your guide is the human solution. It does a far better job of explaining what's going on to a relatively new user.

2) The June 21 version of my script, which is basically just glomming all the code from your guide into one script with a little scripting glue, is probably better for you to use. It's clearer to read, and it follows the human-readable guide much more closely.

3) I like to keep adding bells and whistles to my scripts. At some point, that will likely break backwards compatibility (e.g., requiring a new launch command) which would require you to modify your guide. That adds complexity to what should be a simple guide, and it adds to your maintenance overhead to keep the script and the guide in sync.

4) While I'm happy to publish my scripts, they're ultimately written because they're something I use or would likely use. I know I'm not a particularly good representative of the general community, so perhaps I'm not the best candidate to write a guide.

5) I know very little about the practical realities of compiling code on Linux (or any OS, for that matter). I can copy/paste code snippets and compile commands with the best of them, but if you just hand me a git URL and tell me, "go build this," I'd likely be lost.

So, based on all that, my suggestion is that you maintain your guide as the beginner's entry point into p2pool, and use my script from June 21.  Feel free to customize it as you update your guide, or to use the June 23 script if it's better for you. I'll update my June 23 script into a more advanced tool and post a new topic about it in the near future. I've already got some ideas on how to advance it, including having a Web page that essentially generates a custom script for you to download and use.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
Operatr
Hero Member
*****
Offline Offline

Activity: 798


www.DonateMedia.org


View Profile WWW
June 24, 2014, 04:43:13 PM
 #78

Excellent guide, thank you! After going through so many others this is by far the most complete.

iglasses
Legendary
*
Offline Offline

Activity: 1064


View Profile
June 25, 2014, 02:12:53 AM
 #79

I finally got around to setting up an Ubuntu machine today. It's downloading the blockchain and hopefully I will get to work on this tomorrow. Looking forward to tinkering.  I have some USBs for testing so go me!

ig

I only have a signature because I'm allowed.
coinme.info
Sr. Member
****
Offline Offline

Activity: 261

Interesting...


View Profile WWW
June 26, 2014, 06:33:14 AM
 #80

Hi and thanks for a well written guide.

I noticed a couple of things while working through it that had me stuck for a bit as I'm not a linux user and am setting this up in a VM so I can run my own P2Pool node.

In the following I've highlighted what I think are errors in red:

After you install Linux Ubuntu 14.04 LTS, login and execute the following commands:
Code:

wget http://pool.nitro.gr/install-p2pool.sh
sudo sh ./install-p2pool.sh
chmod -R (youruser):(youruser) .*
chmod -R (youruser):(youruser) *

It will install everything (it will use the binaries not compile everything again) and you just have to wait...
Do a reboot and you are done.
Double check with "ls -al" that all files have owner/group your user. If it says root then do "chown -R (user):(group) *" and then "chown -R (user):(group) .*"

Should the chmod be chown as chmod says that format is incorrect?

Should ls -al be ls -la ?

Also I had to do sudo chown -R (user):(group) * & sudo chown -R (user):(group) .* as they were owned by root and wouldn't allow a chown without sudo first.

Sorry if this is wrong, like I said I'm not a unix personal so picking this up as I go.

Without your guide I wouldn't know where to start so thank you once again.

It would be awesome if KyrosKrane's script could be accessed by the wget method you used as that was easy. I'll have to figure out how to get that bash script into the VM and work out how to run it. Having the wget would make unix noobs setup of the P2Pool sooo much easier.

Cheers to both you guys for sharing your work with everyone!

follow me @CoinMeInfo for irregular random crypto insights...
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 26, 2014, 10:13:22 AM
 #81

You are right

chown should be run with sudo in front.

i hope you replace (youruser) with your username

you can find your username by just typing:
whoami

replace it in both occasions:
eg
sudo chmod -R murdof:murdof .*
sudo chmod -R murdof:murdof *

Kyros has done great work but unfortunately I don't have the time to implement everything in the guide this week as I'm working and I will be away for the weekend.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 26, 2014, 07:14:55 PM
 #82

It would be awesome if KyrosKrane's script could be accessed by the wget method you used as that was easy. I'll have to figure out how to get that bash script into the VM and work out how to run it. Having the wget would make unix noobs setup of the P2Pool sooo much easier.

Ask and ye shall receive! Smiley

Code:
### To download ###
wget http://bitcoin.kyros.info/install-merged-mining.sh

### To run, without downloading the blockchain via http ###
./install-merged-mining.sh --compile
### OR ###
./install-merged-mining.sh --download

### To run, WITH downloading the blockchain via http ###
./install-merged-mining.sh --compile --http
### OR ###
./install-merged-mining.sh --download --http

I also threw up a little info page where you can download it through a browser, if you're on Ubuntu Desktop.  You can see that here:

http://bitcoin.kyros.info/

Murdof, sorry to hijack your thread. Sad I'll post my own thread about this shortly, but I'm doing a few additional updates to the script that I want to complete first.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
raskul
Sr. Member
****
Offline Offline

Activity: 434



View Profile
June 26, 2014, 07:16:54 PM
 #83

you guys are great, I think you should just leave it all in this thread... all us; important people, have been following every word anyway  Cheesy

tips    1APp826DqjJBdsAeqpEstx6Q8hD4urac8a
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 26, 2014, 07:18:06 PM
 #84

replace it in both occasions:
eg
sudo chmod -R murdof:murdof .*
sudo chmod -R murdof:murdof *

To make this generic for everyone, you could do this:

Code:
sudo chown -R $(whoami):$(whoami) .*
sudo chown -R $(whoami):$(whoami) *

Edit: Corrected the command to chown.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
June 27, 2014, 06:08:16 AM
 #85

Thanks Kyros,

great stuff. of course your not hijacking!

When you post your thread let me know so I put a link on the first post!

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 27, 2014, 11:54:35 AM
 #86

Slightly odd question.  Can someone please point me to (or provide me with) a set of copy/paste instructions for compiling bitcoind on a clean install of Ubuntu 14.04? I tried to wade through the readme, honestly I did, but it left my head spinning about what is and isn't a required dependency.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
PatMan
Hero Member
*****
Offline Offline

Activity: 924


Watch out for the "Neg-Rep-Dogie-Police".....


View Profile WWW
June 27, 2014, 12:02:07 PM
 #87

Slightly odd question.  Can someone please point me to (or provide me with) a set of copy/paste instructions for compiling bitcoind on a clean install of Ubuntu 14.04? I tried to wade through the readme, honestly I did, but it left my head spinning about what is and isn't a required dependency.

https://gist.github.com/yubrew/5571485

"When one person is deluded it is called insanity - when many people are deluded it is called religion" - Robert M. Pirsig.  I don't want your coins, I want change.
Amazon UK BTC payment service - https://bitcointalk.org/index.php?topic=301229.0 - with FREE delivery!
http://www.ae911truth.org/ - http://rethink911.org/ - http://rememberbuilding7.org/
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 27, 2014, 03:21:12 PM
 #88

Thanks for that! The post is a few months old, so I want to test it in a VM first and see how it can be added to my existing script.

Quick preview of what I'm working on: http://bitcoin.kyros.info/preview.html

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
Zelek Uther
Hero Member
*****
Offline Offline

Activity: 672


Run a Bitcoin node.


View Profile
June 28, 2014, 04:14:03 AM
 #89

Wonderful, thanks! At some stage I want to try this (got to get a server first).

Noob question: can p2pool be set up to mine to a bitcoin address? I like to mine to a cold-storage address, not to a local wallet.

Run a Bitcoin node, support the network.
How to compile and run bitcoind on a Raspberry Pi
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
June 28, 2014, 04:30:29 AM
 #90

Yes it can. Use the --address parameter on your command line that starts p2pool, so it looks something like this:

Code:
screen -d -m -S p2pool
~/p2pool/run_p2pool.py $Bitcoin_User $Bitcoin_Password \
--merged http://$Namecoin_User:$Namecoin_Password@127.0.0.1:7333 \
--merged http://$Ixcoin_User:$Ixcoin_Password@127.0.0.1:8338 \
--merged http://$Devcoin_User:$Devcoin_Password@127.0.0.1:6333 \
--merged http://$i0coin_User:$i0coin_Password@127.0.0.1:7338 \
--merged http://$Fusioncoin_User:$Fusioncoin_Password@127.0.0.1:18491 \
--merged http://$Huntercoin_User:$Huntercoin_Password@127.0.0.1:8399 \
--address 1YourBitcoinAddress

(Code's taken from my script, so obviously your version will have different usernames and passwords.)

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
letuslook
Full Member
***
Offline Offline

Activity: 146



View Profile
July 12, 2014, 04:00:34 PM
 #91

Thank you so much for the tutorial! Got my own EU (Amsterdam) p2pool running @ 149.210.172.171:9332

p.s. you might add the following nodes for every coin in the config files (coin.conf):

Ixcoin
Code:
addnode=198.154.60.183
addnode=50.116.37.18

Namecoin
Code:
addnode=212.71.251.113
addnode=192.241.171.45

Devcoin
Code:
addnode=dvc.rpwt.org:52333
addnode=devcoin.rpwt.org:52333
addnode=dvc.rpwt.org:52333
addnode=devcoin.rpwt.org:52333
addnode=devcoin.rpwt.org:52333
addnode=dvc.us.public.txn.co.in
addnode=dvc.eu.public.txn.co.in

I0coin
Code:
addnode=85.17.248.211:7333
addnone=198.154.60.61:7333
addnode=188.165.216.59:7333

Fusioncoin
Code:
addnode=54.193.11.95
addnode=54.255.130.210
addnode=198.23.242.92
addnode=121.199.12.227
addnode=54.185.94.219

Huntercoin
Code:
addnode=162.243.175.205
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
July 15, 2014, 07:29:53 AM
 #92

Updated letuslook addnodes.

Also put a note to check KyrosKrane page as it is more complete.

Kyros i have updated binaries!
HUC had some changes and I include bitcoin 0.9.2.1 (ppa still has older version).
So you might change to ~/bin/bitcoind or stick with ppa and hopefully it will get updated to 0.9.2.1.

576f0bdc8659cdd36f627402e1d79b12  p2pool-files.tar.gz

Please update the md5sum in your script.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
YarkoL
Hero Member
*****
Offline Offline

Activity: 896



View Profile
July 22, 2014, 09:50:46 PM
 #93

Thanks for this.

dev blog https://yarkol.github.io
BTC 18kHb54jqcpWEkuAkCFsGMzR6BMgYnpi2T
kgb2mining
Member
**
Offline Offline

Activity: 112


View Profile
August 06, 2014, 07:45:32 PM
 #94

Just a note about the install script from Kryos - might need to either document or change how the code for p2pool itself is grabbed.

Going through building a node here, and we're behind a corporate firewall.  In the script, you're using a git:// repo.  Here that's blocked, and I'm sure other places, so when running the script you get this:

:~$ git clone git://github.com/forrestv/p2pool.git
Cloning into 'p2pool'...
fatal: unable to connect to github.com:
github.com[0: 192.30.252.128]: errno=Connection refused

I missed this in the initial install, and it took me a while to realize what had happened since that step flew by pretty quick.

Most of the other git clones are using http or https, which is much more standard firewall friendly.  I did this instead, and now all is well:

:~$ git clone https://github.com/forrestv/p2pool

Other than that, everything is going swimmingly.  Awesome script and tutorial both of you, thanks a bunch!
KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
August 07, 2014, 06:14:27 PM
 #95

Thanks for the catch! I'll see what I can do to clean that up.

Sadly, RL has caught up with me, and I've been working 12+ hour days with regularity these last couple of months. Thankfully things are calming down now, so hopefully I'll have more time again to clean this up.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
dlasher
Sr. Member
****
Offline Offline

Activity: 468



View Profile WWW
August 07, 2014, 08:29:55 PM
 #96


Thanks for a great guide, very helpful! Since pypy is so much faster, it would be great to see steps to get pypy happy added, if possible.


dlasher
Sr. Member
****
Offline Offline

Activity: 468



View Profile WWW
August 07, 2014, 09:28:40 PM
 #97


Thanks for a great guide, very helpful! Since pypy is so much faster, it would be great to see steps to get pypy happy added, if possible.


I finally got it working, had to do the following, as the user I wanted to run p2pool as:

#sudo apt-get install python-setuptools

#easy_install --user -U twisted
#easy_install --user -U zope.interface

Now you can start it with "pypy ./run_p2pool.py" instead.. and benefit from the speed increases.


KyrosKrane
Sr. Member
****
Offline Offline

Activity: 293


View Profile WWW
August 09, 2014, 10:56:06 AM
 #98

Sorry, I'm not sure I understand.  What's the benefit of pypy in this context? The only thing running Python in this guide is p2pool itself, and it's not like it's stressing out the CPU or anything.

Tips and donations: 1KyrosREGDkNLp1rMd9wfVwfkXYHTd6j5U  |  BTC P2Pool node: p2pool.kyros.info:9332
adamsworks
Newbie
*
Offline Offline

Activity: 28


View Profile
August 12, 2014, 12:20:52 AM
 #99

I run one P2Pool BTC only server (no merged mining) that I managed to piece together almost by luck,  and I am migrating over to a different company and a new sever (once the block chains are downloaded).  I run the pool for my own personal use mainly (but don't mind others mining there).

I just wanted to say thanks for the guide.  I didn't use any of the scripts as I am trying to learn the process of making my own builds (and learn more about linux),  but good work on those too.

I plan on setting up Scrypt Merged Mining, and X11 DarkCoin as well,  as I have a pretty varied mining setup.

I want to eventually have lots of coins available for mining for great choice for me (and perhaps others) via P2Pool, mainly because I believe in the P2Pool concept, and think it is good for the community. I also want to pick up my game in Linux, and this is a good project for it. 

I have a few questions about P2Pool while I wait for the blockchain(s) to download:

1) As long as I use the same BTC address, migrating over to a new P2Pool will still track my submitted shares, and I lose nothing?

2)

a. As I want to run pools with SHA256, scrypt and X11....  should I consider using the same container/VM or should I consider segregating by either main coin being mined, or perhaps algorithm?

b. As I have a choice between a VM or a container (I have selected a container for my first one, but my next pool could be a VM), what do the experts on here recommend? Please note I will only be running P2Pool on the machine with the assorted block chains,  and the web front end for it.

c. Can I run multiple instances of P2Pool using screen, IOT work the offerings differently (ie. Pool X mines LiteCoins, with the other secondary merged coins, and Pool Y mines Doge, with the other secondary merged coins),  or do I have to run separate container's/VM's for each setup?

3) Anybody heard of any work on merged mining for the X11/13/other alogo's?

Thanks for your help,  and thanks again for the guide!

Ryan
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
August 24, 2014, 11:15:55 AM
 #100

Updated namecoind and huntercoind in binaries.

md5sum: ac912f6d457521b51b421a32f5fa4ad7

Note that after updating I got error that i had to repair the blockchain for namecoin.
I finally deleted the blockchain of namecoin and redownloaded.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
August 24, 2014, 11:22:15 AM
 #101

adamswork just saw your post:

1. Yes you can use multiple p2pool nodes with same bitcoin address and shares submitted will increase your payouts.

2. Each algo has its own fork and it runs on different ports. So you can have on the same box different algos on same IP as they use different ports. So it is all up to having enough memory / CPU. Note that when you start the daemons they will take up a lot of CPU but after they get in sync they don't need much. How much memory you need? Well if you are running a VM make sure you have at least 1GB free without swapping. That's my rule of thumb and never had issues.

3. There is merge mining for VTC and for LTC. There is also announcement that DOGE will be merged minable with LTC.
Haven't checked for other algos. Maybe there aren't any as there is no strict leader in those algos...

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
September 09, 2014, 07:11:11 AM
 #102

Updated namecoind and huntercoind.

namecoind issues with merge coin mining are fixed.

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
newbuntu
Member
**
Offline Offline

Activity: 61


View Profile
October 18, 2014, 06:15:19 PM
 #103

To murdof and kyros - great work, thank you for the time and effort that you have put into this.
EDIT:
Comments and question removed due to no activity / response.
yslyung
Legendary
*
Online Online

Activity: 1260


Mine Mine Mine


View Profile
November 30, 2014, 12:55:09 PM
 #104

learning some linux ... doing it all step by step ... many thx to OP & other contributors. installing now & see how things goes.
PatMan
Hero Member
*****
Offline Offline

Activity: 924


Watch out for the "Neg-Rep-Dogie-Police".....


View Profile WWW
November 30, 2014, 01:08:27 PM
 #105

learning some linux ... doing it all step by step ... many thx to OP & other contributors. installing now & see how things goes.

It's a great way to learn - any questions you have, just ask in the p2pool thread  Wink

"When one person is deluded it is called insanity - when many people are deluded it is called religion" - Robert M. Pirsig.  I don't want your coins, I want change.
Amazon UK BTC payment service - https://bitcointalk.org/index.php?topic=301229.0 - with FREE delivery!
http://www.ae911truth.org/ - http://rethink911.org/ - http://rememberbuilding7.org/
yslyung
Legendary
*
Online Online

Activity: 1260


Mine Mine Mine


View Profile
November 30, 2014, 01:11:40 PM
 #106

learning some linux ... doing it all step by step ... many thx to OP & other contributors. installing now & see how things goes.

It's a great way to learn - any questions you have, just ask in the p2pool thread  Wink

now got stuck here .... any suggestions ?

--2014-11-30 08:10:02--  (try: 3)  https://bitfetch.com/static/bootstrap.7z
Connecting to bitfetch.com (bitfetch.com)|176.9.50.103|:443...     
jowo88
Full Member
***
Offline Offline

Activity: 193


View Profile
January 14, 2015, 08:11:57 AM
 #107

stuck in this process, somebody can help me?

yslyung
Legendary
*
Online Online

Activity: 1260


Mine Mine Mine


View Profile
January 14, 2015, 10:21:16 AM
 #108

stuck in this process, somebody can help me?


your bitcoind port is not being forwarded in router. place your questions on the p2pool thread, more active there.

fwd port 8333,9332,9333 & 7333 (if merged mining)
jowo88
Full Member
***
Offline Offline

Activity: 193


View Profile
January 14, 2015, 11:37:45 AM
 #109

stuck in this process, somebody can help me?


your bitcoind port is not being forwarded in router. place your questions on the p2pool thread, more active there.

fwd port 8333,9332,9333 & 7333 (if merged mining)

thank you for answer my question..
nokati
Member
**
Offline Offline

Activity: 64


View Profile
June 25, 2015, 12:50:42 AM
 #110

hi,

I am considering setup a p2pool for my own use and maybe some other friends.

What is currently the payout frequency expecting when having 10TH? is it once a 2-3 days or once a week or more often? This way at leat I know when something is wrong.

I know you cant use an exchange wallet but can you use wallet https://blockchain.info/  for p2pool?


Would this hardware setup be good enough?

http://www.asrock.com/mb/Intel/Q1900-ITX/index.nl.asp

Intel® Quad-Core Processor J1900 and 8 ram and a 32GB SSD?


thanks!
innerchaos
Full Member
***
Offline Offline

Activity: 145


View Profile
June 28, 2015, 01:25:02 AM
 #111

the bitcoin node will need more than 32gb i would at least add another hdd for storing the bitcoin data
kano
Legendary
*
Offline Offline

Activity: 2128


Linux since 1997 RedHat 4


View Profile
June 28, 2015, 01:34:41 AM
 #112

hi,

I am considering setup a p2pool for my own use and maybe some other friends.

What is currently the payout frequency expecting when having 10TH? is it once a 2-3 days or once a week or more often? This way at leat I know when something is wrong.

...
p2pool is PPLNS so it's expected payout frequency is pretty much unrelated to your mining rate unless you are a large % of p2pool - or a VERY low hash rate.

It is of course related to the total p2pool mining rate ... which is how PPLNS works.

However, if your hash rate is too low to get a share as often as a block is found, then your payout frequency will be below the p2pool block finding rate.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
edonkey
Legendary
*
Offline Offline

Activity: 1094



View Profile
June 28, 2015, 04:27:03 AM
 #113

I've got some noob questions. I'm an experienced miner, but have never set up or used p2pool, so sorry in advance for my ignorance.

If I follow this guide, won't the resulting p2pool node be largely unknown, and effectively private?

How do I go about "registering" the node so that people are aware of it and anyone can use it (including the name of the pool, terms, etc)?

I'm a little unclear about merge mining. It sounds like if merge mining is configured, that the resulting merge mining proceeds goes to the pool operator. Is that the case?

At the risk of sounding selfish, if I carve out processor resources, set up a public node, and pay for the bandwidth and power and collect no fees, I want to see if merge mining can help justify the operating costs.

Was I helpful?   BTC: 18wQtEDmhur2xAd3oE8qgrZbpCDeuMsdQW   LTC: LbqLtkZ6wTSpwHHuv1tG4J7tHajGdH5QFB   DOGE: D9R5ySAP2DARpxuNKd7hN7ANmqFiGwB9G6
CohibAA
Full Member
***
Offline Offline

Activity: 218



View Profile WWW
June 28, 2015, 05:17:40 AM
 #114

I've got some noob questions. I'm an experienced miner, but have never set up or used p2pool, so sorry in advance for my ignorance.

If I follow this guide, won't the resulting p2pool node be largely unknown, and effectively private?

If you want your p2pool node to be reachable by other nodes and/or miners, you must allow inbound network connections on ports 9333 for other nodes, and 9332 for miners.

How do I go about "registering" the node so that people are aware of it and anyone can use it (including the name of the pool, terms, etc)?

I'm a little unclear about merge mining. It sounds like if merge mining is configured, that the resulting merge mining proceeds goes to the pool operator. Is that the case?

At the risk of sounding selfish, if I carve out processor resources, set up a public node, and pay for the bandwidth and power and collect no fees, I want to see if merge mining can help justify the operating costs.

If the port(s) above are open, most scanners will recognize your node automatically and list it on their sites.  Some you may need to request your IP be listed.  Merge mining is, essentially, solo mining and all block awards go directly to the node operator's coind core client wallet used when starting and running p2pool with the merge mining parameters.


yslyung
Legendary
*
Online Online

Activity: 1260


Mine Mine Mine


View Profile
June 28, 2015, 05:34:53 AM
 #115

also please upgrade to the latest p2p version 14.0 asap

https://github.com/forrestv/p2pool
edonkey
Legendary
*
Offline Offline

Activity: 1094



View Profile
June 28, 2015, 03:35:17 PM
 #116

It looks like the start-p2pool script basically starts all of the daemons. But what happens if one of the daemons crashes? I think that means you'd have to figure out that a daemon crashed and manually start it up again.

Maybe it makes sense to have each daemon running under a service package, like daemontools. It would be a lot more work to set up than just a script that gets called at boot time. But it would help insure that all the daemons are running.

After setting up the services, you could make a script like start-p2pool, but instead of directly starting the daemons it would start/stop the corresponding services.

If anyone is interested, I did a guide for daemontools here:

https://bitcointalk.org/index.php?topic=577018.0

Note that by default, daemontools will run services as root. You'd have to configure your services to run as your user instead.

Edit: Since it looks like the daemons return right away, you'd have to take that into account when using a service manager like daemontools. You would not want the service manager to keep restarting the daemon because it thinks it has quit.

Was I helpful?   BTC: 18wQtEDmhur2xAd3oE8qgrZbpCDeuMsdQW   LTC: LbqLtkZ6wTSpwHHuv1tG4J7tHajGdH5QFB   DOGE: D9R5ySAP2DARpxuNKd7hN7ANmqFiGwB9G6
thepinkanator95
Newbie
*
Offline Offline

Activity: 15


View Profile
July 13, 2015, 08:00:10 PM
 #117

To those of you who are as big a moron as me when it comes to this stuff, the exact commands on the automatic installation found here:

http://bitcoin.kyros.info/

The commands to install are as follows EXACTLY:

wget http://bitcoin.kyros.info/install-merged-mining.sh
sudo bash ./install-merged-mining.sh --compile

Or if you want to download:

wget http://bitcoin.kyros.info/install-merged-mining.sh
sudo bash ./install-merged-mining.sh --download

I realize this may be a stupid post but I typed in the above but instead of "bash" I put "sh". I kept getting a Bad Substitution error and couldn't figure out why.

I'm a moron. Don't be like me.
p3yot33at3r
Sr. Member
****
Offline Offline

Activity: 266



View Profile
July 13, 2015, 10:21:58 PM
 #118

You can also add UNO & WLC to your list of merge mined coins  Wink
dimke_yu
Sr. Member
****
Offline Offline

Activity: 458



View Profile WWW
July 18, 2015, 04:59:08 PM
 #119

Merged UNO would be great...

p3yot33at3r
Sr. Member
****
Offline Offline

Activity: 266



View Profile
July 18, 2015, 05:26:18 PM
 #120

Merged UNO would be great...
You can do it, just add:

Code:
--merged http://[uno_user_name]:[uno_rpc_password]@127.0.0.1:45888/

to the end of your p2pool startup syntax  Wink

I'll try & get an updated guide posted in the next few days - time permitting.
jonnybravo0311
Legendary
*
Offline Offline

Activity: 1134


Mine at Jonny's Pool


View Profile WWW
July 19, 2015, 04:48:54 PM
 #121

Has anyone compiled a complete list of all p2pool merge-mine coins, their respective ports and exchanges on which they can be traded?  I know of the following coins:

NMC
IXC (no new coins for finding blocks as all have been generated)
I0C
GRP
DVC
HUC
FSC (coin is dead)
UNO
WLC

As has been previously pointed out, to add a coin to be merge-mined, once your coin's daemon is up and running and synched, you just start your p2pool instance with the following additional parameter (assuming all coin daemons are running on the same machine as p2pool):

Code:
--merged http://[rpc_user_name]:[rpc_password]@127.0.0.1:port

Jonny's Pool - Mine with us and help us grow!  Support a pool that supports Bitcoin, not a hardware manufacturer's pockets!  No SPV cheats.  No empty blocks.
coolindark
Hero Member
*****
Offline Offline

Activity: 628



View Profile WWW
May 07, 2016, 03:31:59 PM
 #122

I have a question about merged mining... maybe stupid, maybe not...

I have a BTC pool which is public.
How merged mining make payments? I meant, this thread does not explain this. Also i could not see wallet addresses too. It looks like this is for home use.

Right?

ʕ•̫͡•ʕ*̫͡*ʕ•͓͡•ʔ-̫͡-ʕ•̫͡•ʔ*̫͡*ʔ-̫͡-ʔʕ•̫͡•ʕ*̫͡*ʕ•͓͡•ʔ-̫͡-ʕ•̫͡•ʔ*̫͡*ʔ-̫͡-ʔ
_____________________________________________
jonnybravo0311
Legendary
*
Offline Offline

Activity: 1134


Mine at Jonny's Pool


View Profile WWW
May 07, 2016, 03:34:47 PM
 #123

With p2pool merged mining, there are no payouts of the merge-mined coins to miners.  Either you would have to write some code to figure out how to pay those coins to your miners, or you'd have to do something manually.

Jonny's Pool - Mine with us and help us grow!  Support a pool that supports Bitcoin, not a hardware manufacturer's pockets!  No SPV cheats.  No empty blocks.
coolindark
Hero Member
*****
Offline Offline

Activity: 628



View Profile WWW
May 07, 2016, 03:40:47 PM
 #124

With p2pool merged mining, there are no payouts of the merge-mined coins to miners.  Either you would have to write some code to figure out how to pay those coins to your miners, or you'd have to do something manually.

As i thought... thank you for your quick and clear answer.
Long live classic pooling  Grin

ʕ•̫͡•ʕ*̫͡*ʕ•͓͡•ʔ-̫͡-ʕ•̫͡•ʔ*̫͡*ʔ-̫͡-ʔʕ•̫͡•ʕ*̫͡*ʕ•͓͡•ʔ-̫͡-ʕ•̫͡•ʔ*̫͡*ʔ-̫͡-ʔ
_____________________________________________
jlocana
Newbie
*
Offline Offline

Activity: 5


View Profile
May 26, 2016, 08:24:23 PM
 #125

For New York miners you can use this p2pool server 6 core 12 ram from VPS hosting server in 1and1.com in New York http://prbitcoin.com:9332/static/  This is a great example how to run your own bitcoin mining pool and work excellent. I am from Puerto Rico and work good from New York work better because is close to the server.

Thanks

Jose Luis Ocaña
http://bitcoinpr.net
https://www.facebook.com/PuertoRicoBitcoinMiningPool/   
jlocana
Newbie
*
Offline Offline

Activity: 5


View Profile
June 20, 2016, 10:37:26 PM
 #126

Hello P2pool Owner:

I am prbitcoin.com is a new dedicated server in 1and1.com 8 Core 16 Ram.  I am trying to install p2pool and see the template empty not see the running data and not see any error.  Bitcoin core running good https://bitnodes.21.co/nodes/108.175.9.236-8333/ I use to do it in Virtual server and running everything good but when I install it in a dedicated server wont run. Do you have a extra instruction how to run p2pool in a dedicate server? 

Thanks

Jose Luis Ocana
joseluisocana.net




bapparabi
Hero Member
*****
Online Online

Activity: 686


TravelAffiliateGuru - Earn $ 1000+ a Month Easily


View Profile WWW
July 06, 2016, 03:44:22 AM
 #127

Is this pool is base on PPLNS bitcoin sharing model or any other model ..

           ▄▄▄▀▀▀▀▀▀▀▀▀▄▄▄
       ▄▄▀▀ ▄▄▄▄█████▄▄▄▄ ▀▀▄▄
     ▄▀ ▄▄███████████████▀█▄▄ ▀▄
   ▄▀ ▄██████████████████▄██▀▄▄ ▀▄
  █▀ ███████████▀███▀█████████▀█ ▀█
 █ ▄████████████▄███▄██████████▀█▄ █
▄▀ █████████████████████████████▀█ ▀▄
█ █████████████████████▀█████████▀█ █
█ █████████████▀▀▀▀▀▀██████████████ █
█ ██████████▀████████████████████▄█ █
▀▄ ████████▀████████████████████▄█ ▄▀
 █ ▀██████▀█████▄███▄██████████▄█▀ █
  █▄ █████▄█████▀███▀█████████▄█ ▄█
   ▀▄ ▀████▄███████████████▄▄▀▀ ▄▀
     ▀▄ ▀▀███▄▄███████▄▄▄▄█▀▀ ▄▀
       ▀▀▄▄ ▀▀▀███████▀▀▀ ▄▄▀▀
           ▀▀▀▄▄▄▄▄▄▄▄▄▀▀▀
██
██
██
██
██
██
██
██
██
██
██
▀▀
██
██
██
██
██
██
██
██
██
██
██
▀▀
......READ THE WHITEPAPER          REGISTER TODAY........
...slack   |   Telegram   |   twitter   |   facebook   |   ANN Thread....
jlocana
Newbie
*
Offline Offline

Activity: 5


View Profile
July 12, 2016, 01:10:41 AM
 #128

Thanks for you! help. Now is running in a dedicate server 8 core 16Ram from 1and1.com in New York is http://prbitcoin.com:9332/static/  is running beautiful and paying fast..


Thanks

Jose Luis Ocaña
Puerto Rico http://SeePuertoRico.com
http://bitcoinpr.net
http://prbitcoin.com:9332/static/
https://www.facebook.com/PuertoRicoBitcoinMiningPool/   
bapparabi
Hero Member
*****
Online Online

Activity: 686


TravelAffiliateGuru - Earn $ 1000+ a Month Easily


View Profile WWW
July 12, 2016, 02:50:44 AM
 #129

Thanks for you! help. Now is running in a dedicate server 8 core 16Ram from 1and1.com in New York is http://prbitcoin.com:9332/static/  is running beautiful and paying fast..


Thanks

Jose Luis Ocaña
Puerto Rico http://SeePuertoRico.com
http://bitcoinpr.net
http://prbitcoin.com:9332/static/
https://www.facebook.com/PuertoRicoBitcoinMiningPool/   

running a pool is now worth ?? after bitcoin halving

           ▄▄▄▀▀▀▀▀▀▀▀▀▄▄▄
       ▄▄▀▀ ▄▄▄▄█████▄▄▄▄ ▀▀▄▄
     ▄▀ ▄▄███████████████▀█▄▄ ▀▄
   ▄▀ ▄██████████████████▄██▀▄▄ ▀▄
  █▀ ███████████▀███▀█████████▀█ ▀█
 █ ▄████████████▄███▄██████████▀█▄ █
▄▀ █████████████████████████████▀█ ▀▄
█ █████████████████████▀█████████▀█ █
█ █████████████▀▀▀▀▀▀██████████████ █
█ ██████████▀████████████████████▄█ █
▀▄ ████████▀████████████████████▄█ ▄▀
 █ ▀██████▀█████▄███▄██████████▄█▀ █
  █▄ █████▄█████▀███▀█████████▄█ ▄█
   ▀▄ ▀████▄███████████████▄▄▀▀ ▄▀
     ▀▄ ▀▀███▄▄███████▄▄▄▄█▀▀ ▄▀
       ▀▀▄▄ ▀▀▀███████▀▀▀ ▄▄▀▀
           ▀▀▀▄▄▄▄▄▄▄▄▄▀▀▀
██
██
██
██
██
██
██
██
██
██
██
▀▀
██
██
██
██
██
██
██
██
██
██
██
▀▀
......READ THE WHITEPAPER          REGISTER TODAY........
...slack   |   Telegram   |   twitter   |   facebook   |   ANN Thread....
MessyCoin
Sr. Member
****
Offline Offline

Activity: 441



View Profile
May 05, 2017, 06:28:09 AM
 #130

Hi All,

Emercoin (EMC) now also supports merge mining and personally I am very glad as this opens up the possibility to merge mine EMC alongside p2pool.

Emercoin Links


website: http://emercoin.com
announcement: https://bitcointalk.org/index.php?topic=362513
github: https://github.com/Emercoin/emercoin
downloads: http://emercoin.com/#downloads
explorer: https://emcblock.info
explorer API: https://dev.emercoin.mintr.org/api/help
marketcap: http://coinmarketcap.com/currencies/emercoin
slack: https://emercoin-slack-invite.herokuapp.com

Emercoin ports

port=6661
rpcport=6662

(Thanks for your attention Smiley I don't mean to necropost but this still seems like the best guide on merge-mining with p2pool)

Please update your mege-mining references to include EMC Emercoin!

murdof
Full Member
***
Offline Offline

Activity: 196


View Profile
May 17, 2017, 09:27:31 AM
 #131

Making a new guide for Ubuntu 16.04 and Emercoin merged mining.
If there are any other coins that are not dead and can be merged mined please let me know so that I include them.

Guide here: https://bitcointalk.org/index.php?topic=1921525.0

Buy me a beer: 1mrdfyA1GhKmTPhaSkvyq5DBterQ5m7ZK

Run your own P2Pool with Ubuntu 16.04 LTS and merge mining
Pages: 1 2 3 4 5 6 7 [All]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!