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

plugin: input.mysql: 'innodb_available_undo_logs' different datatype #8319

Closed
eraac opened this issue Oct 26, 2020 · 0 comments · Fixed by #9403
Closed

plugin: input.mysql: 'innodb_available_undo_logs' different datatype #8319

eraac opened this issue Oct 26, 2020 · 0 comments · Fixed by #9403
Labels
area/mysql bug unexpected problem or unintended behavior

Comments

@eraac
Copy link
Contributor

eraac commented Oct 26, 2020

System info:

Telegraf 1.15.2 (git: HEAD cd037b4)
plugin: inputs.mysql (one for master and one for slave)
influxdb: v2-rc2 - I didn't have any issue with v2-beta16

Config

##########
# MASTER #
##########

[[inputs.mysql]]
  servers = ["probe:${CORE_DB_PASSWORD}@tcp(xxxx:3306)/"]
  metric_version = 2

  gather_table_schema = false
  gather_process_list = true
  gather_user_statistics = false
  gather_info_schema_auto_inc = false
  gather_innodb_metrics = false
  gather_slave_status = false
  gather_binary_logs = false
  gather_global_variables = true
  gather_table_io_waits = false
  gather_table_lock_waits = false
  gather_index_io_waits = false
  gather_event_waits = false
  gather_file_events_stats = false
  gather_perf_events_statements = false

[[inputs.mysql]]
  servers = ["probe:${CORE_DB_PASSWORD}@tcp(xxx:3307)/"]
  metric_version = 2

  gather_table_schema = false
  gather_process_list = true
  gather_user_statistics = false
  gather_info_schema_auto_inc = false
  gather_innodb_metrics = false
  gather_slave_status = false
  gather_binary_logs = false
  gather_global_variables = true
  gather_table_io_waits = false
  gather_table_lock_waits = false
  gather_index_io_waits = false
  gather_event_waits = false
  gather_file_events_stats = false
  gather_perf_events_statements = false

[[outputs.influxdb_v2]]
  urls = ["${INFLUXDB_URL}"]

  token = "${INFLUXDB_TOKEN}"
  organization = "xxx"
  bucket = "telegraf"
  bucket_tag = "bucket"
  exclude_bucket_tag = true

Expected behavior:

Field innodb_available_undo_logs should have the same data type

Actual behavior:

Field innodb_available_undo_logs has different data type (int for master, float for slave)

Additional info:

master: SHOW GLOBAL STATUS:

innodb_available_undo_logs: 128

slave: SHOW GLOBAL STATUS:

innodb_available_undo_logs: 18446744073709551615

telegraf --config input_mysql.conf --test:

> mysql,host=xxxx,server=xxxx:3306 innodb_available_undo_logs=128i,innodb_num_open_files=278i,innodb_os_log_pending_fsyncs=0i,innodb_os_log_pending_writes=0i,innodb_os_log_written=512i,innodb_page_size=16384i,innodb_pages_created=420253i,innodb_pages_read=2678435i,innodb_pages_written=0i,innodb_row_lock_current_waits=0i,innodb_row_lock_time=106780i,innodb_row_lock_time_avg=17i,innodb_row_lock_time_max=20866i,innodb_row_lock_waits=5987i,innodb_rows_deleted=339344i,innodb_rows_inserted=3017851i,innodb_rows_read=10347509999129i,innodb_rows_updated=31345161i,innodb_truncated_status_writes=0i,key_blocks_not_flushed=0i 1603728599000000000
> mysql,host=xxxx,server=xxxx:3307 innodb_available_undo_logs=18446744073709552000,innodb_num_open_files=4442i,innodb_os_log_pending_fsyncs=0i,innodb_os_log_pending_writes=0i,innodb_os_log_written=0i,innodb_page_size=16384i,innodb_pages_created=0i,innodb_pages_read=830425i,innodb_pages_written=0i,innodb_row_lock_current_waits=0i,innodb_row_lock_time=0i,innodb_row_lock_time_avg=0i,innodb_row_lock_time_max=0i,innodb_row_lock_waits=0i,innodb_rows_deleted=0i,innodb_rows_inserted=0i,innodb_rows_read=10081762371564i,innodb_rows_updated=0i,innodb_truncated_status_writes=0i,key_blocks_not_flushed=0i 1603728599000000000

error

2020-10-26T15:42:00Z E! [agent] Error writing to outputs.influxdb_v2: 500 Internal Server Error: internal error: unexpected error writing points to database: partial write: field type conflict: input field "innodb_available_undo_logs" on measurement "mysql" is type float, already exists as type integer dropped=8

Under outputs.influxdb_v2, I see a parameter influx_uint_support, does this solve the issue?

@eraac eraac added the bug unexpected problem or unintended behavior label Oct 26, 2020
fxedel added a commit to fxedel/telegraf that referenced this issue Jun 21, 2021
fxedel added a commit to fxedel/telegraf that referenced this issue Jun 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/mysql bug unexpected problem or unintended behavior
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants