Hi, I want to know what would be the best GUEST_TIMEOUT? I have a site with lots of visits. Sometimes SQL enter the duplicate entry for Active Guest table and site gives a session error and stop working. I have set it to too high and it ended up with SQL high CPU usage. Can anyone please help me in defining that value?
Can you explain how you're managing sessions? I'm assuming that you are using a database instead of the file system, but how is the application handling them, and what it the structure of your guest table?
Its just a general contast.php /** * Database Table Constants - these constants * hold the names of all the database tables used * in the script. */ define("TBL_USERS", "users"); define("TBL_ACTIVE_USERS", "active_users"); define("TBL_ACTIVE_GUESTS", "active_guests"); define("TBL_BANNED_USERS", "banned_users"); /** * Special Names and Level Constants - the admin * page will only be accessible to the user with * the admin name and also to those users at the * admin user level. Feel free to change the names * and level constants as you see fit, you may * also add additional level specifications. * Levels must be digits between 0-9. */ define("ADMIN_NAME", "admin"); define("GUEST_NAME", "Guest"); define("ADMIN_LEVEL", 9); define("USER_LEVEL", 1); define("GUEST_LEVEL", 0); /** * This boolean constant controls whether or * not the script keeps track of active users * and active guests who are visiting the site. */ define("TRACK_VISITORS", true); /** * Timeout Constants - these constants refer to * the maximum amount of time (in minutes) after * their last page fresh that a user and guest * are still considered active visitors. */ define("USER_TIMEOUT", 10); define("GUEST_TIMEOUT", 5); <=== that value I am talking about