apatel Posted August 31, 2011 Posted August 31, 2011 I am trying to run a Perl script that processes a series of files and then produces an HTML page with the results. Despite my newbieness, I somehow managed to get it working (including adding the necessary Perl modules to my home path on the server). I tested it first on the server giving three files as input and then giving it about 75. The first test worked flawlessly. The second with more input files did not. I know the script works because I tested it with the 75 files on my desktop (it takes a minute or two to run). It seems like there is an issue with the server processing the request; some kind of timeout issue. Are certain processes limited to a fixed amount of server time? Like I said, I don't have much experience with servers and web programming so maybe someone has some insight into what might be happening? Thanks for your time and help!
Byron Posted August 31, 2011 Posted August 31, 2011 Maximum execution time for php scripts is 30 seconds, so I'm guessing it's the same for cgi/perl scripts, although I'm not 100% sure about this.
apatel Posted September 1, 2011 Author Posted September 1, 2011 Maximum execution time for php scripts is 30 seconds, so I'm guessing it's the same for cgi/perl scripts, although I'm not 100% sure about this. Do you know any way around this?
Piotr GRD Posted September 1, 2011 Posted September 1, 2011 One thing you have to keep in mind is that while your desktop is only yours - shared webhhosts are shared between hundreds or thousands or even more users. And the question is: would you be happy if someone else would take too much server resources and makes it unavailable for you and other users? This is why there are various limits on shared webhosts. There is always some way around. One could save the list of files, split it into several parts and execute one after another (not manually, everything can be coded), but still this will be a bit unfair to other users of the server if this will affect them.
Krydos Posted September 1, 2011 Posted September 1, 2011 What causes the script to take so long? Is it because it causes massive server load, is it because it is waiting on some other slow server somewhere to respond, or is it some other reason? If it's massive server load then maybe you shouldn't be running that process on our servers anyways because it will likely get you suspended eventually.
Krydos Posted November 3, 2011 Posted November 3, 2011 @vol7ron Um, did you read the dates before you dug this thread up?
vol7ron Posted November 3, 2011 Posted November 3, 2011 @vol7ron Um, did you read the dates before you dug this thread up? @Krydos: 8/31/2011? The server has been up and down the past two months. yes.
Krydos Posted November 3, 2011 Posted November 3, 2011 I guess I just don't understand the logic of blaming some downtime today on someone who was running a script 65 days ago on a server with thousands of accounts.
vol7ron Posted November 3, 2011 Posted November 3, 2011 I guess I just don't understand the logic of blaming some downtime today on someone who was running a script 65 days ago on a server with thousands of accounts. Ahh see, you took it for fact, when it was intended to be humorous. Though, if the servers are set up right, it could be true. One person would be able to cause a crash, but I have a feeling ashoat would be on the banffensive in those cases.
Krydos Posted November 4, 2011 Posted November 4, 2011 Vol7ron, ten years ago when you dropped that toothpick and it bounced sightly to the left it began the butterfly effect that eventually lead to my sense of humour being surgically removed by an Iraqi man in a cave with a rusty bowie knife. I'l spare you the boring details, but know that it is your fault entirely.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now