need advice to clean temp files on dedicated server?
i have a website that creates reports (pdf files). these are temporary files and need to be removed. i wrote an exe that loops infinetaly and erases temp files older then 15 minutes. the problem is that when my program is running, the cpu usage goes to 100% and the website almost goes to a hold.
please sugest other ways to erase temp files without killing the cpu.
i had 2 ideas:
1) check for old temp files only when a user logs in
2) write a batch file that calls the exe to remove temp files. i havent written batch files with loops in a long time and don't know how it will effect cpu usage.
thank you
how do you run a scheduled task?
Maybe try to create batch file or VBS and run is as a scheduled task versus a continuous loop. Run is once per hour or so or if your site has alot of traffic and your resources are low run the script during non-peak hours, I.e. midnight or so.
I will give a "How to create a Facebook Fan Page" pdf report for $5! On Fiverr
how to write a report pdf
how to write a report pdf
how to write a report pdf
No comments:
Post a Comment