osclass / Osclass

With Osclass, get your own classifieds site for free. Build your own Osclass installation and start advertising real estate, jobs or whatever you want- in minutes!
http://osclass.org/
649 stars 343 forks source link

Admin panel: Add location fatal error #262

Closed ghost closed 12 years ago

ghost commented 12 years ago

Osclass 2.4 Action: Attempting to add the 'US' as a location via the admin panel, the query execution times out resulting in an error.

Error: Fatal error: Maximum execution time of 30 seconds exceeded .../DBCommandClass.php on line 1003

Local development / php.ini settings: max_execution_time = 30 memory_limit = 128M

Attempted two separate adds: First using default php.ini settings of 30/128. The second attempt I used 60/175. Both failed. Looking at the results of the second attempt, the insert got about half-way through the cities, stopping around Iowa. I assume this is because the insert statement hit the 60 second mark and stopped, leading me to believe the insert statement is attempting to populate the database using a singe insert statement rather than breaking it up in chunks?

ghost commented 12 years ago

Using the united states sql from http://geo.osclass.org/downloads/ I was able to add the 'US' without issue, in addition the insert took a few seconds to execute.

Note: I needed to edit the sql from geo.osclass because the column, fk_c_locale_code, has been removed from the 2.4 database.

conejoninja commented 12 years ago

Hi N00SA,

Sorry for your problem, but there's few we could do with that. max_execution_time is something that we probably could not change and therefor it could fail.

We plan to improve that area soon, and we already changed the .sql files on geo.osclass.org to remove the key . Thanks for the tip!