Обсуждение: Can't locate Ora2Pg.pm while executing export_schema.sh
Hello Team,
I am getting below error while executing export_schema.sh. Any suggestion/help is really appreciated.
BEGIN failed--compilation aborted at /c/Strawberry/perl/site/bin/ora2pg line 27.
Can't locate Ora2Pg.pm in @INC (you may need to install the Ora2Pg module) (@INC contains: /usr/lib/perl5/site_perl /usr/share/perl5/site_perl /usr/lib/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib/perl5/core_perl /usr/share/perl5/core_perl) at /c/Strawberry/perl/site/bin/ora2pg line 27.
BEGIN failed--compilation aborted at /c/Strawberry/perl/site/bin/ora2pg line 27.
If we don’t want to use this script, should we execute ora2pg directly to migrate the database from Oracle to Postgres?
- Ora2pg -c ora2pg.conf
Let me know your views.
Jiten Pansara
Senior Database Analyst
T: +91 9158149600
E: jiten.pansara@fisglobal.com
FIS | Advancing the way the world Pays, Banks, and Invests
Вложения
You should locate Ora2Pg.pm using "find" like this:
[mgogala@umajor ~]$ find /usr/local -name Ora2Pg.pm
/usr/local/share/perl5/5.32/Ora2Pg.pm
[mgogala@umajor ~]$
and then make sure that your PERL5LIB directory contains the location:
export PERL5LIB=/usr/local/share/perl5/5.32:$PERL5LIB
That should do the trick. On most distributions, /usr/local/share/perl5/<perl version> is already included into PERL5LIB. Are you working on Cygwin? You can do a simple test:
[mgogala@umajor ~]$ perl -e 'use Ora2Pg; print "$Ora2Pg::VERSION\n";'
21.0
@font-face {font-family:Wingdings; panose-1:5 0 0 0 0 0 0 0 0 0;}@font-face {font-family:"Cambria Math"; panose-1:2 4 5 3 5 4 6 3 2 4;}@font-face {font-family:Calibri; panose-1:2 15 5 2 2 2 4 3 2 4;}p.MsoNormal, li.MsoNormal, div.MsoNormal {margin:0in; font-size:11.0pt; font-family:"Calibri",sans-serif;}p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph {mso-style-priority:34; margin-top:0in; margin-right:0in; margin-bottom:0in; margin-left:.5in; font-size:11.0pt; font-family:"Calibri",sans-serif;}span.EmailStyle17 {mso-style-type:personal-compose; font-family:"Calibri",sans-serif; color:windowtext;}.MsoChpDefault {mso-style-type:export-only; font-family:"Calibri",sans-serif;}div.WordSection1 {page:WordSection1;}ol {margin-bottom:0in;}ul {margin-bottom:0in;} The information contained in this message is proprietary and/or confidential. If you are not the intended recipient, please: (i) delete the message and all copies; (ii) do not disclose, distribute or use the message in any manner; and (iii) notify the sender immediately. In addition, please be aware that any message addressed to our domain is subject to archiving and review by persons other than the intended recipient. Thank you.Hello Team,
I am getting below error while executing export_schema.sh. Any suggestion/help is really appreciated.
BEGIN failed--compilation aborted at /c/Strawberry/perl/site/bin/ora2pg line 27.
Can't locate Ora2Pg.pm in @INC (you may need to install the Ora2Pg module) (@INC contains: /usr/lib/perl5/site_perl /usr/share/perl5/site_perl /usr/lib/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib/perl5/core_perl /usr/share/perl5/core_perl) at /c/Strawberry/perl/site/bin/ora2pg line 27.
BEGIN failed--compilation aborted at /c/Strawberry/perl/site/bin/ora2pg line 27.
If we don’t want to use this script, should we execute ora2pg directly to migrate the database from Oracle to Postgres?
- Ora2pg -c ora2pg.conf
Let me know your views.
Jiten Pansara
Senior Database Analyst
T: +91 9158149600
E: jiten.pansara@fisglobal.com
FIS | Advancing the way the world Pays, Banks, and Invests
-- Mladen Gogala Database Consultant Tel: (347) 321-1217 https://dbwhisperer.wordpress.com
Вложения
On Tue, Aug 17, 2021 at 4:34 PM Mladen Gogala <gogala.mladen@gmail.com> wrote: > > You should locate Ora2Pg.pm using "find" like this: > > [mgogala@umajor ~]$ find /usr/local -name Ora2Pg.pm > /usr/local/share/perl5/5.32/Ora2Pg.pm Sounds like he is using strawberry Perl, that means he is on windows. Things could be different there. Luca
On 2021-08-17 10:34:28 -0400, Mladen Gogala wrote: > You should locate Ora2Pg.pm using "find" like this: > > [mgogala@umajor ~]$ find /usr/local -name Ora2Pg.pm > /usr/local/share/perl5/5.32/Ora2Pg.pm > [mgogala@umajor ~]$ > > and then make sure that your PERL5LIB directory contains the location: > > export PERL5LIB=/usr/local/share/perl5/5.32:$PERL5LIB > > That should do the trick. On most distributions, > /usr/local/share/perl5/<perl version> is already included into PERL5LIB. It should be. Normally, if a perl module is not where perl can find it that's a pretty good indication that either the module wasn't installed properly in the first place or that something changed which makes a reinstall highly advisable (e.g. a perl upgrade). hp -- _ | Peter J. Holzer | Story must make more sense than reality. |_|_) | | | | | hjp@hjp.at | -- Charles Stross, "Creative writing __/ | http://www.hjp.at/ | challenge!"