Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    [SOLVED] Cron is not working for me

    Scheduled Pinned Locked Moved General pfSense Questions
    1 Posts 1 Posters 1.4k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K
      krosseyed
      last edited by

      I have tried 2 ways to apply a cron job using a custom script

      1. Using the Cron package to use the webUI to load the job
      2. Using the crontab -e command

      Neither of them work, here is my script:

      #!/usr/local/bin/bash
      sleep 15
      /sbin/ifconfig | sendEmail -f ****** -xu ****** -xp ****** -t ****** -u Notification -s smtp.gmail.com:587 -o tls=yes

      I am able to run the script without permission errors, but I cannot get cron to do it automatically.

      Edit: I had posted the wrong version of the script

      Solvedit:

      I had incorrectly stated the program in my script! I have changed it to:

      #!/usr/local/bin/bash
      sleep 15
      /sbin/ifconfig | **/usr/local/bin/**sendEmail -f ****** -xu ****** -xp ****** -t ****** -u Notification -s smtp.gmail.com:587 -o tls=yes

      1 Reply Last reply Reply Quote 0
      • First post
        Last post
      Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.