Dear Alexey From your words I gather that you are running a threaded MPM which is a problem with rivet 2.x (the error you're showing at the end of the message is most probably due to an invalid threaded MPM)
Threaded MPMs are supported by rivet 3.0 which is due to be released in a month or two, you can download it checking out our repository On 09/11/2017 11:56 AM, Alexey Noskov wrote:
Dear all, I develop a web service https://gsdr.gq. SQLite/Spatialite is used as database. Because of multiple massive requests from time to time. SQL requests are interrupted with "malformed database schema". As I understand, Sqlite by default uses serialized mode for multi threading support. (More information about threading in SQLite can be found here https://sqlite.org/threadsafe.html ) Probably, this is the reason of the "malformed" (about every 20-40th SQL request is interrupted with this error). I would like to try to switch SQLite to multi-thread mode and use: /RivetServerConf SeparateVirtualInterps yes// //RivetServerConf SeparateChannels yes/ This allows to use independent database connections for each child and will hopefully resolve as error.
As far as I understand SQLite is not like Postgresql or Mysql in this respect, you're opening a file, not connecting to a service in a client server fashion (if I'm wrong and SQLite has now this ability forgive my ignorance). I'm afraid you're having these "malformed database schema" errors because you have multiple clients trying to access non protected data structures of the SQLite db
Currently I use /RivetServerConf ServerInitScript "source /home/local/rivetfiles/initscript.tcl"/.
SeparateVirtualInterps creates interpreters for each virtual host, this has nothing to do with threads. But even if you switched to the 'prefork' MPM, thus eliminating any multithreading, you would end up with a set of child processes running each an interpreter (one interpreter per virtual host if SeparateVirtualInterps On) and you would need to synchronize them
When I use the following configuration: /RivetServerConf ChildInitScript "source /home/local/rivetfiles/initscript.tcl"// //RivetServerConf SeparateVirtualInterps yes// //RivetServerConf SeparateChannels yes/ Apache rises this error: [...] I use Debian Jessie ARM architecture ( aarch64). rivet-2.3.3 built from source. Apache 2.4.10 and SQLite 3.8.7.1 from repository.
the errors that eventually result in a segmentation fault are quite certainly due to a threaded MPM. If I understand correctly then enable prefork on Debian with the command a2enmod mpm_prefork
I tried different configurations and detected that SEGTERM appeared because of /RivetServerConf ChildInitScript "source /home/local/rivetfiles/initscript.tcl"// / Moreover, I have a problem even with current working configuration (//RivetServerConf ChildInitScript ...,/SeparateVirtualInterps //no/). From time to time (about after day of work) I have an error related to /can not find channel named "stdout"/ Thus, I use cron to restart the apache ones an hour. Thank you and sorry for a long mail, I am not sure that this should be reported as a bug, because I relatively new user of rivet, Kind regards, Alexey
please let us know if my words can be of any help -- Massimo Il 5xmille a favore dell’Università di Parma (indicando il codice fiscale 00308780345) è un gesto tanto semplice quanto importante per creare nuove opportunità di lavoro per giovani di talento nell'ambito della ricerca scientifica. --------------------------------------------------------------------- To unsubscribe, e-mail: rivet-dev-unsubscr...@tcl.apache.org For additional commands, e-mail: rivet-dev-h...@tcl.apache.org