nbrownus / mlogger

Log to syslog from the command line, just like `logger` but more massive
21 stars 3 forks source link

IPv6 support #4

Closed njh closed 7 years ago

njh commented 8 years ago

Hello,

I have just tried using logger with an IPv6 only host, but I got an error message:

$ mlogger -d -n loftpi.aelius.co.uk "Hello World"
mlogger: unable to resolve 'loftpi.aelius.co.uk'

Is this a known issue?

Thanks,

nick.

nbrownus commented 8 years ago

I haven't tried using ipv6 with this. Newer versions of bsdutils logger have a --size option that does basically the same thing that this tool does.

I currently don't have the time to dig into this but I bet it is relatively trivial to fix.

njh commented 8 years ago

I have been using mlogger because it is available in @homebrew on Mac OS X.

The built-in logger on Mac OS X doesn't even support UDP:

logger [-is] [-f file] [-p pri] [-t tag] [message ...]

     -i       Log the process id of the logger process with each line.

     -s       Log the message to standard error, as well as the system log.

     -f file  Log the specified file.

     -p pri   Enter the message with the specified priority.  The priority may be specified numerically or
              as a ``facility.level'' pair.  For example, ``-p local3.info'' logs the message(s) as
              informational level in the local3 facility.  The default is ``user.notice.''

     -t tag   Mark every line in the log with the specified tag.