[ANN] Peerbox project

[quote=“badgolfer, post:173, topic:2485”][quote=“peerchemist, post:172, topic:2485”]

Can I copy wallet.dat from Peerunity to the PeerBox?

Yes, it is possible to just copy wallet.dat file from Peerunity to Peerbox.
See this: https://github.com/peerchemist/Peerbox/wiki/How-to-backup-wallet.dat[/quote][/quote]

OK, tried all of this. Brand new USB “nerd stick”. Copy wallet.dat from my PeerUnity data directory on a WinXP computer. According to Windoze, all is OK.

“sudo ls /media” shows the USB present as USB1 - the name that I gave it in WinXP.

After stopping ppcoind as per instructions, I try:

“sudo cp /media/USB1/wallet.dat /var/lib/ppcoind”

I get an error:
“cp: cannot stat ‘/media/USB1/wallet.dat’: No such file or directory”

Tried to do a full format in Windows. FAT32. Re-copied wallet.dat. Same result.

Really puzzled as to how to copy wallet.dat to the PeerBox. I’m tempted to simply import my private key. Seems simpler.

I saw previous posts about file system problems re: Apple OS. But I’m using Windows. Is there possibly some similar issue?

Edit: PS: FWIW, it took ~36 hours for a blockchain sync for me.

I understand this looks hard to you since you are obviously not Linux user.
So, welcome to Linux terminal. It might not be most user-friendly solution but it is quite simple actually.

cp stands for “copy”
ls stands for “list”

I get an error: "cp: cannot stat '/media/USB1/wallet.dat': No such file or directory"

What this means is that there is not wallet.dat in that directory you have told it to look in.

It would be best for now to list that directory to see what is going on.

sudo ls /media/USB1

Now you should see all the files inside this directory. It is possible that you have placed wallet.dat in some folder inside.

There is no compatibility issues with FAT formatted on Windows, that is OS X specific bug.

Really puzzled as to how to copy wallet.dat to the PeerBox. I'm tempted to simply import my private key. Seems simpler.

Whatever you find easier. I understand that Peerbox is not easy to use for non Linux people. Current focus of development is security and features not ease of use.

Edit: PS: FWIW, it took ~36 hours for a blockchain sync for me.

Sounds about right. 24-36h depending on network connection.

Still stumped…

I didn’t touch anything from last night, but this morning the copy seemed to go OK. There couldn’t have been a typo error, as I copy-and-pasted the same commands as before. The only thing that I did different was “sudo ls /media/USB1” as you suggested. The file was there.

I say seemed to go OK, because peerbox-info is showing 0.0 balance. I fired up Peerunity on my PC, and checked balance. Then I went to the data directory (the same directory containing the blockchain, etc.) and verified that wallet.dat was just accessed - making certain that I was accessing the correct wallet.dat. Copied it to the USB stick, and tried the whole process over. Again, the copy to the raspi went without error message, but I still show 0.0 balance. I even tried copying wallet.dat to the USB stick on my PC using the DOS command window and verifying that the copied file had the same date and time stamp. (FWIW, I’m showing wallet.dat as 64K or 65536 bytes.) Trying “mintbox” gives an error after entering my passphrase. I tried the passphrase with single quotes, double quotes, and naked. Verified that the same passphrase works in Peerunity.

I’m using Peerbox 0.24. Could I be copying to the wrong directory on the PeerBox? I’m using this command:
“sudo cp /media/USB1/wallet.dat /var/lib/ppcoind”

Doing: “sudo ls /var/lib/ppcoind” gives me a list of files similar to what I see in Windows Peerunity.

I’ll keep trying. Maybe something will click.

Thanks for your patience.

I just checked the Peercoin address on the PeerBox. It is the same as when the software was installed, and not the same as Peerunity. So it seems evident (to me at least…) that somehow the copy didn’t work. That is puzzling, as I deleted the file on the USB stick and copied it fresh from the Peerunity data directory on my PC. wallet.dat on the USB stick HAS to be from my PC, not PeerBox. But the file copy to the PeerBox apparently isn’t working somehow.

I guess you did not read wiki entry until the end. Please do this and report output.

sudo ls -al /var/lib/ppcoind

Hi. Here is the result of “sudo ls -al /var/lib/ppcoind”:

total 392160
drwxr-xr-x 3 ppcoind ppcoind 4096 Dec 10 18:56 .
drwxr-xr-x 13 root root 4096 Dec 10 00:00 …
-rw------- 1 ppcoind ppcoind 0 Nov 26 15:36 .lock
-rw------- 1 ppcoind ppcoind 1851392 Dec 10 19:21 __db.001
-rw------- 1 ppcoind ppcoind 1368064 Dec 10 19:21 __db.002
-rw------- 1 ppcoind ppcoind 32776192 Dec 10 19:21 __db.003
-rw------- 1 ppcoind ppcoind 700416 Dec 10 19:21 addr.dat
-rw------- 1 ppcoind ppcoind 217351454 Dec 10 19:13 blk0001.dat
-rw------- 1 ppcoind ppcoind 145334272 Dec 10 19:13 blkindex.dat
drwx------ 2 ppcoind ppcoind 4096 Dec 10 19:13 database
-rw------- 1 ppcoind ppcoind 0 Nov 26 15:36 db.log
-rw------- 1 ppcoind ppcoind 1660832 Dec 10 19:18 debug.log
-rw------- 1 ppcoind ppcoind 73728 Dec 10 19:13 wallet.dat

