Ok

En poursuivant votre navigation sur ce site, vous acceptez l'utilisation de cookies. Ces derniers assurent le bon fonctionnement de nos services. En savoir plus.

  • Ora2PG script creation project

    #!/bin/sh
    #-------------------------------------------------------------------------------
    #
    # Script to create an ora2pg project
    # Author : JJY
    #
    #-------------------------------------------------------------------------------
    #set -vx
    clear
    echo " "
    echo " Welcome in the program to create a migration project. "
    echo " "
    echo " Write the working environment (dev/qa/prd) :"
    echo " "
    read env
    echo " "
    echo " Write the name of your asset :"
    echo " "
    read base
    echo " "
    mkdir -p $ORA2PG_HOME/$env
    ora2pg --project_base $ORA2PG_HOME/$env --init_project $base -c $ORA2PG_CONF
    #cp $ORA2PG_HOME/config/commonstruct.conf $ORA2PG_HOME/$env/$base/config/metadata_ora2pg.conf
    #cp $ORA2PG_HOME/config/commondata.conf $ORA2PG_HOME/$env/$base/config/data_ora2pg.conf
    echo " "
    echo " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
    echo " Working environment created for $base: $ORA2PG_HOME/$env/$base"
    echo " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
    echo " "
    echo " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
    echo " The file  $ORA2PG_HOME/$env/$base/config/metadata_ora2pg.conf         "
    echo " and  $ORA2PG_HOME/$env/$base/config/data_ora2pg.conf have to be fixed."
    echo " !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"

    exit 0

  • [PostgreSQL] Ora2pg Install

    yum install oracle-instantclient12.2-basic-12.2.0.1.0-1.x86_64.rpm
    yum install oracle-instantclient12.2-devel-12.2.0.1.0-1.x86_64.rpm
    yum install oracle-instantclient12.2-jdbc-12.2.0.1.0-1.x86_64.rpm
    yum install oracle-instantclient12.2-sqlplus-12.2.0.1.0-1.x86_64.rpm
    yum -y install perl-DBI
    yum install gcc
    yum install glibc-devel
    yum install perl-ExtUtils-MakeMaker -y
    yum install perl-open.noarch -y


    export ORACLE_HOME=/usr/lib/oracle/12.2/client64
    export LD_LIBRARY_PATH=/usr/lib/oracle/12.2/client64/lib

    tar -xvzf ora2pg-23.0.tar.gz
    cd ora2pg-23.0/
    perl Makefile.PL
    make && make install

    tar -xvzf DBD-Oracle-1.83.tar.gz
    cd DBD-Oracle-1.83
    perl Makefile.PL
    make && make install