Page 1 of 1

how do I install ansible in centos 7

Posted: 2023/05/24 04:27:35
by Jcenos7
Team,

Question: 1 - How to install ansible in Centos 7.

I am trying to install ansible in centos 7, but unable to, could you please help me with procedure.

Tried this already:
1. yum install epel-release
2. yum install ansible <---- but I am not getting any ansible package.
3. shall I download ansible package directly from site or it require any dependent packages as well ?

So please suggest

Question: 2
Any idea when CentOS 9 will be released or CentOS won't release any new ?


Regards
Jay

Re: how do I install ansible in centos 7

Posted: 2023/05/24 09:17:02
by TrevorH
Apparently you did not install epel-release or the repo is not enabled. EPEL has ansible.

Code: Select all

[root@centos7 ~]# yum list ansible\*
Loaded plugins: priorities
173 packages excluded due to repository priority protections
Available Packages
ansible.noarch                              2.9.27-1.el7                  epel  
ansible-collection-microsoft-sql.noarch     1.1.0-1.el7_9                 extras
ansible-doc.noarch                          2.9.27-1.el7                  epel  
ansible-inventory-grapher.noarch            2.4.4-1.el7                   epel  
ansible-lint.noarch                         3.5.1-1.el7                   epel  
ansible-openstack-modules.noarch            0-20140902git79d751a.el7      epel  
ansible-python3.noarch                      2.9.27-1.el7                  epel  
ansible-review.noarch                       0.13.4-1.el7                  epel  
ansible-test.noarch                         2.9.27-1.el7                  epel 
Any idea when CentOS 9 will be released or CentOS won't release any new ?
Never. Red Hat cancelled CentOS about a year after CentOS 8 was released (it's now dead).

Re: how do I install ansible in centos 7

Posted: 2023/05/24 10:53:51
by Jcenos7
Thank you for your response!, I will check and get back.

Regards
Jay

Re: how do I install ansible in centos 7

Posted: 2023/05/24 11:25:17
by TrevorH
Make sure you have installed the correct epel-release package for CentOS 7. It should be epel-release-7-14.noarch so if yours is epel-release-8 or -9 then it's for a different version of RHEL, not for 7.

We ship the correct package in the CentOS 7 'extras' repo so you should be able to just yum remove the current one and then yum --enablerepo=extras install epel-release

Re: how do I install ansible in centos 7

Posted: 2023/05/25 15:06:34
by jlehtone
An alternative to EPEL is CentOS SIG's repo:

Code: Select all

yum install centos-release-ansible-29
yum install ansible
The package 'centos-release-ansible-29' should be in the 'extras' repo.

Note though that EPEL and SIG pack ansible bit differently, and are thus
mutually exclusive on that aspect.

Re: how do I install ansible in centos 7

Posted: 2023/05/26 04:41:46
by Jcenos7
TrevorH wrote:
2023/05/24 09:17:02
Apparently you did not install epel-release or the repo is not enabled. EPEL has ansible.

Code: Select all

[root@centos7 ~]# yum list ansible\*
Loaded plugins: priorities
173 packages excluded due to repository priority protections
Available Packages
ansible.noarch                              2.9.27-1.el7                  epel  
ansible-collection-microsoft-sql.noarch     1.1.0-1.el7_9                 extras
ansible-doc.noarch                          2.9.27-1.el7                  epel  
ansible-inventory-grapher.noarch            2.4.4-1.el7                   epel  
ansible-lint.noarch                         3.5.1-1.el7                   epel  
ansible-openstack-modules.noarch            0-20140902git79d751a.el7      epel  
ansible-python3.noarch                      2.9.27-1.el7                  epel  
ansible-review.noarch                       0.13.4-1.el7                  epel  
ansible-test.noarch                         2.9.27-1.el7                  epel 
Any idea when CentOS 9 will be released or CentOS won't release any new ?
Never. Red Hat cancelled CentOS about a year after CentOS 8 was released (it's now dead).
Sorry to ask again, no more centos release will come ? and what about centos stream 8 and 9 ?

Re: how do I install ansible in centos 7

Posted: 2023/05/26 05:55:54
by jlehtone
Jcenos7 wrote:
2023/05/26 04:41:46
Sorry to ask again, no more centos release will come ? and what about centos stream 8 and 9 ?
Soon after the Red Hat's announcement about CentOS two new projects did start. They are AlmaLinux and Rocky Linux.
Their mission is: Do what CentOS did (but better).

CentOS 7 is a clone of RHEL 7. Similarly,
AlmaLinux 8 and Rocky Linux 8 are clones of RHEL 8 and
AlmaLinux 9 and Rocky Linux 9 are clones of RHEL 9.

Clones are downstream from RHEL; RHEL releases something and the clones rebuild it for their distros.


RHEL codebase has "main / development" branch. That is where Red Hat adds and tests content for future releases.

At some point, branches "9.0", "9.1", and "9.2" have been created off the RHEL 9 main branch.
Content in those branches was polished and then released as RHEL 9.0, RHEL 9.1, and RHEL 9.2, respectively.
For some time Red Hat backports (security) fixes into these "production" branches.

CentOS Stream 9 has content from the main branch. It is a view to upstream. What visits the Stream
may or may not show up in RHEL. It is alpha/early beta content. Point is, we can see (some of) where RHEL is going.

The need for RHEL 9 main branch (and hence Stream 9) ends when the last "9.x" branch is created. In 2027.
The "9.x" branch (and hence the clones) will be maintained to 2032.

Re: how do I install ansible in centos 7

Posted: 2023/05/26 07:32:12
by Jcenos7
jlehtone wrote:
2023/05/26 05:55:54
Jcenos7 wrote:
2023/05/26 04:41:46
Sorry to ask again, no more centos release will come ? and what about centos stream 8 and 9 ?
Soon after the Red Hat's announcement about CentOS two new projects did start. They are AlmaLinux and Rocky Linux.
Their mission is: Do what CentOS did (but better).

CentOS 7 is a clone of RHEL 7. Similarly,
AlmaLinux 8 and Rocky Linux 8 are clones of RHEL 8 and
AlmaLinux 9 and Rocky Linux 9 are clones of RHEL 9.

Clones are downstream from RHEL; RHEL releases something and the clones rebuild it for their distros.


RHEL codebase has "main / development" branch. That is where Red Hat adds and tests content for future releases.

At some point, branches "9.0", "9.1", and "9.2" have been created off the RHEL 9 main branch.
Content in those branches was polished and then released as RHEL 9.0, RHEL 9.1, and RHEL 9.2, respectively.
For some time Red Hat backports (security) fixes into these "production" branches.

CentOS Stream 9 has content from the main branch. It is a view to upstream. What visits the Stream
may or may not show up in RHEL. It is alpha/early beta content. Point is, we can see (some of) where RHEL is going.

The need for RHEL 9 main branch (and hence Stream 9) ends when the last "9.x" branch is created. In 2027.
The "9.x" branch (and hence the clones) will be maintained to 2032.
Thanks for your time and details!!!