Installing Bahmni 0.92 Failed on postgres installation

While installing Bahmni 0.92 on my new CentOS 7 server. It fails on the TASK [postgres : Download postgres yum repo rpm if not present]. It says that it failed because the rpm file no longer exist. Please fix ASAP. Here is the Screenshot

1 Like

Last 5-6 days it is not working. Any luck @angshuonline

Yep I already fixed it. I changed the download repository on /opt/bahmni-installer/bahmni-playbooks/group_vars/local. The error is due to the default download repository is no longer available.

postgres_repo_rpm_name: pgdg-centos96-9.6-3.noarch.rpm postgres_repo_download_url: https://download.postgresql.org/pub/repos/yum/9.6/redhat/rhel-7-x86_64/{{postgres_repo_rpm_name}}

  1. Change the repo rpm name to this: postgres_repo_rpm_name: pgdg-redhat-repo-latest.noarch.rpm

  2. Change the repo download url to this: postgres_repo_download_url: https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/

2 Likes

Hi, I got similar error . Please, do you mean you edit this: /opt/bahmni-installer/bahmni-playbooks/group_vars/local. After jnstallation of the following:

  1. #Prerequisite for the fresh installation of Bahmni` yum install-y https: //kojipkgs.fedoraproject.org//packages/zlib/12.11/19.fc30/x86_64/zlib-1.2.11-19.fc30.x86_64.rpm 2.install Bahmni installer
  2. Kindly make it clear . Thanks

First attempt of installing it, I got the error. But after some research I found out that the default repository indicated in /opt/bahmni-installer/bahmni-playbooks/group_vars/local, is no longer available. You just have to open the file “local” in /opt/bahmni-installer/bahmni-playbooks/group_vars and edit the value of these:

  1. postgres_repo_rpm_name:
  2. postgres_repo_download_url:

the value in default of that is no longer available so you have to change it to this:

  1. postgres_repo_rpm_name: pgdg-redhat-repo-latest.noarch.rpm
  2. postgres_repo_download_url: https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/

After making the changes I rerun the installation and postgresql successfully installed.

3 Likes

Great suggestion! Thanks Aldrin. I will give it a try as commented.

@aldrin19 May be you have solved this issue too Error while installing Bahmni 0.92 - Start Odoo and enable at boot error How you have solved this, after the current problem. I am facing now it

To avoid posgres installtion error i have keep pgdg-centos96-9.6-3.noarch.rpm into /opt folder from my another system(running bahmni ) but still having bellow problem .

I don’t know. Also, I still keep getting that error myself, but I still don’t how to fix it yet. Let me know if you fixed it. Thanks.

1 Like

Anyone out there know how to fix Odoo error on installation? @angshuonline? can you help us?

I am also facing the same types of problem

During installetion I got an error showing

