Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Can't locate module in @INC when executing script over SSH

by Leudwinus (Scribe)
on Jan 27, 2023 at 18:55 UTC ( [id://11149950]=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/env perl
    
    use lib "/home/user/perl5/lib";
    use JSON; # line 4
    print JSON->new->pretty->encode( { qw( a b ) } );
    
  2. or download this
    leudwinus@localmachine:~$ ssh user@remotemachine './json_test'
    Can't locate JSON.pm in @INC (you may need to install the JSON module)
    + (@INC contains: /home/user/perl5/lib /usr/local/lib/perl5/site_perl/
    +mach/5.32 
    /usr/local/lib/perl5/site_perl /usr/local/lib/perl5/5.32/mach /usr/loc
    +al/lib/perl5/5.32) at ./json_test line 4.
    BEGIN failed--compilation aborted at ./json_test line 4.
    
  3. or download this
    user@remotemachine:~$ perldoc -l JSON
    /home/user/perl5/lib/perl5/JSON.pm
    
    ...
        /usr/local/lib/perl5/site_perl
        /usr/local/lib/perl5/5.32/mach
        /usr/local/lib/perl5/5.32
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://11149950]
Front-paged by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (3)
As of 2024-04-19 01:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found