Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
To check the application log, you must first register in the application management tab.
Logging - Application Log - Select an application from the list of applications to view.
View By Hour
: You can search logs from the last 5 minutes to 48 hours ago, and check logs from up to 2 weeks ago.
Application
: You can view a list of all applications that exist in the cluster.
View More
: Get logs since the last time in the list.
Current number of logs
/
Total number of logs
: This refers to the total number of logs viewed at that time and the maximum number of logs.
The maximum number of logs that can be viewed at one time is 5000. The inquiry period is up to 7 days.
The Show More button is displayed when the total number of logs exceeds 5000.
Click the link button for the log viewed by time to check detailed information about the log.
Log Message
: You can check the contents of the log that actually occurred.
Label Information
: Click the + button to expand and view label information.
Label information: You can close the expanded label information by clicking the - button.
If you click on each graph once, you can check the log for that time, and if you click again, you can check the log for the entire time again.
Graph Select
: You can see that there are 60 logs of the current time.
Click the arrow button on the right to see the set of labels for the logs present at that time.
label list key
: Indicates a list of labels for viewed logs. You can check the label value by clicking the label button.
label list values
: Click the label value to search for the log you want to find by adding the conditions you want to search through AND search.
Selected label value
: When you add a label condition, the condition is added to the top of the graph, and you can search by clicking the X button to remove the condition.
Enter the keyword you want to search for and click the search button to view the log for the search term.
Search word
: You can search logs where the string exists regardless of case.
Click the “Download” button at the top of the graph to download the log.
Download
: You can download log data for up to 5,000 searched logs in Excel file format. Each column contains a label value.
This is a method of installing into an existing application using the SDK provided by Opentelemetry.
This guide is for existing JAVA applications that have been build on Cocktail Cloud.
Log Appender is an interface provided by a logging framework or library that provides the ability to collect and process log messages. OpenTelemetry interacts with Log Appender through the Log Bridge API to collect log messages and associate them with tracking data from OpenTelemetry. Therefore, log appenders can be used to collect and integrate log data from OpenTelemetry.
We introduce how to collect data using logback
and log4j
, which are representative loggers.
log-agent Service Address
: Infrastructure - Cluster - Add-ons - Click 'log-agent' and check the service name.
( http port = 4318 , grpc port = 4317)
Using Opentelemetry-operateor, you can simply log using container logs with annotations. Since container logs are collected only in the namespace unit set by the user, the method of collecting them fo
Fluent Bit is a lightweight log data collector that is used to collect and process data. By installing Flentbit as a sidecar in your application, you parse the application's logs and forward them to O
The above guide explains how the application stores logs in the /var/log directory. Please modify the directory and log pattern to suit your environment.
Application to collect logs - Settings - Container Click the "Add" button to create a container as follows.
Image:
fluent/fluent-bit:3.0.0
When you press the save button, the container runs in the existing application in fluent-bit sidecar format.
Logs are stored in the path set in Log Appender, so you need to create a volume in the container and mount it.
Application to collect logs - Settings - Volume - Click the "Create" button to create a volume as follows.
Volume Type
: Empty Dir
Volume Name
: custom name
The following is the process of mounting the created volume.
Application to collect logs - Settings - Volume mount - Click the "Add" button to mount the volume with the following settings.
Container Path
: File path set in Log Appender (eg. /var/log)
The container must mount the directory path where it stores the logs before it can read the file and parse the logs.
You can also add labels or change the label name through Config provided by fluent-bit.
Service map to collect logs - Configuration information - Click the "Create" button to create a configuration map.
Name
: The name of the config map you want to set.
Description
: Additionally, a description of the config map to be specified by the user.
Click the “Add” button to add the config file.
The following config file is not absolute. The location where the log is loaded or the log pattern may vary, so please set it according to your environment.
log-agent Service Address
: Infrastructure - Cluster - Add-ons - Click 'log-agent' and check the service name.
( http port = 4318 , grpc port = 4317)
parsers.conf
Application logs create a label called 'level' to provide users with the ability to filter by level. The following is an example of converting nginx's code value to level when the user's application does not have a value called level.
rewrite.lua
Once the config map creation is complete, return to the application to create the volume.
Application to collect logs - Settings - Volume - Click the "Create" button to create a volume as follows.
Volume Type
: Config Map
Volume Name
: Custom Name
Config Map
: User-created ConfigMap name
Permission
: 644
The following is the process of mounting the created volume.
Application to collect logs - Settings - Volume mount - Click the "Add" button to mount the volume with the following settings.
Container Path
: Log Data - Directory path where logs are stored (eg. /var/log)
Container Path
: Fluent-bit -conf -fluent-bit configuration file path (eg. /fluent-bit/etc)
When the fluent-bit container does not operate properly
We recommend that you select a method that suits your environment.
Collect container logs from workloads using automated instrumentation.
The SDK method is used when you want to collect logs from a specific service through Logger settings.
The sidecar method is used when you want to read and collect log files in a specific directory.
You can leverage Custom Resources to configure the OpenTelemetry auto-instrumentation library and add annotations to your workloads to easily collect logs.
You can create one by searching for Infrastructure - Custom Resources - 'instrumentations'.
You can create it by clicking the Create button, selecting the namespace where you want to collect logs, and modifying the form below.
The above CRD is applied on a namespace basis, and automatic container logs can be collected for other languages in the same namespace.
log-agent Service address
: Infrastructure - Cluster - Add-ons - Click 'log-agent' and check the service name.
( http port = 4318 , grpc port = 4317)
By adding an environment variable for each individual application rather than all applications in the namespace through CRD, you can only collect logs for a specific application.
Add annotations to the workloads in the namespace for which you want to collect logs.
Application - Service Map - Service Map to collect logs - Workload - Select the application to collect logs - Click the "Settings" button.
Change the Yaml view and add the following annotations to the template - metadata - annotations section.
You can create one by searching for Infrastructure - Custom Resources - 'instrumentations'.
You can create it by clicking the Create button, selecting the namespace where you want to collect logs, and modifying the form below.
The above CRD is applied on a namespace basis, and automatic container logs can be collected for other languages in the same namespace.
log-agent Service Address
: Infrastructure - Cluster - Add-ons - Click 'log-agent' and check the service name.
( http port = 4318 , grpc port = 4317)
Add annotations to the workloads in the namespace for which you want to collect logs.
Application - Service Map - Service Map to collect logs - Workload - Select the application to collect logs - Click the "Settings" button.
Change the Yaml view and add the following annotations to the template - metadata - annotations section.
The advantage of using the open source fluent-bit is that the user can handle it by reading log files stored in the directory.
This is a method of installing into an existing application using the SDK provided by Opentelemetry. Logging in Python is currently under development at opentelemetry.
This guide is for existing Python applications that have been build on Cocktail Cloud.
Additionally, the Python application in this guide was created based on 'Flask'
log-agent Service Address
: Infrastructure - Cluster - Add-ons - Click 'log-agent' and check the service name.
( http port = 4318 , grpc port = 4317)
The log service can perform logging depending on various applications, and the process of registering to enable logging is explained.
Logging - Application Management - Click the Registration button to register.
Name
: Actual application service name
Description
: Description field to distinguish
Cluster
: Cluster with application
Namespace
: Namespace where the application resides
Developing Language
: Application development language
Log Service Information
: Log service information useful for the current platform
The log service can collect and search logs of authenticated applications through tokens.
A token is automatically issued when you first register an application, and a new token can be issued through renewal.
Even if the token is renewed, the token applied to the application is not automatically renewed, so you must renew it manually to collect logs.
You can also click the "Action" button to disable the application to stop logging, or delete it from the application list.