LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-04-2004, 08:09 PM   #1
jimbobboy
LQ Newbie
 
Registered: Sep 2003
Location: Colorado
Distribution: Mandrake
Posts: 4

Rep: Reputation: 0
Unhappy Cannot capture streaming with cron


Gang -
Please help mitigate my ignorance re/ cron.
I want to record a webcast with a cron job.
I have the scripts working, but not with cron.
Here's the start script:
mpg123 -b 1024 -s (url goes here) > /home/mydirectory/audio/GDH.pcm
This works like a charm when I invoke the script from the command line.
The file "GDH.pcm" appears, and starts filling up.
Similarly the stop script:
mpg_pid=$(/sbin/pidof mpg123)
echo $mpg_pid
kill $mpg_pid
When invoked, it dutifully echoes the PIDs and kills any mpg123 job(s).
But when I set up "start" to run at a specified time (or launch manually) with kcron, I just get a zero-length file.
The "stop" script does nothing when invoked by kcron.
Permissions for both scripts are 104755.
I am owner and group for "start". Root for "stop", so it can run "pidof."
I don't see anything in /var/log/messages to indicate what the problem is.
For some reason, cron just can't seem to redirect mpg123's output (though it can create the file) and can't kill the jobs.

I know it's something simple, but I've been tinkering off and on for weeks with no success.

Any ideas?

Thanks!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
shell script using /etc/cron.hourly to execute cron.php file? rioguia Programming 3 06-11-2008 09:09 AM
log cron job to capture errors if there are ashley75 Linux - General 1 05-21-2004 11:34 AM
Capture support for dvd and video capture in linux is it even going to be real ever? maximalred Linux - Distributions 3 07-06-2003 08:29 PM
[cron][mdk9.1]cron deamon seems to ignore some task... yannrichet Linux - Newbie 5 06-26-2003 10:57 AM
dual entries in cron log for cron.daily cpharvey Linux - General 3 02-27-2003 03:30 PM


All times are GMT -5. The time now is 10:36 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration