Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 423145

Summary: net-irc/quassel support for syslog in init script
Product: Gentoo Linux Reporter: Michael Mair-Keimberger (iamnr3) <m.mairkeimberger>
Component: Current packagesAssignee: Patrick Lauer <patrick>
Status: RESOLVED FIXED    
Severity: normal CC: johu, net-irc, proxy-maint, sputnick
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: init patch
config patch
init script which actually does work

Description Michael Mair-Keimberger (iamnr3) 2012-06-23 13:45:30 UTC
Created attachment 316063 [details]
init patch

Since 0.8 quassel supports logging to syslog. While there is already a flag for supporting syslog it's still not really possible to use it.
I've now tried to improve the init-script, so that we actually can use the syslog feature.
My plan was not just to enable syslog logging, but to have the choice to choose between syslog or logfile or both.
I had some success, but basically i found a really strange behavior in my updated init script.
While quasselcore starts correctly with the right settings, it actually doesn't log anywhere. I couldn't found the reason for that but as soon as i echo the start command into a separate file (which was executable) and start this file (over the init script) it worked.

It looks like that: 
doesn't work:
		start-stop-daemon --start --user "${QUASSEL_USER}" --background --make-pidfile \
		--pidfile "${PID}" \
		--exec "${CORE}" -- "${START_CONFIG}" \
		${LISTEN:+--listen="${LISTEN}"} ${PORT:+--port="${PORT}"} \
		--configdir="${CONFIGDIR}"

does work:
echo "		start-stop-daemon --start --user "${QUASSEL_USER}" --background --make-pidfile \
		--pidfile "${PID}" \
		--exec "${CORE}" -- "${START_CONFIG}" \
		${LISTEN:+--listen="${LISTEN}"} ${PORT:+--port="${PORT}"} \
		--configdir="${CONFIGDIR}"" > /root/test
	/root/test

Maybe someone finds the problem. :)
I'll post my patches for the config file and the init script (the original one, without the echo statement)
I also post the init script which actually does work.
After all it would be nice to have the syslog feature in the init script :)
Comment 1 Michael Mair-Keimberger (iamnr3) 2012-06-23 13:45:53 UTC
Created attachment 316065 [details, diff]
config patch
Comment 2 Michael Mair-Keimberger (iamnr3) 2012-06-23 13:46:43 UTC
Created attachment 316067 [details]
init script which actually does work
Comment 3 Patrick Lauer gentoo-dev 2012-06-25 05:06:32 UTC
Hrm, good idea, but your patch looks quite ... how to say this nicely ... wrong ;)

( and don't mess around in /root. ever)

I might have a look at it when I find some time for it - shouldn't be that tricky to do :)
Comment 4 Michael Mair-Keimberger (iamnr3) 2012-06-25 20:11:44 UTC
Hehe, yeah, i'm pretty sure my patch isn't perfect at all, especially that part with /root but that was just to show up my (strange) problem. I'm really curious why my init scripts starts quassel but doesn't log to syslog/logfile. It looks like runscript starts quassel differently than bash/sh...
Anyway, i'm looking forward for the correct init script :)
Comment 5 Larry the Git Cow gentoo-dev 2018-03-22 19:58:10 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b4e4a52dfd5dcc298eea1881cdb66562295586d5

commit b4e4a52dfd5dcc298eea1881cdb66562295586d5
Author:     Johannes Huber <johu@gentoo.org>
AuthorDate: 2018-03-22 19:48:25 +0000
Commit:     Johannes Huber <johu@gentoo.org>
CommitDate: 2018-03-22 19:56:54 +0000

    net-irc/quassel: Install newer {init,conf} file
    
    Closes: https://bugs.gentoo.org/639480
    Closes: https://bugs.gentoo.org/423145
    Bug: https://bugs.gentoo.org/603414
    Reported-by: Michael Mair-Keimberger (iamnr3) <bu9zilla@gmail.com>
    Package-Manager: Portage-2.3.24, Repoman-2.3.6

 net-irc/quassel/quassel-0.12.4-r1.ebuild | 4 ++--
 net-irc/quassel/quassel-9999.ebuild      | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)