View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0000917 | 1003.1(2013)/Issue7+TC1 | Shell and Utilities | public | 2015-02-02 11:30 | 2024-06-11 09:02 |
Reporter | rhymoid | Assigned To | |||
Priority | normal | Severity | Editorial | Type | Enhancement Request |
Status | Closed | Resolution | Accepted As Marked | ||
Name | Stijn van Drongelen | ||||
Organization | |||||
User Reference | |||||
Section | logger | ||||
Page Number | 2878-2879 | ||||
Line Number | 94786-94861 | ||||
Interp Status | --- | ||||
Final Accepted Text | 0000917:0002626 | ||||
Summary | 0000917: specified 'logger' does not match actual usage | ||||
Description | After a bit of searching, it seems that UnixWare is the only software distribution that claims POSIX adherence _and_ implements a truly POSIX-compliant version of the 'logger' utility. Any other distribution seems to follow BSD's lead, because that variant is simply more useful. Unlike the specified logger, BSD's logger conforms to the Utility Syntax Guidelines, and seem to have a few options in common: * -f {file}: log the lines of the specified * -i: record the process ID of logger along with the message * -p {facility}.{level}: set the facility and level of the logged message; defaults to "user.notice" * -t {tag}: tag the message (seems to default to a implementation-defined format) These options map trivially to openlog() and syslog() calls. The only weirdness is what happens when both or neither -f and a message is provided (neither: message is taken from standard input, breaking compatibility with the specified logger in yet another way; both: unspecified behaviour?). Now, as for implementation, logger should be a frontend to <syslog.h> on XSI-compliant systems, in my opinion. | ||||
Desired Action | * Investigate the current actual implementation of the logger utility. * Update the standard to reflect the command line syntax for logger in actual use. Preferably, follow the Utility Syntax Guidelines. * Update the standard to require equivalence to appropriate calls to openlog() and syslog() on XSI-compliant systems. | ||||
Tags | issue8 |
|
The claim that UnixWare is the only system that claims POSIX adherence and has a "truly POSIX-compliant" implementation of the logger utility is not correct and is most likely the result of a misunderstanding of what POSIX requires (and allows). In particular, although POSIX does not require logger to conform to the Utility Syntax Guidelines and does not mandate any options, it requires logger to accept an initial "--" argument so that applications can pass a string operand beginning with "-" to implementations of logger that accept (as an allowed extension) one or more options. See XCU 1.4 Utility Description Defaults, under OPTIONS -> Default Behavior. Also, since the SYNOPSIS requires that applications pass at least one string operand to logger, any differences in behaviour of logger implementations when no operands are passed does not constitute non-conformance with POSIX. Having said all that, I would not oppose enhancing logger in Issue 8 along the lines proposed (with XSI shading on any requirements relating logger to openlog() and syslog()). |
|
On page 2878 line 94786 (logger synopsis), change:logger string...to: logger [-i] [-f file] [-p priority] [-t tag] [string...]On page 2878 lines 94788-94790 (logger DESCRIPTION), change: The logger utility saves a message, in an unspecified manner and format, containing the string operands provided by the user. The messages are expected to be evaluated later by personnel performing system administration tasks.to: The logger utility shall send messages to an implementation-defined logging facility, which may log them in an implementation-defined system log, write them to the system console, forward them to a list of users, or forward them to the logging facility on another host over the network. Each logged message shall include a message header and a message body. The message header contains at least a timestamp and a tag string.On page 2878 line 94794 (logger options), change: None.to: The logger utility shall conform to XBD Section 12.2 (on page 215).On page 2878 line 94800 (logger STDIN), change: Not used.to: The standard input shall be used if no string operands are specified and either the -f option is not specified or the -f option is specified with a file option-argument of '-' and the implementation treats the '-' as meaning standard input. Otherwise, the standard input shall not be used. See the INPUT FILES section.On page 2878 line 94802 (logger input files), change: None.to: The input files shall be text files. |
Date Modified | Username | Field | Change |
---|---|---|---|
2015-02-02 11:30 | rhymoid | New Issue | |
2015-02-02 11:30 | rhymoid | Name | => Stijn van Drongelen |
2015-02-02 11:30 | rhymoid | Section | => logger |
2015-02-02 11:30 | rhymoid | Page Number | => . |
2015-02-02 11:30 | rhymoid | Line Number | => . |
2015-02-02 16:06 | geoffclare | Note Added: 0002534 | |
2015-04-02 16:45 | Don Cragun | Page Number | . => 2878-2879 |
2015-04-02 16:45 | Don Cragun | Line Number | . => 94786-94861 |
2015-04-02 16:45 | Don Cragun | Interp Status | => --- |
2015-04-16 16:37 | rhansen | Note Added: 0002626 | |
2015-04-16 16:40 | rhansen | Final Accepted Text | => 0000917:0002626 |
2015-04-16 16:40 | rhansen | Status | New => Closed |
2015-04-16 16:40 | rhansen | Resolution | Open => Accepted As Marked |
2015-04-16 16:40 | rhansen | Tag Attached: issue8 | |
2015-04-16 16:44 | rhansen | Status | Closed => Resolved |
2020-04-03 15:15 | geoffclare | Status | Resolved => Applied |
2024-06-11 09:02 | agadmin | Status | Applied => Closed |