Also I did: “sudo ls -al /media/USB1” and got:

total 80
drwxr-xr-x 2 root root 4096 Dec 10 06:27 .
drwxr-xr-x 3 root root 4096 Dec 9 23:46 …
-rw------- 1 root root 73728 Dec 10 06:27 wallet.dat

TIA.

[quote=“peerchemist, post:185, topic:2485”]I guess you did not read wiki entry until the end. Please do this and report output.

sudo ls -al /var/lib/ppcoind

I’m not quite sure what you meant. I followed the instructions at:

EXACTLY, except that I didn’t do:

"Now copy your wallet.dat to USB flash drive:

sudo cp /var/lib/ppcoind/wallet.dat /media/FLASH"

because I was not backing up from the Peerbox to USB. Instead I copied my Peerunity wallet.dat to USB and proceeded with the rest of the instructions.

I’m using "ppcoind getaccountaddress " to see if the wallet copy operation succeeds. It still reports the same PPC address as installed, not as seen on Peerunity.

restart ppcoind

sudo systemctl restart ppcoind

Restarted. peerbox-info still shows a balance of 0.0 and

"ppcoind getaccountaddress “” "

still shows the PPC address that was there on initial install.

Here’s what I’m doing:

  1. USB to PC.
  2. Erase existing wallet.dat on USB (file from previous attempts)
  3. Copy wallet.dat from: “/Documents and Settings/Default/Application Data/PPCoin”
    I’m confident that this is the correct directory because the time on the blockchain file keeps updating as Peerunity is running.
  4. “Eject” USB
  5. Insert USB into raspi
  6. Verify USB is being seen with: “sudo ls /media/USB1” and wallet.dat shows
  7. sudo systemctl stop ppcoind
  8. sudo cp /media/USB1/wallet.dat /var/lib/ppcoind
  9. sudo chown ppcoind:ppcoind /var/lib/ppcoind/wallet.dat
  10. sudo systemctl start ppcoind

Am I missing something?

[quote=“badgolfer, post:189, topic:2485”]Restarted. peerbox-info still shows a balance of 0.0 and

"ppcoind getaccountaddress “” "

still shows the PPC address that was there on initial install.

Here’s what I’m doing:

  1. USB to PC.
  2. Erase existing wallet.dat on USB (file from previous attempts)
  3. Copy wallet.dat from: “/Documents and Settings/Default/Application Data/PPCoin”
    I’m confident that this is the correct directory because the time on the blockchain file keeps updating as Peerunity is running.
  4. “Eject” USB
  5. Insert USB into raspi
  6. Verify USB is being seen with: “sudo ls /media/USB1” and wallet.dat shows
  7. sudo systemctl stop ppcoind
  8. sudo cp /media/USB1/wallet.dat /var/lib/ppcoind
  9. sudo chown ppcoind:ppcoind /var/lib/ppcoind/wallet.dat
  10. sudo systemctl start ppcoind

Am I missing something?[/quote]

No, you are not missing anything. But it does not work for you somehow.
Let’s try this:

Between step 7. and 8. insert

sudo rm /var/lib/ppcoind/wallet.dat

To ensure the old wallet is removed.

Proposition two:

Maybe blockchain is borked, or wallet is lost in time due to many attempts and occasional using from two places (Peerunity). So maybe rescan the blockchain?
Before step 10, insert this (edit file):

sudo nano /etc/conf.d/ppcoind.conf

https://github.com/peerchemist/Peerbox/blob/master/PKGBLD/ppcoind-git/ppcoind.conf

This is the file, just add “-rescan” after “checkblocks…” separate with space.

Then, start (or restart) the ppcoind. Note that this could take a while. Monitor with “htop”, when CPU usage drops to about 15-20% it is done.

OK, will do.

Something just occurred to me. I have named the USB stick USB1. Is that name somehow reserved in Linux? Like DSK1: is used in some operating systems.

Before I try your suggestions, I think I will rename the USB stick and try again. Like maybe “YouStupidUSBStickHasWastedHoursOfMyTime”.

Edit: I have tried: peerbox-info --health and it checks out OK.

[quote=“badgolfer, post:191, topic:2485”]OK, will do.

Something just occurred to me. I have named the USB stick USB1. Is that name somehow reserved in Linux? Like DSK1: is used in some operating systems.

Before I try your suggestions, I think I will rename the USB stick and try again. Like maybe “YouStupidUSBStickHasWastedHoursOfMyTime”.

Edit: I have tried: peerbox-info --health and it checks out OK.[/quote]

Something weird going on (or more likely something I don’t understand…) with the file systems in either Windows or Linux.

I renamed the usb stick to NerdStick (my son’s name for them - he should know as he carries a pocket full of them.) and then did a full format of the stick. I then created a “hello.txt” file on it. Plugged it into the raspi and… I don’t understand.

