explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 4cn

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Limit (cost=131,378.28..131,378.29 rows=1 width=23) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Sort (cost=131,378.28..131,379.48 rows=479 width=23) (actual rows= loops=)

  • Sort Key: hosts.name
3. 0.000 0.000 ↓ 0.0

HashAggregate (cost=131,368.70..131,373.49 rows=479 width=23) (actual rows= loops=)

  • Group Key: hosts.name, hosts.id
4. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=39,313.51..131,205.03 rows=32,735 width=23) (actual rows= loops=)

  • Hash Cond: (hosts.id = host_status.host_id)
5. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=39,258.10..130,729.87 rows=10,559 width=23) (actual rows= loops=)

  • Hash Cond: (content_facets_hosts_join_2.content_source_id = smart_proxies.id)
  • Filter: (((hosts.name)::text ~~* '%concept1%'::text) OR (hosts.comment ~~* '%concept1%'::text) OR ((reports.origin)::text ~~* '%concept1%'::text) OR ((models.name)::text ~~* '%concept1
6. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=39,257.05..127,431.93 rows=477,014 width=4,976) (actual rows= loops=)

  • Hash Cond: (hosts.id = content_facets_hosts_join_2.host_id)
7. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=39,238.44..121,372.22 rows=477,014 width=4,972) (actual rows= loops=)

  • Hash Cond: (hosts.id = content_facets_hosts_join.host_id)
8. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=39,212.69..115,305.36 rows=477,014 width=4,456) (actual rows= loops=)

  • Hash Cond: (hosts.id = katello_host_collection_hosts.host_id)
9. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=39,163.45..81,530.84 rows=157,579 width=3,940) (actual rows= loops=)

  • Hash Cond: (hosts.id = provision_interfaces_hosts.host_id)
10. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=39,092.19..68,853.26 rows=157,579 width=3,940) (actual rows= loops=)

  • Hash Cond: (hosts.id = primary_interfaces_hosts_join_2.host_id)
11. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=39,020.93..56,175.68 rows=157,579 width=3,940) (actual rows= loops=)

  • Hash Cond: (hosts.id = katello_content_facets.host_id)
12. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=38,995.25..54,154.36 rows=157,579 width=3,922) (actual rows= loops=)

  • Hash Cond: (hosts.operatingsystem_id = operatingsystems.id)
13. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=38,993.64..51,986.04 rows=157,579 width=3,890) (actual rows= loops=)

  • Hash Cond: (hosts.image_id = images.id)
14. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=38,992.62..51,394.09 rows=157,579 width=3,378) (actual rows= loops=)

  • Hash Cond: (hosts.compute_resource_id = compute_resources.id)
15. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=38,989.23..49,431.23 rows=157,579 width=3,362) (actual rows= loops=)

  • Hash Cond: (hosts.architecture_id = architectures.id)
16. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=38,988.16..47,263.45 rows=157,579 width=2,850) (actual rows= loops=)

  • Merge Cond: (hosts.id = primary_interfaces_hosts.host_id)
17. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=38,901.56..44,419.22 rows=157,579 width=2,850) (actual rows= loops=)

  • Merge Cond: (hosts.id = primary_interfaces_hosts_join.host_id)
18. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=38,811.92..41,571.95 rows=157,579 width=2,710) (actual rows= loops=)

  • Merge Cond: (hosts.id = reports.host_id)
19. 0.000 0.000 ↓ 0.0

Sort (cost=165.62..166.81 rows=479 width=2,703) (actual rows= loops=)

  • Sort Key: hosts.id
20. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=50.19..144.29 rows=479 width=2,703) (actual rows= loops=)

  • Join Filter: (environments.id = hosts.environment_id)
21. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=50.19..136.09 rows=479 width=2,191) (actual rows= loops=)

  • Hash Cond: (hosts.realm_id = realms.id)
22. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=38.62..122.71 rows=479 width=1,679) (actual rows= loops=)

  • Hash Cond: (nics.domain_id = domains.id)
23. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=36.52..117.26 rows=479 width=1,667) (actual rows= loops=)

  • Hash Cond: (hosts.hostgroup_id = hostgroups.id)
24. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=35.34..113.66 rows=479 width=639) (actual rows= loops=)

  • Hash Cond: (hosts.model_id = models.id)
25. 0.000 0.000 ↓ 0.0

Hash Right Join (cost=33.98..105.83 rows=479 width=127) (actual rows= loops=)

  • Hash Cond: (nics.host_id = hosts.id)
