Restart works, errno = 104 Firebird 2.5<LI-V2.5.2.26540

276 views
Skip to first unread message

Abdul Muqtadir

unread,
Sep 9, 2024, 6:23:35 AM9/9/24
to firebird-support
Hi all, 

Happy Monday!

Every Monday around 7AM, the users report the application stops loading data and it starts working when I restart the firebird service on the server, that is 2 hours before my shift starts as the manufacturing workers start early in the morning.  

Firebird.log does not show anything other than these regular errors throughout the week. Restarts of the service through cron jobs early in the mornings are my failed attempts to resolve this issue. 

localhost.localdomain (Server) Mon Sep  9 07:07:55 2024
INET/inet_error: read errno = 104


localhost.localdomain (Server) Mon Sep  9 07:07:55 2024
INET/inet_error: read errno = 104


localhost.localdomain (Server) Mon Sep  9 07:07:55 2024
INET/inet_error: read errno = 104


localhost.localdomain (Server) Mon Sep  9 07:07:55 2024
INET/inet_error: send errno = 32

and 
localhost.localdomain (Server) Mon Sep  9 07:48:44 2024
INET/inet_error: read errno = 104


localhost.localdomain (Server) Mon Sep  9 07:49:05 2024
INET/inet_error: read errno = 9


localhost.localdomain (Server) Mon Sep  9 08:01:30 2024
INET/inet_error: read errno = 9


localhost.localdomain (Server) Mon Sep  9 08:10:49 2024
INET/inet_error: read errno = 110


localhost.localdomain (Server) Mon Sep  9 08:11:23 2024
Shutting down the server with 51 active connection(s) to 2 database(s), 0 active service(s)


localhost.localdomain (Client) Mon Sep  9 08:11:27 2024
/opt/firebird/bin/fbguard: /opt/firebird/bin/fbserver terminated abnormally (-1)



localhost.localdomain (Client) Mon Sep  9 08:11:27 2024
/opt/firebird/bin/fbguard: guardian starting /opt/firebird/bin/fbserver



localhost.localdomain (Client) Mon Sep  9 08:11:42 2024
/opt/firebird/bin/fbguard: guardian starting /opt/firebird/bin/fbserver



localhost.localdomain (Server) Mon Sep  9 08:12:32 2024
INET/inet_error: bind errno = 98


localhost.localdomain (Client) Mon Sep  9 08:12:32 2024
/opt/firebird/bin/fbguard: /opt/firebird/bin/fbserver terminated due to startup error (2)



localhost.localdomain (Client) Mon Sep  9 08:12:32 2024
/opt/firebird/bin/fbguard: /opt/firebird/bin/fbserver terminated due to startup error (2)



localhost.localdomain (Server) Mon Sep  9 08:13:12 2024
INET/inet_error: read errno = 9


localhost.localdomain (Server) Mon Sep  9 08:17:58 2024
Shutting down the server with 13 active connection(s) to 1 database(s), 0 active service(s)


localhost.localdomain (Client) Mon Sep  9 08:17:59 2024
/opt/firebird/bin/fbguard: /opt/firebird/bin/fbserver normal shutdown.



localhost.localdomain (Client) Mon Sep  9 08:18:14 2024
/opt/firebird/bin/fbguard: guardian starting /opt/firebird/bin/fbserver



localhost.localdomain (Server) Mon Sep  9 08:34:21 2024
INET/inet_error: read errno = 9


localhost.localdomain (Server) Mon Sep  9 09:07:26 2024
INET/inet_error: read errno = 9

Clueless at the moment and I have exhausted chatgpt as I am not a senior but still could not find the root cause. These errors are regular and when the application freezes, the firebird service is still running. 

Can only think of one error that is consistent on how the application is usually freezing on more than 50 connections but there have been cases it has done so on way less than 50 connections but only happens on the Monday morning. 

Checked resources for hardware issues, could not find anything. Checked the firebird.conf and it doesn't have any max connections setting to increase. checked the scheduled tasks and cron jobs and nothing is interfering. 

Willing to provide more information if needed, please help.

Best regards,
Abdul 

Karol Bieniaszewski

unread,
Sep 9, 2024, 7:21:24 AM9/9/24
to firebird...@googlegroups.com

Hi

 

Look at output of gstat -h

And check if your application handle transaction correctly.

There are infos like:

 

