sqlite3 - php-cgi not always terminating and locking sqlite -


so having occasional issue detrimental system. small embedded arm system serving web pages using busybox's httpd. pages written in php , there sqlite3 backend.

what happens when accessing pages on system system start hanging. have found culprit seems php-cgi not terminating. happens , gets stuck open , causes sqlite3 database accessed locked causing every other process fail out trying access , slows crawl trying , failing access database. if continue browse pages build , pretty have this:

cpu: 34.2% usr 24.5% sys 41.0% nic  0.0% idle  0.0% io  0.0% irq  0.1% sirq load average: 10.99 3.36 1.31 23/131 2172   pid  ppid user     stat   vsz %vsz cpu %cpu command 1229  1208 root     s     107m 21.3   0 39.8 router -t /tmp/volatiletables.d 1224  1208 root     s    81852 15.9   0 14.4 messenger -t /tmp/volatiletable 2103  2102 root     r n  16740  3.2   0  2.1 /usr/bin/php-cgi all_stream.php 2106  2105 root     r n  16264  3.1   0  2.1 /usr/bin/php-cgi all_stream.php 2109  2108 root     r n  15612  3.0   0  2.1 /usr/bin/php-cgi all_stream.php 2112  2111 root     r n  15092  2.9   0  2.1 /usr/bin/php-cgi all_stream.php 2115  2114 root     r n  14708  2.8   0  2.1 /usr/bin/php-cgi all_stream.php 2118  2117 root     r n  14296  2.7   0  2.1 /usr/bin/php-cgi all_stream.php 2121  2120 root     r n  14036  2.7   0  2.1 /usr/bin/php-cgi all_stream.php 2124  2123 root     r n  13908  2.7   0  2.1 /usr/bin/php-cgi all_stream.php 2127  2126 root     r n  13908  2.7   0  2.1 /usr/bin/php-cgi all_stream.php 2131  2130 root     r n  13908  2.7   0  2.1 /usr/bin/php-cgi all_stream.php 2135  2134 root     r n  13776  2.6   0  2.1 /usr/bin/php-cgi all_stream.php 2142  2141 root     r n  13776  2.6   0  2.1 /usr/bin/php-cgi all_stream.php 2145  2144 root     r n  13776  2.6   0  2.1 /usr/bin/php-cgi all_stream.php 2151  2150 root     r n  13776  2.6   0  2.1 /usr/bin/php-cgi all_stream.php 2160  2159 root     r n  13332  2.5   0  2.1 /usr/bin/php-cgi all_stream.php 2163  2162 root     r n  12936  2.5   0  2.1 /usr/bin/php-cgi all_stream.php 2166  2165 root     r n  12780  2.4   0  2.1 /usr/bin/php-cgi all_stream.php 2154  2153 root     r n  13776  2.6   0  1.9 /usr/bin/php-cgi all_stream.php ~ #  

we once able load average way 50! messenger , router applications trying access database being locked php scripts.

any clues me how proceed? should using other method run php files? should maybe try lighttpd instead of busybox's httpd? there in php.ini script need change maybe? bad doing in php scripts themselves?

any clue in right direction helpful!


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -