Can you please elaborate on what you are trying to achieve? Monitor a directory for file? Add a directory into Log monitoring in Dynatrace? Which version of Log Monitoring in Dynatrace are you using (Log Monitoring 1 or Log Monitoring v2)?
The ask is to monitor a log directory instead of an individual file.
Using log monitoring v2.
Application team creates new log files at regular intervals and it is a hassle to manually update each individual file for monitoring in Dynatrace. It would be beneficial, if Dynatrace is able to monitor a log directory/path.
If your log file is automatically detected by OneAget, you can enable log monitoring for the process group and each newly created log file will be monitored automatically.
Go to Settings > Log Monitoring > Log sources and storage and check if you can see the log file under the process group.
Is it possible that the issue reported in this thread comes from the fact that a custom location of the log file is not capable of being monitored?
I'm having a similar issue. The commercial application that my company uses writes a log to a folder structure like this - d:\infogenesis\log_dir\20220413.pmi.
Log monitoring V2 has limitation where if the first or second folder in the path is not exactly like "log" or "logs", then you can't add that path to be monitored for logs. In my case, it's "log_dir" so I can't add it, get error "Specified filepath of log is not valid or not allowed"