Oldest transaction      166

        Oldest active           167

        Oldest snapshot         167

        Next transaction        170

 

 

For details you can run some select on MON$ tables to see where the exact problem is.

 

PS. Which Firebird version?

 

Regards,

Karol Bieniaszewski

--
You received this message because you are subscribed to the Google Groups "firebird-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/firebird-support/6de2ceea-a34d-4d4e-be58-34c977e9bd52n%40googlegroups.com.

 

Abdul Muqtadir

unread,
Sep 9, 2024, 9:57:34 PM9/9/24
to firebird-support
Hi Karol, 

Thanks for your reply.

The firebird version is  Firebird 2.5<LI-V2.5.2.26540.

Ran gstat -h on one of the .fdb.  

Database header page information:
        Flags                   0
        Checksum                12345
        Generation              19744
        Page size               4096
        ODS version             11.1
        Oldest transaction      17138
        Oldest active           17139
        Oldest snapshot         17139
        Next transaction        17140
        Bumped transaction      1
        Sequence number         0
        Next attachment ID      2614
        Implementation ID       16
        Shadow count            0
        Page buffers            0
        Next header page        0
        Database dialect        3
        Creation date           May 24, 2016 14:24:40
        Attributes              force write

    Variable header data:
        Sweep interval:         20000
        *END*

Please let me know if you need more information. I am currently speaking to the application team as well to see if there is something on their end that is stopping it. 

Cheers,
Abdul 

Karol Bieniaszewski

unread,
Sep 10, 2024, 1:57:34 AM9/10/24
to firebird...@googlegroups.com

Hi

 

Few things.

  1. You are using discontinued version of Firebird and also 2.5.2 when the latest is 2.5.9 in the series.
  2. Use gstat -h when you have problems with db, not after restore 😉.
  3. You are using really low page size (4096).
  4. Page buffers are 0 in db, what is DefaultDBCachePages in Firebird.conf?
  5. What is server type, classic, superserver?

Abdul Muqtadir

unread,
Sep 10, 2024, 10:26:05 AM9/10/24
to firebird-support
Hi,

I really appreciate you being kind. 

I'll have to wait till next Monday morning to run gstat -h because that's the only time I have to restart and the only time the application stops working for our users.  

#DefaultDbCachePages = 2048 in firebird.conf.

SuperServer
 is running, based on the presence of the fbserver process.

Still stuck on the same issue, why do I have to restart firebird on Monday and why does it usually logs it like "Shutting down the server with 67 active connection(s) to 2 database(s), 0 active service(s)", to 2 databases is consistent on the firebird.log with a lots of INET/inet_error: read errno = 104 when I end up having to restart.

Can provide more information if you need?

The below are the gstat results of the few .GDB databases that our app is related to. 

Main Database


Database header page information:
        Flags                   0
        Checksum                12345
        Generation              6199492
        Page size               4096
        ODS version             11.2
        Oldest transaction      6164270
        Oldest active           6164271
        Oldest snapshot         6164271
        Next transaction        6164272

        Bumped transaction      1
        Sequence number         0
        Next attachment ID      373068
        Implementation ID       19

        Shadow count            0
        Page buffers            0
        Next header page        0
        Database dialect        3
        Creation date           Nov 20, 2023 12:06:14

        Attributes              force write

    Variable header data:
        Sweep interval:         20000
        *END*


Archive database
Database header page information:
        Flags                   0
        Checksum                12345
        Generation              67700

        Page size               4096
        ODS version             11.1
        Oldest transaction      62269
        Oldest active           67315
        Oldest snapshot         67315
        Next transaction        67316

        Bumped transaction      1
        Sequence number         0
        Next attachment ID      12887

        Implementation ID       16
        Shadow count            0
        Page buffers            0
        Next header page        0
        Database dialect        3
        Creation date           May 19, 2014 16:32:15

        Attributes              force write

    Variable header data:
        Sweep interval:         20000
        *END*

3rd Databse file


Database header page information:
        Flags                   0
        Checksum                12345
        Generation              65439

        Page size               4096
        ODS version             11.1
        Oldest transaction      65424
        Oldest active           65425
        Oldest snapshot         65425
        Next transaction        65426

        Bumped transaction      1
        Sequence number         0
        Next attachment ID      2242
        Implementation ID       24

        Shadow count            0
        Page buffers            0
        Next header page        0
        Database dialect        3
        Creation date           Jun 6, 2011 10:15:01

        Attributes              force write

    Variable header data:
        Sweep interval:         20000
        *END*

Cheers,
Abdul 

Dimitry Sibiryakov

unread,
Sep 10, 2024, 10:37:42 AM9/10/24
to firebird...@googlegroups.com
Abdul Muqtadir wrote 10.09.2024 16:26:
> Still stuck on the same issue, why do I have to restart firebird on Monday and
> why does it usually logs it like "Shutting down the server with 67 active
> connection(s) to 2 database(s), 0 active service(s)", to 2 databases is
> consistent on the firebird.log with a lots of INET/inet_error: read errno = 104
> when I end up having to restart.

You must read the message literally: 67 connections are established to 2
databases at the moment when you decided to restart your server.
If your server is not locked for new attachments completely you'd better to
find out what it is busy with using monitoring tables. Perhaps you or someone
else scheduled a long process that uses a transaction with unusually high
isolation level.
Audit service can help you to track such situation.

--
WBR, SD.

Karol Bieniaszewski

unread,
Sep 10, 2024, 10:54:00 AM9/10/24
to firebird...@googlegroups.com

I do not know how big is your database but

pageSize * DefaultDbCachePages = 4096 * 2048 = 8 MB cache memory used for support your database 😉

Abdul Muqtadir

unread,
Sep 10, 2024, 12:09:04 PM9/10/24
to firebird-support
Main db is 2.6GB, archives are in hundreds.

will have to wait till Monday morning to troubleshoot this I guess.

Will let you know, will have a few minutes to run diagnostics before I have to restart as it halts production workers on the floor. 

Sorry about the incompetence, I am not a senior and just taking this opportunity at work to learn.

Can update I suppose but I will never find the root cause that made someone from my team login a couple of hours early every monday morning. 

Anymore suggestions in the meanwhile would be greatly appreciated.

Cheers,

Dimitry Sibiryakov

unread,
Sep 10, 2024, 12:31:32 PM9/10/24
to firebird...@googlegroups.com
Abdul Muqtadir wrote 10.09.2024 18:09:
> Sorry about the incompetence, I am not a senior and just taking this opportunity
> at work to learn.

If you a not a senior most likely you lack access level required for such
investigation.
But at least you can start from finding out what exactly "application stops
loading data" mean. Does it return an error? Does it wait for something?
If it waits - find out exactly what it is waiting for with precision up to
Firebird API call. Then you can proceed to finding out what can cause this wait.

Probably, the application developer was furious about the firing order and
planted a time bomb into the app in retaliation...

--
WBR, SD.

Abdul Muqtadir

unread,
Sep 11, 2024, 4:26:00 AM9/11/24
to firebird-support
Hi SD & Karol,

Really appreciate your replies.

Regarding,"pageSize * DefaultDbCachePages = 4096 * 2048 = 8 MB cache memory used for support your database 😉"

     I am leaning towards this being the root cause as cannot think of anything else. 

Regarding, But at least you can start from finding out what exactly "application stops
loading data" mean. Does it return an error? Does it wait for something?
If it waits - find out exactly what it is waiting for with precision up to
Firebird API call. Then you can proceed to finding out what can cause this wait.

Probably, the application developer was furious about the firing order and
planted a time bomb into the app in retaliation..."

                   I have reached out to the app developer and will hear back soon regarding this, for now the app just keeps loading forever during the outage and is usually fast when it works.

Regarding, " If your server is not locked for new attachments completely you'd better to

find out what it is busy with using monitoring tables. Perhaps you or someone
else scheduled a long process that uses a transaction with unusually high
isolation level.''

                      I have readied a script that runs gstat -h on all 3 databases and will run it during downtime. I will also try to telnet <firebird_server> 3050 from the client machine. Will also query the mon tables. Please add anything you would do to find the root cause. 

Please find the attached screenshot, maybe you can deduce something out of it. Also attaching firebird.log. Can provide more information if needed.

WBR, Abdul

image.png
firebird.log

Mark Rotteveel

unread,
Sep 11, 2024, 4:29:58 AM9/11/24
to firebird...@googlegroups.com
On 11/09/2024 10:25, Abdul Muqtadir wrote:
> Hi SD & Karol,
>
> Really appreciate your replies.
>
> Regarding,"pageSize * DefaultDbCachePages = 4096 * 2048 = *_8 MB_*_cache
> memory_ used for support your database 😉"
>
>      I am leaning towards this being the root cause as cannot think of
> anything else.

You should start with upgrading to Firebird 2.5.9, you're missing 7
bugfix versions, which, IIRC, also were crashes and hangs.

Ultimately, you should also upgrade to a supported version, like
Firebird 5, but that will be more involved than a point release upgrade.

Mark
--
Mark Rotteveel

Dimitry Sibiryakov

unread,
Sep 11, 2024, 5:22:41 AM9/11/24
to firebird...@googlegroups.com
Abdul Muqtadir wrote 11.09.2024 10:25:
> for now the app just keeps loading forever during the outage and is usually fast when it works.

This is where you must use debugger to find out what exactly is "done forever".

> Please find the attached screenshot, maybe you can deduce something out of it.
> Also attaching firebird.log.

The log says that the application is often crashing and has a very bad
control over transactions lifetime.
Also perhaps there are issues with firewall or antivirus that blocks
secondary events connections.
Output of `top` shows high CPU load by Firebird which means that the server
is busy with something. Audit is a good way to find out what makes it busy.

--
WBR, SD.

Karol Bieniaszewski

unread,
Sep 11, 2024, 7:43:10 AM9/11/24
to firebird...@googlegroups.com

Dimitry - about „Timeout occurred while waiting for a secondary connection for event processing” this issue occurred for us too.

And starting clearly new app even on different computer was not possible as Firebird stopped responding for events connections.

It respond for normal connections without events, but events stopped working.

Only restart of the Firebird service helped, no changes in the firewall was required at all. So looks like some issue with FB itself is possible here too.

 

Regards,

Karol Bieniaszewski

 

Od: 'Dimitry Sibiryakov' via firebird-support
Wysłano: środa, 11 września 2024 11:22
Do: firebird...@googlegroups.com
Temat: Re: [firebird-support] Restart works, errno = 104 Firebird 2.5<LI-V2.5.2.26540

 

Abdul Muqtadir wrote 11.09.2024 10:25:

--

You received this message because you are subscribed to the Google Groups "firebird-support" group.

To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.

Dimitry Sibiryakov

unread,
Sep 11, 2024, 7:55:30 AM9/11/24
to firebird...@googlegroups.com
'Karol Bieniaszewski' via firebird-support wrote 11.09.2024 13:43:
> Dimitry - about „Timeout occurred while waiting for a secondary connection for
> event processing” this issue occurred for us too.
>
> And starting clearly new app even on different computer was not possible as
> Firebird stopped responding for events connections.
>
> It respond for normal connections without events, but events stopped working.
>
> Only restart of the Firebird service helped, no changes in the firewall was
> required at all. So looks like some issue with FB itself is possible here too.

Perhaps related to https://github.com/FirebirdSQL/firebird/issues/8017

--
WBR, SD.

Karol Bieniaszewski

unread,
Sep 11, 2024, 8:35:39 AM9/11/24
to firebird...@googlegroups.com

Yes, it looks exactly the same.

 

Regards,

Karol Bieniaszewski

 

Od: 'Dimitry Sibiryakov' via firebird-support
Wysłano: środa, 11 września 2024 13:55
Do: firebird...@googlegroups.com
Temat: Re: [firebird-support] Restart works, errno = 104 Firebird 2.5<LI-V2.5.2.26540

 

'Karol Bieniaszewski' via firebird-support wrote 11.09.2024 13:43:

--

You received this message because you are subscribed to the Google Groups "firebird-support" group.

To unsubscribe from this group and stop receiving emails from it, send an email to firebird-suppo...@googlegroups.com.

Abdul Muqtadir

unread,
Sep 11, 2024, 9:15:14 AM9/11/24
to firebird-support
Hi All, 

Is there any other information I can provide which might be of help?

Forgot to mention, the restarts you can see in the firebird.log are all either done manually or with a cron job around 4AM, 5&5:30 all by my teammate who was trying to see if a restart in the early morning will fix this issue. 

The users on production floor start at 5:30am and don't have any issues till around 7am, so cannot set a cron job to restart around this time. 

Next Monday I will run gstat -h, query mon tables, check if 3050 is accepting more connections  

Just dumping a few more outputs, all these commands below were run during downtime.

[root@localhost bin]# ulimit -n

1024

[root@localhost bin]# sysctl net.core.somaxconn

