I got a problem when uninstall php-pgsql. it can't be remove.
[root#ip-172-31-31-52 /]# yum list php-pgsql\*
Loaded plugins: priorities, update-motd, upgrade-helper
Available Packages
php-pgsql.x86_64 5.3.29-1.8.amzn1 amzn-main
[root#ip-172-31-31-52 /]# yum remove php-pgsql\*
Loaded plugins: priorities, update-motd, upgrade-helper
No Match for argument: php-pgsql*
No Packages marked for removal
When i check the package is available but stil can't remove. Please help. Thank you
If you look at the output of the list command, it shows that the php-pgsql.x86_64 is available, not installed on the machine. and that's why, when you hit the remove command, it shows that no packages marked for removal.
To support my answer, I had tried to run both of your command on ec2, and which does remove the package , if its installed.
Now if the plugin in installed on ec2 and you run list command , it shows the installed packages:
[root#ip-xx-xxx-xx-xxx ec2-user]# yum list php-pgsql*
Loaded plugins: priorities, update-motd, upgrade-helper
Installed Packages -- this line shows it installed.
php-pgsql.x86_64
Try remove command to remove the packages:
[root#ip-xx-xxx-xx-xxx ec2-user]# yum remove php-pgsql* -y
Loaded plugins: priorities, update-motd, upgrade-helper
Resolving Dependencies
--> Running transaction check
---> Package php-pgsql.x86_64 0:5.3.29-1.8.amzn1 will be erased
--> Finished Dependency Resolution
Dependencies Resolved
=============================================================================================================================================================================================================================================
Package Arch Version Repository Size
=============================================================================================================================================================================================================================================
Removing:
php-pgsql x86_64 5.3.29-1.8.amzn1 #amzn-main 315 k
Transaction Summary
=============================================================================================================================================================================================================================================
Remove 1 Package
Installed size: 315 k
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Erasing : php-pgsql-5.3.29-1.8.amzn1.x86_64 1/1
Verifying : php-pgsql-5.3.29-1.8.amzn1.x86_64 1/1
Removed:
php-pgsql.x86_64 0:5.3.29-1.8.amzn1
Complete!
Related
I cannot use yum commands like sudo yum update in Amazon EC2 instance.
[ec2-user#ip-***-***-*** /]$ sudo yum update
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
amzn2-core | 3.7 kB 00:00:00
No packages marked for update
I tried all of the stuff writing on net but I couldn't solved it.
Lastly I tried:
sudo sed 's/-$guid//g' /etc/yum.repos.d/amzn2-core.repo -i
Is there any way to solve it?
I have started EC2 instance from L=amazon linux 2 AMI.
I am trying to install syslog-ng with yum but I am getting error.
Commands used :
$ sudo amazon-linux-extras install epel -y
$ sudo yum install syslog-ng
AND
$ sudo yum-config-manager --add-repo=https://copr.fedorainfracloud.org/coprs/czanik/syslog-ng321/repo/epel-7/czanik-syslog-ng321-epel-7.repo"
$ sudo yum install --enablerepo=epel --assumeyes syslog-ng
But I am getting following error in both the cases:
Loaded plugins: dkms-build-requires, extras_suggestions, langpacks, priorities, update-motd
215 packages excluded due to repository priority protections
Resolving Dependencies
--> Running transaction check
---> Package syslog-ng.x86_64 0:3.23.1-1.el6 will be installed
--> Processing Dependency: libmaxminddb.so.0()(64bit) for package: syslog-ng-3.23.1-1.el6.x86_64
--> Processing Dependency: libpcre.so.0()(64bit) for package: syslog-ng-3.23.1-1.el6.x86_64
--> Running transaction check
---> Package libmaxminddb.x86_64 0:1.2.0-1.el7 will be installed
---> Package syslog-ng.x86_64 0:3.23.1-1.el6 will be installed
--> Processing Dependency: libpcre.so.0()(64bit) for package: syslog-ng-3.23.1-1.el6.x86_64
--> Finished Dependency Resolution
Error: Package: syslog-ng-3.23.1-1.el6.x86_64 (copr:copr.fedorainfracloud.org:czanik:syslog-ng323epel6)
Requires: libpcre.so.0()(64bit)
You could try using --skip-broken to work around the problem
** Found 1 pre-existing rpmdb problem(s), 'yum check' output follows:
cloud-init-19.3-44.amzn2.noarch has missing requires of rsyslog
I wrote these instructions a year ago: https://www.syslog-ng.com/community/b/blog/posts/installing-syslog-ng-in-amazon-linux-2-including-graviton2
I do not have any AWS accounts right now, but if they do not work, the I'll try to get one...
**Update:**
First of all: I double checked your report. You mention adding a repo for EPEL 7 syslog-ng 3.21, however the error below it is about syslog-ng 3.23 for EPEL 6.
OK, I got access. I followed my own instructions and it works:
[ec2-user#ip-xxx ~]$ syslog-ng -V
syslog-ng 3 (3.29.1)
Config version: 3.29
Installer-Version: 3.29.1
Revision:
Compile-Date: Aug 29 2020 08:27:16
Module-Directory: /usr/lib64/syslog-ng
Module-Path: /usr/lib64/syslog-ng
Include-Path: /usr/share/syslog-ng/include
Available-Modules: add-contextual-data,affile,afprog,afsocket,afstomp,afuser,appmodel,basicfuncs,cef,confgen,cryptofuncs,csvparser,dbparser,disk-buffer,examples,graphite,hook-commands,json-plugin,kvformat,linux-kmsg-format,map-value-pairs,pseudofile,sdjournal,stardate,syslogformat,system-source,tags-parser,tfgetent,timestamp,xml,azure-auth-header,http
Enable-Debug: off
Enable-GProf: off
Enable-Memtrace: off
Enable-IPv6: on
Enable-Spoof-Source: on
Enable-TCP-Wrapper: on
Enable-Linux-Caps: on
Enable-Systemd: on
[ec2-user#ip-xxx ~]$ cat /etc/os-release
NAME="Amazon Linux"
VERSION="2"
ID="amzn"
ID_LIKE="centos rhel fedora"
VERSION_ID="2"
PRETTY_NAME="Amazon Linux 2"
ANSI_COLOR="0;33"
CPE_NAME="cpe:2.3:o:amazon:amazon_linux:2"
HOME_URL="https://amazonlinux.com/"
And tried to latest version (3.35), and that works as well.
Tried with specific package and its able to install.
$ sudo yum --enablerepo=epel -y install syslog-ng-3.5.6-3.el7.x86_64
AWS security advisory https://alas.aws.amazon.com/AL2/ALAS-2021-1674.html is causing my security scan to fail. The advice is to yum update httpd to install httpd-2.4.48-2.amzn2.x86_64. However when I do this AWS yum repo only has an old version of this package (httpd-2.4.46-2.amzn2.x86_64).
yum update httpd
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
No packages marked for update
yum install httpd
Loaded plugins: extras_suggestions, kernel-livepatch, langpacks, priorities, update-motd
amzn2-core | 3.7 kB 00:00:00
Package httpd-2.4.46-2.amzn2.x86_64 already installed and latest version
Nothing to do
This is a brand new unmodified AWS linux 2 instance. I have tried everything I could find online (making sure I can access yum repo and clearing cache)
Can anyone else using amazon linux 2 see this new package? (2.4.48) or even better have any suggestions how to proceed?
Worked it out - AWS Elastic Beanstalk in all their wisdom append a "-$guid" to the YUM repo list on an instance, which must be stuck in their CDN as was returning an out of date package list. I have resolved via:
sed 's/-$guid//g' /etc/yum.repos.d/amzn2-core.repo -i
AWS security advisory Link mention that we have to do "yum update httpd". If it still does not work I would say we have to update yum repo.
I installed AWS Redshift drivers in Tableau Server using:
Download:
wget https://s3.amazonaws.com/redshift-downloads/drivers/odbc/1.4.27.1000/AmazonRedshiftODBC-64-bit-1.4.27.1000-1.x86_64.rpm
Install:
sudo yum --nogpgcheck localinstall AmazonRedshiftODBC-64-bit-1.4.27.1000-1.x86_64.rpm
Install output is:
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
Examining AmazonRedshiftODBC-64-bit-1.4.27.1000-1.x86_64.rpm: AmazonRedshiftODBC-64bit-1.4.27-1.x86_64
Marking AmazonRedshiftODBC-64-bit-1.4.27.1000-1.x86_64.rpm to be installed
Resolving Dependencies
--> Running transaction check
---> Package AmazonRedshiftODBC-64bit.x86_64 0:1.4.27-1 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
========================================================================================================================================================================================================================
Package Arch Version Repository Size
========================================================================================================================================================================================================================
Installing:
AmazonRedshiftODBC-64bit x86_64 1.4.27-1 /AmazonRedshiftODBC-64-bit-1.4.27.1000-1.x86_64 60 M
Transaction Summary
========================================================================================================================================================================================================================
Install 1 Package
Total size: 60 M
Installed size: 60 M
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : AmazonRedshiftODBC-64bit-1.4.27-1.x86_64 1/1
Verifying : AmazonRedshiftODBC-64bit-1.4.27-1.x86_64 1/1
Installed:
AmazonRedshiftODBC-64bit.x86_64 0:1.4.27-1
Complete!
When I test redshift connection I get this error:
Drivers needed not installed to connect to db.<br>2021-06-28 14:39:57.163, (YNnfPNRMIky5JaHdM7bkwwAAANQ,1:1
downgrade the driver to 1.4.20.1001, any version after this is not compatible with tableau server.
https://s3.amazonaws.com/redshift-downloads/drivers/odbc/1.4.20.1001/AmazonRedshiftODBC-64-bit-1.4.20.1001-1.x86_64.rpm
My company has firewall rules for yum so we can use only rpm to install the softwares on the RHEL 6 SERVER. So, I got a task to install virtualbox 5.1 on it. i used the rpm from the virtualbox website and installed it, but it failed with 2 dependencies and i installed them also. Then i got the below error.I just googled that i need some kernel-devel rpms but i dono, what to do after that and what else i need to make the virtual box running.
# virtualbox
WARNING: The vboxdrv kernel module is not loaded. Either there is no module available for the current kernel (2.6.32-642.4.2.el6.x86_64) or it failed to load. Please recompile the kernel module and install it by
sudo /sbin/vboxconfig
You will not be able to start VMs until this problem is fixed.
Qt FATAL: QXcbConnection: Could not connect to display
Aborted
There will be lot of dependencies while installing rpm's. you need to check one by one and install the RPM's. Is suggest you to build local yum repository which doesnt require internet. you should use rhel 6 iso file to build local repo. And download the virtual box rpm, and try to install it with yum utility. yum will use local repo for dependency resolution.
Build repo:
1. mount DVD
[root#lh1 Packages]# cd /etc/yum.repos.d
[root#lh1 yum.repos.d]# vi dvd.repo
[root#lh1 yum.repos.d]# cat dvd.repo
[DVD_ISO]
name= Linux 6
baseurl=file:///mnt/cdrom
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY
gpgcheck=1
enabled=1
[root#lh1 rpm-gpg]# yum clean all
Loaded plugins: rhnplugin
[Errno 2] No such file or directory: '/var/cache/yum/x86_64/6Server'
[root#lh1 rpm-gpg]# yum repolist
Loaded plugins: rhnplugin
This system is not registered with ULN.
ULN support will be disabled.
DVD_ISO | 3.7 kB 00:00 ...
DVD_ISO/primary_db | 3.1 MB 00:00 ...
repo id repo name status
DVD_ISO Linux 6 3,379
repolist: 3,379