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

Symbol incorrectly written to table in 7.4.2 when multiple processes sending to QuestDB #4481

Closed
1 task done
sevenjay opened this issue May 8, 2024 · 7 comments · Fixed by #4507
Closed
1 task done
Labels
Bug Incorrect or unexpected behavior ILP Issues or changes relating to Influx Line Protocol

Comments

@sevenjay
Copy link

sevenjay commented May 8, 2024

To reproduce

Description:

After updating QuestDB from version 7.3.7 to 7.4.2 using Docker, an issue occurred is in the same table defining different symbol names are incorrectly writing. The symbol is erroneously written as the default one.

The write method uses from questdb.ingress import Sender and is performed by two separate Python processes. The symbol names have been verified to be correct. Over the past three days, this issue has occurred 3 times, each time after approximately 160 to 240 records have been written by each process. During the occurrence, which lasts for about 5 minutes, almost all writes are incorrectly attributed to the other symbol.

For example below, the symbols represent different exchanges, with one process responsible for Binance and the other for Upbit. During normal operation, without any process interruption, when each process has written after ablut 160 to 240 records, all Upbit records are incorrectly written as Binance. It has been confirmed that the sent Exchange name is indeed Upbit.
image

image

This issue started occurring after updating from version 7.3.7 to 7.4.2. Only the storage location moved, and the server IP changed, all other settings and envirment remained unchanged.

Steps to reproduce:

After updating QuestDB from version 7.3.7 to 7.4.2 using Docker

  1. Set up two Python processes, each defining a different symbol name (e.g., Binance and Upbit).
  2. Use from questdb.ingress import Sender to write data to the same table from both processes.
  3. Monitor the table after each process has written after about 160 to 240 records. (in my case about 16 to 24 hours)

Expected behavior:

Each process should correctly write its respective symbol name to the table.

Actual behavior:

After each process has written after about 160 to 240 records, in 5 minutes almost all records from one process (e.g., Upbit) are incorrectly written with the symbol name (written as the default one? e.g., Binance).

Please assist me in resolving this issue or point out any areas that need modification which I may have overlooked, to ensure consistent writing of correct symbol names into tables when using multiple processes in QuestDB. Thank you.

QuestDB version:

7.4.2

OS, in case of Docker specify Docker and the Host OS:

Ubuntu 22.04 (Docker)

File System, in case of Docker specify Host File System:

zfs

Full Name:

Jay

Affiliation:

sevenjay.tw

Have you followed Linux, MacOs kernel configuration steps to increase Maximum open files and Maximum virtual memory areas limit?

  • Yes, I have

Additional context

No response

@puzpuzpuz
Copy link
Contributor

zfs

Unfortunately, ZFS is not supported by QuestDB. This may explain the data corruption you've observed.

@sevenjay
Copy link
Author

sevenjay commented May 8, 2024

thank you,
i will try to move to ext4.

@sevenjay
Copy link
Author

sevenjay commented May 9, 2024

zfs

Unfortunately, ZFS is not supported by QuestDB. This may explain the data corruption you've observed.

@puzpuzpuz how about BTRFS? My original QuestDB server works on Btrfs.
And someone seems works fine #1784 (comment)

@puzpuzpuz
Copy link
Contributor

@sevenjay we only run tests on ext4 and xfs, so btrfs is terra incognita. You could try running our test suite on btrfs. If it passes, it's a good sign.

@nwoolmer
Copy link
Contributor

@sevenjay We plan to release ZFS support in open source soon, possibly next release.

@sevenjay
Copy link
Author

@sevenjay We plan to release ZFS support in open source soon, possibly next release.

Wonderful, I'm really looking forward to it!

@bluestreak01 bluestreak01 added Bug Incorrect or unexpected behavior ILP Issues or changes relating to Influx Line Protocol labels May 16, 2024
@bluestreak01
Copy link
Member

ZFS is on master now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Incorrect or unexpected behavior ILP Issues or changes relating to Influx Line Protocol
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants