Skip to content

Go routine memory allocation issue #181

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

Closed
rlagyu0 opened this issue Feb 25, 2025 · 9 comments
Closed

Go routine memory allocation issue #181

rlagyu0 opened this issue Feb 25, 2025 · 9 comments

Comments

@rlagyu0
Copy link
Contributor

rlagyu0 commented Feb 25, 2025

error emit like below

ts=2025-02-25T07:55:33.803Z caller=collector.go:511 level=debug msg="Calling function ScrapeGenericValues()"
ts=2025-02-25T07:55:33.803Z caller=collector.go:616 level=debug msg="Calling function GeneratePrometheusMetrics()"
double free or corruption (out)
SIGABRT: abort
PC=0x7f756d1235ef m=0 sigcode=18446744073709551610
signal arrived during cgo execution

Typically, it fetches data successfully for the first 2-3 times, but it seems that during the memory allocation/deallocation process of goroutines, they get tangled, leading to issues with duplicate memory allocation or deallocation. Please provide your opinion.

rlagyu0 added a commit to rlagyu0/oracle-db-appdev-monitoring that referenced this issue Feb 25, 2025
rlagyu0 added a commit to rlagyu0/oracle-db-appdev-monitoring that referenced this issue Feb 25, 2025
rlagyu0 pushed a commit to rlagyu0/oracle-db-appdev-monitoring that referenced this issue Feb 26, 2025
markxnelson pushed a commit that referenced this issue Feb 26, 2025
* #181 issue 181 seperate only error and scrape error

Co-authored-by: DESKTOP-0U07UK2\kpcard <rlagyu0>
@RainerW
Copy link

RainerW commented Feb 27, 2025

Same problem, with 1.5.3, but 1.5.2 seems to work.

@markxnelson
Copy link
Member

thanks @RainerW - i think we are narrowing in on the issue. seems to only happen with godror 0.46.0 and later, not earlier versions. doing more debugging to try to isolate the root cause

@anders-swanson
Copy link
Member

See: godror/godror#361

@anders-swanson
Copy link
Member

In testing, using connection pooling parameters resolved the issue. However, let's see what godror maintainers think :)

@markxnelson
Copy link
Member

We believe we have this fixed in 1.5.4 - if you still see the error, please reopen, or open a new issue to let you know. Thanks very much for your input.

@VictorErmakov
Copy link
Contributor

@markxnelson, unfortunately I still face this issue in 1.5.4

@anders-swanson
Copy link
Member

@VictorErmakov can you share the parameters used for the exporter, as well as the following details about the environment you're running it on:

  • OS
  • Architecture
  • Containerized or bare metal/VM?
  • version of instant client
  • version of glibc

In my testing, I found that increasing the maximum idle connections can resolve this problem:

      --database.maxIdleConns=10
      --database.maxOpenConns=10

@VictorErmakov
Copy link
Contributor

@anders-swanson
OS: Ubuntu 22.04.3 LTS
Architecture: x86_64
Container: docker-compose
glibc: ldd (Ubuntu GLIBC 2.35-0ubuntu3.9) 2.35

Following parameters helped! At least it does not throw an error in the first 10 minutes!

Probably it should be added in the example compose file.

Thanks!

@anders-swanson
Copy link
Member

Perfect, thanks for opening the PR. I am hopeful future versions of godror will handle this better too.

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

No branches or pull requests

5 participants