Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions translator/tocwconfig/sampleConfig/no_skip_log_timestamp.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[agent]
collection_jitter = "0s"
debug = false
flush_interval = "1s"
flush_jitter = "0s"
hostname = ""
interval = "60s"
logfile = "/opt/aws/amazon-cloudwatch-agent/logs/amazon-cloudwatch-agent.log"
logtarget = "lumberjack"
metric_batch_size = 1000
metric_buffer_limit = 10000
omit_hostname = false
precision = ""
quiet = false
round_interval = false

[inputs]

[[inputs.logfile]]
destination = "cloudwatchlogs"
file_state_folder = "/opt/aws/amazon-cloudwatch-agent/logs/state"

[[inputs.logfile.file_config]]
file_path = "/tmp/not-amazon-cloudwatch-agent.log"
from_beginning = true
log_group_name = "amazon-cloudwatch-agent.log"
pipe = false
retention_in_days = -1
timestamp_layout = "15:04:05 06 Jan 02"
timestamp_regex = "(d{2}:d{2}:d{2} d{2} w{3} d{2})"

[outputs]

[[outputs.cloudwatchlogs]]
force_flush_interval = "5s"
log_stream_name = "i-UNKNOWN"
region = "us-west-2"
15 changes: 15 additions & 0 deletions translator/tocwconfig/sampleConfig/no_skip_log_timestamp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"logs": {
"logs_collected": {
"files": {
"collect_list": [
{
"file_path": "/tmp/not-amazon-cloudwatch-agent.log",
"log_group_name": "amazon-cloudwatch-agent.log",
"timestamp_format": "%H:%M:%S %y %b %d"
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[agent]
collection_jitter = "0s"
debug = false
flush_interval = "1s"
flush_jitter = "0s"
hostname = ""
interval = "60s"
logfile = "c:\\ProgramData\\Amazon\\AmazonCloudWatchAgent\\Logs\\amazon-cloudwatch-agent.log"
logtarget = "lumberjack"
metric_batch_size = 1000
metric_buffer_limit = 10000
omit_hostname = false
precision = ""
quiet = false
round_interval = false

[inputs]

[[inputs.logfile]]
destination = "cloudwatchlogs"
file_state_folder = "c:\\ProgramData\\Amazon\\AmazonCloudWatchAgent\\Logs\\state"

[[inputs.logfile.file_config]]
file_path = "c:\\tmp\\not-amazon-cloudwatch-agent.log"
from_beginning = true
log_group_name = "amazon-cloudwatch-agent.log"
pipe = false
retention_in_days = -1
timestamp_layout = "15:04:05 06 Jan 02"
timestamp_regex = "(d{2}:d{2}:d{2} d{2} w{3} d{2})"

[outputs]

[[outputs.cloudwatchlogs]]
force_flush_interval = "5s"
log_stream_name = "i-UNKNOWN"
region = "us-west-2"
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{

"logs": {
"logs_collected": {
"files": {
"collect_list": [
{
"file_path": "c:\\tmp\\not-amazon-cloudwatch-agent.log",
"log_group_name": "amazon-cloudwatch-agent.log",
"timestamp_format": "%H:%M:%S %y %b %d"
}
]
}
}
}
}
35 changes: 35 additions & 0 deletions translator/tocwconfig/sampleConfig/skip_log_timestamp.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
[agent]
collection_jitter = "0s"
debug = false
flush_interval = "1s"
flush_jitter = "0s"
hostname = ""
interval = "60s"
logfile = "/opt/tmp/a.log"
logtarget = "lumberjack"
metric_batch_size = 1000
metric_buffer_limit = 10000
omit_hostname = false
precision = ""
quiet = false
round_interval = false

[inputs]

[[inputs.logfile]]
destination = "cloudwatchlogs"
file_state_folder = "/opt/aws/amazon-cloudwatch-agent/logs/state"

[[inputs.logfile.file_config]]
file_path = "/opt/tmp/a.log"
from_beginning = true
log_group_name = "amazon-cloudwatch-agent.log"
pipe = false
retention_in_days = -1

[outputs]

[[outputs.cloudwatchlogs]]
force_flush_interval = "5s"
log_stream_name = "i-UNKNOWN"
region = "us-west-2"
18 changes: 18 additions & 0 deletions translator/tocwconfig/sampleConfig/skip_log_timestamp.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"agent": {
"logfile": "/opt/tmp/a.log"
},
"logs": {
"logs_collected": {
"files": {
"collect_list": [
{
"file_path": "/opt/tmp/a.log",
"log_group_name": "amazon-cloudwatch-agent.log",
"timestamp_format": "%H:%M:%S %y %b %d"
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
[agent]
collection_jitter = "0s"
debug = false
flush_interval = "1s"
flush_jitter = "0s"
hostname = ""
interval = "60s"
logfile = "/opt/aws/amazon-cloudwatch-agent/logs/amazon-cloudwatch-agent.log"
logtarget = "lumberjack"
metric_batch_size = 1000
metric_buffer_limit = 10000
omit_hostname = false
precision = ""
quiet = false
round_interval = false

[inputs]

[[inputs.logfile]]
destination = "cloudwatchlogs"
file_state_folder = "/opt/aws/amazon-cloudwatch-agent/logs/state"

[[inputs.logfile.file_config]]
file_path = "/opt/aws/amazon-cloudwatch-agent/logs/amazon-cloudwatch-agent.log"
from_beginning = true
log_group_name = "amazon-cloudwatch-agent.log"
pipe = false
retention_in_days = -1

[outputs]

[[outputs.cloudwatchlogs]]
force_flush_interval = "5s"
log_stream_name = "i-UNKNOWN"
region = "us-west-2"
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"logs": {
"logs_collected": {
"files": {
"collect_list": [
{
"file_path": "/opt/aws/amazon-cloudwatch-agent/logs/amazon-cloudwatch-agent.log",
"log_group_name": "amazon-cloudwatch-agent.log",
"timestamp_format": "%H:%M:%S %y %b %d"
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
[agent]
collection_jitter = "0s"
debug = false
flush_interval = "1s"
flush_jitter = "0s"
hostname = ""
interval = "60s"
logfile = "c:\\ProgramData\\Amazon\\AmazonCloudWatchAgent\\Logs\\amazon-cloudwatch-agent.log"
logtarget = "lumberjack"
metric_batch_size = 1000
metric_buffer_limit = 10000
omit_hostname = false
precision = ""
quiet = false
round_interval = false

[inputs]

[[inputs.logfile]]
destination = "cloudwatchlogs"
file_state_folder = "c:\\ProgramData\\Amazon\\AmazonCloudWatchAgent\\Logs\\state"

[[inputs.logfile.file_config]]
file_path = "c:\\ProgramData\\Amazon\\AmazonCloudWatchAgent\\Logs\\amazon-cloudwatch-agent.log"
from_beginning = true
log_group_name = "amazon-cloudwatch-agent.log"
pipe = false
retention_in_days = -1

[outputs]

[[outputs.cloudwatchlogs]]
force_flush_interval = "5s"
log_stream_name = "i-UNKNOWN"
region = "us-west-2"
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"logs": {
"logs_collected": {
"files": {
"collect_list": [
{
"file_path": "c:\\ProgramData\\Amazon\\AmazonCloudWatchAgent\\Logs\\amazon-cloudwatch-agent.log",
"log_group_name": "amazon-cloudwatch-agent.log",
"timestamp_format": "%H:%M:%S %y %b %d"
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
[agent]
collection_jitter = "0s"
debug = false
flush_interval = "1s"
flush_jitter = "0s"
hostname = ""
interval = "60s"
logfile = "c:\\tmp\\am.log"
logtarget = "lumberjack"
metric_batch_size = 1000
metric_buffer_limit = 10000
omit_hostname = false
precision = ""
quiet = false
round_interval = false

[inputs]

[[inputs.logfile]]
destination = "cloudwatchlogs"
file_state_folder = "c:\\ProgramData\\Amazon\\AmazonCloudWatchAgent\\Logs\\state"

[[inputs.logfile.file_config]]
file_path = "c:\\tmp\\am.log"
from_beginning = true
log_group_name = "amazon-cloudwatch-agent.log"
pipe = false
retention_in_days = -1

[outputs]

[[outputs.cloudwatchlogs]]
force_flush_interval = "5s"
log_stream_name = "i-UNKNOWN"
region = "us-west-2"
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"agent": {
"logfile": "c:\\tmp\\am.log"
},
"logs": {
"logs_collected": {
"files": {
"collect_list": [
{
"file_path": "c:\\tmp\\am.log",
"log_group_name": "amazon-cloudwatch-agent.log",
"timestamp_format": "%H:%M:%S %y %b %d"
}
]
}
}
}
}
Loading