sql_exporter icon indicating copy to clipboard operation
sql_exporter copied to clipboard

IBM DB2 support

Open nubenum opened this issue 6 years ago • 4 comments

I have adapted this project to support IBM DB2 and added some example metrics: https://github.com/nubenum/sql_exporter

Maybe it comes in handy for someone else. I would be glad to make a pull request, however, since there are so many added dependencies, it's probably not worth it to add it for everyone. I'm not sure if one could adapt the build process to conditionally only include required dependencies. Maybe you want to have a look at it, otherwise, this issue is just informational and can be closed.

nubenum avatar Aug 06 '19 07:08 nubenum

+1 for pull request!

brunowego avatar Jan 30 '20 13:01 brunowego

when i make build, i got this

>> building binaries
 >   sql_exporter
# github.com/ibmdb/go_ibm_db/api
../../go/pkg/mod/github.com/ibmdb/[email protected]/api/api_unix.go:13:11: fatal error: sqlcli1.h: No such file or directory
   13 | // #include <sqlcli1.h>
      |           ^~~~~~~~~~~
compilation terminated.
!! command failed: build -o /home/vagrant/lbproject/sql_exporter/sql_exporter -ldflags -X github.com/prometheus/common/version.Version=0.5 -X github.com/prometheus/common/version.Revision=6f96b0d6b40340929e4d84c902378e7ead113ff1 -X github.com/prometheus/common/version.Branch=master -X github.com/prometheus/common/version.BuildUser=vagrant@debian11-1-11-dev -X github.com/prometheus/common/version.BuildDate=20230201-09:52:22  -a -tags netgo github.com/free/sql_exporter/cmd/sql_exporter: exit status 2
make: *** [Makefile:49:build] 错误 1

what can i do?Thanks.

dartagnanli avatar Feb 01 '23 09:02 dartagnanli

Not sure, but as can be seen from the Makefile I adapted, I think you have to run make all or at least run make depend before make build. Disclaimer: I haven't looked at it for a very long time and both the upstream and my fork are obviously not maintained (but other forks are apparently).

nubenum avatar Feb 01 '23 10:02 nubenum

ok,i have resolved it,thank you every much.please see this link if necessary

dartagnanli avatar Feb 02 '23 09:02 dartagnanli