Should I have it in etc/openser/openser.cfg OR? etc/openser/openserctlrc
I get the same error if I have in either of the files. If I have it in openser.cfg openser doesnt start. The message is syntax error where I have this setting. Do you know what I should do? thanks On 3/18/07, Berry Bartels <[EMAIL PROTECTED]> wrote:
Make sure you have the following lines in your configuration fifo="/tmp/ser_fifo" fifo_db_url="postgres://<username>:<password>@localhost/<database>" Replace <username>,<password> and <database> with the right values. Berry -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: zondag 18 maart 2007 4:23 To: [EMAIL PROTECTED] Cc: [email protected]; [email protected] Subject: Re: [Users] Re: openser + postgres starting problem Thanks a lot. It worked. This was from the latest 1.2 release from OpenSER. Maybe it should be fixed there in the release? I still get this error: Can you tell what I should do? /usr/local/sbin/openserctl moni database engine 'PGSQL' loaded Control engine 'FIFO' loaded ERROR: Error opening OpenSER's FIFO FIFO ERROR: Make sure you have line 'fifo=FIFO' in your config thanks a lot On 3/17/07, Berry Bartels <[EMAIL PROTECTED]> wrote: > There was a ' to many on line 19 > PGSQL="$TOOLPATH"' -> PGSQL="$TOOLPATH" > > Try this one > > # > # $Id: openserctl.pgsql 1827 2007-03-12 15:22:53Z bogdan_iancu $ # # sc: > openser control; tool for maintaining openser # > #=================================================================== > > ##### ----------------------------------------------- ##### ### PGSQL > specific variables and functions # > > ##### ----------------------------------------------- ##### ### load SQL > base # if [ -f "$MYLIBDIR/openserctl.sqlbase" ]; then > . "$MYLIBDIR/openserctl.sqlbase" > else > echo "Cannot load SQL core functions '$MYLIBDIR/openserctl.sqlbase' > - exiting ..." > exit -1 > fi > > ##### ----------------------------------------------- ##### ### binaries if > [ -z "$PGSQL" ] ; then > locate_tool psql > if [ -z "$TOOLPATH" ] ; then > echo "error: 'psql' tool not found: set PGSQL variable to > correct tool path" > exit > fi > PGSQL="$TOOLPATH" > fi > > ##### ----------------------------------------------- ##### ### variables > > # type of sql tables > if [ -z "$TABLE_TYPE" ]; then > TABLE_TYPE="" > fi > > # input: sql query, optional pgsql command-line params > pgsql_query() { > # if password not yet queried, query it now > prompt_pw "PgSql password for user '[EMAIL PROTECTED]'" > mecho "pgsql_query: $PGSQL $2 -A -q -t -P fieldsep=' ' -h $DBHOST > -U $DBRWUSER $DBNAME -c '$1'" > PGPASSWORD="$DBRWPW" $PGSQL $2 \ > -A -q -t \ > -P fieldsep=" " \ > -h $DBHOST \ > -U $DBRWUSER \ > $DBNAME \ > -c "$1" > } > > # input: sql query, optional pgsql command-line params > pgsql_ro_query() { > mdbg "pgsql_ro_query: $PGSQL $2 -h $DBHOST -U $DBROUSER $DBNAME -c > '$1'" > PGPASSWORD="$DBROPW" $PGSQL $2 \ > -h $DBHOST \ > -U $DBROUSER \ > $DBNAME \ > -c "$1" > } > > DBCMD=pgsql_query > DBROCMD=pgsql_ro_query > #DBRAWPARAMS="-A -q -t -P fieldsep=\" \"" > DBRAWPARAMS="-A -q -t" > > Kind regards, > > Berry Bartels > > > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf > Of [EMAIL PROTECTED] > Sent: zondag 18 maart 2007 0:23 > To: [email protected] > Subject: [Users] Re: openser + postgres starting problem > > Here is the full configuration file: > > more /usr/local/lib/openser/openserctl/openserctl.pgsql > # > # $Id: openserctl.pgsql 1827 2007-03-12 15:22:53Z bogdan_iancu $ > # > # sc: openser control; tool for maintaining openser > # > #=================================================================== > > ##### ----------------------------------------------- ##### > ### PGSQL specific variables and functions > # > > ##### ----------------------------------------------- ##### > ### load SQL base > # > if [ -f "$MYLIBDIR/openserctl.sqlbase" ]; then > . "$MYLIBDIR/openserctl.sqlbase" > else > echo "Cannot load SQL core functions > '$MYLIBDIR/openserctl.sqlbase' - exiting ..." > exit -1 > fi > > ##### ----------------------------------------------- ##### > ### binaries > if [ -z "$PGSQL" ] ; then > locate_tool psql > if [ -z "$TOOLPATH" ] ; then > echo "error: 'psql' tool not found: set PGSQL variable > to correct tool path" > exit > fi > PGSQL="$TOOLPATH"' > fi > > ##### ----------------------------------------------- ##### > ### variables > > # type of sql tables > if [ -z "$TABLE_TYPE" ]; then > TABLE_TYPE="" > fi > > # input: sql query, optional pgsql command-line params > pgsql_query() { > # if password not yet queried, query it now > prompt_pw "PgSql password for user '[EMAIL PROTECTED]'" > mecho "pgsql_query: $PGSQL $2 -A -q -t -P fieldsep=' ' -h > $DBHOST -U $DBRWUSER $DBNAME -c '$1' > " > PGPASSWORD="$DBRWPW" $PGSQL $2 \ > -A -q -t \ > -P fieldsep=" " \ > -h $DBHOST \ > -U $DBRWUSER \ > $DBNAME \ > -c "$1" > } > > # input: sql query, optional pgsql command-line params > pgsql_ro_query() { > mdbg "pgsql_ro_query: $PGSQL $2 -h $DBHOST -U $DBROUSER $DBNAME -c > '$1'" > PGPASSWORD="$DBROPW" $PGSQL $2 \ > -h $DBHOST \ > -U $DBROUSER \ > $DBNAME \ > -c "$1" > } > > DBCMD=pgsql_query > DBROCMD=pgsql_ro_query > #DBRAWPARAMS="-A -q -t -P fieldsep=\" \"" > DBRAWPARAMS="-A -q -t" > > thanks > > > On 3/17/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Hi > > If I compiled openser with postgres module and I get the following errors: > > > > > > [EMAIL PROTECTED]|~|16:34:34] /usr/local/sbin/openserctl moni > > > > /usr/local/lib/openser/openserctl/openserctl.pgsql: line 57: > > unexpected EOF while looking for matching `'' > > /usr/local/lib/openser/openserctl/openserctl.pgsql: line 70: syntax > > error: unexpected end of file > > database engine 'PGSQL' loaded > > Control engine 'FIFO' loaded > > ERROR: Error opening OpenSER's FIFO FIFO > > ERROR: Make sure you have line 'fifo=FIFO' in your config > > > > > > The line 57 3rd line in here: > > > > # input: sql query, optional pgsql command-line params > > pgsql_ro_query() { > > mdbg "pgsql_ro_query: $PGSQL $2 -h $DBHOST -U $DBROUSER $DBNAME -c > '$1'" > > PGPASSWORD="$DBROPW" $PGSQL $2 \ > > -h $DBHOST \ > > -U $DBROUSER \ > > $DBNAME \ > > -c "$1" > > } > > > > > > How to fix this? > > thanks > > > > _______________________________________________ > Users mailing list > [email protected] > http://openser.org/cgi-bin/mailman/listinfo/users >
_______________________________________________ Users mailing list [email protected] http://openser.org/cgi-bin/mailman/listinfo/users