“rpm” (https://download.postgresql.org/pub/repos/yum/9.6/redhat/rhel-7-x86_64/pgdg-centos96-9.6-3.noarch.rpm) not found for PostgreSQL. PostgreSQL may be removed that rpm from the list of rpm.

To overcome this problem, I put the rpm file to opt folder manually taking from an existing system. And run installation command.

But I got another error

Can anyone help me please to install it properly?

@moyeen Please follow Bahmni 0.92 Install on CentOS 7.6 Minimal Fails Steps for odoo boot issue. I solved my error using that steps.

Downgrade systemd and use yum version lock

Hello Team, kindly help here as the Bahmni installation hangs up on Task install postgresql yum repository. Am installing Bahmni 0.92 on centos 7.6 minimal installation,using the latest postgresql these are files i did replace

  1. postgres_repo_rpm_name:
  2. postgres_repo_download_url:

the value in default of that is no longer available so you have to change it to this:

  1. postgres_repo_rpm_name: pgdg-redhat-repo-latest.noarch.rpm
  2. postgres_repo_download_url: https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/ Thanks

hello Bahmni team, this the atachment where i get stuck any one to help here backup openelis error.txt (3.0 KB)

I followed this but I got this error, does anyone faced this error or have any idea how to solve this issue?

@akshaybirajdar I too faced the same error, but it got resolved when I uninstalled the Postgres rpm(pgdg-redhat-repo-latest.noarch.rpm) available at /opt/ and reinstalled it from command

cd /opt/

wget https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm

yum install pgdg-redhat-repo-latest.noarch.rpm

After this run the bahmni install command and it will fail at this step

Follow this link for the solution.

Thanks @ritesh,

We are facing the same issue and have tried the above solution; we did get a different error:

“Failure talking to yum: failure: repodata/repomd.xml from pgdg-common: [Errno 256] No more mirrors to try.\nhttps://download.postgresql.org/pub/repos/yum/common/redhat/rhel-7-x86_64/repodata/repomd.xml: [Errno -1] repomd.xml signature could not be verified for pgdg-common”

The error is happening on the task [bahmni-base : install utils]. Do you know how to address this issue?

@akshaybirajdar did you experience the issue below, or know how to resolve it?

TASK [bahmni-base : install utils] **************************************************************************************************************************************************************
task path: /opt/bahmni-installer/bahmni-playbooks/roles/bahmni-base/tasks/main.yml:47
failed: [localhost] (item=[u'tree', u'htop', u'lsof', u'wget', u'unzip', u'python-pip', u'rsync']) => {"changed": false, "failed": true, "item": ["tree", "htop", "lsof", "wget", "unzip", "python-pip", "rsync"], "msg": "Failure talking to yum: failure: repodata/repomd.xml from pgdg-common: [Errno 256] No more mirrors to try.\nhttps://download.postgresql.org/pub/repos/yum/common/redhat/rhel-7-x86_64/repodata/repomd.xml: [Errno -1] repomd.xml signature could not be verified for pgdg-common"}
	to retry, use: --limit @/opt/bahmni-installer/bahmni-playbooks/all.retry

PLAY RECAP **************************************************************************************************************************************************************************************
localhost                  : ok=15   changed=2    unreachable=0    failed=1   

In /etc/yum.repos.d/pgdg-redhat-all.repo try disabling GPG signature-checking by setting gpgcheck to 0 (gpgcheck=0) and see if the install passes that step.

Thanks @rubailly for the feedback.

@ritesh @akshaybirajdar I have eventually successfully installed bahmni, by slightly modifying the official installation process (see “Installing Bahmni version 0.92 (Recommended)” https://bahmni.atlassian.net/wiki/spaces/BAH/pages/33128505/Install+Bahmni+on+CentOS):

- I updated the values on the 2 keys below in the file /opt/bahmni-installer/bahmni-playbooks/group_vars/local 
	○ postgres_repo_rpm_name: pgdg-redhat-repo-latest.noarch.rpm
	○ postgres_repo_download_url: https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/{{postgres_repo_rpm_name}}

The installation failed with the error below:

This issue was resolved by installing postgresql-libs and then restarting the installation:

sudo yum install postgresql-libs
bahmni -aru http://repo.mybahmni.org/releases/ansible-2.4.6.0-1.el7.ans.noarch.rpm install

Notes:

  • with the above approach, I didn’t need to manually remove and install the package “pgdg-redhat-repo-latest.noarch.rpm”.
  • I have also tried installing “postgresql-libs” before starting the bahmni installation (to avoid the above error), but that didn’t work. I am not sure why this is the case, but the approach that worked was to first start bahmni installation which will fail, then install “postgresql-libs” and finally restart bahmni installation which succeeds on the second try
5 Likes

I did all the things @aldrin19 said . But it is not working TASK [postgres : Install postgresql yum repository] **************************** task path: /opt/bahmni-installer/bahmni-playbooks/roles/postgres/tasks/main.yml: 9 An exception occurred during task execution. To see the full traceback, use -vvv . The error was: _rpm.error: error reading package header fatal: [localhost]: FAILED! => {“changed”: false, “module_stderr”: “Traceback (m ost recent call last):\n File “/tmp/ansible_xWLNYI/ansible_module_yum.py”, li ne 1345, in \n main()\n File “/tmp/ansible_xWLNYI/ansible_module_yu m.py”, line 1336, in main\n skip_broken, security, params[‘installroot’], al low_downgrade)\n File “/tmp/ansible_xWLNYI/ansible_module_yum.py”, line 1228, in ensure\n res = install(module, pkgs, repoq, yum_basecmd, conf_file, en_re pos, dis_repos, installroot=installroot, allow_downgrade=allow_downgrade)\n Fil e “/tmp/ansible_xWLNYI/ansible_module_yum.py”, line 743, in install\n envra = local_envra(module, package)\n File “/tmp/ansible_xWLNYI/ansible_module_yum .py”, line 609, in local_envra\n header = ts.hdrFromFdno(fd)\n File “/usr/ lib64/python2.7/site-packages/rpm/transaction.py”, line 170, in hdrFromFdno\n raise rpm.error(“error reading package header”)\n_rpm.error: error reading p ackage header\n”, “module_stdout”: “”, “msg”: “MODULE FAILURE”, “rc”: 0} to retry, use: --limit @/opt/bahmni-installer/bahmni-playbooks/all.retry

PLAY RECAP ********************************************************************* localhost : ok=158 changed=57 unreachable=0 failed=1