[syslog] Add support for sending console output to a syslog server

Originally-implemented-by: Anselm Martin Hoffmeister <anselm@hoffmeister.be>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown
2011-03-10 05:33:45 +00:00
parent 1c0ff6e1a7
commit e49d81689c
3 changed files with 243 additions and 0 deletions

36
src/include/ipxe/syslog.h Normal file
View File

@@ -0,0 +1,36 @@
#ifndef _IPXE_SYSLOG_H
#define _IPXE_SYSLOG_H
/** @file
*
* Syslog protocol
*
*/
FILE_LICENCE ( GPL2_OR_LATER );
/** Syslog server port */
#define SYSLOG_PORT 514
/** Syslog line buffer size
*
* This is a policy decision
*/
#define SYSLOG_BUFSIZE 128
/** Syslog facility
*
* This is a policy decision
*/
#define SYSLOG_FACILITY 0 /* kernel */
/** Syslog severity
*
* This is a policy decision
*/
#define SYSLOG_SEVERITY 6 /* informational */
/** Syslog priority */
#define SYSLOG_PRIORITY( facility, severity ) ( 8 * (facility) + (severity) )
#endif /* _IPXE_SYSLOG_H */