Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connection to Localhost on Linux with blob fields [CORE469] #815

Closed
firebird-automations opened this issue Mar 1, 2005 · 13 comments
Closed

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: marcolovato (marcolovato)

Attachments:
nicequery.pl

SFID: 1154198#⁠
Submitted By: marcolovato

Hi FB TEAM!

I already posted this to lots of Firebird lists, but
the strange problem remains.

Here is the scenario:

I run Eclipse3/Quantum and made this query (the same
behavior occurs on aqua-data-studio):

SELECT * FROM MBREPORTS WHERE MBREPORT_ID IN (1344,
1697, 1805, 777, 650, 965, 883, 770, 659, 774, 652,
773, 775, 660, 772, 779, 778, 693, 694, 780, 731, 730,
882, 881, 884, 1259, 1318, 1319, 1320, 1321, 1674,
1261, 1346, 2064, 1345, 1802, 1803, 2065, 1806, 1807)

This table has this structure:
MBREPORT_ID: Integer(10)
COLLECT_TYPE_ID: Integer(10)
VEHICLE_ID: Integer(10)
MBCLIENT_ID: Integer(10)
START_TIMESTAMP: Timestamp(19)
END_TIMESTAMP: Timestamp(19)
STORE_TIMESTAMP: Timestamp(19)
XML_DESCRIPTOR: Blob SubType 1
XML_REPORT: Blob SubType 1

I have 1856 records on this table.

STEPs:
- Make this query on WINDOWS, Firebird Localhost. OK
- Make this query on WINDOWS, Firebird on remote
WINDOWS. OK
- Make this query on WINDOWS, Firebird on remote LINUX. OK
- Make this query on LINUX, Firebird on remote WINDOWS. OK
- Make this query on LINUX, Firebird on remote LINUX. OK
- Make this query on LINUX, Firebird Localhost. NOT_OK

The last test hangs for 21 secs, while others are
executed just on 3 secs. It keeps transfering data thru
"lo", no CPU activity, but a extremelly low rate.
All queries are slowed down on localhost linux database.

I tested all JDBC drivers.

LinuxBoxes are GentooLinux & ConectivaLinux

Hardware vary from CompaqNotebook PIII, PII350,
DellPowerEdge1800 and AthlonXP2000+

I made the regular instalation, and took a lot on lots
of docs & howtos.

This poor performance happens on all linux
instalations. I made 4 instalations from scratch, and
on every one, the behavior was the same as described on
section "STEPs".

Bes

@firebird-automations
Copy link
Collaborator Author

Commented by: Alice F. Bird (firebirds)

Date: 2005-03-02 15:50
Sender: marcolovato
Logged In: YES
user_id=1072975

Michael,

I dit it yesterday, BEFORE reading your followup.
And it worked. I put 30000, but with 'strace' I saw it uses
just 16384.
And I cannot put 32K, because I got an error while starting
firebird, or making client connections.

I discovered also that the default value is 8192, and it
runs ok for ETH0, not for "lo".

So, 4 things:
a) Why on windows 8192 (or the default on Windows is 16384?)
works fine for this kind of traffic?
b) It shouldnt be explicit warned on firebird.conf? I took
several days trying to find it out.
c) On firebird.conf, it says that TcpRemoteBufferSize works
for CLIENT and SERVER, but for me the only way of changing
it was on the client. If the server has another value (8192)
the proccess occurs at the client value (30000).
d) Why cant I put 32K (the maxvalue) on the TcpRemoteBufferSize?

WITH 32768
close(4) = 0
munmap(0x403ee000, 131072) = 0
umask(022) = 0111
shutdown(3, 2 /* send and receive */) = -1 ENOTCONN
(Transport endpoint is not connected)
close(3) = 0
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++

WITH 32767
close(4) = 0
munmap(0x403ee000, 131072) = 0
umask(022) = 0111
send(3, "\0\0\0\6", 4, 0) = -1 EPIPE (Broken pipe)
--- SIGPIPE (Broken pipe) @ 0 (0) ---
+++ killed by SIGPIPE +++

