Hi Dale,
If an unhandled error occurs, there is a routine that runs that checks if the site needs an upgrade and if so it redirects to the setup page. If an error occurs in the routine that checks the upgrade status then it will assume an upgrade is needed. So in some broad errors like if the database became unavailable or was timing out, it would redirect to setup.
I would review the log to see what errors were occuring that caused the redirect.
Hope it helps,
Joe