sqlrelay-discussion Mailing List for SQL Relay (Page 26)
Brought to you by:
mused
You can subscribe to this list here.
| 2005 |
Jan
|
Feb
(20) |
Mar
(27) |
Apr
(17) |
May
(32) |
Jun
(45) |
Jul
(49) |
Aug
(68) |
Sep
(44) |
Oct
(29) |
Nov
(64) |
Dec
(25) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2006 |
Jan
(61) |
Feb
(22) |
Mar
(25) |
Apr
(31) |
May
(18) |
Jun
(28) |
Jul
(19) |
Aug
(16) |
Sep
(8) |
Oct
(17) |
Nov
(32) |
Dec
(4) |
| 2007 |
Jan
(20) |
Feb
(25) |
Mar
(5) |
Apr
(12) |
May
(11) |
Jun
(18) |
Jul
(16) |
Aug
(22) |
Sep
(37) |
Oct
(20) |
Nov
(11) |
Dec
(2) |
| 2008 |
Jan
(11) |
Feb
(33) |
Mar
(12) |
Apr
(18) |
May
(22) |
Jun
(31) |
Jul
(23) |
Aug
(6) |
Sep
|
Oct
(10) |
Nov
(22) |
Dec
|
| 2009 |
Jan
(12) |
Feb
(8) |
Mar
(11) |
Apr
(20) |
May
(18) |
Jun
(7) |
Jul
(27) |
Aug
(2) |
Sep
(10) |
Oct
(5) |
Nov
(2) |
Dec
(1) |
| 2010 |
Jan
(11) |
Feb
(18) |
Mar
(10) |
Apr
(28) |
May
(28) |
Jun
|
Jul
(27) |
Aug
(9) |
Sep
(21) |
Oct
(2) |
Nov
(2) |
Dec
(11) |
| 2011 |
Jan
|
Feb
(2) |
Mar
(4) |
Apr
(2) |
May
(2) |
Jun
(44) |
Jul
(9) |
Aug
(2) |
Sep
(12) |
Oct
(7) |
Nov
(11) |
Dec
(7) |
| 2012 |
Jan
(5) |
Feb
|
Mar
(9) |
Apr
(9) |
May
(12) |
Jun
|
Jul
(13) |
Aug
(3) |
Sep
(3) |
Oct
(1) |
Nov
(1) |
Dec
(10) |
| 2013 |
Jan
(21) |
Feb
(3) |
Mar
(4) |
Apr
|
May
(3) |
Jun
(2) |
Jul
(3) |
Aug
(3) |
Sep
(3) |
Oct
|
Nov
|
Dec
(4) |
| 2014 |
Jan
(7) |
Feb
|
Mar
(1) |
Apr
|
May
(2) |
Jun
|
Jul
(4) |
Aug
(2) |
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2016 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2017 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2021 |
Jan
|
Feb
|
Mar
|
Apr
(3) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2022 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: David M. <dav...@fi...> - 2008-05-21 03:36:50
|
It looks like the scaler really doesn't support -localstatedir. It should but it doesn't. A quick fix would be to edit src/scaler/scaler.C and replace instances of TMP_DIR with whatever directory you want to use. Then rebuild and reinstall. I'll fix this in the next release. David Muse dav...@fi... On Fri, 2008-05-16 at 23:35 -0700, Tim Piatenko wrote: > Hi folks, > > I have just successfully setup SQLRelay to connect to a MS SQL db, but > all my efforts are being spoiled by the fact that I can't seem to be > able to run sqlr-scaler ... The problem is that I don't have write > permissions to /var/cache/sqlrelay/tmp/, which is where the scaler > looks for the sqlr-listener-x file. I'm using the "sqlr-start -id ID > -config CONFIGFILE [-localstatedir LOCALSTATEDIR]" form to start the > listener and the connection daemons, and they work fine. I have them > running and writing tmp files as well as debugging output in my home > dir. So when I try to run "query -id ID -config MYCONFIG select ...", > it just hangs forever. I looked in the debug files and saw the > following: > > tim@xyz debug: cat sqlr-listener.12775 > > 05/16/2008 22:57:44 PST listener [12775] : creating shared memory and semaphores > > ... blah blah blah ... > > 05/16/2008 23:01:53 PST listener [12775] : forked a child: 12814 > > 05/16/2008 23:01:53 PST listener [12775] : waiting for client connection... > > tim@xyz debug: cat sqlr-listener.12814 > > 05/16/2008 23:01:53 PST listener [12814] : getting authentication... > > 05/16/2008 23:01:53 PST listener [12814] : listener-based > authentication succeeded > > 05/16/2008 23:01:53 PST listener [12814] : incrementing session count... > > and then nothing ... it never gets incremented. > > Is there really nothing I can do? I can't believe that there's a > "-localstatedir" option for everything but the scaler. When I try to > run the scaler, I get: > > sqlr-scaler error: > The file /var/cache/sqlrelay/tmp/sqlr-listener-sql1 was not found. > This usually means that the sqlr-listener is not running. > The sqlr-listener must be running for the sqlr-scaler to start. > > Is there no way to tell it where my local tmp file is? > > Thanks! > > -Tim > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Sqlrelay-discussion mailing list > Sql...@li... > https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion > > > __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |
|
From: David M. <dav...@fi...> - 2008-05-21 03:10:02
|
The package installation should have created /var/sqlrelay/tmp and the necessary subdirectories. I'm surprised that it didn't. They would have been root-owned, but should have 777 permissions. Make sure that the following directories exist and have 777 perms: /var/sqlrelay/tmp /var/sqlrelay/tmp/ipc /var/sqlrelay/tmp/pids /var/sqlrelay/tmp/sockets /var/sqlrelay/cache /var/sqlrelay/debug If they already exist, remove any existing files in them. If you ran sqlrelay as root once, then try to run it as a different user afterward, there could still be a file out there owned by root that can't be overwritten or opened by the new user. That should take care of it. Hope this helps. David dav...@fi... On Tue, 2008-05-20 at 17:42 +0200, Anthony Gardner wrote: > I sent this under yahoo but have just seen in the archives that it's > totally HTML. So, sorry about that. Let's see how gmail copes!! > > Using the following sqlrelay.conf file ..... > <?xml version="1.0"?> > <!DOCTYPE instances SYSTEM "sqlrelay.dtd"> > <instances> > > <instance id="sqlitetest" > port="9000" > socket="/tmp/sqlitetest.socket" > dbase="sqlite" > connections="3" > maxconnections="5" > maxqueuelength="0" > growby="1" > ttl="60" > endofsession="commit" > sessiontimeout="600" > runasuser="anthony" > runasgroup="anthony" > cursors="5" > authtier="listener" > handoff="pass" > debug="listener_and_connection"> > <users> > <!-- user user="sqlitetest" password="sqlitetest"/ --> > <user user="" password=""/> > </users> > <connections> > <connection connectionid="sqlitetest" > string="db=/home/anthony/Development/sqlrelay/sqlrelay_test.db" > metric="1"/> > </connections> > </instance> > > </instances> > > I get the following output from running .... sudo sqlr-start -id > sqlitetest -config sqlrelay.conf > > > Starting listener: > sqlr-listener-debug -id sqlitetest -config sqlrelay.conf & > Debugging to: /var/cache/sqlrelay/debug/sqlr-listener.10989 > Could not open: /var/cache/sqlrelay/tmp/ipc/sqlitetest > Make sure that the file and directory are readable and writable. > > unsuccessful completion > > Starting 3 connections to sqlitetest : > sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest > -config sqlrelay.conf & > Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10991 > > sqlr-connection error: > The pid > file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest was not > found. > This usually means that the sqlr-listener > is not running. > The sqlr-listener must be running for the sqlr-connection to > start. > > sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest > -config sqlrelay.conf & > Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10996 > > sqlr-connection error: > The pid > file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest was not > found. > This usually means that the sqlr-listener > is not running. > The sqlr-listener must be running for the sqlr-connection to > start. > > sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest > -config sqlrelay.conf & > Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10998 > > sqlr-connection error: > The pid > file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest was not > found. > This usually means that the sqlr-listener > is not running. > The sqlr-listener must be running for the sqlr-connection to > start. > > > Starting cache manager: > sqlr-cachemanager > Warning: using default id. > > > Thanks to MP3.com for sponsoring: > Clustered/Replicated database support. > Perl API. > Thanks to FeedLounge for sponsoring: > Query routing and filtering. > > /var/cache/sqlrelay/tmp/ipc/sqlitetest was automatically created by > sqlrelay > > I manually created pids and sockets directory > /var/cache/sqlrelay/tmp/pids > /var/cache/sqlrelay/tmp/sockets > > I have changed permissions to 777 from /var/cache/sqlrelay downwards > > SQL Relay version: 0.38 installed from Ubuntu binaries on 8.04 > > Any pointers would be great. > > -Ants __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ Sqlrelay-discussion mailing list Sql...@li... https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |
|
From: Anthony G. <ant...@gm...> - 2008-05-20 15:42:13
|
I sent this under yahoo but have just seen in the archives that it's totally
HTML. So, sorry about that. Let's see how gmail copes!!
Using the following sqlrelay.conf file .....
<?xml version="1.0"?>
<!DOCTYPE instances SYSTEM "sqlrelay.dtd">
<instances>
<instance id="sqlitetest"
port="9000"
socket="/tmp/sqlitetest.socket"
dbase="sqlite"
connections="3"
maxconnections="5"
maxqueuelength="0"
growby="1"
ttl="60"
endofsession="commit"
sessiontimeout="600"
runasuser="anthony"
runasgroup="anthony"
cursors="5"
authtier="listener"
handoff="pass"
debug="listener_and_connection">
<users>
<!-- user user="sqlitetest" password="sqlitetest"/ -->
<user user="" password=""/>
</users>
<connections>
<connection connectionid="sqlitetest"
string="db=/home/anthony/Development/sqlrelay/sqlrelay_test.db" metric="1"/>
</connections>
</instance>
</instances>
I get the following output from running .... sudo sqlr-start -id sqlitetest
-config sqlrelay.conf
Starting listener:
sqlr-listener-debug -id sqlitetest -config sqlrelay.conf &
Debugging to: /var/cache/sqlrelay/debug/sqlr-listener.10989
Could not open: /var/cache/sqlrelay/tmp/ipc/sqlitetest
Make sure that the file and directory are readable and writable.
unsuccessful completion
Starting 3 connections to sqlitetest :
sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest
-config sqlrelay.conf &
Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10991
sqlr-connection error:
The pid file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest
was not found.
This usually means that the sqlr-listener
is not running.
The sqlr-listener must be running for the sqlr-connection to start.
sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest
-config sqlrelay.conf &
Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10996
sqlr-connection error:
The pid file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest
was not found.
This usually means that the sqlr-listener
is not running.
The sqlr-listener must be running for the sqlr-connection to start.
sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest
-config sqlrelay.conf &
Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10998
sqlr-connection error:
The pid file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest
was not found.
This usually means that the sqlr-listener
is not running.
The sqlr-listener must be running for the sqlr-connection to start.
Starting cache manager:
sqlr-cachemanager
Warning: using default id.
Thanks to MP3.com for sponsoring:
Clustered/Replicated database support.
Perl API.
Thanks to FeedLounge for sponsoring:
Query routing and filtering.
/var/cache/sqlrelay/tmp/ipc/sqlitetest was automatically created by sqlrelay
I manually created pids and sockets directory
/var/cache/sqlrelay/tmp/pids
/var/cache/sqlrelay/tmp/sockets
I have changed permissions to 777 from /var/cache/sqlrelay downwards
SQL Relay version: 0.38 installed from Ubuntu binaries on 8.04
Any pointers would be great.
-Ants
|
|
From: Anthony G. <cyc...@ya...> - 2008-05-20 12:16:30
|
<table cellspacing='0' cellpadding='0' border='0' ><tr><td style='font: inherit;'>Using the following sqlrelay.conf file .....<br><?xml version="1.0"?><br><!DOCTYPE instances SYSTEM "sqlrelay.dtd"><br><instances><br><br> <instance id="sqlitetest"<br> port="9000"<br> socket="/tmp/sqlitetest.socket"<br> dbase="sqlite"<br> connections="3"<br> maxconnections="5"<br> maxqueuelength="0"<br> growby="1"<br> ttl="60"<br> endofsession="commit"<br> sessiontimeout="600"<br> runasuser="anthony"<br> runasgroup="anthony"<br> cursors="5"<br> authtier="listener"<br> handoff="pass"<br> debug="listener_and_connection"><br> <users><br> <!-- user user="sqlitetest" password="sqlitetest"/ --><br> <user user="" password=""/><br> </users><br> <connections><br> <connection connectionid="sqlitetest" string="db=/home/anthony/Development/sqlrelay/sqlrelay_test.db" metric="1"/><br> </connections><br> </instance><br><br></instances><br><br>I get the following output from running .... sudo sqlr-start -id sqlitetest -config sqlrelay.conf<br><br><br>Starting listener:<br> sqlr-listener-debug -id sqlitetest -config sqlrelay.conf &<br>Debugging to: /var/cache/sqlrelay/debug/sqlr-listener.10989<br>Could not open: /var/cache/sqlrelay/tmp/ipc/sqlitetest<br>Make sure that the file and directory are readable and writable.<br><br>unsuccessful completion<br><br>Starting 3 connections to sqlitetest :<br> sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest -config sqlrelay.conf &<br>Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10991<br><br>sqlr-connection error:<br> The pid file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest was not found.<br> This usually means that the sqlr-listener <br>is not running.<br> The sqlr-listener must be running for the sqlr-connection to start.<br><br> sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest -config sqlrelay.conf &<br>Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10996<br><br>sqlr-connection error:<br> The pid file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest was not found.<br> This usually means that the sqlr-listener <br>is not running.<br> The sqlr-listener must be running for the sqlr-connection to start.<br><br> sqlr-connection-sqlite-debug -id sqlitetest -connectionid sqlitetest -config sqlrelay.conf &<br>Debugging to: /var/cache/sqlrelay/debug/sqlr-connection.10998<br><br>sqlr-connection error:<br> The pid file /var/cache/sqlrelay/tmp/pids/sqlr-listener-sqlitetest was not found.<br> This usually means that the sqlr-listener <br>is not running.<br> The sqlr-listener must be running for the sqlr-connection to start.<br><br><br>Starting cache manager:<br> sqlr-cachemanager<br>Warning: using default id.<br><br><br>Thanks to MP3.com for sponsoring: <br> Clustered/Replicated database support.<br> Perl API.<br>Thanks to FeedLounge for sponsoring: <br> Query routing and filtering.<br><br>/var/cache/sqlrelay/tmp/ipc/sqlitetest was automatically created by sqlrelay <br><br>I manually created pids and sockets directory<br>/var/cache/sqlrelay/tmp/pids<br>/var/cache/sqlrelay/tmp/sockets<br><br>I have changed permissions to 777 from /var/cache/sqlrelay downwards<br><br>SQL Relay version: 0.38 installed from Ubuntu binaries on 8.04<br><br>Any pointers would be great.<br><br>-Ants<br><br>Disclaimer: Technically speaking, I am always wrong!</td></tr></table><br> <hr size=1> Sent from <a href="http://us.rd.yahoo.com/mailuk/taglines/isp/control/*http://us.rd.yahoo.com/evt=52418/*http://uk.docs.yahoo.com/nowyoucan.html" target=_blank>Yahoo! Mail</a>. <br> A Smarter Email. |
|
From: David M. <dav...@fi...> - 2008-05-20 03:51:16
|
It appears that the build is finding an older version of rudiments. You may need to install the most current version of the rudiments library. Or, if it's already installed, then you'll need to remove any older versions. David Muse dav...@fi... On Fri, 2008-05-09 at 08:36 +0200, Sebastien BROCHET wrote: > Hello, > > I can't build sqlrelay 0.39.4 on my solaris 10 box. > > # gmake > gmake -C src all > gmake[1]: Entering directory `/export/home/seb/sqlrelay-0.39.4/src' > gmake -C util all > gmake[2]: Entering directory `/export/home/seb/sqlrelay-0.39.4/src/util' > /bin/sh ../../libtool --mode=compile g++ -Wall -pipe -pthread > -DTMP_DIR=\"/usr/local/firstworks/var/sqlrelay/tmp\" > -DDEBUG_DIR=\"/usr/local/firstworks/var/sqlrelay/debug\" > -DDEFAULT_CONFIG_FILE=\"/usr/local/firstworks/etc/sqlrelay.conf\" -I./ > -I../../ -I../../src/common -I/usr/pkg/include -pthread > -I/usr/sfw/include -c cmdline.C -o cmdline.lo > g++ -Wall -pipe -pthread > -DTMP_DIR=\"/usr/local/firstworks/var/sqlrelay/tmp\" > -DDEBUG_DIR=\"/usr/local/firstworks/var/sqlrelay/debug\" > -DDEFAULT_CONFIG_FILE=\"/usr/local/firstworks/etc/sqlrelay.conf\" -I./ > -I../../ -I../../src/common -I/usr/pkg/include -pthread > -I/usr/sfw/include -c cmdline.C -fPIC -DPIC -o .libs/cmdline.o > g++: unrecognized option `-pthread' > g++: unrecognized option `-pthread' > cmdline.C: In member function `void cmdline::setId()': > cmdline.C:20: error: `getValue' undeclared (first use this function) > cmdline.C:20: error: (Each undeclared identifier is reported only once > for each function it appears in.) > cmdline.C: In member function `void cmdline::setConfig()': > cmdline.C:30: error: `getValue' undeclared (first use this function) > cmdline.C: In member function `void cmdline::setLocalStateDir()': > cmdline.C:39: error: `getValue' undeclared (first use this function) > gmake[2]: *** [cmdline.lo] Error 1 > gmake[2]: Leaving directory `/export/home/seb/sqlrelay-0.39.4/src/util' > gmake[1]: *** [all] Error 2 > gmake[1]: Leaving directory `/export/home/seb/sqlrelay-0.39.4/src' > gmake: *** [all] Error 2 > > Any ideas ? > > Séb. > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Sqlrelay-discussion mailing list > Sql...@li... > https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion > > > __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |
|
From: Tim P. <ti...@gm...> - 2008-05-17 06:35:27
|
Hi folks, I have just successfully setup SQLRelay to connect to a MS SQL db, but all my efforts are being spoiled by the fact that I can't seem to be able to run sqlr-scaler ... The problem is that I don't have write permissions to /var/cache/sqlrelay/tmp/, which is where the scaler looks for the sqlr-listener-x file. I'm using the "sqlr-start -id ID -config CONFIGFILE [-localstatedir LOCALSTATEDIR]" form to start the listener and the connection daemons, and they work fine. I have them running and writing tmp files as well as debugging output in my home dir. So when I try to run "query -id ID -config MYCONFIG select ...", it just hangs forever. I looked in the debug files and saw the following: tim@xyz debug: cat sqlr-listener.12775 05/16/2008 22:57:44 PST listener [12775] : creating shared memory and semaphores ... blah blah blah ... 05/16/2008 23:01:53 PST listener [12775] : forked a child: 12814 05/16/2008 23:01:53 PST listener [12775] : waiting for client connection... tim@xyz debug: cat sqlr-listener.12814 05/16/2008 23:01:53 PST listener [12814] : getting authentication... 05/16/2008 23:01:53 PST listener [12814] : listener-based authentication succeeded 05/16/2008 23:01:53 PST listener [12814] : incrementing session count... and then nothing ... it never gets incremented. Is there really nothing I can do? I can't believe that there's a "-localstatedir" option for everything but the scaler. When I try to run the scaler, I get: sqlr-scaler error: The file /var/cache/sqlrelay/tmp/sqlr-listener-sql1 was not found. This usually means that the sqlr-listener is not running. The sqlr-listener must be running for the sqlr-scaler to start. Is there no way to tell it where my local tmp file is? Thanks! -Tim |
|
From: Jonathan K. <jka...@vo...> - 2008-05-09 19:39:27
|
Hi,
(This is a resend because I didn't see it show up in the mailing list.)
I'm running the latest release of SQLRelay, 0.39.4, which is talking to an Oracle database.
I've looked at the archives of the mailing list and haven't seen my issue mentioned before.
I have a problem with the python db api 2.0-esque bindings, PySQLRDB; cur.rowcount always returns 0 (cur.rowCount() from PySQLClient works fine).
>>> from SQLRelay import PySQLRDB
>>> con = PySQLRDB.connect('localhost', 9200, '', 'username', 'password', 0, 1)
>>> cur = con.cursor()
>>> cur.execute("select 1 from dual")
>>> cur.rowcount
0
>>> cur.fetchall()
[[Decimal("1")]]
>>> cur.rowcount
0
>>> from SQLRelay import PySQLRClient
>>> con = PySQLRClient.sqlrconnection('localhost', 9200, '', 'username', 'password', 0, 1)
>>> cur = PySQLRClient.sqlrcursor(con)
>>> cur.sendQuery("select 1 from dual")
1
>>> cur.rowCount()
1
I looked at PySQLRDB.py, PySQLRClient.py, and CSQLRelay.C.
In rowCount(), in PySQLRClient.py, the value returned comes from CSQLRelay.rowCount(self.cursor), which comes from ((sqlrcursor *)sqlrcur)->rowCount().
In execute(), in PySQLRDB.py, rowcount is assigned to either CSQLRelay.totalRows(self.cursor) or CSQLRelay.affectedRows(self.cursor), which come from ((sqlrcursor *)sqlrcur)->totalRows() or ((sqlrcursor *)sqlrcur)->affectedRows(), respectively.
So, rowCount returns 1, and both totalRows and affectedRows return 0.
Does anyone know why cur.rowcount, from PySQLRDB.py, would always return 0?
Thank you,
Jonathan Kaczynski
|
|
From: Sebastien B. <seb...@do...> - 2008-05-09 06:36:16
|
Hello, I can't build sqlrelay 0.39.4 on my solaris 10 box. # gmake gmake -C src all gmake[1]: Entering directory `/export/home/seb/sqlrelay-0.39.4/src' gmake -C util all gmake[2]: Entering directory `/export/home/seb/sqlrelay-0.39.4/src/util' /bin/sh ../../libtool --mode=compile g++ -Wall -pipe -pthread -DTMP_DIR=\"/usr/local/firstworks/var/sqlrelay/tmp\" -DDEBUG_DIR=\"/usr/local/firstworks/var/sqlrelay/debug\" -DDEFAULT_CONFIG_FILE=\"/usr/local/firstworks/etc/sqlrelay.conf\" -I./ -I../../ -I../../src/common -I/usr/pkg/include -pthread -I/usr/sfw/include -c cmdline.C -o cmdline.lo g++ -Wall -pipe -pthread -DTMP_DIR=\"/usr/local/firstworks/var/sqlrelay/tmp\" -DDEBUG_DIR=\"/usr/local/firstworks/var/sqlrelay/debug\" -DDEFAULT_CONFIG_FILE=\"/usr/local/firstworks/etc/sqlrelay.conf\" -I./ -I../../ -I../../src/common -I/usr/pkg/include -pthread -I/usr/sfw/include -c cmdline.C -fPIC -DPIC -o .libs/cmdline.o g++: unrecognized option `-pthread' g++: unrecognized option `-pthread' cmdline.C: In member function `void cmdline::setId()': cmdline.C:20: error: `getValue' undeclared (first use this function) cmdline.C:20: error: (Each undeclared identifier is reported only once for each function it appears in.) cmdline.C: In member function `void cmdline::setConfig()': cmdline.C:30: error: `getValue' undeclared (first use this function) cmdline.C: In member function `void cmdline::setLocalStateDir()': cmdline.C:39: error: `getValue' undeclared (first use this function) gmake[2]: *** [cmdline.lo] Error 1 gmake[2]: Leaving directory `/export/home/seb/sqlrelay-0.39.4/src/util' gmake[1]: *** [all] Error 2 gmake[1]: Leaving directory `/export/home/seb/sqlrelay-0.39.4/src' gmake: *** [all] Error 2 Any ideas ? Séb. |
|
From: Chad J. <cha...@gm...> - 2008-05-01 17:07:45
|
On Thu, May 1, 2008 at 10:17 AM, David Muse <dav...@fi...> wrote: > Aaah! You're right. And it looks like that's not a ruby-specific > issue. Basically any non C/C++ api has the problem. In C/C++ you can > free or delete the cursor, but not in other languages. > > I'll add a feature to close a cursor in the next release. > > David Muse > dav...@fi... Excellent, thanks David! -Chad Johnson |
|
From: Holger A. <ke...@fe...> - 2008-05-01 16:14:52
|
I found out, that the tweaks are not necessary. configure looks for a mysql_config, but MacPorts added a 5 to almost all mysql executables and paths. So a ln -s /opt/local/bin/mysql_config5 /opt/local/bin/ mysql_config and ./configure --with-mysql-prefix=/opt/local works too. |
|
From: Holger A. <ke...@fe...> - 2008-05-01 16:05:47
|
Hi David!
David Muse wrote:
> Did the MacPorts version of mysql come with a mysql_config script? If
> so, you should just have to provide the configure script with it's
> prefix. For example, if it's in /opt/local/bin/mysql_config, then you
> could use:
>
> ./configure --with-mysql-prefix=/opt/local
>
> And it will find the mysql_config script and use it to get the paths
> for
> libs and include files. And everything should go well.
Yes, there is an mysql_config5 in /opt/local/bin which prints
Usage: /opt/local/bin/mysql_config5 [OPTIONS]
Options:
--cflags [-I/opt/local/include/mysql5/mysql]
--include [-I/opt/local/include/mysql5/mysql]
--libs [-L/opt/local/lib -L/opt/local/lib/mysql5/
mysql -lmysqlclient -L/opt/local/lib -lz -lm -L/opt/local/lib -lssl -
lcrypto]
--libs_r [-L/opt/local/lib -L/opt/local/lib/mysql5/
mysql -lmysqlclient_r -L/opt/local/lib -lz -lm -L/opt/local/lib -
lssl -lcrypto]
--socket [/opt/local/var/run/mysql5/mysqld.sock]
--port [3306]
--version [5.0.51]
--libmysqld-libs [-L/opt/local/lib -L/opt/local/lib/mysql5/
mysql -lmysqld -L/opt/local/lib -lz -lm -L/opt/local/lib -lssl -
lcrypto]
but running ./configure --with-mysql-prefix=/opt/local without tweaks
disables mysql support.
> Otherwise, you're on the right track. It looks like the tweaks to the
> configure script just didn't do the job. Try adding them around line
> 23992 which is right before the tests are run. You'll know it
> worked if
> the various "checking for XXX" lines output by the configure script
> say
> "yes" sometimes.
23992? Are you sure?
23991 (exit $ac_status); } &&
23992 { ac_try='test -z "$ac_cxx_werror_flag"
23993 || test ! -s conftest.err'
23994 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
Line 23644 seems better to me and I added lines according to
mysql_config5
23644 #eval "MYSQLINCLUDES=\"$INCLUDESTRING\""
23645 #eval "MYSQLLIBS=\"$LIBSTRING\""
23646 eval "MYSQLINCLUDES=\"-I/opt/local/include/mysql5/mysql\""
23647 eval "MYSQLLIBS=\"-L/opt/local/lib -L/opt/local/lib/mysql5/mysql
-lmysqlclient -L/opt/local/lib -lz -lm -L/opt/local/lib -lssl -lcrypto
\""
and now I get
***** MySQL ******************
checking if MySQL requires -lz... no
checking for gzopen in -lz... yes
checking for mysql_real_connect... yes
checking for mysql_select_db... yes
checking for mysql_ping... yes
checking for mysql_change_user... yes
checking for mysql_commit... yes
checking for mysql_rollback... yes
checking for mysql_autocommit... yes
checking for mysql_prepare... yes
checking for mysql_next_result... yes
checking for CR_SERVER_GONE_ERROR... yes
checking for CR_SERVER_LOST... yes
checking for FIELD_TYPE_YEAR... yes
checking for FIELD_TYPE_NEWDATE... yes
checking for FIELD_TYPE_ENUM... yes
checking for FIELD_TYPE_SET... yes
checking for FIELD_TYPE_NEWDECIMAL... yes
checking for MYSQL_OPT_RECONNECT... yes
checking for MYSQL_GET_SERVER_VERSION... yes
mysql includes... -I/opt/local/include/mysql5/mysql
mysql libs... -L/opt/local/lib -L/opt/local/lib/mysql5/mysql -
lmysqlclient -L/opt/local/lib -lz -lm -L/opt/local/lib -lssl -lcrypto
and sql relay compiles without problems. Thank you very much! :)
|
|
From: David M. <dav...@fi...> - 2008-05-01 15:30:13
|
It looks like the tweaks to the configure script didn't do the job. Try adding them around line 23992. Did the MacPorts version of mysql come with a mysql_config script? If so, you should just have to provide the configure script with it's prefix. For example, if it's in /opt/local/bin/mysql_config, then you could use: ./configure --with-mysql-prefix=/opt/local And it will find the mysql_config script and use it to get the paths for libs and include files. And everything should go well. Otherwise, you're on the right track. It looks like the tweaks to the configure script just didn't do the job. Try adding them around line 23992 which is right before the tests are run. You'll know it worked if the various "checking for XXX" lines output by the configure script say "yes" sometimes. David Muse dav...@fi... On Wed, 2008-04-30 at 15:59 +0200, Holger Amann wrote: > Hi! > > I'm trying to compile sql relay on OS X 10.5.2 with MySQL 5.0.51 > installed by MacPorts in /opt/local/libs/mysql5/mysql and /opt/local/ > include/mysql5/mysql. Because configure didn't find the headers and > libs, I played with configure.mk.in and set > > MYSQLINCLUDES = -I/opt/local/include/mysql5/mysql > MYSQLLIBS = -L/opt/local/libs/mysql5/mysql > > , and I modified configure with > > MYSQLINCLUDES="/opt/local/include/mysql5/mysql" > MYSQLLIBS="/opt/local/libs/mysql5/mysql" > > This results in > > ... > ***** MySQL ****************** > checking for mysql_real_connect... no > checking for mysql_select_db... no > checking for mysql_ping... no > checking for mysql_change_user... no > checking for mysql_commit... no > checking for mysql_rollback... no > checking for mysql_autocommit... no > checking for mysql_prepare... no > checking for mysql_next_result... no > checking for CR_SERVER_GONE_ERROR... no > checking for CR_SERVER_LOST... no > checking for FIELD_TYPE_YEAR... no > checking for FIELD_TYPE_NEWDATE... no > checking for FIELD_TYPE_ENUM... no > checking for FIELD_TYPE_SET... no > checking for FIELD_TYPE_NEWDECIMAL... no > checking for MYSQL_OPT_RECONNECT... no > checking for MYSQL_GET_SERVER_VERSION... no > mysql includes... /opt/local/include/mysql5/mysql > mysql libs... /opt/local/libs/mysql5/mysql > ... > > and make aborts with > ... > make -C connection all > make[2]: Nothing to be done for `all'. > make -C connections all > make -C status all > make[3]: Nothing to be done for `all'. > make -C mysql all > /bin/sh ../../../libtool --mode=compile g++ -Wall -pipe -Wno-long- > double -I/opt/local/include/mysql5/mysql -pthread -I./ -I../../../ - > I../../../src/common -I../../../src/util -I../../../src/connection -I/ > usr/local/firstworks/include -pthread -I/opt/local/include -I/opt/ > local/include/mysql5/mysql -I../../../src/api/c++/include -c > mysqlconnection.C -o mysqlconnection.lo > g++ -Wall -pipe -Wno-long-double -I/opt/local/include/mysql5/mysql - > pthread -I./ -I../../../ -I../../../src/common -I../../../src/util - > I../../../src/connection -I/usr/local/firstworks/include -pthread -I/ > opt/local/include -I/opt/local/include/mysql5/mysql -I../../../src/api/ > c++/include -c mysqlconnection.C -fno-common -DPIC -o .libs/ > mysqlconnection.o > mysqlconnection.C: In member function 'virtual bool > mysqlconnection::logIn(bool)': > mysqlconnection.C:102: error: 'mysql_connect' was not declared in this > scope > mysqlconnection.C:70: warning: unused variable 'dbval' > make[3]: *** [mysqlconnection.lo] Error 1 > make[2]: *** [all] Error 2 > make[1]: *** [all] Error 2 > make: *** [all] Error 2 > ... > > I want to write an application based on sql relay, but I have no idea > how to resolve this. > Thanks for any hint or suggestion! > > Holger > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Sqlrelay-discussion mailing list > Sql...@li... > https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion > > > __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |
|
From: David M. <dav...@fi...> - 2008-05-01 15:18:39
|
Aaah! You're right. And it looks like that's not a ruby-specific issue. Basically any non C/C++ api has the problem. In C/C++ you can free or delete the cursor, but not in other languages. I'll add a feature to close a cursor in the next release. David Muse dav...@fi... On Thu, 2008-04-24 at 17:18 -0500, Chad Johnson wrote: > Within the Ruby bindings there does not appear to be a way to explicitly > close an open SQLRCursor object. > > Now this isn't a catastrophic problem because cursors are being closed when > SQLRCursor objects are garbage collected. But if you run up against the > configured SQL Relay cursor limit (5 by default) it appears as though your > code will hang (assuming the garbage collector hasn't had a chance to kick > in). > > Can a method be added to the Ruby bindings to allow a cursor to be closed > by hand? > > -Chad Johnson > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Sqlrelay-discussion mailing list > Sql...@li... > https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion > > > __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |
|
From: David M. <dav...@fi...> - 2008-04-30 20:15:27
|
I'm really not sure. It probably wouldn't be a C++ thing though, rather a FastCGI thing. It's possible that the fastcgi framework might throw an exception. I believe that the apache module api provides a way for a function to be called when the page is aborted. If you're using fastcgi as an apache module, then it may implement that function and provide it's own callback that you'd override or may raise an exception. I don't know fastcgi well enough though to say. Dave On Wed, 2008-04-30 at 08:29 -0600, TazaTek wrote: > In C++, what would be the equivalent of a register_shutdown_function()?? > > Would this be a try-catch block? Or do I need to register a signal? Or... ??? > > I'm not sure of what happens when a user aborts the connection.... could you shed some light on this? > > Thanks > > Matt > > > > >> If so, the only issue that I know of is that you really need to make > >> sure that you handle page aborts carefully. > > >> See http://sqlrelay.sourceforge.net/sqlrelay/faq.html#php for > >> PHP-specific info. The same may apply to fastcgi. > > >> Dave > >> dav...@fi... > > > On Thu, 2008-04-24 at 13:24 -0600, TazaTek wrote: > > > > > > Hello all! > > > > > > > > I was wondering if there were any problems in mixing fastcgi and > > sqlrelay? It seems that they both handle some of the speed > > performance mechanisms that are required of a web server, but I didn’t > > know if there were any problems in mixing the two. > > > > > > > > Thanks > > > > > > > > Matt > > > > -- > > > > Matthew Kettlewell > > > > President - TazaTek > > > > www.TazaTek.com > > > > www.Pairs-List.com > > > > 970-985-4192 > > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Sqlrelay-discussion mailing list > Sql...@li... > https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion > > __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |
|
From: TazaTek <ma...@ta...> - 2008-04-30 14:25:12
|
In C++, what would be the equivalent of a register_shutdown_function()?? Would this be a try-catch block? Or do I need to register a signal? Or... ??? I'm not sure of what happens when a user aborts the connection.... could you shed some light on this? Thanks Matt >> If so, the only issue that I know of is that you really need to make >> sure that you handle page aborts carefully. >> See http://sqlrelay.sourceforge.net/sqlrelay/faq.html#php for >> PHP-specific info. The same may apply to fastcgi. >> Dave >> dav...@fi... On Thu, 2008-04-24 at 13:24 -0600, TazaTek wrote: > > > Hello all! > > > > I was wondering if there were any problems in mixing fastcgi and > sqlrelay? It seems that they both handle some of the speed > performance mechanisms that are required of a web server, but I didn’t > know if there were any problems in mixing the two. > > > > Thanks > > > > Matt > > -- > > Matthew Kettlewell > > President - TazaTek > > www.TazaTek.com > > www.Pairs-List.com > > 970-985-4192 |
|
From: Holger A. <ke...@fe...> - 2008-04-30 13:59:29
|
Hi! I'm trying to compile sql relay on OS X 10.5.2 with MySQL 5.0.51 installed by MacPorts in /opt/local/libs/mysql5/mysql and /opt/local/ include/mysql5/mysql. Because configure didn't find the headers and libs, I played with configure.mk.in and set MYSQLINCLUDES = -I/opt/local/include/mysql5/mysql MYSQLLIBS = -L/opt/local/libs/mysql5/mysql , and I modified configure with MYSQLINCLUDES="/opt/local/include/mysql5/mysql" MYSQLLIBS="/opt/local/libs/mysql5/mysql" This results in ... ***** MySQL ****************** checking for mysql_real_connect... no checking for mysql_select_db... no checking for mysql_ping... no checking for mysql_change_user... no checking for mysql_commit... no checking for mysql_rollback... no checking for mysql_autocommit... no checking for mysql_prepare... no checking for mysql_next_result... no checking for CR_SERVER_GONE_ERROR... no checking for CR_SERVER_LOST... no checking for FIELD_TYPE_YEAR... no checking for FIELD_TYPE_NEWDATE... no checking for FIELD_TYPE_ENUM... no checking for FIELD_TYPE_SET... no checking for FIELD_TYPE_NEWDECIMAL... no checking for MYSQL_OPT_RECONNECT... no checking for MYSQL_GET_SERVER_VERSION... no mysql includes... /opt/local/include/mysql5/mysql mysql libs... /opt/local/libs/mysql5/mysql ... and make aborts with ... make -C connection all make[2]: Nothing to be done for `all'. make -C connections all make -C status all make[3]: Nothing to be done for `all'. make -C mysql all /bin/sh ../../../libtool --mode=compile g++ -Wall -pipe -Wno-long- double -I/opt/local/include/mysql5/mysql -pthread -I./ -I../../../ - I../../../src/common -I../../../src/util -I../../../src/connection -I/ usr/local/firstworks/include -pthread -I/opt/local/include -I/opt/ local/include/mysql5/mysql -I../../../src/api/c++/include -c mysqlconnection.C -o mysqlconnection.lo g++ -Wall -pipe -Wno-long-double -I/opt/local/include/mysql5/mysql - pthread -I./ -I../../../ -I../../../src/common -I../../../src/util - I../../../src/connection -I/usr/local/firstworks/include -pthread -I/ opt/local/include -I/opt/local/include/mysql5/mysql -I../../../src/api/ c++/include -c mysqlconnection.C -fno-common -DPIC -o .libs/ mysqlconnection.o mysqlconnection.C: In member function 'virtual bool mysqlconnection::logIn(bool)': mysqlconnection.C:102: error: 'mysql_connect' was not declared in this scope mysqlconnection.C:70: warning: unused variable 'dbval' make[3]: *** [mysqlconnection.lo] Error 1 make[2]: *** [all] Error 2 make[1]: *** [all] Error 2 make: *** [all] Error 2 ... I want to write an application based on sql relay, but I have no idea how to resolve this. Thanks for any hint or suggestion! Holger |
|
From: Chad J. <cha...@gm...> - 2008-04-24 22:18:38
|
Within the Ruby bindings there does not appear to be a way to explicitly close an open SQLRCursor object. Now this isn't a catastrophic problem because cursors are being closed when SQLRCursor objects are garbage collected. But if you run up against the configured SQL Relay cursor limit (5 by default) it appears as though your code will hang (assuming the garbage collector hasn't had a chance to kick in). Can a method be added to the Ruby bindings to allow a cursor to be closed by hand? -Chad Johnson |
|
From: David M. <dav...@fi...> - 2008-04-24 20:26:57
|
If I remember correctly, fastcgi keeps the cgi running persistently rather than having a cgi process start and stop over and over. If so, the only issue that I know of is that you really need to make sure that you handle page aborts carefully. Similar issues exist when using mod_perl or mod_php. If someone hits stop on their browser with a regular cgi, then the cgi will exit and everything will be cleaned up. However, with fastcgi, if the entire code doesn't execute, then clean-up code may not be called and it could leave lingering network connections between the http server and sqlrelay server as well as general memory leaks. See http://sqlrelay.sourceforge.net/sqlrelay/faq.html#php for PHP-specific info. The same may apply to fastcgi. Dave dav...@fi... On Thu, 2008-04-24 at 13:24 -0600, TazaTek wrote: > > > Hello all! > > > > I was wondering if there were any problems in mixing fastcgi and > sqlrelay? It seems that they both handle some of the speed > performance mechanisms that are required of a web server, but I didn’t > know if there were any problems in mixing the two. > > > > Thanks > > > > Matt > > > > > > > > -- > > Matthew Kettlewell > > President - TazaTek > > www.TazaTek.com > > www.Pairs-List.com > > 970-985-4192 > > > > > > > __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ Sqlrelay-discussion mailing list Sql...@li... https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |
|
From: TazaTek <ma...@ta...> - 2008-04-24 19:20:43
|
Hello all! I was wondering if there were any problems in mixing fastcgi and sqlrelay? It seems that they both handle some of the speed performance mechanisms that are required of a web server, but I didn't know if there were any problems in mixing the two. Thanks Matt -- Matthew Kettlewell President - TazaTek www.TazaTek.com www.Pairs-List.com 970-985-4192 |
|
From: John K. <kl...@gm...> - 2008-04-23 18:07:39
|
The list archive is mum on the topic of BFILE data... A google search within the sqlrelay.sourceforge.net site is also mum. [ I saw what looked like a mirror of the SQL Relay pages, but on a foreign server (http://doc.dvgu.ru/db/sql_relay/faq.html), that said something about BFILE support. I'm guessing that's old/invalid somehow, though. ] Anyway, when I use the non-DBI perl bindings with SQL Relay, and query for a BFILE column, I get back what appears to be the right number of bytes (might not be -- not sure), but all of the characters in the data are nulls (they look like ^@ in Emacs :-)). When I use the DBD perl bindings with SQL Relay, and do the same thing, I get a one- or two-character chunk of data back (despite long-read-length set high, and truncate set to false). If I use regular DBD::Oracle, without SQL Relay, I get the whole BFILE back. So is BFILE supported, and if so, is there a trick? :-) Thanks. |
|
From: Peter C. <pc...@sa...> - 2008-04-18 08:40:59
|
Hello David,
Many thanks for your reply, much appreciated. For real world usage I
think I may be able to make a few generic rules for filtering as they
will be database revision based (fingers crossed there :-) )
I had a play with the router example but hit the following errors. Ones
of particular interest were the unknown dbase router and it didn't like
an instance section without a router entry. I've attached a v.
simplistic version of the config and output below (apologies if I'm
missing something obvious here). On the plus side the connection pooling
is working elsewhere like a charm (so many thanks there :-) )
sqlrelay version:
0.37.1-3.1 (with Debian Etch)
config file:
see attached
output:
Starting SQL Relay ... /etc/sqlrelay/sqlrelay.conf:14: element instance:
validity error : Element instance content does not follow the DTD,
expecting (users , connections , router), got (users connections )
</instance>
^
/etc/sqlrelay/sqlrelay.conf:24: element instance: validity error :
Element instance content does not follow the DTD, expecting (users ,
connections , router), got (users connections )
</instance>
^
/etc/sqlrelay/sqlrelay.conf:27: element instance: validity error : Value
"router" for attribute dbase of instance is not among the enumerated set
tringbindvaluelength="4000" maxlobbindvaluelength="71680"
idleclienttimeout="-1"
^
/etc/sqlrelay/sqlrelay.conf:40: parser error : expected '>'
</instances>
^
SQL Relay not started/etc/sqlrelay/sqlrelay.conf:14: element instance:
validity error : Element instance content does not follow the DTD,
expecting (users , connections , router), got (users connections )
</instance>
^
/etc/sqlrelay/sqlrelay.conf:24: element instance: validity error :
Element instance content does not follow the DTD, expecting (users ,
connections , router), got (users connections )
</instance>
^
/etc/sqlrelay/sqlrelay.conf:27: element instance: validity error : Value
"router" for attribute dbase of instance is not among the enumerated set
tringbindvaluelength="4000" maxlobbindvaluelength="71680"
idleclienttimeout="-1"
^
/etc/sqlrelay/sqlrelay.conf:40: parser error : expected '>'
</instances>
^
SQL Relay not started.
Many thabks again for your assistance
Pete
> SQL Relay can do this. You need to set up 4 instances of SQL Relay, one
> to talk to each database. Then you need to set up a 5th instance to
> "route" queries to the other 4.
>
> There's a doc at: http://sqlrelay.sourceforge.net/sqlrelay/router.html
> that describes this in detail. The section "Provide a Single Point of
> Access to Multiple Databases" is the section that applies in this case.
> In that example, one of the db's is mysql and the other is postgresql,
> but you could just as easily use several mysql databases.
>
> The trick is that you need to come up with regular expressions so that
> the router can look at a query and know which database to send it to by
> which expression it matches. That could be a long list of regular
> expressions for each db.
>
> Dave
>
> On Thu, 2008-04-17 at 11:45 +0100, Peter Clapham wrote:
>
>> Dear all,
>>
>> Having just started playing with sqlrealy I apologise if this is a daft
>> Q, I've browsed the archives but I'm not sure I've found how best to
>> tackle the following problem.
>>
>> We have a number of mysql instances running on various hosts and ports.
>> We would like to be able to rediect queries to a given instance
>> depending upon the database requested. So in essence we'd have:
>>
>> server1 port 3306 database1
>> server2 port 3307 database2
>> server2 port 5307 database3
>> server3 port 5304 database4
>>
>> So user points connection at sqlrelay for a given database connection
>> this is then (hopefully) redirected transparently to the required server .
>>
>> Pointers of best way forward would be much appreciated.
>>
>> Many thanks
>>
>> Pete
>>
>>
>>
>
>
>
> __________________________________________________
> D O T E A S Y - "Join the web hosting revolution!"
> http://www.doteasy.com
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
> Don't miss this year's exciting event. There's still time to save $100.
> Use priority code J8TL2D2.
> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
> _______________________________________________
> Sqlrelay-discussion mailing list
> Sql...@li...
> https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion
>
--
The Wellcome Trust Sanger Institute is operated by Genome Research
Limited, a charity registered in England with number 1021457 and a
company registered in England with number 2742969, whose registered
office is 215 Euston Road, London, NW1 2BE.
|
|
From: David M. <dav...@fi...> - 2008-04-17 16:52:25
|
SQL Relay can do this. You need to set up 4 instances of SQL Relay, one to talk to each database. Then you need to set up a 5th instance to "route" queries to the other 4. There's a doc at: http://sqlrelay.sourceforge.net/sqlrelay/router.html that describes this in detail. The section "Provide a Single Point of Access to Multiple Databases" is the section that applies in this case. In that example, one of the db's is mysql and the other is postgresql, but you could just as easily use several mysql databases. The trick is that you need to come up with regular expressions so that the router can look at a query and know which database to send it to by which expression it matches. That could be a long list of regular expressions for each db. Dave On Thu, 2008-04-17 at 11:45 +0100, Peter Clapham wrote: > Dear all, > > Having just started playing with sqlrealy I apologise if this is a daft > Q, I've browsed the archives but I'm not sure I've found how best to > tackle the following problem. > > We have a number of mysql instances running on various hosts and ports. > We would like to be able to rediect queries to a given instance > depending upon the database requested. So in essence we'd have: > > server1 port 3306 database1 > server2 port 3307 database2 > server2 port 5307 database3 > server3 port 5304 database4 > > So user points connection at sqlrelay for a given database connection > this is then (hopefully) redirected transparently to the required server . > > Pointers of best way forward would be much appreciated. > > Many thanks > > Pete > > __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |
|
From: Peter C. <pc...@sa...> - 2008-04-17 10:46:03
|
Dear all, Having just started playing with sqlrealy I apologise if this is a daft Q, I've browsed the archives but I'm not sure I've found how best to tackle the following problem. We have a number of mysql instances running on various hosts and ports. We would like to be able to rediect queries to a given instance depending upon the database requested. So in essence we'd have: server1 port 3306 database1 server2 port 3307 database2 server2 port 5307 database3 server3 port 5304 database4 So user points connection at sqlrelay for a given database connection this is then (hopefully) redirected transparently to the required server . Pointers of best way forward would be much appreciated. Many thanks Pete -- The Wellcome Trust Sanger Institute is operated by Genome Research Limited, a charity registered in England with number 1021457 and a company registered in England with number 2742969, whose registered office is 215 Euston Road, London, NW1 2BE. |
|
From: Culley H. <har...@gm...> - 2008-04-10 16:27:13
|
My latest attempt this morning is to avoid the port and install from scratch. During the make process (I had to use gmake) I get this error. Any ideas? ==== g++ -o .libs/sqlr-listener .libs/sqlrlistener.o .libs/main.o -pthread -L/usr/home/culley/Desktop/sqlrelay-0.39.4/src/util /usr/home/culley/Desktop/sqlrelay-0.39.4/src/util/.libs/libsqlrutil.so -L/usr/local/lib /usr/local/lib/librudiments.so -pthread -L/usr/lib -lcrypt -Wl,--rpath -Wl,/usr/local/firstworks/lib -Wl,--rpath -Wl,/usr/local/lib /usr/local/lib/librudiments.so: undefined reference to `SSL_shutdown' /usr/local/lib/librudiments.so: undefined reference to `SSL_get_error' /usr/local/lib/librudiments.so: undefined reference to `SSL_read' /usr/local/lib/librudiments.so: undefined reference to `SSL_new' /usr/local/lib/librudiments.so: undefined reference to `SSL_pending' /usr/local/lib/librudiments.so: undefined reference to `SSL_set_bio' /usr/local/lib/librudiments.so: undefined reference to `SSL_accept' /usr/local/lib/librudiments.so: undefined reference to `SSL_connect' /usr/local/lib/librudiments.so: undefined reference to `SSL_free' /usr/local/lib/librudiments.so: undefined reference to `BIO_new_fd' /usr/local/lib/librudiments.so: undefined reference to `SSL_write' /usr/local/lib/librudiments.so: undefined reference to `BIO_new_socket' gmake[2]: *** [sqlr-listener] Error 1 gmake[2]: Leaving directory `/usr/home/culley/Desktop/sqlrelay-0.39.4/src/listener' gmake[1]: *** [all] Error 2 gmake[1]: Leaving directory `/usr/home/culley/Desktop/sqlrelay-0.39.4/src' gmake: *** [all] Error 2 On Wed, 09 Apr 2008, David Muse wrote: > Usually this is permissions-related. The user that sqlrelay is > configured to run as can't write files to the directory that the ipc > files are stored in. In this case, probably /var/sqlrelay/tmp/ipc. > Or possibly that directory doesn't exist. > > If that's not the case, then you may need to do some stracing to see > what's causing ftok to generate the -1 id. > > Dave > dav...@fi... > > On Mon, 2008-04-07 at 22:01 -0700, Culley Harrelson wrote: > > Hello, > > > > I am trying to configure sqlrelay on freebsd-- pc-bsd actually, my > > development machine and eventually on my production freebsd servers. > > Sqlrelay was installed from the port-- version sqlrelay-0.38_2 > > > > When I try to start it I get the below error. Any ideas? It seems like it > > is looking for /var/sqlrelay. In this directory there was no > > /var/sqlrelay/var so I created it but it didn't fix the problem. > > > > ch > > > > =================== > > > > > > [root@pcbsd /usr/local/etc]# sqlr-start -id flashex > > > > Starting listener: > > sqlr-listener -id flashex -config /usr/local/etc/sqlrelay.conf > > > > sqlr-listener error: > > Unable to create a semaphore set. This is usally because an > > sqlr-listener is already running for the flashex instance. > > > > If it is not running, something may have crashed and left an old semaphore set > > lying around. Use the ipcs command to inspect existing semaphore sets > > and the ipcrm command to remove the semaphore set with > > id -1. > > > > Error was: No such file or directory > > > > unsuccessful completion > > > > sqlr-listener failed to start. > > > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > > Register now and save $200. Hurry, offer ends at 11:59 p.m., > > Monday, April 7! Use priority code J8TLD2. > > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > > _______________________________________________ > > Sqlrelay-discussion mailing list > > Sql...@li... > > https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion > > > > > > __________________________________________________ > > D O T E A S Y - "Join the web hosting revolution!" > > http://www.doteasy.com > > > > __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Sqlrelay-discussion mailing list > Sql...@li... > https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion |
|
From: David M. <dav...@fi...> - 2008-04-09 18:52:30
|
Usually this is permissions-related. The user that sqlrelay is configured to run as can't write files to the directory that the ipc files are stored in. In this case, probably /var/sqlrelay/tmp/ipc. Or possibly that directory doesn't exist. If that's not the case, then you may need to do some stracing to see what's causing ftok to generate the -1 id. Dave dav...@fi... On Mon, 2008-04-07 at 22:01 -0700, Culley Harrelson wrote: > Hello, > > I am trying to configure sqlrelay on freebsd-- pc-bsd actually, my > development machine and eventually on my production freebsd servers. > Sqlrelay was installed from the port-- version sqlrelay-0.38_2 > > When I try to start it I get the below error. Any ideas? It seems like it > is looking for /var/sqlrelay. In this directory there was no > /var/sqlrelay/var so I created it but it didn't fix the problem. > > ch > > =================== > > > [root@pcbsd /usr/local/etc]# sqlr-start -id flashex > > Starting listener: > sqlr-listener -id flashex -config /usr/local/etc/sqlrelay.conf > > sqlr-listener error: > Unable to create a semaphore set. This is usally because an > sqlr-listener is already running for the flashex instance. > > If it is not running, something may have crashed and left an old semaphore set > lying around. Use the ipcs command to inspect existing semaphore sets > and the ipcrm command to remove the semaphore set with > id -1. > > Error was: No such file or directory > > unsuccessful completion > > sqlr-listener failed to start. > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Register now and save $200. Hurry, offer ends at 11:59 p.m., > Monday, April 7! Use priority code J8TLD2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Sqlrelay-discussion mailing list > Sql...@li... > https://lists.sourceforge.net/lists/listinfo/sqlrelay-discussion > > > __________________________________________________ > D O T E A S Y - "Join the web hosting revolution!" > http://www.doteasy.com __________________________________________________ D O T E A S Y - "Join the web hosting revolution!" http://www.doteasy.com |