Cannot migrate my node

Hello guys,

I’m new here (and proud to be part of you). My Node (a VM on my VMware ESXi homelab) is running since 2 days and I wanted to migrate to a ZFS drive with compression enabled but it won’t do the trick… I followed this doc : How do I migrate my node to a new device? - Node Operator
But when I restart STORJ docker container it keeps restarting and I don’t understand why…

Here are the commands I run to switch to ZFS storage fastly :
rsync -aP /mnt/STORJ/* /mnt/temp/
docker stop storagenode
docker rm storagenode
rsync -aP /mnt/STORJ/* /mnt/temp/
umount /mnt/STORJ
zfs unmount STORJ/temp
zfs set mountpoint=/mnt/STORJ STORJ/temp
zfs mount STORJ/temp
docker run -d --restart unless-stopped --stop-timeout 300
-p 28967:28967
-p 14002:14002
-e WALLET=“0x0000000000000000000000000000000000000000”
-e EMAIL=“okok@okok.ok”
-e ADDRESS=“okokok.ddns.net:28967
-e STORAGE=“7TB”
–mount type=bind,source="/root/.local/share/storj/identity/storagenode",destination=/app/identity
–mount type=bind,source="/mnt/STORJ",destination=/app/config
–name storagenode storjlabs/storagenode:latest
docker ps -a

No error, everything seems OK… I’ve seen a post talking about permanents restarts but my rights and file/directories owner are identical between the source drive and the destination drive so it seems ok…

Thanks per advance

PS : I have another command list to recover my config, my node is still running don’t worry :slight_smile:

You missed out the final rsync with --delete
If your node is running it is too late now and --delete would destroy it

1 Like

Thanks for your answer ! Yes I didn’t do it because I didn’t want to delete the data on one side without being sure that it works on the other… Why do I have to add “–delete”? What does it change on the STORJ application side?

Can you confirm that the following commands do what I want?

rsync -aP /mnt/STORJ/* /mnt/temp/
docker stop storagenode
docker rm storagenode
rsync -aP /mnt/STORJ/* /mnt/temp/ --delete
umount /mnt/STORJ
zfs unmount STORJ/temp
zfs set mountpoint=/mnt/STORJ STORJ/temp
zfs mount STORJ/temp
docker run -d --restart unless-stopped --stop-timeout 300
-p 28967:28967
-p 14002:14002
-e WALLET=“0x0000000000000000000000000000000000000000”
-e EMAIL=“okok@okok.ok”
-e ADDRESS=“okokok.ddns.net:28967
-e STORAGE=“7TB”
–mount type=bind,source="/root/.local/share/storj/identity/storagenode",destination=/app/identity
–mount type=bind,source="/mnt/STORJ",destination=/app/config
–name storagenode storjlabs/storagenode:latest
docker ps -a

Is there a “quick” way back if it fails (being a VM, I can do a snapshot before deleting the data, for example)

Because your source node keeps running, so it is not just receiving files, it is also deleting files. The --delete option deletes files only on destination side, which are no longer present on source side.

2 Likes

Oh okay ! Stopping & deleting the docker container doesn’t stop the entire app ?

Just tried this code but it’s the same… Docker keeps restarting…

Any hint in the logs?

1 Like

Sorry but… I searched for them… Where are they ?

Hello @tigerblue77 ,
Welcome to the forum!

This guide should help:

1 Like

Hop ! Here they are :slight_smile:
image|690x260
Ok I see the first line… “less than required minimum” ^^… Why do I need at least 500 GB ? ^^’
Or 550GB as written here : Prerequisites - Node Operator

Hello,
2x Thanks ! :slight_smile:

Well, I expanded my VMDK drive to 500GB and it worked :slight_smile: thanks and sorry for the inconvenience !

1 Like

You might want to expand it a bit more so there’s a bit of extra room just in case.
StorjLabs recommend adding 10% of extra space to be safe, so if you configure your node to use 500GB, it is recommanded to run it on a disk with 550GB of dedicated space for the node.

Personnally, I think this “10%” is unnecessarily high for way larger disks, but for such a small space (500GB), that’s a good ratio.

1 Like

Now it’s more tricky… I don’t understand if it’s my previous EXT4 LVM volume that is used or my new ZFS volume… Here is what df -h command gives me :

So, as STORJ/temp is my ZFS :

image

I was thinking I could remove my LVM volume so first i deactivated it using this command :

lvchange -an /dev/STORJ-vg/STORJ

But then my /mnt/STORJ mounpoint was empty… W T F
Any idea ?

Thanks for the advice. I understand but I’m not worried : I’m monitoring it :slight_smile: and I want to see the LZ4 compression benefits before doing anything.
My internet connection being only 20/25Mb/s, I have time to anticipate before the 500GB volume is full haha!

Maybe I missed something… But where is command like

rsync -aP --delete /mnt/temp /mnt/STORJ

Did you ever moved data from /mnt/temp to your zfs volume?
Please also give me result of the command:

df -HT

No problem, it’s the 4th command of my little script (present in the first message you quoted), arguments are just not in the same order.

At the beginning of this script, /mnt/STORJ is the EXT4 and /mnt/temp is the ZFS and so, the 1st and the 4th command copy & delete data to/from the ZFS.

I’ll give you the command result when I’ll be back to home :slight_smile:

I’m afraid it won’t do anything on data files that are nothing but random noise almost impossible to compress. It will probably marginally use less space by compressing databases, but that’s about it.
IMHO :slight_smile:

You’re totally right :3 my compress ratio is 1,02x x’) but I’m happy with that considering it’s “free” compression and it doesn’t use much CPU/memory haha !