How to free up space if you own multiple vNodes

What does ls -al output?

. … constants.example1.ts constants.example2.ts constants.example3.ts constants.ts db deno.json Duplicated-files-cleaner-Incognito import_map.json index.ts LICENSE README.md types utils

If it makes any difference, I can’t even get manually hardlinked files to work properly. 2 of these are normal and the restarting/offline node is hardlinked.

What OS is this installed on and what method did you use to install Deno?

I recently discovered I can create self-contained binaries with Deno, and this situation created the perfect opportunity for me to test it. Please read carefully the instructions at https://github.com/J053Fabi0/Duplicated-files-cleaner-Incognito/tree/binaries. Be aware I haven’t test the binaries (I no longer use the script myself) so errors can happen.

1 Like

Ubuntu 22.04. Installed Deno with snap. I already tried uninstalling this Deno so I could use the Deno install script, but that didn’t work (error creating /root).

Thanks for your help Jose. I’m calling it a night and hopefully I’ll get the chance to try the self-contained binaries tomorrow.

I got hard links to work and the deno script works. I would like to point out to others trying this they need to be patient. I thought my hard links were failing, but I wasn’t giving node monitor enough time.

After bootstrapping it take about an hour to show online. Realizing this, I kept waiting after hardlinking instead of restarting again. It took over 2 hours after hardlinking. As long as your docker ps doesn’t show restarting containers and all containers have roughly the same uptime, just be patient.

This is on SATA SSD. 8gb RAM, Intel i5 from 2012

1 Like

Anyone having the issue where it’s running both your configured instructions + the default? I’m using example3 as the basis for my constants.ts and when it runs it runs both my given instructions + it does it’s own thing.

Blockquote
Getting instructions.
[
{
shardName: “beacon”,
toNodesIndex: [
0, 1, 2, 3, 4
],
fromPath: “/home/incognito/fullnode/mainnet/block/beacon”
},
{
shardName: “beacon”,
fromNodeIndex: 0,
toNodesIndex: [
1, 2, 3, 4
]
},
{
shardName: “shard0”,
toNodesIndex: [ 2, 4 ],
fromPath: “/home/incognito/fullnode/mainnet/block/shard0”
},
{ shardName: “shard0”, fromNodeIndex: 2, toNodesIndex: [ 4 ] },
]

1 Like

Hello @bjeung,

That is a known issue:

https://github.com/J053Fabi0/Duplicated-files-cleaner-Incognito/issues/25

However, it doesn’t impact the ability for the script to run.

2 Likes

Finally, I’ve started to use deno. Here is my observation. It really gives much space back but the space given back is filled by the validators withing a short duration (at most ~1 day). So strange. For example, deno gives 300 GB back but that 300 GB is filled quickly. Then I can run deno to take 300 GB back again and the rest is the same :slight_smile: This is not related to deno but before I start to examine this issue, I want to ask: “Is there anyone knowing the reason?”

1 Like

Yes, I have this same problem. I brought this up to @Jared attention several months ago because it didn’t make any sense. I would be down to 19% after running the script, and by the next day my drive would be full if I didn’t run the script again. In the end there was no explanation for how it could fill up the drive so fast in a day. For now, i just run the script twice a day automated, and just have 2 alarms on my phone go off an hour later twice a day, to check to make sure all nodes are properly online in node monitor. Usually it is fine, but about 25% of the time 1 or more nodes will be stalled, so i have to manually re-run the script again and usually that fixes it… but sometimes (like last night) i had to manually run it 3 times before it would end with all nodes online in “latest”.

Not the most optimized way to do things, but it has been working. Without this script I would have had to upgrade to double the driver space on both drives and probably still would have a problem, so I am grateful I have this solution, but it would be nice if there was an explanation for how the drive fills up so quickly after the script is run.

4 Likes

To those using this script, is anyone running the new 2.0+ versions?

I want to update but am nervous as the current version 1 i am running works (though requires a lot of babysitting). I am hesitant to update in case i run in to any problems. Can anyone confirm they are running the newer version without issues?

I didn’t intend that version to be used by the public, but if you know how to read code and can adapt it to your needs, go ahead.
Those versions work along with my new website for hosting nodes, which is not open source.

In case anyone is curious about my hosting service, I leave the link: Hosting service for vNodes.

oh ok, good thing I didn’t update then.

1 Like

Hey everyone. If you haven’t already, using this hardlink script process in combination with @Jared 's node controller script is invaluable. You’ll want to use the --keep-status flag. Using these 2 in combination has made managing the server much easier.

Also, has anyone updated their deno version to any of the latest versions, and have you had any problems?

I am still running deno 1.30.3 because last time I updated (months ago) it ended up breaking this script. So i have been afraid to update. Curious what version of deno you guys are running with this script so I know if I can safely update.

4 Likes

Just for future reference, the binaries do not work. They may work on J053’s machine, but there is a file referenced on his machine that will not be on your machine and you will get an error. I doubt he ever fixes this, and you should just use the deno or npm script.

In case you are here and having issues getting this running, here are instructions. This assumes you are running Ubuntu Server (or some flavor of Ubuntu). I am running the newest 22.04.3 LTS release.

  1. Grant yourself root privileges:

sudo su

  1. Enter your user password

  2. Install Deno:

curl -fsSL https://deno.land/install.sh | sh

  1. Add Deno to the PATH Variable:

nano $HOME/.bashrc

Now paste the following at the end of the .bashrc file:

export DENO_INSTALL="/root/.deno"
export PATH="$DENO_INSTALL/bin:$PATH"

Now reboot your system to apply the PATH.

  1. Clone the Repository (note that I am cloning version 1.1.9, which is the last version before Jose changed to pulling the validator information directly from docker containers. The newer versions 1.2 to 2.0.1 do not require you to enter your validator keys, but have a bug where they pull instructions from the docker containers and then also apply your instructions. If you just want to apply instructions without also auto pulling from docker, it can’t work that way. You can experiment with the newer versions, but if you want to avoid this bug, use version 1.1.9. Versions 3.0+ are not intended for end users, and you should not use them):

git clone --depth 1 -b 1.1.9 https://github.com/J053Fabi0/Duplicated-files-cleaner-Incognito.git

  1. Change your directory to the newly downloaded git files:

cd Duplicated-files-cleaner-Incognito

  1. Copy the example constants file to the one the script will use:

cp constants.example1.ts constants.ts

  1. Edit the constants file with your Validator Public Keys:

nano constants.ts

You can also omit Validator Public Keys and specify instructions, if you have some weird use case. Look at the constants.example2.ts and constants.example3.ts files if you want to specify instructions.

  1. Now run the script:

deno task run

That’s it folks. If I made some mistake in the above instructions please let me know and I’ll fix it.

4 Likes

Hey thanks for this! I have been using version 1 (something?) for awhile with little to no issues. Super great that @J053 shared this project with you, but I also had a fear that if I ever needed to re-install this, I would be screwed because of the newer updates. I really appreciate having documentation step by step on how to install the public version of this in case I ever need to.

This project has been essential to me being able to support all my nodes on 1 server.

I am in the process of switching to a new server I built and also staking with a single reward address. The beacon alone for 15 nodes filled up the 2TB drive so I needed this to even get going. I initially set this up over a year ago and it was a struggle to get it going again now, so I knew there are others that would come here and find it useful.