I have written a perl script to get some info form LMS and store it into a file. Now I want to SFTP this file onto a network share. I want to implement this in Perl as well but on my solaris box (having the solaris perl installed) I cannot find an according module. When I try to install 'Net-SFTP-Foreign' I have problems because I have the wrong compiler. Now I want to know if it is save to add this module to the CiscoWorks Perl version. Or will I run into problems?
Any other suggestion on how to realize this is pretty welcome!
Do not add any modules to CiscoWorks' Perl as this could mess up upgrades. As an alternative to installing modules, just keep your modules in a local directory, and use perl -I to find them. For example:
perl -I/export/home/marcus/lib/perl script.pl
Expect is another way to go. With expect, you could easily just wrap the box's sftp executable. Of course, this will mean writing some TCL code.
Ok, when I want to keep the module in a local dir can I use CiscoWorks' version of Perl to install the modules?
When I use the 'standard' version of my solaris box (/usr/bin/perl) I have got the following 2 problems:
1) prerequisite failed
2) when I want to install the missing module it cannot be compiled (thats the main problem..)
but I think it should work if I would use CiscoWorks' Perl. But what is the correct command to install the modules with /opt/CSCOpx/bin/perl in a local directory (like /usr/perl5/myCPAN) without running into prolblems with LMS
##### this is an excerpt of what I get when trying to install the modules
bash-2.05# perl Makefile.PL
Checking if your kit is complete...
Warning: prerequisite Scalar::Util failed to load: Can't locate Scalar/Util.pm in @INC (@INC contains: /usr/perl5/5.6.1/lib/sun4-solaris-64int /usr/perl5/5.6.1/lib /usr/perl5/site_perl/5.6.1/sun4-solaris-64int /usr/perl5/site_perl/5.6.1 /usr/perl5/site_perl /usr/perl5/vendor_perl/5.6.1/sun4-solaris-64int /usr/perl5/vendor_perl/5.6.1 /usr/perl5/vendor_perl .) at (eval 4) line 3.
Warning: prerequisite Test::More failed to load: Can't locate Test/More.pm in @INC (@INC contains: /usr/perl5/5.6.1/lib/sun4-solaris-64int /usr/perl5/5.6.1/lib /usr/perl5/site_perl/5.6.1/sun4-solaris-64int /usr/perl5/site_perl/5.6.1 /usr/perl5/site_perl /usr/perl5/vendor_perl/5.6.1/sun4-solaris-64int /usr/perl5/vendor_perl/5.6.1 /usr/perl5/vendor_perl .) at (eval 5) line 3.
No, this problem indicates you don't have a compiler installed. You need to install the Sun Forte compiler if you want to use Sun's cc.
If you just want to compile stuff, I recommend checking out Blastwave (http://www.blastwave.org). This site makes third-party package management a breeze for Solaris. Here you can find the GNU C compiler, which will allow you to build native Perl modules.
Once you get a good compiler on your server, you can build your Perl modules by specifying an alternate installation prefix:
Then when you install the module, it will go where you want it to go. Note: you should do the installation as a non-root user so that modules that are not PREFIX-safe don't corrupt your CiscoWorks installation.
Oh, it's not me who want to use cc, - it's 'make' who want to use it... (I just want to add a module to my installed version of Perl..;-) )
As I have previously installed a mdoule (libnet-1.19 to get Net::FTP) without a problem I thought I should have all I need- but from what you say (if I understand correct) not every perl module needs a C compiler to get installed.
And now I am at the point that I want to install a perl module that needs a C compiler. And - is that correct? - my 'Sun' Perl wants to use the Forte C compiler (cc) with which my 'Sun' Perl was built. And because I don't have it I will run in that error.
We are pleased to announce availability of Beta software for 16.6.3.
16.6.3 will be the second rebuild on the 16.6 release train targeted
towards Catalyst 9500/9400/9300/3850/3650 switching platforms. We are
looking for early feedback from customers befor...
Introduction Featured Speakers Luis Espejel is the Telecommunications
Manager of IENova, an Oil & Gas company. Currently he works with Cisco
IOS® and Cisco IOS XE platforms, and NX to some extent. He has also
worked as a Senior Engineer with the Routing P...
In this session you can learn more about Layer 3 multicast and the best
practices to identify possible threats and take security measures. It
provides an overview of basic multicast, the best security practices for
use of this technology, and recommendati...