Skip to content

Commit

Permalink
syslog: Provide stub functions for openlog and syslog.
Browse files Browse the repository at this point in the history
One option to implement openlog and syslog functionality in Windows
is to use windows event logger. But it looks like it involves changing
registry settings and in general looks complicated.

For the time being, do nothing for syslog. All the information needed for
debugging will be present through the 'file' option anyways.

We can start OVS daemons on Windows with "-vfile:info -vsyslog:off".

Signed-off-by: Gurucharan Shetty <[email protected]>
Acked-by: Ben Pfaff <[email protected]>
  • Loading branch information
shettyg committed Jan 24, 2014
1 parent fa5b8c6 commit 5a6af13
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 0 deletions.
11 changes: 11 additions & 0 deletions include/windows/syslog.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,15 @@
#define LOG_LOCAL6 (22<<3) /* reserved for local use */
#define LOG_LOCAL7 (23<<3) /* reserved for local use */

static inline void
openlog(const char *ident OVS_UNUSED, int option OVS_UNUSED,
int facility OVS_UNUSED)
{
}

static inline void
syslog(int priority OVS_UNUSED, const char *format OVS_UNUSED, ...)
{
}

#endif /* syslog.h */
4 changes: 4 additions & 0 deletions lib/vlog-unixctl.man
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@ module.
\fBsyslog\fR, \fBconsole\fR, or \fBfile\fR, to limit the log level
change to only to the system log, to the console, or to a file,
respectively.
.IP
On Windows platform, \fBsyslog\fR is accepted as a word and is only
useful along with the \fB\-\-syslog\-target\fR option (the word has no
effect otherwise).
.
.IP \(bu
\fBoff\fR, \fBemer\fR, \fBerr\fR, \fBwarn\fR, \fBinfo\fR, or
Expand Down
4 changes: 4 additions & 0 deletions lib/vlog.man
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@ module.
\fBsyslog\fR, \fBconsole\fR, or \fBfile\fR, to limit the log level
change to only to the system log, to the console, or to a file,
respectively.
.IP
On Windows platform, \fBsyslog\fR is accepted as a word and is only
useful along with the \fB\-\-syslog\-target\fR option (the word has no
effect otherwise).
.
.IP \(bu
\fBoff\fR, \fBemer\fR, \fBerr\fR, \fBwarn\fR, \fBinfo\fR, or
Expand Down
4 changes: 4 additions & 0 deletions utilities/ovs-appctl.8.in
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,10 @@ module.
\fBsyslog\fR, \fBconsole\fR, or \fBfile\fR, to limit the log level
change to only to the system log, to the console, or to a file,
respectively.
.IP
On Windows platform, \fBsyslog\fR is accepted as a word and
is only useful if the \fItarget\fR was started with the
\fB\-\-syslog\-target\fR option (the word has no effect otherwise).
.
.IP \(bu
\fBoff\fR, \fBemer\fR, \fBerr\fR, \fBwarn\fR, \fBinfo\fR, or
Expand Down

0 comments on commit 5a6af13

Please sign in to comment.