Splunk Dev

python ログのローテーションの設定を変更すると SplunkWeb がハングする

CurryPan
Communicator

下記のように log.cfg の [python] スタンザを変更し、pythonログのローテーションサイズと個数を変更しました。

[python]
appender.python.maxBackupIndex = 10 
appender.python.maxFileSize = 500

変更を反映するために、Splunkを再起動したところ、SplunkWebがスタートできずハングしたようになります。web_services.log を確認したところ、下記のエラーメッセージが表示されていました。

2017-04-04 15:56:02,928 ERROR   [58e34382a0701d2955c0] root:814 - 'module' object has no attribute '10' 
Traceback (most recent call last): 
File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\appserver\mrsparkle\root.py", line 90, in <module> 
splunk.setupSplunkLogger(logger, LOGGING_DEFAULT_CONFIG_FILE, LOGGING_LOCAL_CONFIG_FILE, LOGGING_STANZA_NAME) 
File "C:\Program Files\Splunk\Python-2.7\Lib\site-packages\splunk\__init__.py", line 154, in setupSplunkLogger 
logging.getLogger(loggerName).setLevel(getattr(logging, level)) 
AttributeError: 'module' object has no attribute '10' 

pythonログのローテーション設定はできないのでしょうか。

0 Karma

CurryPan
Communicator

Splunkでは、Python ログのローテーションを設定することはサポート対象外となり、設定すると SplunkWebが正常に起動されなくなります。なお、SplunkWebが起動できなくなる問題につきましては、Splunk ver.6.5.4 にて修正されます。

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...