Need to erase files from ftp server automatically

Discussion in 'Software' started by BrokenArrows, Dec 5, 2004.

  1. BrokenArrows

    BrokenArrows Sergeant

    Hi i have an ftp server where reports automatically get uploaded multiple times a day. After viewing these reports i have no need for them. As there is such a large amount of deleating to be done i wonder is there any perl or cgi program that will delete the specified files for me.

    Each report is created in its own folder named time and date of upload . There are three files in each report.

    So i need a script or something that can erase everything in the main report folder except one file which is index.html and images folder.

    Any help would be appreciated.
     
  2. Wookie

    Wookie Sergeant Major

    well the route I would take on this is when the file is automatically created have the software that does that write the file name and date created to a database such as mysql. Then each time a page is accessed have it look at that table and for file names x days old and delete anything older than a day, just grab all the records where datecreated older than one day then go through each name and issue a FTP delete command witht eh variable name as file name.
     
  3. BrokenArrows

    BrokenArrows Sergeant

    i like your thinking. although i dont run sql but i might have another way to do it with the same theory.

    Cool i just made senior member!! lol
     
  4. Colemanguy

    Colemanguy MajorGeek


MajorGeeks.Com Menu

Downloads All In One Tweaks \ Android \ Anti-Malware \ Anti-Virus \ Appearance \ Backup \ Browsers \ CD\DVD\Blu-Ray \ Covert Ops \ Drive Utilities \ Drivers \ Graphics \ Internet Tools \ Multimedia \ Networking \ Office Tools \ PC Games \ System Tools \ Mac/Apple/Ipad Downloads

Other News: Top Downloads \ News (Tech) \ Off Base (Other Websites News) \ Way Off Base (Offbeat Stories and Pics)

Social: Facebook \ YouTube \ Twitter \ Tumblr \ Pintrest \ RSS Feeds