2
votes

I need to work on a Perl script that has some tasks, like reading/writing Excel sheets, connection to an Oracle database, etc.

First I used ActivePerl. On installing modules, ActivePerl threw an error:

Authorization required 401

(I.e., it requires a business licence for adding modules.)

Then I tried the same with Strawberry Perl, but I still could not install.

What I have tried:

  1. CPAN
  2. ppm
  3. Download a module and install using it nmake
  4. Install modules using the Padre Perl IDE.

Is this a license issue? Or am I missing something here? Is Perl a free distribution for development?

The image shows installing DBD::Oracle on Strawberry Perl v5.22.0:

Enter image description here

3
I've installed modules without problems on both ActiveState Perl and Strawberry Perl. I don't know if there even is a business license for ActiveState Perl (there definitely isn't one for Strawberry). That sounds more like a proxy problem or something.melpomene
What happens when you try to install modules in strawberry with cpan?ysth
That error means you're not connecting to CPAN. Check your proxy settingsSobrique
It means that for some reason - you're host is not able to directly reach the internet. The most common reason for this is that you're going through a proxy server to reach it from a corporate/campus network. Look in your browser settings and you should see something that tells you what they are. Then set this via o conf http_proxy in your CPAN shell.Sobrique
@melpomene, AS only provides AS-built packages for free to the two most recent versions of Perl. Doesn't stop you from using ppm to install packages built by anyone else, or from using cpan. But yeah, the problem he's now experiencing is a lack of access to the internet.ikegami

3 Answers

2
votes

It looks like you are using Strawberry Perl. That requires no license or other special steps to use. It's ready to go.

One of the top lines of output in your picture is "Can't connect to cpan.strawberryperl.com:80". It then tries to connect to other sites and has the same failure. It looks like a network issue.

1
votes

The community edition of ActivePerl provides support to only the latest versions of Perl, and access to the packages ActiveState built for older versions is available in Business and Enterprise edition.

If you install Perl 5.18.4, 5.20.2 or 5.22.0 then you'll not get a 401 error.

Alternate solution: Use CPAN instead of ppm to install Perl modules.

See more at: Download and Install Perl: ActivePerl

1
votes

ActiveState is a commercial company. They release a community edition, but they make money from support. Part of that means they only offer "free" the newest versions. Which is why you get the error you do - upgrade to a newer Perl, and they'll let you update.

More broadly - technically each module can be licensed separately. There's no requirement to release Perl code (including modules) under any sort of FLOSS license.

However, bear in mind that the ActiveState community edition isn't the same license as CPAN modules would be. CPAN modules are "Mostly GNU". But ActiveState CE has some additional terms.

For example,

The use of the Software is unsupported and is for non-commercial or non-production use.

You should make a point of reviewing licenses, because it really is a bit of a minefield if you're not careful.