The issue is this commit on 4.0.5:
https://github.com/apache/cassandra/commit/cd0a40d09e5c029e3cac260ecf4cb3dc02deabc7
From:
Requires: jre >= 1.8.0
To:
Requires: (jre-1.8.0 *or* jre-11)
But support for “Boolean Dependencies” was added only in rpm version 4.13,
CentOS 7 with rpm 4.11.3.

This is my workaround to CentOS 7.

For cassandra 4.0.5:
Upgrade rpm/rpm-libs/python2-rpm/rpm-plugin-selinux/rpm-build-libs to
4.13.0.2:
[cass@h00104 ~]# sudo rpm --version
RPM version 4.13.0.2
[cass@h00104 ~]#  sudo rpm -Uvh
https://archive.apache.org/dist/cassandra/redhat/40x/cassandra-4.0.5-1.noarch.rpm
Retrieving
https://archive.apache.org/dist/cassandra/redhat/40x/cassandra-4.0.5-1.noarch.rpm
Preparing...                          #################################
[100%]
Updating / installing...
   1:cassandra-4.0.5-1                #################################
[100%]

For older versions like Cassandra 4.0.4 it's very simple, change baseurl to:
baseurl=https://archive.apache.org/dist/cassandra/redhat/40x/
And execute:
[cass@h00104 ~]#  sudo yum install cassandra-4.0.4-1.noarch
cassandra-tools-4.0.4-1.noarch



On Tue, Aug 9, 2022 at 3:48 PM Amit Patel via user <
user@cassandra.apache.org> wrote:

> Hi Stephane,
>
>
>
> I have followed same instruction but new rpm version 4.0.5 is broken(bug)
> and there are no other package on that repo (download base url for rhel) so
> I can not install older stable version.
>
>
>
> Kind regards,
>
> Amit Patel
>
>
>
> *From:* Stéphane Alleaume <crystallo...@gmail.com>
> *Sent:* 09 August 2022 13:32
> *To:* user@cassandra.apache.org; Amit Patel <amit.pa...@euroclear.com>
> *Subject:* Re: RPM Installation on RHEL7 broken
>
>
>
> *CAUTION:* This email comes from outside Euroclear! Be vigilant!
>
> Hi
>
>
>
> Hope it will help :
>
>
>
>
>
>
> https://cassandra.apache.org/doc/trunk/cassandra/getting_started/installing.html#installing-the-rpm-packages
>
>
>
>    1. Add the Apache repository of Cassandra to the file
>    /etc/yum.repos.d/cassandra.repo (as the root user). The latest major
>    version is 4.0 and the corresponding distribution name is 40x (with an
>    "x" as the suffix). For older releases use 311x for C* 3.11 series, 30x for
>    {30_version}, 22x for {22_version} and 21x for {21_version}. For
>    example, to add the repository for version 4.0 (40x):
>
> [cassandra]
>
> name=Apache Cassandra
>
> baseurl=https://downloads.apache.org/cassandra/redhat/40x/ 
> <https://downloads.apache.org/cassandra/redhat/40x/gpgcheck=1repo_gpgcheck=1gpgkey=https:/downloads.apache.org/cassandra/KEYS>
>
> gpgcheck=1 
> <https://downloads.apache.org/cassandra/redhat/40x/gpgcheck=1repo_gpgcheck=1gpgkey=https:/downloads.apache.org/cassandra/KEYS>
>
> repo_gpgcheck=1 
> <https://downloads.apache.org/cassandra/redhat/40x/gpgcheck=1repo_gpgcheck=1gpgkey=https:/downloads.apache.org/cassandra/KEYS>
>
> gpgkey=https://downloads.apache.org/cassandra/KEYS 
> <https://downloads.apache.org/cassandra/redhat/40x/gpgcheck=1repo_gpgcheck=1gpgkey=https:/downloads.apache.org/cassandra/KEYS>
>
>
>    1. Update the package index from sources:
>
> $ sudo yum update
>
>
>    1. Install Cassandra with YUM:
>
> $ sudo yum install cassandra
>
> A new Linux user cassandra will get created as part of the installation.
> The Cassandra service will also be run as this user.
>
>    1. Start the Cassandra service:
>
> $ sudo service cassandra start
>
>
>
> Le mar. 9 août 2022, 14:17, Amit Patel via user <user@cassandra.apache.org>
> a écrit :
>
> Hi All,
>
>
>
> We are facing the issue on RHEL7 as well , we have java8 installed on the
> system but when I tried to install yum install Cassandra or even
> localinstall(downloaded rpm) gives similar error as below .
>
>
>
> There are bug report  for this issue (CASSANDRA-17765
> <https://issues.apache.org/jira/browse/CASSANDRA-17765>) but not sure
> when it can resolve.
>
> #yum localinstall cassandra-4.0.5-1.noarch.rpm
> Loaded plugins: product-id, search-disabled-repos, subscription-manager
> Examining cassandra-4.0.5-1.noarch.rpm: cassandra-4.0.5-1.noarch
> Marking cassandra-4.0.5-1.noarch.rpm to be installed
> Resolving Dependencies
> --> Running transaction check
> ---> Package cassandra.noarch 0:4.0.5-1 will be installed
> *Error: Invalid version flag: or*
>
> Edit
> <https://issues.apache.org/jira/secure/EditComment!default.jspa?id=13472721&commentId=17576846>
> Delete
> <https://issues.apache.org/jira/secure/DeleteComment!default.jspa?id=13472721&commentId=17576846>
>
>
>
> We have used the below repo:
>
>
>
> [cassandra]
>
> name=Apache Cassandra
>
> baseurl=https://downloads.apache.org/cassandra/redhat/40x/
>
> gpgcheck=1 repo_gpgcheck=1
>
> gpgkey=https://downloads.apache.org/cassandra/KEYS
>
>
>
> I tried older version but no package available on  Index of
> /cassandra/redhat/40x (apache.org)
> <https://downloads.apache.org/cassandra/redhat/40x/>
>
> yum install cassandra-4.0.4*
>
> No package cassandra-4.0.4* available.
>
>
>
> And broken package
>
>
>
> yum install cassandra-4*
>
> Loaded plugins: product-id, search-disabled-repos, subscription-manager
>
> Resolving Dependencies
>
> --> Running transaction check
>
> ---> Package cassandra.noarch 0:4.0.5-1 will be installed
>
> Error: Invalid version flag: or
>
>
>
> How Can I install the stable version?  Can someone please guide, What is
> the best practice to install cassandra on production server rpm package or
> tarball?
>
>
>
>
>
> Thanks & Kind regards,
>
> Amit Patel
>
>
>
>
>
>
>
>
>
>
>
> This e-mail message, including any attachments transmitted with it, is
>
> CONFIDENTIAL and may contain legally privileged information. This message is
>
> intended solely for the use of the individual or entity to whom it is 
> addressed. If
>
> you have received this message in error, please notify us immediately and 
> delete
>
> it from your system. Please visit our website to read the full disclaimer
>
> www.euroclear.com/disclaimer and for Euroclear Group company
>
> information www.euroclear.com/aboutus
>
>
>
> This e-mail message, including any attachments transmitted with it, is
> CONFIDENTIAL and may contain legally privileged information. This message is
> intended solely for the use of the individual or entity to whom it is 
> addressed. If
> you have received this message in error, please notify us immediately and 
> delete
> it from your system. Please visit our website to read the full disclaimer 
> www.euroclear.com/disclaimer and for Euroclear Group company
> information www.euroclear.com/aboutus
>
>

-- 
*בברכה,*
*יקיר גיברלטר*

Reply via email to