Archive:HOW-TO:Send xbmc.log to rsyslog: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
>UNiversal
mNo edit summary
>UNiversal
m (final cleanups and updates.)
Line 1: Line 1:
The following has been tested with Ubuntu 10.04 but should work with any distribution which include '''rsyslog''' and the [http://www.rsyslog.com/doc/imfile.html imfile module].
The following has been tested with Ubuntu 10.04 and should work with any distribution which include '''rsyslog''' and the [http://www.rsyslog.com/doc/imfile.html imfile module].


* Create the following file with contents as below:
* Create the following file with contents as below:
'''/etc/rsyslog.d/10-xbmc.conf '''
{{highlight|'''Note:'''|bordered=yes|color=#BEF781}} '''Text in bold''' will need to be adapted to value which are relevant to your system.
{{highlight|'''Note:'''|bordered=yes|color=#BEF781}} '''Text in bold''' will need to be adapted to value which are relevant to your system.


'''/etc/rsyslog.d/10-xbmc.conf '''
#
  #
$ModLoad imfile
  $ModLoad imfile
#
  #
# /home/'''xbmc'''/.xbmc/temp/xbmc.log
  # /home/'''xbmc'''/.xbmc/temp/xbmc.log
$InputFileName /home/'''xbmc'''/.xbmc/temp/xbmc.log
  $InputFileName /home/'''xbmc'''/.xbmc/temp/xbmc.log
$InputFileTag tag_xbmc_log:
  $InputFileTag tag_xbmc_log:
$InputFileStateFile xbmc_log
  $InputFileStateFile xbmc_log
$InputFileSeverity debug
  $InputFileSeverity debug
$InputFileFacility local3
  $InputFileFacility local3
$InputRunFileMonitor
  $InputRunFileMonitor
#
  #
# check for new lines every 10 seconds
  # check for new lines every 10 seconds
$InputFilePollingInterval 10
  $InputFilePollingInterval 10
#
  #
# send the log to a remote host: (optional)
  # send the log to a remote host: (optional)
local3.debug @'''<remote_host>'''
  local3.debug @'''<remote_host>'''


* restart rsyslog:
* restart rsyslog:


  sudo restart rsyslog
<source lang="bash">
sudo restart rsyslog
</source>


[[Category:How-to]]
[[Category:How-to]]
[[Category:Linux]]
[[Category:Linux]]

Revision as of 12:45, 17 December 2012

The following has been tested with Ubuntu 10.04 and should work with any distribution which include rsyslog and the imfile module.

  • Create the following file with contents as below:

/etc/rsyslog.d/10-xbmc.conf

Note: Text in bold will need to be adapted to value which are relevant to your system.

#
$ModLoad imfile
#
# /home/xbmc/.xbmc/temp/xbmc.log
$InputFileName /home/xbmc/.xbmc/temp/xbmc.log
$InputFileTag tag_xbmc_log:
$InputFileStateFile xbmc_log
$InputFileSeverity debug
$InputFileFacility local3
$InputRunFileMonitor
#
# check for new lines every 10 seconds
$InputFilePollingInterval 10
#
# send the log to a remote host: (optional)
local3.debug @<remote_host>
  • restart rsyslog:
sudo restart rsyslog