Instalando o oracle instantclient no ubuntu 14.04

4

Estou tentando instalar o oracle instantclient para poder usar a extensão php5_oci8, mas quando tento converter os arquivos fornecidos pelo rpm para .deb com o comando alien , recebo os seguintes erros:

vagrant@sherwood:/vagrant/src/packages/oracle-instantclient$ sudo alien -i oracle-instantclient12.1-basic-12.1.0.2.0-1.x86_64.rpm
Package build failed. Here's the log:
dh_testdir
dh_testdir
dh_testroot
dh_prep
dh_installdirs
dh_installdocs
dh_installchangelogs
find . -maxdepth 1 -mindepth 1 -not -name debian -print0 | \
                xargs -0 -r -i cp -a {} debian/oracle-instantclient12.1-basic
dh_compress
dh_makeshlibs
dh_installdeb
dh_shlibdeps
dpkg-shlibdeps: error: couldn't find library libclntsh.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libociei.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntshcore.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libociei.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntsh.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocijdbc12.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntshcore.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocijdbc12.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libmql1.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocijdbc12.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libipc1.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocijdbc12.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libnnz12.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocijdbc12.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntsh.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/genezi (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntshcore.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/genezi (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocci.so.12.1 contains an unresolvable reference to symbol slnxsub: it's probably a plugin
dpkg-shlibdeps: warning: 262 other similar warnings have been skipped (use -v to see them all)
dpkg-shlibdeps: warning: couldn't find library libipc1.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libmql1.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libmql1.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntsh.so.12.1 (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libipc1.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntsh.so.12.1 (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libnnz12.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntsh.so.12.1 (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libons.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntsh.so.12.1 (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntshcore.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntsh.so.12.1 (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntshcore.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libnnz12.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntsh.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/adrci (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntshcore.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/adrci (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libmql1.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/adrci (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libipc1.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/adrci (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: couldn't find library libnnz12.so needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/adrci (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntsh.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/liboramysql12.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: error: couldn't find library libclntshcore.so.12.1 needed by debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/liboramysql12.so (ELF format: 'elf64-x86-64'; RPATH: '')
dpkg-shlibdeps: warning: package could avoid a useless dependency if debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libociei.so debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocijdbc12.so debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/genezi debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntshcore.so.12.1 debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntsh.so.12.1 debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/adrci debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/liboramysql12.so were not linked against libnsl.so.1 (they use none of the library's symbols)
dpkg-shlibdeps: error: cannot continue due to the errors listed above
Note: libraries are not searched in other binary packages that do not have any shlibs or symbols file.
To help dpkg-shlibdeps find private libraries, you might need to use -l.
dh_shlibdeps: dpkg-shlibdeps -Tdebian/oracle-instantclient12.1-basic.substvars debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/adrci debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/bin/genezi debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntsh.so.12.1 debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libclntshcore.so.12.1 debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libipc1.so debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libmql1.so debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libnnz12.so debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocci.so.12.1 debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libociei.so debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libocijdbc12.so debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/libons.so debian/oracle-instantclient12.1-basic/usr/lib/oracle/12.1/client64/lib/liboramysql12.so returned exit code 2
make: [binary-arch] Error 2 (ignored)
dh_gencontrol
dpkg-gencontrol: warning: Depends field of package oracle-instantclient12.1-basic: unknown substitution variable ${shlibs:Depends}
dh_md5sums
dh_builddeb
dpkg-deb: error: control directory has bad permissions 777 (must be >=0755 and <=0775)
dh_builddeb: dpkg-deb --build debian/oracle-instantclient12.1-basic .. returned exit code 2
make: *** [binary-arch] Error 1

Eu encontrei este erro em nenhum lugar, alguém pode me indicar a direção correta?

    
por kitensei 09.07.2015 / 15:47

2 respostas

4

Este é provavelmente um problema do Vagrant / Windows, que você está encontrando ao tentar instalar os arquivos RPM de uma pasta de fragmentação.

Copie os RPMs para um diretório / oracle (ou qualquer outro) que não esteja em seus diretórios compartilhados, e o erro deve desaparecer.

    
por Mike 24.07.2015 / 22:06
0

o problema é que você não instalou pacotes necessários para o oracle em seu sistema. Eu recomendaria usar o instalador universal da oracle, que aponta para os pacotes necessários quando você tenta instalá-lo.

normalmente este problema pode ser facilmente corrigido executando o pacote “oracle-rdbms-server-11gR2-preinstall” oferecido pelo repositório “Oracle Public Yum”. Infelizmente, não temos esse repositório para o Ubuntu, e os pacotes de outros sistemas não funcionam bem.

se, por alguma razão, você não puder usar o OUI, então você pode fazer isso de maneira longa instalando com o apt-get todos os pacotes no seu log que não foram encontrados.

    
por alexey pervyshin 11.07.2015 / 22:25