Setting up the Applications Dashboard
To monitor and quickly respond to the changes in your Chef Habitat environments, the Chef Automate Applications Dashboard gives you operational observability into your Chef Habitat systems. This Applications Dashboard Service Groups table is an overview of your Chef Habitat network, grouped by package, service group, environment, and application.
Requirements and Capacity Planning
On any system, the Chef Enterprise Application Stack, with Chef Automate as well as Chef Habitat, can scale up to 15,000 services using:
- 4 CPU
- 16GB of RAM
- 50 GB disk space
- Chef Habitat, minimum version 1.5.0
- Chef Automate, the current version
The Compliance and Infrastructure observability features of Chef Automate require additional memory and computing capacity. Large-scale systems (15,000+ services) consume CPU resources for processing application data.
Chef Habitat Service Group Best Practices
All of the services for a single package are in a service group. The services in a group are connected within a Chef Habitat supervisor network and have a single relationship structure (topology).
For best results:
Each application deployment environment (Development, Test, Acceptance, Production) should have its Chef Habitat network.
Use the default Chef Habitat service group names.
Setting up the Applications Dashboard
To set the dashboard, you need:
A Chef Automate API token specifically for this integration
Running installations of Chef Automate and Chef Habitat Builder SasS or Builder on-prem
To know more about Setting up the Applications Dashboard, follow this link.
Applications Dashboard
Your chef applications data from Chef Habitat may be organized and displayed intuitively using the Chef Automate Applications dashboard. Chef Automate uses the Chef Habitat supervisor's application and environment tags to manage the data. Even when scaling out to a large number of services, you can understand the status of your Chef Habitat services in the Service Groups display under the Chef Automate Applications dashboard.
Prerequisites
Concepts from Chef Habitat, as described in the Glossary, are introduced in the Chef Automate EAS applications feature.
See Setting up the Applications Dashboard for information on setting up Chef Automate and Chef Habitat to work alongside.
Service Groups
Chef Automate orders service groups, also known as Chef Habitat services, based on package identifiers and configurations. You can see a top-level view of your Chef Habitat service groups in the chef Applications dashboard Service Groups display. You can also drill down into the status of individual instances to understand more about the health and contents of any given service instance. Only the available services are shown in the default Service Groups view. For each individual service, there is detailed reporting in the right sidebar.
Service Health Status Count
The Service Health Status Count, consisting of five containers, is the page's first informational gathering. The first container on the left lists all of the service groups, and the following containers categorize the services into four criticality levels based on the condition of the group's most important service. The containers for the service health status are Critical, Warning, OK, and Unknown. Each service group is categorized according to its most important service, so if even one of its instances reports a "critical" state, Chef Automate considers the entire group to have a "critical" status.
Service Groups Table
The Service Groups table's row displays the outcomes for a particular service group. The service groups reporting the least amount of healthy services and most "critical" services appear at the top of the rows since they are sorted by highest criticality.
The table rows are ordinarily sorted from the lowest to the highest proportion of "OK" services. The order is reversed when the Health column is chosen, and the percentage of "OK" services is shown from highest to lowest.
Health
The donut chart under the Health column depicts the service group's percentage of health status in terms of color. The percentage inside the circle shows the proportion of services with an OK status.
If applicable, a status icon with the correct color appears next to the circle display. A magenta triangle exclamation icon is displayed next to the service group's circle display to emphasize the critical status, for instance, if it is 20% OK and 80% Critical.
The Service Groups will appear in the same order of priority—Critical, Unknown, and Warning—if more than one Service Group has the same OK health percentage.
Service Group
The Service Group column includes the name of the Service Group and the proportion of healthy services—those reporting an OK status—to all the services in the group.
To enhance your knowledge about the service group details sidebar and filtering results, you can follow this link.
Desktop Dashboard
The Chef Automate Desktop dashboard displays the status information about all the desktops connected to Chef Automate. Desktop information fills this dashboard after a Chef Infra Client run.
Setting Up the Desktop Dashboard
See the installing Chef Desktop documentation for guidance on installing Chef Desktop. The Chef Desktop installation does not include any compliance profiles, and the Desktop Dashboard does not support any compliance profiles.
Desktop Dashboard Display
In Chef Automate, to summarize information, the Desktop dashboard uses four panels: Daily Check-in, History of Check-in, Top 10 Errors, and Time since Last Check-in. Rows within these displays can be selected to identify pertinent desktops and choose a specific desktop to display its particular information.
Project filtering is not supported by the Desktop dashboard. Liveness agents may be counted as node counts in the desktop dashboard.
Daily Check-in
Top-level statistics for daily desktop check-ins are displayed in the Daily Check-in display. The proportion of desktops with unknown and checked-in status is shown in a bar graph. Counts of all desktops, desktops with an unknown status, and desktops with a checked-in status are shown in boxes below the bar. Desktops reporting into Chef Automate are referred to as checked-in. Over the past twenty-four hours, unknown Desktops have not reported to Chef Automate.
A Filtered Desktop List of desktops for the selected status is displayed after selecting a box. When selecting a different box, the filters you've chosen will not remain in effect.
Check-in History
Check-in History displays a graphed history of the number of desktops that have been checked in over a selected period. To select a different time period, use the drop-down option. "Last 3 Days," "Last 7 Days," and "Last 14 Days" are the available time periods.
Time Since Last Check-in
The count of Desktops with an unknown status for specified timeframes gets displayed in the Time since Last Check-in display. A Filtered Desktop List of the desktops for the selected timeframe is displayed when a row is selected.
Top 10 Errors
The Top 10 Errors display shows the top ten errors that have affected all desktops over the past twenty-four hours, along with a breakdown of how many desktops each error affected. You can enable additional inquiry by opening the Filter Desktop List with the applied error filter by selecting an error.
Filtered Desktop Lists
The Filtered Desktop List gets activated by selecting rows from the Daily Check-in, Time since Last Check-in, or Top 10 Errors. According to the status, timeframe, or error chosen in the previous display, the Filtered Desktop List displays a list of filtered desktops.
If desired, add more filters to this initial list. Specific filter values, such as "platform," "environment," "domain," and "last run status," populate following the available desktop information.
See the node details for an individual desktop by selecting an individual desktop row.
Troubleshooting
Index Issues
Indices with bad default mappings
You can find out the current state of the root cause cure for this at: chef software ideas
A complaint about poor default index mappings could appear in the journalctl -u chef-automate output as follows:
ingest-service.default(O): time="2022-03-03T00:32:40Z" level=error msg="Failed initializing elasticsearch" error="Error creating index node-1-run-info with error: elastic: Error 400 (Bad Request): mapper [node_uuid] of different type, current_type [text], merged_type [keyword] [type=illegal_argument_exception]"
Because automate-cs-nginx and automate-cs-oc-erchef depend on ingest-ability service's to connect to port 10122, where it would be listening if it weren't constantly restarting, as a result, ingest-service can never correctly start up, which causes other processes like automate-cs-oc-erchef to malfunction.
The following command sequence can rebuild any index with complex mappings using the list of INDEX_NAME provided below.
- node-1-run-info
- node-attribute
- node-state-7
- converge-history-DATE-STAMP
First, block all incoming traffic to the Automate system. You can, for instance, stop using your Chef Server. Use chef-server-ctl maintenance if your system combines Automate and Chef Server. Choose a method that you feel comfortable with.
Then, execute the deletion using the subsequent commands, being sure to replace INDEX_NAME with the desired one from the list above.
chef-automate dev stop-converge
hab svc unload chef/ingest-service
curl -XDELETE localhost:10141/INDEX_NAME
chef-automate dev start-converge
The ingest-service will then restart after that. For more knowledge regarding troubleshooting visit this link.
Frequently Asked Questions
Is chef free to use?
Open Source Chef is free but with comes with no support and without many of the valuable add-ons available in the enterprise versions.
What is a node in Chef?
A node is nothing but any machine that the Chef server is currently managing. It can be attached to any network that can send and receive information.
What is the URL for a chef server?
Our Chef Server automatically uses your system's FQDN as the Chef Server URL. Using the urls "https://10.33.33.33" and "https://10.33.33.33/version," we can access the Chef Server web interface and version information, respectively.
What port does Chef use?
The Chef Server uses ports 22, 443, and 8443.
How do Ansible and Chef vary from one another?
Chef is a commercial automation tool, whereas Ansible is an open-source IT tool. The use of Ansible is for application deployment automation and configuration management.
Conclusion
In this blog, we learned about Chef Applications in detail. In this article, we have learned about setting up the application and desktop dashboard and troubleshooting methods. To enhance your knowledge regarding Chef, you also refer following blogs.
CHEF - DEPLOYMENT
CHEF- HIGH AVAILABILITY
Refer to our guided paths on Coding Ninjas Studio to learn more about DSA, Competitive Programming, JavaScript, System Design, etc. Enroll in our courses and refer to the mock test and problems available.
You can refer to other similar articles as well
Happy Learning Ninja!