Summary: | media-tv/mythtv - logging to a file in /etc/conf.d/mythbackend fails because of hard-wired /etc/init.d/mythbackend settings | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Wilson M. Michaels <thebitpit> |
Component: | Current packages | Assignee: | MythTV Maintainers <mythtv+disabled> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | henson, olav |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Wilson M. Michaels
2012-11-13 17:58:35 UTC
*** Bug 498420 has been marked as a duplicate of this bug. *** I see there's been some activity on new mythtv ebuilds; any possibility on following up on this bug and making the logging configuration set in the conf file rather than the init script? That seems like a pretty simple change and keeps people who want to do syslog logging from having to overwrite the init script. Ideally it could also conditionalize the chown of /var/log/mythtv on whether or not file logging is enabled, as you don't really want to do that with syslog logging. Thanks... I'll see if I can get this to work. The trick will be making the corresponding changes to the systemd unit, but I can just stick the logging option in a variable and pass it either way. Conditionally fixing file permissions conditionally might be trickier, since there is no script running for systemd unless we create and execute one. I'm not sure if mythbackend supports logging to the console but that would also be a logical option for systemd users. If I get it all working I'll post new scripts for you to test - I don't actually have any systems running openrc and mythbackend at this point, but the changes will be along the lines of the patch you proposed. I'm away for a week so it might be a bit before I get to this. Hmm, I don't seem to be reliably getting bugzilla email updates :(, I didn't realize you'd updated this ticket 6 months ago 8-/. mythbackend will log to stdout if not daemonized; I see your current unit file has: # Systemd sends stdout to syslog, and mythbackend has console logging enabled without --daemon. # Send stdout to /dev/null so console logging doesn't go to syslog StandardOutput=null # Default setting for Type=simple. ExecStart=/usr/bin/mythbackend --logpath /var/log/mythtv --loglevel crit So it looks like you're already doing that, but dumping the console logs and still logging to a file... I don't really care what the default is, it would just be nice to be able to configure a different setting without having to munge the init script :). Thanks... So you're one of those systemd users, eh ;)? Any further thoughts on this? Maybe at least moving the logpath option from the init script to the conf.d file so users can override it? Thanks... I apologize for the delay in resolving this issue. The next bump I'll do to MythTV will include the following in /etc/conf.d/mythbackend. # Configures where mythbackend logs # Valid values: # * files - logs each individual daemon in /var/log/mythtv (default) # * database - logs into the database # * syslog FACILITY - logs to syslog using FACILITY (see syslog(3)) #MYTHBACKEND_LOGGING="files" (In reply to Doug Goldstein from comment #6) > I apologize for the delay in resolving this issue. The next bump I'll do to > MythTV will include the following in /etc/conf.d/mythbackend. > > # Configures where mythbackend logs > # Valid values: > # * files - logs each individual daemon in /var/log/mythtv > (default) > # * database - logs into the database > # * syslog FACILITY - logs to syslog using FACILITY (see syslog(3)) > #MYTHBACKEND_LOGGING="files" If you change anything at build-time to accomplish this please coordinate on testing of the systemd units. As I recall the mythtv logging design is somewhat odd in its behavior. Obviously if you only end up touching the init.d scripts there shouldn't be any conflict with systemd at all. Happy to work with you either way. Long-term upstream is removing the mythlogserver component so these configurations should tend to converge. Thanks for the report. Fixed in http://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9ada29b52010e465a522fdc68d4eee0da6eaa349 |