Masternodes: Guide 2-in-1... How to verify installed version and if autoupdate is active.


  • 3DCoinTalk Italia

    📌💻 📚 Guide... actually they are 2 guide in 1 😃😅😆🚀🚀🚀

    Check version + verify presence of autoupdate activated on VPS (how to check which version you have and if you have autoupdate active on your masternode).

    📗 Part 1 (version verification)

    To see the installed version of the masternode use the following commands on the VPS (log in as root on Putty)

    3dcoin-cli getinfo
    
    3dcoind -version
    

    The first command will tell you which version of the "client" you have on board your VPS and the second command will tell you which version of the "daemon" 😈 you have. Then open your browser and go to the following link:

    https://github.com/BlockchainTechLLC/3dcoin/releases/latest

    Compare the version you get from the two commands above with the latest release you see on Github (for example currently the last version you can see on Github as I write is 3DCoin Core v0.14.3.4) so ​​if you get from the first command on the VPS (3dcoin-cli getinfo) the words "version": 140304 and from the second command (3dcoind -version) the words "3DCoin Core Daemon version v0.14.3.4-b56975b" (the final part b56975b after the dash do not take it into account, the important one is the main version ie 0.14.3.4) then it means that you have the latest version right now and your masternode is perfectly updated! 😉👍🏻

    📘 Part 2 (verify autoupdate)

    Do you also want to make sure you have the autoupdate active in addition to the latest installed version? Here are the checks to be made to see if your masternode will update automatically when a new version is released! 😃

    On the VPS use the following commands:

    crontab -l
    

    (Attention is a lowercase "L" not a capital "i")

    Check if the result you get is made up of these 5 lines to follow (no matter the order of the lines)

    @reboot /usr/local/bin/3dcoind
    0 0 * * * /usr/local/bin/Masternode/Check-scripts.sh
    */10 * * * * /usr/local/bin/Masternode/daemon_check.sh
    0 $h * * * /usr/local/bin/Masternode/UpdateNode.sh
    * * */2 * * /usr/local/bin/Masternode/clearlog.sh
    

    Attention: on the fourth line (0 $ h * * * /usr/local/bin/Masternode/UpdateNode.sh) instead of $ h you will find a random time, for example 12 or 23 (it's just an example) in short an hour of the day, it is the random time assigned by the script during installation and it is the time in which the autoupdate will start automatically.

    So the line will not be

    0 $h * * * /usr/local/bin/Masternode/UpdateNode.sh
    

    but it will be for example

    0 23 * * * /usr/local/bin/Masternode/UpdateNode.sh
    

    (0 23 it's only an example of random time, at 23:00 in this case)

    All clear? 😅

    ✅ Ok first step verified ✅ (if you do not get the correct result, continue to read and do the same the second step but obviously there is something wrong then you have to apply what is indicated at the end in case of failed verification)

    Now give the following command:

    cd /usr/local/bin/Masternode && ls -al
    

    (all are lowercase "L" there are no "i" uppercase, pay attention instead that the M of Masternode is capitalized, not wrong to write)

    If you see the following files listed at this point then everything is ok:

    -rw-r--r-- 1 root root   7 Feb 26 13:10 blockcount
    -rwxr-xr-x 1 root root  689 Feb 9 20:07 Check-scripts.sh
    -rwxr-xr-x 1 root root  176 Feb 9 20:07 clearlog.sh
    -rwxr-xr-x 1 root root  618 Feb 9 20:07 daemon_check.sh
    -rw-r--r-- 1 root root 49859 Feb 26 12:31 update.log
    -rwxr-xr-x 1 root root 2551 Feb 9 20:07 UpdateNode.sh
    -rwxr-xr-x 1 root root  424 Feb 9 20:07 Update-scripts.sh
    -rw-r--r-- 1 root root  140 Feb 9 20:07 Version
    

    It is also very important that you see the various "x" that you see in the example and that all the files of type ".sh" are green (so all green except "blockcount", "update.log", "Version") because this means that they are "executables" and this is very important!

    ✅ Ok second step verified ✅ (hopefully ...)

    The FUNDAMENTAL thing is that BOTH the steps above are verified (one is NOT enough) and therefore correspond the results obtained from the commands that I have illustrated above with what is indicated in this guide.

    Finally there is a further test (therefore third step but not obligatory) that you can do to be sure that the autoupdate is working (ie it is activating every day automatically at the preset random time).

    Let's see if in the "log" of the autoupdate there is a trace of the daily checks ... this is a new function of the recent updates released, very useful because now we have a "register" of the work that does the autoupdate script. Give this command always in the terminal of the VPS to open the log with a text editor:

    nano /usr/local/bin/Masternode/update.log
    

    (to move inside the open text file in "nano" you have to use the arrows on the keyboard, while to exit the "nano" editor and return to the previous screen of the terminal you have to press the CTRL + X keys together)

    or instead of the "nano" editor you can use the "cat" viewer to read the log, then the command becomes:

    cat /usr/local/bin/Masternode/update.log
    

    For more advanced users it is advisable to use "tail" to read only a certain number of lines of the log, for example if you want to read only the last ten lines the command to be given would be:

    tail -10 /usr/local/bin/Masternode/update.log
    

    In any case, everyone has his own methods to read the logs, a log is a normal text file so read it in the way you prefer. If you are a masternodes manager you know that it is important to know some basic notions of using the Linux Ubuntu terminal so it is useless to dwell on how to open a log file.

    These above are therefore useful commands to view the log file of the autoupdate on VPS ... for those who do not know it is a novelty introduced with the latest version of autoupdate masternode 3DCoin at the beginning of 2019, so now we know that we have a automatic log always available to check what happens during the autoupdates programmed in random time in the crontab! ✅✅✅😎😎😎🚀🚀🚀

    ✅ Ok third step verified ✅ (it was optional ... that there is a log is a good signal but the first two verification steps are the essential ones as already mentioned)

    So if for both the first two steps above you get the right result then everything is ok and it is not necessary to continue reading. At the next release of updates your masternode will automatically update at the random time set in the crontab, as we saw above! And of course you will find a trace of the work of the autoupdate script in the log you learned to open in the optional third step! 😃✅

    If instead something ❌ does not correspond ❌ that is, if you have not passed the checks of the first two steps above then continue reading because you have to intervene and fix things... 😉

    If you do not have the autoupdate active because the above checks did not give you a positive result, then if the ✅ two steps ✅ do not match ❌ then use the guide you find at the following link in this forum to install the latest version of autoupdate for your 3DCoin masternode:

    https://3dctalk.net/topic/1187/new-masternodes-mandatory-update-script-update-instructions-for-masternodes-owners-and-managers

    Apply the guide following it step by step with great care and you will see that everything will be for the best.

    ⚠️ WARNING: Everything mentioned in this post concerns only the masternodes installed with OFFICIAL PROCEDURES and with OFFICIAL SCRIPT, if instead you have used other "custom / unofficial" installation procedures you must NOT use the instructions given in this post (above all referring to the verification of the part 2 of the guide) because you could get misleading results! ⚠️