Mobitest-agents hangs every night

Hi,

I have a private instance of webpagetest setup with 2 iphones using mobitest-agents (Google Code Archive - Long-term storage for Google Code Project Hosting.).
Jobs are sent to the devices (via a php script) every 15 minutes, and they report back to the webpagetest private instance. So far so good. The problem is that after about 12 hours, mostly during the night, they usually stop reporting, and the mobitest-agents just displays a white screen (the app hangs). The following tests just ends up in a very long queue, and I have to restart the apps on the test devices. I know that the sites that are tested is usually rebooted every night.

Anyone that have had the same problem, and managed to solve it?

Any input would be great :slight_smile:

Andy

The way I deal with it requires a jailbreak but has kept the devices as super-reliable:

  • cron job on the wpt server calls getTesters.php every 5 minutes and checks how long it has been since each phone last checked in
  • for any phone that hasn’t checked in in over 5 minutes the script ssh’s into the phone and runs a restart.sh script
  • the restart.sh script does a killall for all running instances of the mobitest agent and re-starts it

The jailbreak requirement is a pain but the script has made it so that the only time the phones need manual TLC is when an alert box for an OS update needs to be dismissed.

Thanks a lot Patrick!

Ive been really frustrated with this, but this is a solution I can live with. Right now Im restarting the apps every morning.

What’s the stability of the node agent talking to iOS Safari like?

Not sure yet, I haven’t had a chance to move my deployments over. We have some dev systems running it and they go offline periodically but I don’t know if that’s from iOS, the dev tools proxy or from the Node agent itself.

The Node.js agent still requires a jailbreak to clear the cache (and possibly a few other things) but there is no persistent agent that runs on the phone so presumably it should be a lot better.