Welcome to the Dash Forum!

Please sign up to discuss the most innovative cryptocurrency!

how to make sentienel crontab when using dashman ??

Discussion in 'Masternode Questions and Help.' started by semajjames, Apr 8, 2017.

  1. semajjames

    semajjames Member

    Joined:
    Feb 5, 2015
    Messages:
    154
    Likes Received:
    13
    Trophy Points:
    78
    I have just moved a MN to a new server ,,,
    I installed dashman then used it to install dash in root because dashman says it is not compatible with multi user

    then I installed sentinel,synced and started the MN which is now running
    but dashman says that "sentinel crontab" is not enabled ,,,

    when i try to manually make the crontab using putty like this:-
    step 9) create a crontab entry to wake sentinel every five minutes

    crontab -e

    Choose Joe as your editor. Add this line to the end of the file.

    * * * * * cd /.dashcore/sentinel && ./venv/bin/python bin/sentinel.py 2>&1 >> sentinel-cron.log

    I run into problems ,,
    joe does not open and putty complains that there is no crontab for "root"

    does anyone know how i should be making this crontab ??

    cheers
     
  2. semajjames

    semajjames Member

    Joined:
    Feb 5, 2015
    Messages:
    154
    Likes Received:
    13
    Trophy Points:
    78
    yes and i think "888" refers to something that i typed in the first time i tried to make this crontab in root

    [email protected]:~# cd .dashcore
    [email protected]:~/.dashcore# cd sentinel
    [email protected]:~/.dashcore/sentinel# crontab -e
    no crontab for root - using an empty one
    888
     
  3. demo

    demo Well-known Member

    Joined:
    Apr 23, 2016
    Messages:
    3,114
    Likes Received:
    263
    Trophy Points:
    153
    Dash Address:
    XnpT2YQaYpyh7F9twM6EtDMn1TCDCEEgNX
    Oh really? Then use vi or ed. :p


    Seriously now, some hosting companies don’t allow access to cron.

    If this is not the case, maybe you should change your default editor.

    env | grep EDI
    EDITOR=ed
    The above shows you use the ed editor.
    to change it type:
    export EDITOR=vim;

    The crontab files are usally stored in /var/spool/cron/crontabs
    So maybe you have just created an empty crontab, for the user root.
    Type crontab -e again, and if your default editor is ed then change it to an easier (for you) editor.

    But first of all ask your hosting company, whether they allow you to use cron.
     
    #3 demo, Apr 8, 2017
    Last edited: Apr 8, 2017
  4. semajjames

    semajjames Member

    Joined:
    Feb 5, 2015
    Messages:
    154
    Likes Received:
    13
    Trophy Points:
    78
    Ok thanks I look into all that ,,,,
     
  5. moocowmoo

    moocowmoo Bovine Bit-flipper
    Foundation Member

    Joined:
    Jun 15, 2014
    Messages:
    483
    Likes Received:
    603
    Trophy Points:
    263
    Dash Address:
    XmoocowYfrPKUR6p6M5aJZdVntQe71irCX
    forget all of that and just run
    Code:
    dashman install sentinel
    :)

    And, you really shouldn't be running things as root. Or logging in as root for that matter.
     
  6. semajjames

    semajjames Member

    Joined:
    Feb 5, 2015
    Messages:
    154
    Likes Received:
    13
    Trophy Points:
    78
    Ok So "dashman" should work inside a new user ??

    I'll Reinstall
     
  7. moocowmoo

    moocowmoo Bovine Bit-flipper
    Foundation Member

    Joined:
    Jun 15, 2014
    Messages:
    483
    Likes Received:
    603
    Trophy Points:
    263
    Dash Address:
    XmoocowYfrPKUR6p6M5aJZdVntQe71irCX
    • Agree Agree x 1
  8. demo

    demo Well-known Member

    Joined:
    Apr 23, 2016
    Messages:
    3,114
    Likes Received:
    263
    Trophy Points:
    153
    Dash Address:
    XnpT2YQaYpyh7F9twM6EtDMn1TCDCEEgNX

    Dont reinstall. First try "crontab -l" instead of "crontab -e"

    Example of correct crontab command line code (you have to substitute the variables to the appropriate directories of course):
    https://github.com/moocowmoo/dashma...2fb3d9b27aaa13/lib/dashman_functions.sh#L1241
    https://github.com/moocowmoo/dashma...32fb3d9b27aaa13/lib/dashman_functions.sh#L562

    If this fails, then crontab is not your only installation error, and you need to reinstall.
     
    #8 demo, Apr 8, 2017
    Last edited: Apr 8, 2017
  9. semajjames

    semajjames Member

    Joined:
    Feb 5, 2015
    Messages:
    154
    Likes Received:
    13
    Trophy Points:
    78
    Na I'm going to reinstall
    I did know about not using root but for some reason got it in my head that "dashman" used root ,,,now that has been put straight i'll get things sorted the way they should

    thanks guys
     
    • Agree Agree x 1