26. 0.000 0.000 ↓ 0.0

Seq Scan on nics (cost=0.00..65.27 rows=479 width=38) (actual rows= loops=)

  • Filter: "primary
27. 0.000 0.000 ↓ 0.0

Hash (cost=27.99..27.99 rows=479 width=93) (actual rows= loops=)

  • -> Seq Scan on hosts (cost=0.00..27.99 rows=479 width=93
  • Filter: ((type)::text = 'Host::Managed'::text)
28. 0.000 0.000 ↓ 0.0

Hash (cost=1.16..1.16 rows=16 width=520) (actual rows= loops=)

29. 0.000 0.000 ↓ 0.0

Seq Scan on models (cost=0.00..1.16 rows=16 width=520) (actual rows= loops=)

30. 0.000 0.000 ↓ 0.0

Hash (cost=1.08..1.08 rows=8 width=1,036) (actual rows= loops=)

31. 0.000 0.000 ↓ 0.0

Seq Scan on hostgroups (cost=0.00..1.08 rows=8 width=1,036) (actual rows= loops=)

32. 0.000 0.000 ↓ 0.0

Hash (cost=1.49..1.49 rows=49 width=20) (actual rows= loops=)

33. 0.000 0.000 ↓ 0.0

Seq Scan on domains (cost=0.00..1.49 rows=49 width=20) (actual rows= loops=)

34. 0.000 0.000 ↓ 0.0

Hash (cost=10.70..10.70 rows=70 width=520) (actual rows= loops=)

35. 0.000 0.000 ↓ 0.0

Seq Scan on realms (cost=0.00..10.70 rows=70 width=520) (actual rows= loops=)

36. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..1.01 rows=1 width=520) (actual rows= loops=)

37. 0.000 0.000 ↓ 0.0

Seq Scan on environments (cost=0.00..1.01 rows=1 width=520) (actual rows= loops=)

38. 0.000 0.000 ↓ 0.0

Materialize (cost=38,646.31..39,434.20 rows=157,579 width=11) (actual rows= loops=)

39. 0.000 0.000 ↓ 0.0

Sort (cost=38,646.31..39,040.26 rows=157,579 width=11) (actual rows= loops=)

  • Sort Key: reports.host_id
40. 0.000 0.000 ↓ 0.0

Seq Scan on reports (cost=0.00..22,347.74 rows=157,579 width=11) (actual rows= loops=)

  • Filter: ((type)::text = 'ConfigReport'::text)
41. 0.000 0.000 ↓ 0.0

Sort (cost=89.64..90.84 rows=479 width=144) (actual rows= loops=)

  • Sort Key: primary_interfaces_hosts_join.host_id
42. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=1.24..68.31 rows=479 width=144) (actual rows= loops=)

  • Hash Cond: (primary_interfaces_hosts_join.subnet_id = subnets.id)
43. 0.000 0.000 ↓ 0.0

Seq Scan on nics primary_interfaces_hosts_join (cost=0.00..65.27 rows=479 width=8) (actual rows= loops=)

  • Filter: "primary
44. 0.000 0.000 ↓ 0.0

Hash (cost=1.23..1.23 rows=1 width=144) (actual rows= loops=)

45. 0.000 0.000 ↓ 0.0

Seq Scan on subnets (cost=0.00..1.23 rows=1 width=144) (actual rows= loops=)

  • Filter: ((type)::text = 'a'::text)
46. 0.000 0.000 ↓ 0.0

Sort (cost=86.59..87.79 rows=479 width=4) (actual rows= loops=)

  • Sort Key: primary_interfaces_hosts.host_id
47. 0.000 0.000 ↓ 0.0

Seq Scan on nics primary_interfaces_hosts (cost=0.00..65.27 rows=479 width=4) (actual rows= loops=)

  • Filter: "primary
48. 0.000 0.000 ↓ 0.0

Hash (cost=1.03..1.03 rows=3 width=520) (actual rows= loops=)

49. 0.000 0.000 ↓ 0.0

Seq Scan on architectures (cost=0.00..1.03 rows=3 width=520) (actual rows= loops=)

50. 0.000 0.000 ↓ 0.0

Hash (cost=2.62..2.62 rows=62 width=24) (actual rows= loops=)

51. 0.000 0.000 ↓ 0.0

Seq Scan on compute_resources (cost=0.00..2.62 rows=62 width=24) (actual rows= loops=)

52. 0.000 0.000 ↓ 0.0

Hash (cost=1.01..1.01 rows=1 width=520) (actual rows= loops=)

