Error: Package: postgresq (pgdg15)

oracle-error

Tabla de contenido

Problema

Al momento de ejecutar el comando yum install -y postgresql15-server, para la instalación de postgres, se produce el error:

Error: Package: postgresql15-15.8-1PGDG.rhel7.x86_64 (pgdg15)
           Requires: libzstd >= 1.4.0
Error: Package: postgresql15-server-15.8-1PGDG.rhel7.x86_64 (pgdg15)
           Requires: libzstd.so.1()(64bit)
Error: Package: postgresql15-15.8-1PGDG.rhel7.x86_64 (pgdg15)
           Requires: libzstd.so.1()(64bit)
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

Solucion Error

Esto se debe a que no tenemos instalado el paquete libzstd, el cual se debe instalar antes de poder instalar postgres, ya que es un requisito

[root@soyundba ~]# yum install libzstd
Loaded plugins: fastestmirror, langpacks
libzstd-1.5.1-2.el9.i686.rpm                                                                                                                     | 334 kB  00:00:00
Examining /var/tmp/yum-root-PSBg9R/libzstd-1.5.1-2.el9.i686.rpm: libzstd-1.5.1-2.el9.i686
Marking /var/tmp/yum-root-PSBg9R/libzstd-1.5.1-2.el9.i686.rpm to be installed
Resolving Dependencies
--> Running transaction check
---> Package libzstd.i686 0:1.5.1-2.el9 will be installed
--> Processing Dependency: libc.so.6 for package: libzstd-1.5.1-2.el9.i686
Loading mirror speeds from cached hostfile
--> Processing Dependency: libc.so.6(GLIBC_2.0) for package: libzstd-1.5.1-2.el9.i686
--> Processing Dependency: libc.so.6(GLIBC_2.1.3) for package: libzstd-1.5.1-2.el9.i686
--> Processing Dependency: libc.so.6(GLIBC_2.3.2) for package: libzstd-1.5.1-2.el9.i686
--> Processing Dependency: libc.so.6(GLIBC_2.3.4) for package: libzstd-1.5.1-2.el9.i686
--> Processing Dependency: libc.so.6(GLIBC_2.34) for package: libzstd-1.5.1-2.el9.i686
--> Processing Dependency: libc.so.6(GLIBC_2.4) for package: libzstd-1.5.1-2.el9.i686
--> Running transaction check
---> Package glibc.i686 0:2.17-326.el7_9.3 will be installed
--> Processing Dependency: libfreebl3.so(NSSRAWHASH_3.12.3) for package: glibc-2.17-326.el7_9.3.i686
--> Processing Dependency: libfreebl3.so for package: glibc-2.17-326.el7_9.3.i686
---> Package libzstd.i686 0:1.5.1-2.el9 will be installed
--> Processing Dependency: libc.so.6(GLIBC_2.34) for package: libzstd-1.5.1-2.el9.i686
--> Running transaction check
---> Package libzstd.i686 0:1.5.1-2.el9 will be installed
--> Processing Dependency: libc.so.6(GLIBC_2.34) for package: libzstd-1.5.1-2.el9.i686
---> Package nss-softokn-freebl.i686 0:3.90.0-6.el7_9 will be installed
--> Finished Dependency Resolution
Error: Package: libzstd-1.5.1-2.el9.i686 (/libzstd-1.5.1-2.el9.i686)
           Requires: libc.so.6(GLIBC_2.34)
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest
[root@soyundba ~]#

Sin embargo, al momento de intentar instalar el paquete, se requieren dependencias para este paquete tambien, las cuales salen con el error:

Error: Package: libzstd-1.5.1-2.el9.i686 (/libzstd-1.5.1-2.el9.i686)
           Requires: libc.so.6(GLIBC_2.34)
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

Por lo cual, primero ejecutaremos esas dependencias

[root@soyundba ~]# yum install epel-release
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
Resolving Dependencies
--> Running transaction check
---> Package epel-release.noarch 0:7-11 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================================================================================
 Package                                      Arch                                   Version                               Repository                              Size
========================================================================================================================================================================
Installing:
 epel-release                                 noarch                                 7-11                                  extras                                  15 k

Transaction Summary
========================================================================================================================================================================
Install  1 Package

Total download size: 15 k
Installed size: 24 k
Is this ok [y/d/N]: y
Downloading packages:
epel-release-7-11.noarch.rpm                                                                                                                     |  15 kB  00:00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : epel-release-7-11.noarch                                                                                                                             1/1
  Verifying  : epel-release-7-11.noarch                                                                                                                             1/1

