Jump to content

How to debug intermittent problem?


JRS

Recommended Posts

Hello,

I am looking for suggestions on how to try and debug this problem or determine if the problem is with the ISP's system.

I have a PHP/Mysql application:
ISP - it's on Linux, Mysql & PHP
Local - Win XP, Mysql & PHP

My application access a database of customers and list them. On the ISP site - sometimes it comes up blank. Other times it lists all the customers.

I assumed, there was something wrong in my code and copied the database locally to test on my development system. I was thinking the database was exposing a problem in my code. However, on the local site - I cannot get the application to fail. However, on the ISP site - it fails intermittently.

So I'm thinking perhaps I'm having problems with Mysql database connection - however, I'm not getting any error messages! I'm on a shared site - so I don't have administrator priveleges. I checked the log files that are available to me and they are all empty.

One other thing - I'm going to check are slow queries - but I've set limits on all my queries - so it shouldn't time out.

If anyone has any suggestions on how I can track this problem down - it would be much appreciated.
Thanks in advance
JRS
PS: I've set these ini settings
ini_set("display_errors", "1");
error_reporting(E_ALL);
Link to comment
Share on other sites

bump
ISP reported back Mysql server running normally without any problems. I have error report turned on - so my queries are ok - but sometimes I'm not getting data returned for my queries - other times all is fine - very confused.
JRS
Link to comment
Share on other sites

[!--quoteo(post=376892:date=May 25 2006, 12:29 AM:name=DapperDanMan)--][div class=\'quotetop\']QUOTE(DapperDanMan @ May 25 2006, 12:29 AM) [snapback]376892[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Just to double check, you cannot get the problem to repeat? In other words, you do a query and get the error, doing the exact same query again gets the correct information?

DapperDanMan
[/quote]
DapperDanMan,

I think I've found the problem - REGISTER_GLOBALS!!!!!!!! - it's on the ISP system - I've turned it on
my test system - still can't reproduce the problems - but making sure I'm not using the same variable names as GLOBAL variables - such as $_SESSION & $_GETs

To answer your question - the query never generated any errors only blank results. Sometimes
it would work - ie. I will get the list of the customers other times the customer list would come up blank.
At first I thought this due to bad queries that maybe be timimg out - but after putting some echo statements in the ISP system - some variables are not being set correctly (other times they are being set correctly) - very strange.

So I've decided to go through all my code to verify the $_SESSIONs & $_GETs to make sure the variable names are all different.

Thanks
JRS
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.