I have a PHP script which has to make some posts on wordpress blogs, it runs with a cron job every 5 minutes. I have a dedicated server. Sometimes the script works well but sometimes after a time of running it just go 0% CPU consumption and 0.1% RAM consumption and stays like that forever, I have to manually kill it. I know that it never ends because if it went to 0% CPU the last line of code in the script is never executed. Earlier this script had to post 150 articles and it did well, now I have reduced to 20 and it does not work well. Can it be a problem with server or with the script?