1Z0-888 · Question #15
Consider these global status variables: mysql> SELECT * FROM performance_schema.global_status WHERE VARIABLE_NAME LIKE '%connection%' OR VARIABLE_NAME LIKE '%thread%'…
The correct answer is B. There are 510 connections to MySQL at the time of the output. D. There are more connections being idle than executing queries. B is correct because Connections = 510 is the cumulative count of all connection attempts to MySQL since the server started - exactly what the output shows as of that moment. D is correct because Threads_connected = 140 (currently connected) minus Threads_running = 14 (actively…
Question
Options
- AThere are 140 Performance Schema threads at the time of the output.
- BThere are 510 connections to MySQL at the time of the output.
- CThe thread cache has been configured with thread_cache_size set to at least 6.
- DThere are more connections being idle than executing queries.
- EAll max_connections were in use at 2018-03-22 14:54:06
How the community answered
(50 responses)- A12% (6)
- B80% (40)
- C2% (1)
- E6% (3)
Explanation
B is correct because Connections = 510 is the cumulative count of all connection attempts to MySQL since the server started - exactly what the output shows as of that moment. D is correct because Threads_connected = 140 (currently connected) minus Threads_running = 14 (actively executing) leaves 126 idle connections - far outnumbering the 14 active ones.
A is wrong: Threads_connected = 140 counts client connection threads, not Performance Schema threads, which are tracked by separate variables like Performance_schema_thread_instances_lost. C is a trap: while 6 threads are currently cached, thread_cache_size could have been set to a higher value or changed after those threads were cached, so you cannot reliably infer the configured setting from Threads_cached alone. E is wrong because Max_used_connections = 145 shows the all-time peak concurrent connections, but this output contains no timestamp metadata - the date in the answer is fabricated and not derivable from anything shown.
Memory tip: Keep three counters straight - Connections (total ever, like a turnstile count), Threads_connected (currently in the building), and Threads_running (currently at a desk working). Idle = connected minus running.
Topics
Community Discussion
No community discussion yet for this question.