syslognet (version 0.1.2.1)

syslog: Send log message to syslog server

Description

Send log message to syslog server.

Usage

syslog(
  message,
  severity = "NOTICE",
  facility = "USER",
  host = Sys.info()[["nodename"]],
  app_name = Sys.info()[["user"]],
  proc_id = Sys.getpid(),
  server = "localhost",
  port = 601L
)

Arguments

message

text message (string).

severity

severity level (string).

facility

log facility (string).

host

machine that originally sends the message (string).

app_name

application name that originally sends the message (string).

proc_id

process id that originally sends the message (numeric).

server

syslogd server hostname (string).

port

syslogd server port (integer).

Value

Number of bytes written to socket.

Examples

Run this code
# NOT RUN {
syslog("log message", "INFO", app_name = 'program', server = 'logserver')
# }

Run the code above in your browser using DataLab