LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 05-12-2009, 12:46 AM   #1
frenchn00b
Senior Member
 
Registered: Jun 2007
Location: E.U., Mountains :-)
Distribution: Debian, Etch, the greatest
Posts: 2,561

Rep: Reputation: 57
Do you use mplayer or aplay with the crontab -e?


mpplayer not working, from bash/sh script
aplay either

Best regards
 
Old 05-12-2009, 02:43 AM   #2
rylan76
Senior Member
 
Registered: Apr 2004
Location: Potchefstroom, South Africa
Distribution: Fedora 17 - 3.3.4-5.fc17.x86_64
Posts: 1,552

Rep: Reputation: 103Reputation: 103
Hi

Maybe you need to post more info?

What are you trying to do? What specific error messages do you see? Anything in the cron log?
 
Old 05-12-2009, 03:12 AM   #3
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,

Without any other info the only thing that comes to mind is the lack of environment variables when running mplayer (and probably aplay) from the crontab. Mplayer needs some of these to work properly (not sure about aplay, but if I have to guess....).

One way of tackling this problem is by parsing your user profile from the script:

# Needed due to crontab issue: profile user not parsed
[[ "`/usr/bin/tty`" == "not a tty" ]] && . ~/.profile


This will check if the program is run from the command line or crontab and parses the user .profile if needed.

Hope this helps.
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
crontab & mplayer static linuxhippy Slackware 3 11-16-2005 03:15 PM
aplay does nothing fisheromen1031 Linux - Newbie 3 09-19-2005 08:01 PM
wierd problem with aplay and mplayer LinToWinWin Linux - Hardware 1 05-23-2005 06:16 PM
alsa ; compiling aplay.c vose Programming 0 01-13-2005 01:42 AM
New email sound Thunderbird with aplay? Moloko Linux - Software 0 01-02-2005 02:34 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 08:02 AM.

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
Open Source Consulting | Domain Registration