Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 937264 - media-sound/mpd-0.23.15-r1 init script no longer supports log_file="syslog"
Summary: media-sound/mpd-0.23.15-r1 init script no longer supports log_file="syslog"
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Adrian Schollmeyer
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-08-04 05:45 UTC by Walther
Modified: 2024-08-04 10:00 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Walther 2024-08-04 05:45:41 UTC
/etc/mpd.conf:
[code]
# These settings are the locations for the daemon log files for the daemon.
#
# The special value "syslog" makes MPD use the local syslog daemon. This
# setting defaults to logging to syslog.
#
# If you use systemd, do not configure a log_file.  With systemd, MPD
# defaults to the systemd journal, which is fine.
#
log_file "syslog"
[/code]

/etc/init.d/mpd:
[code]
start_pre() {
   check_config

   local pid_dir="$(dirname "${pidfile}")"
   checkpath -d -m 700 -o "${mpd_user}:${mpd_group}" "${pid_dir}"

   local log_file="$(get_config log_file)"
   if [ -n "${log_file}" ]; then
      local log_dir="$(dirname "${log_file}")"
      checkpath -d -m 755 -o "${mpd_user}:${mpd_group}" "${log_dir}"
   fi
}
[/code]


 /etc/init.d/mpd start
 * checkpath: empty or relative path
 * ERROR: mpd failed to start

The current (stable) init.d script for mpd fails to account for the special value of the log_file "syslog", and the daemon only starts if it specifies an absolute file.