sudo ls /media gives:
NERDSTICK USB1 (USB1 was the prior name for the stick)
sudo ls /media/NERDSTICK gives:
nothing. It should show (I think): hello.txt
sudo ls /media/USB1 gives:
wallet.dat ??? This file was erased even before doing the full format! There
is no trace of it when the usb stick is viewed from Windows (or DOS window)

It looks like there are somehow remnants of prior contents of the usb stick on the raspi. And it refuses to see the new contents.

I’m about ready to do a re-flash of the SD card and start over.

Edit: Took out the usb stick from the raspi. It is in my hand. And then entered:

[sunny@peerbox ~]$ sudo ls /media
USB1
[sunny@peerbox ~]$ sudo ls /media/USB1
wallet.dat
[sunny@peerbox ~]$

So USB1 (and some version of wallet.dat) is still there on the raspi file system.

OK, I’m back to square one.

I deleted the directory /media/USB1 on the raspi.

Copied wallet.dat from my PC to the usb stick, newly formatted and named NerdStick

Inserted into the raspi and tried to see if I could see wallet.dat:

[sunny@peerbox ~]$ sudo ls /media/NERDSTICK
[sunny@peerbox ~]$ sudo ls -at /media
. NERDSTICK …
[sunny@peerbox ~]$ sudo ls -at /media/NERDSTICK
. …
[sunny@peerbox ~]$

As you can see, peerbox does not see anything on the usb stick, but the file is most definitely there in Windows. This is where I was last night.

Hmmmm…

[quote=“badgolfer, post:193, topic:2485”]OK, I’m back to square one.

I deleted the directory /media/USB1 on the raspi.

Copied wallet.dat from my PC to the usb stick, newly formatted and named NerdStick

Inserted into the raspi and tried to see if I could see wallet.dat:

[sunny@peerbox ~]$ sudo ls /media/NERDSTICK
[sunny@peerbox ~]$ sudo ls -at /media
. NERDSTICK …
[sunny@peerbox ~]$ sudo ls -at /media/NERDSTICK
. …
[sunny@peerbox ~]$

As you can see, peerbox does not see anything on the usb stick, but the file is most definitely there in Windows. This is where I was last night.

Hmmmm…[/quote]

I think I’m on to something…

See if anyone else can replicate this:

  1. Put EMPTY usb stick in raspi. Mine is called NerdStick
  2. And do: (note that I had already stopped ppcoind)

[sunny@peerbox ~]$ sudo ls /media
NERDSTICK
[sunny@peerbox ~]$ sudo cp /var/lib/ppcoind/wallet.dat /media/NERDSTICK
[sunny@peerbox ~]$ sudo umount /media/NERDSTICK
umount: /media/NERDSTICK: not mounted

  1. Take out usb stick, plug into your favorite Windows PC. See if wallet.dat is
    present. In my case it isn’t.

  2. With usb still NOT plugged into the raspi, do:

[sunny@peerbox ~]$ sudo ls /media
NERDSTICK
[sunny@peerbox ~]$ sudo ls /media/NERDSTICK
wallet.dat
[sunny@peerbox ~]$

So it looks like the backup went to a directory on the peerbox itself, not the usb stick.
Also, referencing what is quoted above from my previous message, it seems that peerbox cannot see files created on my WinXP machine.

Some sort of file system incompatibility?

I have too look into this myself.
I do not have windows machine at hand, so I can not test it.

However it seems that udev really does not remove directory in /media after it is created. I need to see what can be done with that or replace current implementation with something better.

I’m sorry I can not look into this right now, I have some other issues to tend to right now.

Can you try importing priv-key?

Lucky you. I’m about ready to throw Windows in the dumpster and buy “Linux for Dummies”

Can you try importing priv-key?

I’ll give it a try a bit later. I’m not in a hair tearing rush to mint, as most my coins are not old enough anyway.

Thanks for being patient.

http://torrents.linuxmint.com/torrents/linuxmint-17.1-cinnamon-64bit.iso.torrent

Give it a shot :wink:

[quote=“peerchemist, post:197, topic:2485”]http://torrents.linuxmint.com/torrents/linuxmint-17.1-cinnamon-64bit.iso.torrent

Give it a shot ;)[/quote]

When I saw that, I thought it was some sort of Linux based tool for minting coins. LOL.
But — Interesting. I have a trashed XP machine that I might load it on.

Had never tried importing private key before, and it took a long time. Almost gave up thinking Peerbox had crashed. But it worked. Little raspi just sitting quietly on edge of desk, 20 connections currently.

[quote=“badgolfer, post:198, topic:2485”][quote=“peerchemist, post:197, topic:2485”]http://torrents.linuxmint.com/torrents/linuxmint-17.1-cinnamon-64bit.iso.torrent

Give it a shot ;)[/quote]

When I saw that, I thought it was some sort of Linux based tool for minting coins. LOL.[/quote]

I noticed a while ago that Linux Mint actually accept Mintcoin donations. Looks like Peercoin was beaten to that strategic partnership :smiley:

Cool, nice to hear that.

Can you write up that process from noobs perspective? I guess some people wonder about the same thing.
Thanks.