[Icecast-dev] Writing Alpha Tags into the comments of an ogg stream

roger roger at eskimo.com
Fri Jul 20 17:09:01 PDT 2007

On Sat, 2007-07-21 at 00:45 +0300, Geoff Shang wrote:
> "roger" <roger at eskimo.com> wrote:
> > Figured it out.  Using Ices, I can either write to stdin or a file.
> >
> >
> > Using a file method:
> >
> > $ cat metadata
> > artist=Eugene Oregon
> > title=Scanning
> >
> > $ ps -ax |grep ices
> >
> > $ kill -SIGUSR1 [pid of ices]
> I *think* you can tell Ices to generate a file containing it's process ID. 
> (it's awhile since I messed with Ices 2.x).
> If this is true, you could simply do something like:
> kill -USR1 `cat ices.pid`

I thought of this, but figured this would end up to be distro specific
where init would create a pid file (ie. Gentoo would create a pid
in /var/run).

So, I leave this up to the user for now grepping the "$ ps -ax |grep
ices" and supplying the pid via an arg.  This allows me to work on more
pertinent issues (such as only writing a metadata file only when needed
instead of every .5 seconds). 

> (assuming USR1 is the right signal, I thought it was USR2 actually but I've 
> not looked.)

SIGUSR1 according to the Ices2 docs, but I think Icecast uses SIGUSR2.

> > Writing to stdin method:
> >
> > [snip]
> > $cat metadata >
> > http://localhost:8000/admin/updatemetadata.xsl?mount=/stream.ogg
> I'm pretty sure you can't do this.  HTTP is a protocol, not a device, so 
> you'd have to pipe to a program which could talk HTTP and turn your standard 
> input into something usable by Icecast.
> But I'm pretty sure you can send standard output to Ices' standard input and 
> get it to read it too.  But I've not ever done this so have not looked at 
> it.
> Geoff.

Trying to keep things portable as usual. Once I figure-out what a good
standard method of checking for pid or pid files
(ie. /var/run/ices.pid), I'll implement my feature further in my
program. Thanks for your time! :-)

Key fingerprint = 8977 A252 2623 F567 70CD 1261 640F C963 1005 1D61

Fri Jul 20 17:04:09 PDT 2007

More information about the Icecast-dev mailing list