[MPlayer-users] Cron mplayer issue

John Coulthard bahhab at hotmail.com
Wed Jan 4 08:47:33 CET 2006


Thanks for the reply.

I've not sovled the strange cron behavior but I have come up with a work 
round.  The default file location for -ao pcm is ./audiodump.wav so instead 
of trying to hard code the output location just do a cd 
/required/location/dir in the shell script and the audiodump.wav file will 
be put in there.

For anyone serching for a solution here are my crontab comand and shell 
script.

------------------crontab comand------------------
21 7 * * 3 root /home/ann/rec >/home/ann/rec.log 2>&1

------------------shell script------------------------

#!/bin/bash

DATE=`date +%F`
echo "recording"
cd /home/ann/rips
rm /home/ann/rips/audiodump.wav  #remove previous audiodump.wav files
mplayer -cache 256 -playlist 
http://www.station.co.uk/radio/aod/shows/rpms/show.rpm -ao pcm -vc dummy -vo 
null -really-quiet </dev/null &
#sleep 10800   #sleep for 3hrs
sleep 120    #sleep for 120sec
kill $!   #kill the mplayer job
echo "recording done"
lame /home/ann/rips/audiodump.wav /home/ann/rips/Show$DATE.mp3
echo "all done :)"




>From: Martin Collins <martin at mkcollins.org>
>Reply-To: "MPlayer usage questions, feature requests,  bug reports" 
><mplayer-users at mplayerhq.hu>
>To: "MPlayer usage questions, feature requests,  bug reports" 
><mplayer-users at mplayerhq.hu>
>Subject: Re: [MPlayer-users] Cron mplayer issue
>Date: Wed, 4 Jan 2006 02:30:44 +0000
>
>On Tue, 03 Jan 2006 11:46:49 +0000
>"John Coulthard" <bahhab at hotmail.com> wrote:
>
> > So anyone know why the specified output file is not used by cron?
>
>Wy don't you post the contents of your crontab, maybe the problem lies
>there.
>
>Martin
>
>_______________________________________________
>MPlayer-users mailing list
>MPlayer-users at mplayerhq.hu
>http://mplayerhq.hu/mailman/listinfo/mplayer-users

_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE! 
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/




More information about the MPlayer-users mailing list