Thank you for your time, and I hope my days of research can
hope someone on the future, just by browsing this
bugtracker, or by find extra info on firebird.conf, if
FBTeam consider ok my point of view.

Thank you VERY much. You were, among dozens of FBusers, the
only one who figured out how to solve my particular(?)
problem (besides of me :-D ).

@firebird-automations
Copy link
Collaborator Author

Commented by: Alice F. Bird (firebirds)

Date: 2005-03-02 13:12
Sender: mghie
Logged In: YES
user_id=17524

Try increasing the value of TcpRemoteBufferSize in
firebird.conf, I have observed the effect you describe with
blob data which is bigger than 8192 bytes.

HTH, Michael Hieke

@firebird-automations
Copy link
Collaborator Author

Commented by: Alice F. Bird (firebirds)

Date: 2005-03-01 20:20
Sender: marcolovato
Logged In: YES
user_id=1072975

I made another tests:

#⁠!/usr/bin/perl
use DBD::InterBase;
$dbh =
DBI->connect("dbi:InterBase:db=/opt/mbserver/firebird/MBDB.GDB;host=localhost/3050",
"sysdba", "masterkey");
$dbh->{LongReadLen} = 1000000000;
#⁠$dbh->{LongTruncOk}=100000000;
my $sth=$dbh->prepare("SELECT XML_REPORT FROM MBREPORTS
WHERE MBREPORT_ID IN (1344, 1697, 1805, 777, 650, 965, 883,
770, 659, 774, 652, 773, 775, 660, 772, 779, 778, 693, 694,
780, 731, 730, 882, 881, 884, 1259, 1318, 1319, 1320, 1321,
1674, 1261, 1346, 2064, 1345, 1802, 1803, 2065, 1806, 1807)");
$sth->execute();
while (@DaTa=$sth->fetchrow_array()) {
$dumbbuffer = $dumbbuffer.$data[0].$data[1];
}
$dbh->disconnect();

With this, I can simulate all the stuff, removing
Java/JayBird/JDBC from scenario.

mcfly tmp #⁠ time http://nicequery.pl #⁠LOCALHOST

real 0m21.360s
user 0m1.710s
sys 0m0.065s

mcfly tmp #⁠ time http://nicequery.pl #⁠REMOTELLY

real 0m3.335s
user 0m1.775s
sys 0m0.216s

Any ideas?

@firebird-automations
Copy link
Collaborator Author

Modified by: Alice F. Bird (firebirds)

description: SFID: 1154198#⁠
Submitted By: marcolovato

Hi FB TEAM!

I already posted this to lots of Firebird lists, but
the strange problem remains.

Here is the scenario:

I run Eclipse3/Quantum and made this query (the same
behavior occurs on aqua-data-studio):

SELECT * FROM MBREPORTS WHERE MBREPORT_ID IN (1344,
1697, 1805, 777, 650, 965, 883, 770, 659, 774, 652,
773, 775, 660, 772, 779, 778, 693, 694, 780, 731, 730,
882, 881, 884, 1259, 1318, 1319, 1320, 1321, 1674,
1261, 1346, 2064, 1345, 1802, 1803, 2065, 1806, 1807)

This table has this structure:
MBREPORT_ID: Integer(10)
COLLECT_TYPE_ID: Integer(10)
VEHICLE_ID: Integer(10)
MBCLIENT_ID: Integer(10)
START_TIMESTAMP: Timestamp(19)
END_TIMESTAMP: Timestamp(19)
STORE_TIMESTAMP: Timestamp(19)
XML_DESCRIPTOR: Blob SubType 1
XML_REPORT: Blob SubType 1

I have 1856 records on this table.

STEPs:
- Make this query on WINDOWS, Firebird Localhost. OK
- Make this query on WINDOWS, Firebird on remote
WINDOWS. OK
- Make this query on WINDOWS, Firebird on remote LINUX. OK
- Make this query on LINUX, Firebird on remote WINDOWS. OK
- Make this query on LINUX, Firebird on remote LINUX. OK
- Make this query on LINUX, Firebird Localhost. NOT_OK

The last test hangs for 21 secs, while others are
executed just on 3 secs. It keeps transfering data thru
"lo", no CPU activity, but a extremelly low rate.
All queries are slowed down on localhost linux database.

I tested all JDBC drivers.

LinuxBoxes are GentooLinux & ConectivaLinux

Hardware vary from CompaqNotebook PIII, PII350,
DellPowerEdge1800 and AthlonXP2000+

I made the regular instalation, and took a lot on lots
of docs & howtos.

This poor performance happens on all linux
instalations. I made 4 instalations from scratch, and
on every one, the behavior was the same as described on
section "STEPs".

Bes

=>

SFID: 1154198#⁠
Submitted By: marcolovato

Hi FB TEAM!

I already posted this to lots of Firebird lists, but
the strange problem remains.

Here is the scenario:

I run Eclipse3/Quantum and made this query (the same
behavior occurs on aqua-data-studio):

SELECT * FROM MBREPORTS WHERE MBREPORT_ID IN (1344,
1697, 1805, 777, 650, 965, 883, 770, 659, 774, 652,
773, 775, 660, 772, 779, 778, 693, 694, 780, 731, 730,
882, 881, 884, 1259, 1318, 1319, 1320, 1321, 1674,
1261, 1346, 2064, 1345, 1802, 1803, 2065, 1806, 1807)

This table has this structure:
MBREPORT_ID: Integer(10)
COLLECT_TYPE_ID: Integer(10)
VEHICLE_ID: Integer(10)
MBCLIENT_ID: Integer(10)
START_TIMESTAMP: Timestamp(19)
END_TIMESTAMP: Timestamp(19)
STORE_TIMESTAMP: Timestamp(19)
XML_DESCRIPTOR: Blob SubType 1
XML_REPORT: Blob SubType 1

I have 1856 records on this table.

STEPs:
- Make this query on WINDOWS, Firebird Localhost. OK
- Make this query on WINDOWS, Firebird on remote
WINDOWS. OK
- Make this query on WINDOWS, Firebird on remote LINUX. OK
- Make this query on LINUX, Firebird on remote WINDOWS. OK
- Make this query on LINUX, Firebird on remote LINUX. OK
- Make this query on LINUX, Firebird Localhost. NOT_OK

The last test hangs for 21 secs, while others are
executed just on 3 secs. It keeps transfering data thru
"lo", no CPU activity, but a extremelly low rate.
All queries are slowed down on localhost linux database.

I tested all JDBC drivers.

LinuxBoxes are GentooLinux & ConectivaLinux

Hardware vary from CompaqNotebook PIII, PII350,
DellPowerEdge1800 and AthlonXP2000+

I made the regular instalation, and took a lot on lots
of docs & howtos.

This poor performance happens on all linux
instalations. I made 4 instalations from scratch, and
on every one, the behavior was the same as described on
section "STEPs".

Bes

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

assignee: Dmitry Yemanov [ dimitr ]

SF_ID: 1154198 =>

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

status: Resolved [ 5 ] => Closed [ 6 ]

SF_ID: 1154198 =>

@firebird-automations
Copy link
Collaborator Author

Commented by: @pcisar

Reopened just to add attachment.

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

status: Closed [ 6 ] => Reopened [ 4 ]

SF_ID: 1154198 =>

resolution: Fixed [ 1 ] =>

@firebird-automations
Copy link
Collaborator Author

Commented by: @pcisar

Perl File

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

Attachment: http://nicequery.pl [ 10040 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

status: Reopened [ 4 ] => Closed [ 6 ]

resolution: Fixed [ 1 ]

SF_ID: 1154198 =>

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

Workflow: jira [ 10493 ] => Firebird [ 14785 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

QA Status: No test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants