You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: logging/Azure_log_analytics_workspaces.md
+38-58Lines changed: 38 additions & 58 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,34 +2,32 @@
2
2
3
3
## Introduction
4
4
5
-
If you use Microsoft Azure and want to use Azure Monitor *instead* of OpenSearch
6
-
to explore, filter, and report on log messages from a SAS Viya environment, you
7
-
can deploy the logging solution described in this document. This solution uses a
8
-
combination of Fluent Bit and an Azure Log Analytics workspace to handle log
9
-
messages so that they can be accessed by Azure Monitor. Please note that
10
-
the development work in this solution has been limited, and is primarily a
11
-
proof of concept.
12
-
13
-
**Note: Azure Monitor and Azure Log Analytics are optional features of
14
-
Microsoft Azure, and they require agreement to additional licensing terms and
15
-
additional charges. You must understand the terms and charges before you
5
+
If you use Microsoft Azure and want to use Azure Monitor *instead* of OpenSearch
6
+
to explore, filter, and report on log messages from a SAS Viya environment, you
7
+
can deploy the alternate logging solution described in this document. This solution
8
+
uses acombination of Fluent Bit and an Azure Log Analytics workspace to handle log
9
+
messages so that they can be accessed by Azure Monitor. Please note that the
10
+
development work in this solution has been limited, and is primarily a proof of
11
+
concept.
12
+
13
+
**Note: Azure Monitor and Azure Log Analytics are optional features of
14
+
Microsoft Azure, and they require agreement to additional licensing terms and
15
+
additional charges. You must understand the terms and charges before you
16
16
deploy the solution described in this document.**
17
17
18
18
## Technical Overview
19
19
20
-
In this solution, log messages are collected by the Fluent Bit
21
-
pods that are part of the standard logging solution and that are deployed
22
-
cluster-wide by using a Kubernetes DaemonSet. These Fluent Bit pods can
23
-
parse and process log messages from all SAS Viya components, including
24
-
third-party products. As a result, log messages are handled consistently,
25
-
regardless of the original source.
20
+
In this alternate solution, log messages are collected by the Fluent Bit
21
+
pods that are part of the standard logging solution and that are deployed
22
+
cluster-wide by using a Kubernetes DaemonSet. These Fluent Bit pods can
23
+
parse and process log messages from all SAS Viya components, including
24
+
third-party products. As a result, log messages are handled consistently,
25
+
regardless of the original source.
26
26
27
-
In the standard solution, Fluent Bit sends the log messages to OpenSearch.
28
-
In this solution, the log messages are loaded into a Log Analytics workspace
29
-
as a "custom log" source. You can then use Azure Monitor to explore, filter, and
30
-
report on the collected log messages. By default, this solution also includes
31
-
the Event Router, with is a component that surfaces Kubernetes events as
32
-
pseudo-log messages beside the log messages collected by Fluent Bit.
27
+
In the standard solution, Fluent Bit sends the log messages to OpenSearch.
28
+
In this solution, the log messages are loaded into a Log Analytics workspace
29
+
as a "custom log" source. You can then use Azure Monitor to explore, filter, and
30
+
report on the collected log messages.
33
31
34
32
## Deploy the Fluent Bit and Azure Log Analytics Solution
35
33
@@ -74,37 +72,19 @@ This command returns two shared keys, labeled ***"primarySharedKey"*** and ***"s
74
72
/logging/bin/deploy_logging_azmonitor.sh
75
73
```
76
74
77
-
You can also deploy individual components:
78
-
- Event Router
79
-
```bash
80
-
/logging/bin/deploy_eventroutersh
81
-
```
82
-
- Fluent Bit
83
-
```bash
84
-
/logging/bin/deploy_fluentbit_azmonitor.sh
85
-
```
86
-
87
75
## Remove the Fluent Bit and Azure Log Analytics Solution
88
76
89
77
To remove all logging components for this solution, issue this command:
90
78
```bash
91
79
/logging/bin/remove_logging_azmonitor.sh
92
80
```
93
-
By default, this script does not delete the namespace, but it does delete configmaps and secrets that were created by the deployment script.
94
-
95
-
To remove individual components, issue these commands:
96
-
- Event Router
97
-
```bash
98
-
/logging/bin/remove_eventroutersh
99
-
```
100
-
- Fluent Bit
101
-
```bash
102
-
/logging/bin/remove_fluentbit_azmonitor.sh
103
-
```
81
+
By default, this script does not delete the namespace, but it does delete configmaps and secrets that were created by the deployment script. If you would like to delete the namespace as part
82
+
of this script's execution, set the evnironment variable `LOG_DELETE_NAMESPACE_ON_REMOVE` to
83
+
*'true'* prior to running the script.
104
84
105
85
## Using Connection Information From a Kubernetes Secret
106
86
107
-
The deployment script creates a Kubernetes secret named `connection-info-azmonitor`containing the connection information.
87
+
The deployment script creates a Kubernetes secret named `connection-info-azmonitor`containing the connection information.
108
88
This ensures that the connection information is available in case the Fluent Bit pods are
109
89
restarted or new nodes are added to the cluster. This secret is created
110
90
in the same namespace into which the Fluent Bit pods are deployed. If this secret already exists
@@ -115,11 +95,11 @@ when you run the deployment script, the script obtains the connection informatio
115
95
After deploying this solution, the collected log messages appear as
116
96
a new table, **viya_logs_CL**, in the ***Custom Logs*** grouping within the
117
97
specified Log Analytics workspace. The structure of this table is similar
118
-
to the structure of the log messages that are surfaced in OpenSearch Dashboards when using the
98
+
to the structure of the log messages that are surfaced in OpenSearch Dashboards when using the
119
99
standard logging solution. However, due to features of the Azure
120
100
API, the names of some fields are slightly different. The tables feature
121
101
a flattened data model, so multi-level JSON fields appear as multiple
122
-
fields with the JSON hierarchy embedded in each field's name. In addition, a
102
+
fields with the JSON hierarchy embedded in each field's name. In addition, a
123
103
suffix is added to the name of most of the fields to indicate the field's data type,
124
104
such as ***_s*** for string fields and ***_d*** for a numeric (double) field.
125
105
@@ -131,23 +111,23 @@ appear in the **viya_logs_CL** table as **kube_namespace_s** and **kube_pod_s**.
131
111
132
112
## Using the Data
133
113
134
-
Although a full explanation of how you can use the collected log messages in
135
-
Azure Monitor and the Log Analytics workspace is out of scope for this document,
114
+
Although a full explanation of how you can use the collected log messages in
115
+
Azure Monitor and the Log Analytics workspace is out of scope for this document,
136
116
here are some tips to help you get started.
137
117
138
118
### Kusto Queries
139
119
Kusto is a powerful query language used by Log Analytics workspaces
140
-
and Azure Monitor. To access an interactive Kusto query window in Azure Monitor,
141
-
selectyour Log Analytics workspace in Azure Monitor, thenselect**Logs** from
142
-
the **General** area of the toolbar on the left side of the window.
120
+
and Azure Monitor. To access an interactive Kusto query window in Azure Monitor,
121
+
select your Log Analytics workspace in Azure Monitor, then select **Logs** from
122
+
the **General** area of the toolbar on the left side of the window.
Copy file name to clipboardExpand all lines: logging/README.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,10 +4,10 @@ To learn how to deploy the logging component, see [Getting Started](https://docu
4
4
5
5
## Important Information about OpenSearch and OpenSearch Dashboards
6
6
7
-
>As of release 1.2.0, this project uses OpenSearch and OpenSearch Dashboards.
8
-
9
-
**Notes:**
10
-
11
-
* OpenSearch replaces Elasticsearch.
12
-
* OpenSearch Dashboards replaces Kibana.
13
-
* Some configuration options, environment variables, and other aspects of this project might still include references to the prior product names. This is intentional. Doing so supports backward compatibility and continuity for users of this project. These references might change at a later date.
7
+
This project uses OpenSearch and OpenSearch Dashboards and this has been
8
+
true since version 1.2.0 released in June of 2022. Prior to that, the
9
+
project used Elasticsearch and Kibana. To support backward compitibility,
10
+
some configuration options, environment variables, and other aspects of
11
+
this project still include references to those product names. References
12
+
to Elasticsearch and Kibana should be understood to refer to OpenSearch
Copy file name to clipboardExpand all lines: samples/README.md
+2-3Lines changed: 2 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,7 +18,7 @@ each deployment file.
18
18
19
19
You customize your logging deployment by specifying values in `user.env` and
20
20
`*.yaml` files. These files are stored in a local directory outside of your
21
-
repository that is identified by the `USER_DIR` environment variable.
21
+
repository that is identified by the `USER_DIR` environment variable.
22
22
For information about the customization process, see [Create the Deployment Directory](https://documentation.sas.com/?cdcId=obsrvcdc&cdcVersion=v_003&docsetId=obsrvdply&docsetTarget=p15fe8611w9njkn1fucwbvlz8tyg.htm) in the SAS Viya Monitoring for Kubernetes Help Center.
23
23
24
24
The customization files in each sample provide a starting point for the
@@ -61,8 +61,7 @@ from SAS Viya components.
61
61
*[ingress](ingress) - Deploys using host-based or path-based ingress.
Copy file name to clipboardExpand all lines: samples/generic-base/README.md
+5-4Lines changed: 5 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ reference links and variable listings.
8
8
9
9
You customize your deployment by specifying values in `user.env` and `*.yaml`
10
10
files. These files are stored in a local directory outside of your
11
-
repository that is identified by the `USER_DIR` environment variable.
11
+
repository that is identified by the `USER_DIR` environment variable.
12
12
For information about the customization process, see [Create the Deployment Directory](https://documentation.sas.com/?cdcId=obsrvcdc&cdcVersion=v_003&docsetId=obsrvdply&docsetTarget=p15fe8611w9njkn1fucwbvlz8tyg.htm) in the SAS Viya Monitoring for Kubernetes Help Center.
13
13
14
14
The customization files in this sample provide a starting point for
@@ -25,7 +25,8 @@ your customization files after you add the values in this sample.
25
25
After you finish modifying the customization files, deploy the metric-monitoring and
26
26
log-monitoring components. See [Deploy](https://documentation.sas.com/?cdcId=obsrvcdc&cdcVersion=v_003&docsetId=obsrvdply&docsetTarget=n1rhzwx0mcnnnun17q11v85bspyk.htm) in the SAS Viya Monitoring for Kubernetes Help Center.
27
27
28
-
## Grafana Dashboards
28
+
## Grafana Dashboards and Alerting
29
29
30
-
In addition to customizing the deployment, you can also use this sample to add
31
-
your own Grafana dashboards. See [Add More Grafana Dashboards](https://documentation.sas.com/?cdcId=obsrvcdc&cdcVersion=v_003&docsetId=obsrvdply&docsetTarget=n1sg9bc44ow616n1sw7l3dlsbmgz.htm) for details.
30
+
In addition to customizing the deployment, this sample show how you can add
31
+
your own Grafana dashboards, alerts, contact points and notifications policies. See [Add More Grafana Dashboards](https://documentation.sas.com/?cdcId=obsrvcdc&cdcVersion=v_003&docsetId=obsrvdply&docsetTarget=n1sg9bc44ow616n1sw7l3dlsbmgz.htm), [Add More Grafana Alerts](***NEED***LINK***) and
32
+
[Configure Contact Points, and Notification Policies](***NEED***LINK***) for details.
0 commit comments