Installed:
  epel-release.noarch 0:7-11

Complete!
[root@soyundba ~]#

La dependencia epel-release, ejecutó de manera exitosa, por lo cual, ya podemos proceder con la dinstalaciónel paquete libzstd

[root@soyundba ~]# yum install libzstd
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
epel/x86_64/metalink                                                                                                                             | 5.1 kB  00:00:00
 * epel: d2lzkl7pfhq30w.cloudfront.net
epel                                                                                                                                             | 4.3 kB  00:00:00
(1/3): epel/x86_64/group                                                                                                                         | 399 kB  00:00:00
(2/3): epel/x86_64/updateinfo                                                                                                                    | 1.0 MB  00:00:01
(3/3): epel/x86_64/primary_db                                                                                                                    | 8.7 MB  00:00:03
Resolving Dependencies
--> Running transaction check
---> Package libzstd.x86_64 0:1.5.5-1.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================================================================================
 Package                                 Arch                                   Version                                      Repository                            Size
========================================================================================================================================================================
Installing:
 libzstd                                 x86_64                                 1.5.5-1.el7                                  epel                                 292 k

Transaction Summary
========================================================================================================================================================================
Install  1 Package

Total download size: 292 k
Installed size: 775 k
Is this ok [y/d/N]: y
Downloading packages:
warning: /var/cache/yum/x86_64/7/epel/packages/libzstd-1.5.5-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID 352c64e5: NOKEY ]  0.0 B/s | 225 kB  --:--:-- ETA
Public key for libzstd-1.5.5-1.el7.x86_64.rpm is not installed
libzstd-1.5.5-1.el7.x86_64.rpm                                                                                                                   | 292 kB  00:00:00
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
Importing GPG key 0x352C64E5:
 Userid     : "Fedora EPEL (7) <epel@fedoraproject.org>"
 Fingerprint: 91e9 7d7c 4a5e 96f1 7f3e 888f 6a2f aea2 352c 64e5
 Package    : epel-release-7-11.noarch (@extras)
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
Is this ok [y/N]: y
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : libzstd-1.5.5-1.el7.x86_64                                                                                                                           1/1
  Verifying  : libzstd-1.5.5-1.el7.x86_64                                                                                                                           1/1

Installed:
  libzstd.x86_64 0:1.5.5-1.el7

Complete!
[root@soyundba ~]#

Ahora si, podemos proseguir con la instalación de postgres

[root@soyundba ~]# yum install -y postgresql15-server
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
 * epel: d2lzkl7pfhq30w.cloudfront.net
Resolving Dependencies
--> Running transaction check
---> Package postgresql15-server.x86_64 0:15.8-1PGDG.rhel7 will be installed
--> Processing Dependency: postgresql15-libs(x86-64) = 15.8-1PGDG.rhel7 for package: postgresql15-server-15.8-1PGDG.rhel7.x86_64
--> Processing Dependency: postgresql15(x86-64) = 15.8-1PGDG.rhel7 for package: postgresql15-server-15.8-1PGDG.rhel7.x86_64
--> Processing Dependency: libpq.so.5()(64bit) for package: postgresql15-server-15.8-1PGDG.rhel7.x86_64
--> Running transaction check
---> Package postgresql15.x86_64 0:15.8-1PGDG.rhel7 will be installed
---> Package postgresql15-libs.x86_64 0:15.8-1PGDG.rhel7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================================================================================
 Package                                        Arch                              Version                                       Repository                         Size
========================================================================================================================================================================
Installing:
 postgresql15-server                            x86_64                            15.8-1PGDG.rhel7                              pgdg15                            5.8 M
Installing for dependencies:
 postgresql15                                   x86_64                            15.8-1PGDG.rhel7                              pgdg15                            1.6 M
 postgresql15-libs                              x86_64                            15.8-1PGDG.rhel7                              pgdg15                            287 k

Transaction Summary
========================================================================================================================================================================
Install  1 Package (+2 Dependent packages)

Total download size: 7.7 M
Installed size: 34 M
Downloading packages:
warning: /var/cache/yum/x86_64/7/pgdg15/packages/postgresql15-libs-15.8-1PGDG.rhel7.x86_64.rpm: Header V4 RSA/SHA1 Signature, key ID 73e3b907: NOKEY  0 B  --:--:-- ETA
Public key for postgresql15-libs-15.8-1PGDG.rhel7.x86_64.rpm is not installed
(1/3): postgresql15-libs-15.8-1PGDG.rhel7.x86_64.rpm                                                                                             | 287 kB  00:00:00
(2/3): postgresql15-15.8-1PGDG.rhel7.x86_64.rpm                                                                                                  | 1.6 MB  00:00:01
(3/3): postgresql15-server-15.8-1PGDG.rhel7.x86_64.rpm                                                                                           | 5.8 MB  00:00:02
------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                                   2.2 MB/s | 7.7 MB  00:00:03
Retrieving key from file:///etc/pki/rpm-gpg/PGDG-RPM-GPG-KEY-RHEL7
Importing GPG key 0x73E3B907:
 Userid     : "PostgreSQL RPM Repository <pgsql-pkg-yum@lists.postgresql.org>"
 Fingerprint: f245 f0bf 96ac 1827 44ca ff2e 64fa ce11 73e3 b907
 Package    : pgdg-redhat-repo-42.0-38PGDG.noarch (@/pgdg-redhat-repo-latest.noarch)
 From       : /etc/pki/rpm-gpg/PGDG-RPM-GPG-KEY-RHEL7
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : postgresql15-libs-15.8-1PGDG.rhel7.x86_64                                                                                                            1/3
  Installing : postgresql15-15.8-1PGDG.rhel7.x86_64                                                                                                                 2/3
  Installing : postgresql15-server-15.8-1PGDG.rhel7.x86_64                                                                                                          3/3
  Verifying  : postgresql15-server-15.8-1PGDG.rhel7.x86_64                                                                                                          1/3
  Verifying  : postgresql15-libs-15.8-1PGDG.rhel7.x86_64                                                                                                            2/3
  Verifying  : postgresql15-15.8-1PGDG.rhel7.x86_64                                                                                                                 3/3

Installed:
  postgresql15-server.x86_64 0:15.8-1PGDG.rhel7

Dependency Installed:
  postgresql15.x86_64 0:15.8-1PGDG.rhel7                                           postgresql15-libs.x86_64 0:15.8-1PGDG.rhel7

Complete!
[root@soyundba ~]#

De esta manera, ya podemos continuar con los otros comandos que solicita la instalación

[root@soyundba ~]# /usr/pgsql-15/bin/postgresql-15-setup initdb
Initializing database ... OK

[root@soyundba ~]#
[root@soyundba ~]# systemctl enable postgresql-15
Created symlink from /etc/systemd/system/multi-user.target.wants/postgresql-15.service to /usr/lib/systemd/system/postgresql-15.service.
[root@soyundba ~]#
[root@soyundba ~]# systemctl start postgresql-15

Podemos ya realizar conexion a la base de datos, evidenciando que es exitosa.

[root@soyundba ~]# su - postgres
-bash-4.2$ psql
psql (15.8)
Type "help" for help.

postgres=# \l
                                                 List of databases
   Name    |  Owner   | Encoding |   Collate   |    Ctype    | ICU Locale | Locale Provider |   Access privileges
-----------+----------+----------+-------------+-------------+------------+-----------------+-----------------------
 postgres  | postgres | UTF8     | en_US.UTF-8 | en_US.UTF-8 |            | libc            |
 template0 | postgres | UTF8     | en_US.UTF-8 | en_US.UTF-8 |            | libc            | =c/postgres          +
           |          |          |             |             |            |                 | postgres=CTc/postgres
 template1 | postgres | UTF8     | en_US.UTF-8 | en_US.UTF-8 |            | libc            | =c/postgres          +
           |          |          |             |             |            |                 | postgres=CTc/postgres
(3 rows)

postgres=#

Te invito a seguir consultando más errores relacionados a Postgres dando clic aquí.

 

Acerca de JulianOrtiz0506

Soy administrador de bases de datos y desarrollador web, desde mis inicios en el mundo de la informática, he implementando proyectos personales y empresariales. Por consiguiente esto me ha permitido contar con una amplia calificación y destreza sobre mis áreas de conocimiento. Sobre todo suelo estar en constante aprendizaje, diariamente me estoy informando sobre nuevas tecnologías. Ya queme gusta estar actualizado en la tecnología de punta para todas las plataformas que me apasionan y con las cuales trabajo día a día.

Ver todas las entradas de JulianOrtiz0506 →

Deja una respuesta

Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *