Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Member
    Join Date
    Apr 2003
    Location
    Bay Area, CA
    Posts
    97

    Default Anyone have a script that will mail files from the server that can be run in CRON?

    Ok, so I'm tired of PICOing my log files via SSH. Anyone have a script or know the syntax to grab specified log files and mail them? It would be good to set it as a Cron job and have them shot daily for review on a local machine.

    Would appreciate any help or suggestions.
    Dan Marshall

  2. #2
    Member Nico's Avatar
    Join Date
    Dec 2001
    Location
    Edmond, OK
    Posts
    233

    Default

    You can create a PHP script to do that with the 'fopen' function and the 'mail' function. Cpanel did email the log files a year or so ago. You might also look into a prgram called 'Logcheck' it will email the log files as well.

Similar Threads & Tags
Similar threads

  1. Cron Job, Run PHP script
    By bowers01 in forum New User Questions
    Replies: 2
    Last Post: 11-18-2010, 03:23 PM
  2. Replies: 3
    Last Post: 03-29-2007, 04:31 AM
  3. Shell script will not run via cron?
    By jols in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 11-20-2006, 07:16 AM
  4. cron jobs - how to run a simple php script
    By adentone in forum cPanel and WHM Discussions
    Replies: 7
    Last Post: 09-19-2005, 06:26 AM
  5. Script wont run in cron
    By Aerosmith in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 05-05-2002, 07:40 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube