in reply to Re^5: JSON::XS and blessings
in thread JSON::XS and blessings

I built it myself, not deploying binaries This ubuntu server came naked, and I installed apache, mod_perl and all the cpan modules I use including JSON (and JSON:XS).

If JSON:XS did not work, it would have been an easy thing to fix. If it does work in one virtual server and not on the other (running on the same machine, same apache server), that may push one to believe in ghosts.

Replies are listed 'Best First'.
Re^7: JSON::XS and blessings
by Your Mother (Archbishop) on Oct 15, 2015 at 00:44 UTC

    :P Heisenbugs happen… they are, by nature, not repeatable.

      Haha, yes. Except that in this case it's totally repeatable. One virtual server always has a live cat, the other always has a dead cat.

        You have already stated that the problem only occurs when Apache is involved.

        Have you stopped and restarted Apache?

        Does the problem persist when the Perl script is run as a CGI program instead of being run as a mod_perl script?

        Check the versions of all modules loaded into mod_perl and compare them between the two machines:

        for my $module (sort keys %INC) { (my $namespace = $module) =~ s!/!::!g; $namespace =~ s/\.pm$//; print sprintf "Module: %s; Path: %s; Size: %d; VERSION: %s\n", $module, $INC{$module}, -s($INC{$module}), $namespace->VERSION +; }

        Note that you need to run the above output from within Apache, because when run from the shell everything seems to be OK for you.