You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Randall Hansen <li...@sonofhans.net> on 2003/06/26 00:52:29 UTC

[users@httpd] Apache::MP3 installed, being invoked, but doing nothing

Folks ~

[Egads, this is long; apologies in advance.]

I'm trying to get Apache::MP3[1] working on an internal server and
having no success.  This may be an issue with Apache and/or mod_perl
rather than Apache::MP3, but my limited experience with all three of
these is hampering my debugging.

See below: Versions[2] for what I'm running, Config[3] the relevant
chunk of httpd.conf.

Symptoms: when I browse to http://localhost/songs I get a 404.

Setup for Apache::MP3 is simple: install the module, add a few
directives to httpd.conf[3].  Those directives don't appear to change
Apache's behavior at all, though.

I know that mod_perl is working:  as a test I added another handler
which works as expected, printing a single "hello" to the browser when
I go to http://localhost/songs_test(or anywhere below that).

I know that Apache::MP3::handler does get called: I edited
Apache/MP3.pm and put a 'die' right under the package declaration;
this prevents Apache from starting, as expected.  A 'die' as the first
line of 'sub handler' gives me a '500' error when I browse to
http://localhost/songs, again as expected.

Note that the 'songs' doesn't exist.  I created it
('/var/www/music/songs') and added some MP3s to it -- then I see a
blank directory index instead of a 404 (even after the 'die'
statements).

I have the requisite 'apache_mp3' directory under /var/www/music and a
few MP3s under /var/www/music and a couple subdirectories.

Apache's error logs show nothing but a few "File does not exist:
/var/www/music/songs" lines.

So it seems as if all the individual components are working, but it's
doesn't bloody *do* anything.  That's as far as I've been able to take
it.  I've done all variety of searching to no avail -- most people
seem to have little trouble installing it.

TIA,

Randall

-- references --------------------------------------

[1] Apache::MP3:  Perl module to stream MP3s
    http://search.cpan.org/author/LDS/Apache-MP3-3.04/MP3.pm

[2] Versions:
 - Debian Sarge (testing)
 - Apache 1.3.27
 - mod_perl 1.27
 - Apache::MP3 3.04

[3] Config:
# startup.pl contains:
#   use MP3::Info;
#   use Apache::MP3;
#   1;
PerlRequire /etc/apache/startup.pl
<VirtualHost *>
    ServerName music # defined in '/etc/hosts'
    DocumentRoot /var/www/music

    CustomLog /var/log/apache/music_access.log combined
    ErrorLog /var/log/apache/music_error.log 

    <Location /songs>
        Options Indexes FollowSymLinks
        SetHandler perl-script
        PerlHandler Apache::MP3
    </Location>

    <Location /songs_test>
        Options Indexes FollowSymLinks
        SetHandler perl-script
        PerlHandler AMT # simple module with handler, prints 'hello'
    </Location>
</VirtualHost>