author | Devjani Ray <devjani.ray@oracle.com> |
Fri, 20 May 2016 17:42:29 -0400 | |
branch | s11u3-sru |
changeset 6035 | c9748fcc32de |
permissions | -rw-r--r-- |
6035
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
1 |
In-house patch to remove the hardcoding of /dev/log as the address for |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
2 |
syslog. The default logging module is smart enough to use the proper |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
3 |
path in Solaris. |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
4 |
|
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
5 |
--- oslo.log-1.0.0/oslo_log/log.py.orig 2015-09-29 16:41:03.335483630 -0600 |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
6 |
+++ oslo.log-1.0.0/oslo_log/log.py 2015-09-29 16:41:23.112003925 -0600 |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
7 |
@@ -285,11 +285,9 @@ def _setup_logging_from_conf(conf, proje |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
8 |
# TODO(bogdando) use the format provided by RFCSysLogHandler |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
9 |
# after existing syslog format deprecation in J |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
10 |
if conf.use_syslog_rfc_format: |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
11 |
- syslog = handlers.RFCSysLogHandler(address='/dev/log', |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
12 |
- facility=facility) |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
13 |
+ syslog = handlers.RFCSysLogHandler(facility=facility) |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
14 |
else: |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
15 |
- syslog = logging.handlers.SysLogHandler(address='/dev/log', |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
16 |
- facility=facility) |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
17 |
+ syslog = logging.handlers.SysLogHandler(facility=facility) |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
18 |
log_root.addHandler(syslog) |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
19 |
except socket.error: |
c9748fcc32de
PSARC 2015/535 OpenStack service updates for Kilo
Devjani Ray <devjani.ray@oracle.com>
parents:
diff
changeset
|
20 |
log_root.error('Unable to add syslog handler. Verify that syslog ' |