[MPlayer-users] A Case of mplayer Working manually, but not as an at job
Martin McCormick
martin at dc.cis.okstate.edu
Sat Jan 20 05:25:24 CET 2007
There is an URL for Radio Rebelde in Cuba. The file I
use is as follows:
<ASX version="3">
<Entry><ref href="http://media.enet.cu/radiorebelde"/>
</Entry>
</ASX>
If I call it rebelde.phtml and access it via mplayer from
the command prompt as
mplayer -quiet -playlist [path]/rebelde.phtml, it plays fine.
Don't know why they usually use only the left channel, but that's
for speculation.
If I call a script to capture the stream which looks like:
#! /bin/sh
mplayer -quiet -dumpstream -playlist $HOME/radio/rebelde.phtml
That works great.
In most other cases of links to streaming audio, I can
even set an at job to call that same type of script and it works
great because at jobs should run with the environment of the user
so as far as the system is concerned, I got up at 3 A.M. and ran
that command by hand.
On this one URL, however, it fails strangely because the
output of mplayer looks like it does when I run it by hand.
MPlayer 1.0pre8-3.3.5 (C) 2000-2006 MPlayer Team
CPU: Intel Celeron 2/Pentium III Coppermine,Geyserville (Family: 6, Model: 8, Stepping: 1)
CPUflags: MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 0
Compiled for x86 CPU with extensions: MMX MMX2 SSE
Playing http://media.enet.cu/radiorebelde.
STREAM_HTTP(1), URL: http://media.enet.cu/radiorebelde
Resolving media.enet.cu for AF_INET...
Connecting to server media.enet.cu[200.55.129.7]: 80...
STREAM_ASF, URL: http://media.enet.cu/radiorebelde
Resolving media.enet.cu for AF_INET...
Connecting to server media.enet.cu[200.55.129.7]: 80...
Resolving media.enet.cu for AF_INET...
Connecting to server media.enet.cu[200.55.129.7]: 80...
Cache size set to 64 KBytes
Stream not seekable!
At this point, it is capturing to stream.dump perfectly
and the stream plays back as expected. Now, if I do:
$ at now
$ at now
warning: commands will be executed using /bin/sh
at> rebelde_capture
at> <EOT>
job 42 at 2007-01-19 21:53
A few seconds later, I get an Email from root with the following
failure message:
Subject: Output from your job 42
MPlayer 1.0pre8-3.3.5 (C) 2000-2006 MPlayer Team
CPU: Intel Celeron 2/Pentium III Coppermine,Geyserville (Family: 6, Model: 8, S
tepping: 1)
CPUflags: MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 0
Compiled for x86 CPU with extensions: MMX MMX2 SSE
Terminal type `unknown' is not defined.
Playing http://media.enet.cu/radiorebelde.
STREAM_HTTP(1), URL: http://media.enet.cu/radiorebelde
Resolving media.enet.cu for AF_INET...
Connecting to server media.enet.cu[200.55.129.7]: 80...
STREAM_ASF, URL: http://media.enet.cu/radiorebelde
Resolving media.enet.cu for AF_INET...
Connecting to server media.enet.cu[200.55.129.7]: 80...
Failed, exiting.
STREAM_HTTP(2), URL: http://media.enet.cu/radiorebelde
Resolving media.enet.cu for AF_INET...
Connecting to server media.enet.cu[200.55.129.7]: 80...
File not found: 'media.enet.cu/radiorebelde'
Failed to open http://media.enet.cu/radiorebelde.
Exiting... (End of file)
I have printed out the environment I get when I log in
and the environment one gets from at and the things you would
hope are good such as the path are the same in both cases.
Other audio feeds actually do work this way but there is
something special about this feed that makes it fail under at.
Is the terminal variable enough to make mplayer fail?
Note that mplayer does try to run. In most bad or
missing path cases, you will get the familiar "No such file or
directory" message or a "file not found" report. In this case,
the "file not found" stems from there being no connection open to
the server.
Again, thanks for any trouble-shooting thoughts.
Martin McCormick WB5AGZ Stillwater, OK
Systems Engineer
OSU Information Technology Department Network Operations Group
More information about the MPlayer-users
mailing list