Skip to content
Advertisement

Tag: logging

How to use –since option with docker logs command

I want to look at last 1 hour of docker container log using docker logs –since option. Which value I should provide for –since parameter? Answer as the help says –since string Show logs since timestamp (e.g. 2013-01-02T13:23:37) or relative (e.g. 42m for 42 minutes I would do docker logs mycontainer_or_id –since 60m This syntax is correct according to my

How to make path location dynamic in xml

I have a logback.xml configured in a spring MVC + hibernate project, it is working fine on my local machine. the local machine has windows 10 OS installed. I wish to run the code of production machine which has Linux installed. What is want to know, is there a way to make LOG_PATH and LOG_ARCHIVE locations dynamic according to OS

bash ls output to file when ls finds no results

i’m relative new to scripting in bash, and made the following script: At the end of the script, i don’t make a new MLSready file. When i execute the script, i expect to see the result of the latest ‘ls -l’ command in my logfile, however (because i didn’t create a new MLSready file?) the output is redirected to my

Node.js logging gets an issue when log files are rolling by OS.

I have Node.js application which is running under Linux system and uses log4js logging library. Log files are daily rolled by Linux rolling system. The question is the following: somebody know how force the log4js to recreate and use original log file when it’s renamed somehow? Note, Log4js continue writes log into renamed file (seems, stream descriptor is kept). Please

Quick remote logging system?

I want to be about to quickly insert some logging into some testing using either (Linux) command line or Python. I don’t want to do anything system wide (e.g. re-configuring syslogd). I’ve done something like this before by doing: wget URL/logme?im=module_name&msg=hello_world And then just parsing the server log file. It’s a bit hackish and you have to URL encode all

error while running SOLR application

i am newbie on SOLR, i want to start my SOLR via terminal ubuntu but it always give error message : tail: cannot open ‘/var/solr/logs/solr.log’ for reading: No such file or directory i try to use this script service solr start and ./solr start but the result still same, any idea to fix this problem? Answer I fixed this increasing

Analyze log file of dnsmasq

I current facing a problem. When I open the dnsmasq log, it looks like this: It’s very difficult for us to analyze it. Anybody have a idea to only show the queried domain which should be like this? However I tried this: http://www.tannerwilliamson.com/analyzing-dnsmasq-log-with-awk/1610/ and its output i like this: It’s little bit different from what I want. Anybody could help

Generate log4j timestamp format in linux date

I want to mimic the format used in log4j for timestamps using the linux date (just some quick scripting) On log4j the format is defined as %d{dd MMM yyyy HH:mm:ss,SSS} That would translate into lines like: 2016-03-10 07:01:09,778 2016-03-10 07:01:09,784 Can this be accomplished in date? The closer I got was using But this still has 9 digits instead of

Advertisement