net.core.somaxconn = 128


[root@localhost firebird]# pstree -p | grep fbserver

           |-fbguard(26664)---fbserver(26665)-+-{fbserver}(26669)

           |                                  |-{fbserver}(26671)

           |                                  |-{fbserver}(26710)

           |                                  |-{fbserver}(26711)

           |                                  |-{fbserver}(26712)

           |                                  |-{fbserver}(26713)

           |                                  |-{fbserver}(26714)

           |                                  |-{fbserver}(3249)

           |                                  |-{fbserver}(3503)

           |                                  |-{fbserver}(3505)

           |                                  |-{fbserver}(6098)

           |                                  |-{fbserver}(8503)

           |                                  |-{fbserver}(11447)

           |                                  |-{fbserver}(11764)

           |                                  |-{fbserver}(11770)

           |                                  `-{fbserver}(12297)

[root@localhost firebird]# /usr/sbin/service firebird status

Firebird server [default] is running (pid 26665)

[root@localhost firebird]# free -h

              total        used        free      shared  buff/cache   available

Mem:           5.5G        1.5G        285M        148M        3.8G        3.6G

Swap:           15G        294M         15G


[root@localhost firebird]# netstat -an | grep 3050

tcp        0      0 0.0.0.0:3050            0.0.0.0:*               LISTEN

tcp        0      0 *.*.*.*  :3050          **********  :57204        ESTABLISHED

*more than 50 established user connections here below*

===================

[root@localhost firebird]# lsof -i :3050

COMMAND    PID     USER   FD   TYPE    DEVICE SIZE/OFF NODE NAME

fbserver 26665 firebird    0u  IPv4 300649456      0t0  TCP *:gds_db (LISTEN)

fbserver 26665 firebird    3u  IPv4 300768648      0t0  TCP localhost.localdomain:gds_db->************************:56512 (ESTABLISHED)

*more than 50 established user connections here below*

===============================

Best Regards,
Abdul 

Abdul Muqtadir

unread,
Sep 17, 2024, 12:08:01 AM9/17/24
to firebird-support
Hi All,

Our outage was back this Monday around 7AM, I managed to run a few diagnostics around downtime. 

Attaching a few logs below if someone can take a look.

I am waiting on the app vendor to get back to me, they have also mentioned that they only run Firebird 2.5<LI-V2.5.2.26540 on all their customers and have plans to upgrade in the future and no customer has this issue.

Please have a look and let me know if there is anyway I can fix this on my end or if you need more information. 

Cheers,
Abdul 

FS_consolelog.txt

Karol Bieniaszewski

unread,
Sep 17, 2024, 2:23:30 AM9/17/24
to firebird...@googlegroups.com

Hi

 

Looking at the logs, nothing stands out. However, there are multiple updates recorded on the same table.

You can check the full gstat to see if there aren't too many record versions on the updated table.

There is a small gap in transactions, but it isn't significant (Oldest active vs. Next transaction).

 

However, without knowing the exact operation that is slow for you and causing you to stop the service, it's difficult for us to pinpoint the cause.

 

Regards,

Karol Bieniaszewski

Abdul Muqtadir

unread,
Sep 18, 2024, 6:13:15 AM9/18/24
to firebird-support
Hi Karol,

Really appreciate your help here.

What do you think about the below table? Does it point me to look somewhere to find the root cause? The queries were here for more than 45 minutes until I restarted and they all disappeared from the below table and the app started working for the users.

MON$TRANSACTION_ID MON$ATTACHMENT_ID MON$STATE MON$TIMESTAMP ================== ================= ========= ========================= 6298250 383973 1 2024-09-16 06:59:46.6620 6298285 383977 1 2024-09-16 07:00:07.0460 6298286 383976 1 2024-09-16 07:00:07.0680 6298298 383776 1 2024-09-16 07:01:31.2310 6298398 383995 1 2024-09-16 07:03:31.1580 6298405 383993 1 2024-09-16 07:04:03.1380 6298797 384029 1 2024-09-16 07:17:31.8730 6298979 384037 1 2024-09-16 07:22:28.4940 6298980 384037 1 2024-09-16 07:22:28.5290

What about this sql text, is this normal?

MON$SQL_TEXT:
update jigs set jig_job = ? where jig_id = ?

Where would you have me look next? I am just curious as to why I am unable to find the root cause. Are there any tools I can use to provide more information?

Kind Regards,
Abdul

Dimitry Sibiryakov

unread,
Sep 18, 2024, 6:19:36 AM9/18/24
to firebird...@googlegroups.com
Abdul Muqtadir wrote 18.09.2024 12:13:
> What about this sql text, is this normal?
>
> MON$SQL_TEXT:
> update jigs set jig_job = ? where jig_id = ?

What do you mean "normal"? It is a valid SQL query. What it is supposed to do
you must ask database and application developer.

> Where would you have me look next? I am just curious as to why I am unable to
> find the root cause. Are there any tools I can use to provide more information?

Yes, Trace and Audit Service is very useful for performance troubleshooting.
You are unable to find the root of the problem because you don't know how the
application really works. Examining trace logs can help you to find it out.

--
WBR, SD.

Abdul Muqtadir

unread,
Sep 21, 2024, 4:09:38 AM9/21/24
to firebird-support
Hi SD,

Thanks for the support.

I have enabled GUI for better view on this server and also setup network monitoring with cronjobs around the outage time.

I have enabled fbtrace and have confirmed that it is logging.

But it has logged 1MB on the weekend with no activity to 1MB in one hour. 

Is the logging I enabled too extensive? I took the backups before updating configs and I am attaching the updated fbtrace.conf & firebird.conf files below. 

Please let me know if there is anything I should change. 

Best Regards,
Abdul 
firebird.conf
fbtrace (1).conf

Dimitry Sibiryakov

unread,
Sep 21, 2024, 5:51:00 AM9/21/24
to firebird...@googlegroups.com
Abdul Muqtadir wrote 21.09.2024 10:09:
> I have enabled fbtrace and have confirmed that it is logging.
>
> But it has logged 1MB on the weekend with no activity to 1MB in one hour.
>
> Is the logging I enabled too extensive?

If it let you find the reason for outages - no. 1M is not that big, you can
read such volume even with naked eyes.

--
WBR, SD.

Abdul Muqtadir

unread,
Sep 26, 2024, 12:28:14 PM9/26/24
to firebird-support
Hi SD & Karol,

Had enabled logging last Saturday morning and stopped Monday at 9:58am.

Key takeaways from Audit Trace logs:
Log stats:- Total size: 512MB, Total length: 536,582,200, Total lines: 11,540,543

- Search "violation" (240466 hits in 1 file of 1 searched)
- Search "10.3.88.127" (790134 hits in 1 file of 1 searched)
- Search "SYSDBA" (775256 hits in 1 file of 1 searched)
- Search "error" (241910 hits in 1 file of 1 searched)

- 90% of Violation are these logs "Line 11528183: 335544466 : violation of FOREIGN KEY constraint "TRUSSDATA_CAMBER_FK" on table "TRUSSDATA_CAMBER""
- All logs after 07:00:05 are user "SYSDBA:NONE, NONE, TCPv4:10.3.88.127"

example log: 
2024-09-23T09:04:36.3710 (27247:0xebbb28f8) ERROR AT jrd8_execute
/home/storage/network/files/ProdDatabase/PM-ARCHIVE.GDB (ATT_13147, SYSDBA:NONE, NONE, TCPv4:10.3.88.127)
335544466 : violation of FOREIGN KEY constraint "TRUSSDATA_CAMBER_FK" on table "TRUSSDATA_CAMBER"
335544838 : Foreign key reference target does not exist

2024-09-23T09:04:36.3720 (27247:0xebbb28f8) EXECUTE_STATEMENT_START
/home/storage/network/files/ProdDatabase/PM-ARCHIVE.GDB (ATT_13147, SYSDBA:NONE, NONE, TCPv4:10.3.88.127)
(TRA_68092, READ_COMMITTED | REC_VERSION | WAIT | READ_WRITE)

- I restarted at 9:58 and these errors stopped exactly that time.
- Out of more than 48 hours of logging, 90% of the logs are from 7am-9:58am.
- first time violation appears here

Statement 48:
-------------------------------------------------------------------------------
INSERT INTO COUNTRY(COUNTRY."COUNTRY_ABBR", COUNTRY."COUNTRY_CAPITAL", COUNTRY."COUNTRY_CODE", COUNTRY."COUNTRY_FLAG_ICON", COUNTRY."COUNTRY_NAME", COUNTRY."COUNTRY_NUMBER") VALUES (?, ?, ?, ?, ?, ?)

param0 = char(3), "AND"
param1 = varchar(80), "Andorra"
param2 = char(2), "AD"
param3 = blob, "<NULL>"
param4 = varchar(80), "ANDORRA"
param5 = smallint, "20"


2024-09-23T07:00:05.9630 (27247:0xebbb28f8) ERROR AT jrd8_execute
/home/storage/network/files/ProdDatabase/PM-ARCHIVE.GDB (ATT_13147, SYSDBA:NONE, NONE, TCPv4:10.3.88.127)
335544665 : violation of PRIMARY or UNIQUE KEY constraint "PK_COUNTRY" on table "COUNTRY"

2024-09-23T07:00:05.9690 (27247:0xebbb28f8) EXECUTE_STATEMENT_START
/home/storage/network/files/ProdDatabase/PM-ARCHIVE.GDB (ATT_13147, SYSDBA:NONE, NONE, TCPv4:10.3.88.127)
(TRA_68092, READ_COMMITTED | REC_VERSION | WAIT | READ_WRITE)
 
Please advise, I'll dig deeper in the logs.

Best regards,
Abdul

Dimitry Sibiryakov

unread,
Sep 28, 2024, 6:29:13 AM9/28/24
to firebird...@googlegroups.com
Abdul Muqtadir wrote 26.09.2024 18:28:
> Please advise, I'll dig deeper in the logs.

You've got enough information for now. Start fixing these errors.

"time_treshold" setting can reduce log size limiting it to slow queries only.

--
WBR, SD.

Abdul Muqtadir

unread,
Oct 2, 2024, 4:11:12 AM10/2/24
to firebird-support
Hi SD & Karol,

Thanks for your support so far, I managed to get a troubleshooting session with the support persons of our vendor because of the logs showing its their issue.

They have suggested to change the time of the database archiving to out of working hours now which is a feature within the app which was set to run at 7AM on Mondays, absolutely insane I know.

Wouldn't have figured it out without your help which has garnered me a lot of praise today like, "We had a linux expert contractor look at this issue but he couldn't find the root cause and we got our own internal linux expert now" from my manager.

I'll keep you updated as we move closer to completely close this case next Monday hopefully as this Monday there was no outage as I had changed the name of the archiving database itself to something random and the app wasn't able to connect to the database and the outage did not happen.

Only question I have is from the above attached fbtrace.conf file, why is it not logging anything regarding services? It logs everything regarding databases to the audittrace.log 512MB file but the audittraceservices.log 0KB is completely empty I used the same config file that I have uploaded here to test. 

Please advise if I should make any changes to the config file so that I can enable services logging as well, I made sure the .log files have same permissions to be written to.

Many thanks again for your support. 

Cheers,
Abdul 

Mark Rotteveel

unread,
Oct 2, 2024, 4:17:44 AM10/2/24
to firebird...@googlegroups.com
On 02/10/2024 10:11, Abdul Muqtadir wrote:
> Only question I have is from the above attached fbtrace.conf file, why
> is it not logging anything regarding services? It logs everything
> regarding databases to the audittrace.log 512MB file but
> the audittraceservices.log 0KB is completely empty I used the same
> config file that I have uploaded here to test.

At first glance, that config file looks OK, but I'm not an expert in
using the trace facility. Maybe there are simply no service API calls done?

Mark
--
Mark Rotteveel

Abdul Muqtadir

unread,
Oct 2, 2024, 4:51:40 AM10/2/24
to firebird-support
Yeah, you are right but I had enabled logging for 3 days which also included firebird restarts with creation of .GBK files every weekday at 2AM.

We have a cronjob running to create those .GBK files every weekday. What kind of database backups will get logged in that file? 

Thanks,
Abdul

Mark Rotteveel

unread,
Oct 2, 2024, 5:06:40 AM10/2/24
to firebird...@googlegroups.com
On 02/10/2024 10:51, Abdul Muqtadir wrote:
> Yeah, you are right but I had enabled logging for 3 days which also
> included firebird restarts with creation of .GBK files every weekday at 2AM.
>
> We have a cronjob running to create those .GBK files every weekday. What
> kind of database backups will get logged in that file?

Database backups that are performed through the service API, e.g. if you
use the -se option with gbak.

Mark
--
Mark Rotteveel
Reply all
Reply to author
Forward
0 new messages