Details
-
Improvement
-
Status: Done
-
Medium
-
Resolution: Fixed
-
3.5.0
-
None
-
None
-
Yes
-
Yes
-
2
Description
How to Repeat
Results are for PS 5.7.40.
$ prove -vw --trap --timer t/pt-heartbeat/ [17:48:39] t/pt-heartbeat/basics.t ............... ok 1 - Dies on empty heartbeat table with --check (issue 45) ok 2 - Dies on empty heartbeat table with --monitor (issue 45) ok 3 - Automatically inserts heartbeat row (issue 1292) ok 4 - Record is there ok 5 - Output is just a number not ok 6 - It is running # Failed test 'It is running' # at t/pt-heartbeat/basics.t line 108. # '' # doesn't match '(?^:/home/sveta/src/percona-toolkit/bin/pt-heartbeat -F /tmp/12345/my.sandbox.cnf )' not ok 7 - PID file created # Failed test 'PID file created' # at t/pt-heartbeat/basics.t line 109. not ok 8 - PID file has correct PID # Failed test 'PID file has correct PID' # at t/pt-heartbeat/basics.t line 112. # got: '' # expected: undef not ok 9 - It is being updated # Failed test 'It is being updated' # at t/pt-heartbeat/basics.t line 120. # got: ' 00s [ 0.00s, 0.00s, 0.00s ]' # expected: ' 0s [ 0.00s, 0.00s, 0.00s ]' ok 10 - It is not running anymore ok 11 - PID file removed not ok 12 - It is running # Failed test 'It is running' # at t/pt-heartbeat/basics.t line 135. # '' # doesn't match '(?^:/home/sveta/src/percona-toolkit/bin/pt-heartbeat -F /tmp/12345/my.sandbox.cnf )' ok 13 - Created sentinel ok 14 - It is not running ok 15 - Sentinel file is there ok 16 - --create-table creates heartbeat table ok 17 - --create-table-engine creates heartbeat table using a non-default engine ok 18 - --check output has :port ok 19 - Heartbeat on master ok 20 - Heartbeat on slave1 ok 21 - New heartbeat on master ok 22 - No slave error ok 23 - By default, fails if the server is read_only=1 ok 24 - ...but just skips doing any work and waits if --check-read-only was specified ok 25 - Sandbox servers 1..25 # Looks like you failed 5 tests of 25. Dubious, test returned 5 (wstat 1280, 0x500) Failed 5/25 subtests [17:49:29] t/pt-heartbeat/check_schema_exists.t .. ok 1 - Sandbox servers 1..1 ok 912 ms ( 0.00 usr 0.00 sys + 0.28 cusr 0.12 csys = 0.40 CPU) [17:49:30] t/pt-heartbeat/multi_update_mode.t .... 1..29 Can't locate object method "daemonize" via package "Daemon" at /home/sveta/src/percona-toolkit/bin/pt-heartbeat line 6375. not ok 1 - --update on 12345 started # Failed test '--update on 12345 started' # at t/pt-heartbeat/multi_update_mode.t line 57. Can't locate object method "daemonize" via package "Daemon" at /home/sveta/src/percona-toolkit/bin/pt-heartbeat line 6375. not ok 2 - --update on 12346 started # Failed test '--update on 12346 started' # at t/pt-heartbeat/multi_update_mode.t line 57. Can't locate object method "daemonize" via package "Daemon" at /home/sveta/src/percona-toolkit/bin/pt-heartbeat line 6375. not ok 3 - --update on 12347 started # Failed test '--update on 12347 started' # at t/pt-heartbeat/multi_update_mode.t line 57. ok 4 - One heartbeat row on master ok 5 - Master heartbeat ok 6 - Master file and position ok 7 - No relay_master_log_file or exec_master_log_pos for master ok 8 - Two heartbeat rows on slave1 ok 9 - Slave1 has master heartbeat ok 10 - Slave1 heartbeat ok 11 - Slave1 master file and position ok 12 - Slave1 relay_master_log_file and exec_master_log_pos for master ok 13 - Three heartbeat rows on slave2 ok 14 - Slave2 has master heartbeat ok 15 - Slave2 has slave1 heartbeat ok 16 - Slave1 heartbeat ok 17 - Slave2 master file and position ok 18 - Slave2 relay_master_log_file and exec_master_log_pos for master not ok 19 - Master heartbeat ts is changing and replicating # Failed test 'Master heartbeat ts is changing and replicating' # at t/pt-heartbeat/multi_update_mode.t line 163. # '2022-12-29T17:49:31.440770' # gt # '2022-12-29T17:49:31.440770' not ok 20 - Master binlog position is changing and replicating # Failed test 'Master binlog position is changing and replicating' # at t/pt-heartbeat/multi_update_mode.t line 170. # '4605083' # > # '4605083' ok 21 - Master binlog file is not changing ok 22 - --check 12347, automatic master server_id not ok 23 - --check 12347 from --master-server-id 12346 # Failed test '--check 12347 from --master-server-id 12346' # at t/pt-heartbeat/multi_update_mode.t line 203. # '71.20 12346 # ' # doesn't match '(?^:0\.\d\d\s+12346\n)' not ok 24 - --check 12347 from --master-server-id 12345 # Failed test '--check 12347 from --master-server-id 12345' # at t/pt-heartbeat/multi_update_mode.t line 215. # '102.56 12345 # ' # doesn't match '(?^:0\.\d\d\s+12345\n)' ok 25 - Error if --master-server-id row doesn't exist ok 26 - --update on 12345 stopped ok 27 - --update on 12346 stopped ok 28 - --update on 12347 stopped ok 29 - Sandbox servers # Looks like you failed 7 tests of 29. Dubious, test returned 7 (wstat 1792, 0x700) Failed 7/29 subtests [17:51:19] t/pt-heartbeat/pt-1508.t .............. 1..2 Sleeping 4 seconds at t/pt-heartbeat/pt-1508.t line 50. # Thread started ok 1 - PT-1508 --read-only-interval ok 2 - Sandbox servers ok 9450 ms ( 0.00 usr 0.00 sys + 0.47 cusr 0.23 csys = 0.70 CPU) [17:51:28] t/pt-heartbeat/pt-1857.t .............. 1..2 ok 1 - PT-1508 --read-only-interval ok 2 - Sandbox servers ok 7262 ms ( 0.00 usr 0.00 sys + 0.47 cusr 0.22 csys = 0.69 CPU) [17:51:36] t/pt-heartbeat/pxc.t .................. 1..0 # SKIP PXC tests skipped: PXC tests [17:51:36] t/pt-heartbeat/standard_options.t ..... 1..2 not ok 1 - Dies if PID file already exists (--pid without --daemonize) (issue 391) # Failed test 'Dies if PID file already exists (--pid without --daemonize) (issue 391)' # at t/pt-heartbeat/standard_options.t line 43. # 'Can't locate object method "make_PID_file" via package "Daemon" at /home/sveta/src/percona-toolkit/bin/pt-heartbeat line 6381. # ' # doesn't match '(?^:PID file /tmp/mk-script.pid already exists)' ok 2 - Sandbox servers # Looks like you failed 1 test of 2. Dubious, test returned 1 (wstat 256, 0x100) Failed 1/2 subtests [17:51:37] t/pt-heartbeat/utc.t .................. tempfile(): temporary filename requested but not opened. Possibly unsafe, consider using tempfile() with OPEN set to true Can't locate object method "make_PID_file" via package "Daemon" at /home/sveta/src/percona-toolkit/bin/pt-heartbeat line 6381. not ok 1 - --update on 12345 started # Failed test '--update on 12345 started' # at t/pt-heartbeat/utc.t line 64. not ok 2 - --utc bypasses time zone differences (bug 886059, bug 1099665) # Failed test '--utc bypasses time zone differences (bug 886059, bug 1099665)' # at t/pt-heartbeat/utc.t line 102. # '31.03 # ' # doesn't match '(?^:\A\d.\d{2}$)' Cannot open /tmp/pt-heartbeat-test.Xj05JhQ9.12345.pid: No such file or directory at t/pt-heartbeat/utc.t line 71. # Tests were run but no plan was declared and done_testing() was not seen. # Looks like your test exited with 2 just after 2. Dubious, test returned 2 (wstat 512, 0x200) Failed 2/2 subtests [17:52:09] Test Summary Report ------------------- t/pt-heartbeat/basics.t (Wstat: 1280 Tests: 25 Failed: 5) Failed tests: 6-9, 12 Non-zero exit status: 5 t/pt-heartbeat/multi_update_mode.t (Wstat: 1792 Tests: 29 Failed: 7) Failed tests: 1-3, 19-20, 23-24 Non-zero exit status: 7 t/pt-heartbeat/standard_options.t (Wstat: 256 Tests: 2 Failed: 1) Failed test: 1 Non-zero exit status: 1 t/pt-heartbeat/utc.t (Wstat: 512 Tests: 2 Failed: 2) Failed tests: 1-2 Non-zero exit status: 2 Parse errors: No plan found in TAP output Files=8, Tests=63, 210 wallclock secs ( 0.05 usr 0.01 sys + 3.97 cusr 1.41 csys = 5.44 CPU) Result: FAIL
Suggested Fix
Identify which tests fail, because badly written and which show real issues with code, fix either tests or code.