53. 0.000 0.000 ↓ 0.0

Seq Scan on images (cost=0.00..1.01 rows=1 width=520) (actual rows= loops=)

54. 0.000 0.000 ↓ 0.0

Hash (cost=1.27..1.27 rows=27 width=40) (actual rows= loops=)

55. 0.000 0.000 ↓ 0.0

Seq Scan on operatingsystems (cost=0.00..1.27 rows=27 width=40) (actual rows= loops=)

56. 0.000 0.000 ↓ 0.0

Hash (cost=20.34..20.34 rows=427 width=22) (actual rows= loops=)

57. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=1.20..20.34 rows=427 width=22) (actual rows= loops=)

  • Hash Cond: (katello_content_facets.content_view_id = katello_content_views.id)
58. 0.000 0.000 ↓ 0.0

Seq Scan on katello_content_facets (cost=0.00..13.27 rows=427 width=8) (actual rows= loops=)

59. 0.000 0.000 ↓ 0.0

Hash (cost=1.09..1.09 rows=9 width=22) (actual rows= loops=)

60. 0.000 0.000 ↓ 0.0

Seq Scan on katello_content_views (cost=0.00..1.09 rows=9 width=22) (actual rows= loops=)

61. 0.000 0.000 ↓ 0.0

Hash (cost=65.27..65.27 rows=479 width=8) (actual rows= loops=)

62. 0.000 0.000 ↓ 0.0

Seq Scan on nics primary_interfaces_hosts_join_2 (cost=0.00..65.27 rows=479 width=8) (actual rows= loops=)

  • Filter: "primary
63. 0.000 0.000 ↓ 0.0

Hash (cost=65.27..65.27 rows=479 width=4) (actual rows= loops=)

64. 0.000 0.000 ↓ 0.0

Seq Scan on nics provision_interfaces_hosts (cost=0.00..65.27 rows=479 width=4) (actual rows= loops=)

  • Filter: provision
65. 0.000 0.000 ↓ 0.0

Hash (cost=31.12..31.12 rows=1,450 width=520) (actual rows= loops=)

66. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=1.04..31.12 rows=1,450 width=520) (actual rows= loops=)

  • Hash Cond: (katello_host_collection_hosts.host_collection_id = katello_host_collections.id)
67. 0.000 0.000 ↓ 0.0

Seq Scan on katello_host_collection_hosts (cost=0.00..24.50 rows=1,450 width=8) (actual rows= loops=)

68. 0.000 0.000 ↓ 0.0

Hash (cost=1.02..1.02 rows=2 width=520) (actual rows= loops=)

69. 0.000 0.000 ↓ 0.0

Seq Scan on katello_host_collections (cost=0.00..1.02 rows=2 width=520) (actual rows= loops=)

70. 0.000 0.000 ↓ 0.0

Hash (cost=20.41..20.41 rows=427 width=520) (actual rows= loops=)

71. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=1.27..20.41 rows=427 width=520) (actual rows= loops=)

  • Hash Cond: (content_facets_hosts_join.lifecycle_environment_id = katello_environments.id)
72. 0.000 0.000 ↓ 0.0

Seq Scan on katello_content_facets content_facets_hosts_join (cost=0.00..13.27 rows=427 width=8) (actual rows= loops=)

73. 0.000 0.000 ↓ 0.0

Hash (cost=1.12..1.12 rows=12 width=520) (actual rows= loops=)

74. 0.000 0.000 ↓ 0.0

Seq Scan on katello_environments (cost=0.00..1.12 rows=12 width=520) (actual rows= loops=)

75. 0.000 0.000 ↓ 0.0

Hash (cost=13.27..13.27 rows=427 width=8) (actual rows= loops=)

76. 0.000 0.000 ↓ 0.0

Seq Scan on katello_content_facets content_facets_hosts_join_2 (cost=0.00..13.27 rows=427 width=8) (actual rows= loops=)

77. 0.000 0.000 ↓ 0.0

Hash (cost=1.02..1.02 rows=2 width=520) (actual rows= loops=)

78. 0.000 0.000 ↓ 0.0

Seq Scan on smart_proxies (cost=0.00..1.02 rows=2 width=520) (actual rows= loops=)

79. 0.000 0.000 ↓ 0.0

Hash (cost=36.85..36.85 rows=1,485 width=4) (actual rows= loops=)

80. 0.000 0.000 ↓ 0.0

Seq Scan on host_status (cost=0.00..36.85 rows=1,485 width=4) (actual rows= loops=)