[icecast] capturing pid from command line

Adon Irani adon at yorku.ca
Tue Nov 4 06:01:17 UTC 2003



hello ;

can't recall where i got it from , but this should work .,

ps auxw | fgrep icecast | fgrep -v fgrep | awk '{print $2}'

 a:/,

<p>On Mon, 3 Nov 2003, Dave St John wrote:

> Anyone know of or how to capture the pid via the command line in bash?
>
> i.e. i use this to capture shoutcast's process id
> #!/bin/bash
> SRV=`cat serverlst.txt`
>
> rm -rf pids/*
>
>
> for c in $SRV ; do
>
> nohup ./sc_serv servers/$c > /dev/null 2>&1 &
>
> echo "$! - $c" | tee pids/$c.pid
>
> done
>
> that works successfully with shoutcast but not with icecast2, ideas anyone?
>
>
> Dave St John
> (CEO) Mediacast1.com
>
>
> --- >8 ----
> List archives:  http://www.xiph.org/archives/
> icecast project homepage: http://www.icecast.org/
> To unsubscribe from this list, send a message to 'icecast-request at xiph.org'
> containing only the word 'unsubscribe' in the body.  No subject is needed.
> Unsubscribe messages sent to the list will be ignored/filtered.
>
--- >8 ----
List archives:  http://www.xiph.org/archives/
icecast project homepage: http://www.icecast.org/
To unsubscribe from this list, send a message to 'icecast-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the Icecast mailing list