Installing xdebug on php 5.6 Amazon Linux AMI - linux

I created an Elastic Beanstalk Environment
ID_LIKE="rhel fedora"
VERSION_ID="2016.03"
PRETTY_NAME="Amazon Linux AMI 2016.03"
ANSI_COLOR="0;33"
CPE_NAME="cpe:/o:amazon:linux:2016.03:ga"
HOME_URL="http://aws.amazon.com/amazon-linux-ami/"
I'm trying to install xdebug using
sudo yum install php-pecl-xdebug
But I keep get the following error
Loaded plugins: priorities, update-motd, upgrade-helper
Resolving Dependencies
--> Running transaction check
---> Package php-pecl-xdebug.x86_64 0:2.2.3-1.5.amzn1 will be installed
--> Processing Dependency: php(api) = 20090626-x86-64 for package: php-pecl-xdebug-2.2.3-1.5.amzn1.x86_64
--> Processing Dependency: php(zend-abi) = 20090626-x86-64 for package: php-pecl-xdebug-2.2.3-1.5.amzn1.x86_64
--> Running transaction check
---> Package php-common.x86_64 0:5.3.29-1.8.amzn1 will be installed
--> Processing Conflict: php56-common-5.6.21-1.124.amzn1.x86_64 conflicts php-common < 5.5.22-1.98
--> Finished Dependency Resolution
Error: php56-common conflicts with php-common-5.3.29-1.8.amzn1.x86_64
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
What should I be using instead? And for reference how do I figure out which packages are available?
Thanks alot.

The php-pecl-xdebug depends on the default version of PHP for Amazon Linux, 2.3. Since you have PHP 5.6 installed, you're getting a conflict.
Unfortunately, it looks like Amazon Linux only has packages for xdebug up to PHP 5.5:
[ec2-user#ip-xxx-xxx-xxx-xxx ~]$ sudo yum search xdebug
Loaded plugins: priorities, update-motd, upgrade-helper
============================= N/S matched: xdebug ==============================
php-pecl-xdebug.x86_64 : PECL package for debugging PHP scripts
php54-pecl-xdebug.x86_64 : PECL package for debugging PHP scripts
php55-pecl-xdebug.x86_64 : PECL package for debugging PHP scripts
Name and summary matches only, use "search all" for everything.
Since there is a PECL package, you can install it through that:
[ec2-user#ip-xxx-xxx-xxx-xxx ~]$ sudo yum install php-pear php56-devel gcc
[ec2-user#ip-xxx-xxx-xxx-xxx ~]$ sudo mount -o remount,exec /var/tmp/
[ec2-user#ip-xxx-xxx-xxx-xxx ~]$ sudo pecl install xdebug
[ec2-user#ip-xxx-xxx-xxx-xxx ~]$ sudo mount -o remount,noexec /var/tmp/

Related

Install node in Amazon Linux 2

I purchased Amazon Linux 2 machine using AWS LightSail and tried to install node on that machine. But after several tries I can't able to install node and got the error shared below.
[root#ip-my public ip /]# sudo yum install nodejs
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
Resolving Dependencies
--> Running transaction check
---> Package nodejs.x86_64 2:18.3.0-1nodesource will be installed
--> Processing Dependency: libc.so.6(GLIBC_2.28)(64bit) for package: 2:nodejs-18.3.0-1nodesource.x86_64
--> Processing Dependency: libm.so.6(GLIBC_2.27)(64bit) for package: 2:nodejs-18.3.0-1nodesource.x86_64
--> Finished Dependency Resolution
Error: Package: 2:nodejs-18.3.0-1nodesource.x86_64 (nodesource)
Requires: libc.so.6(GLIBC_2.28)(64bit)
Error: Package: 2:nodejs-18.3.0-1nodesource.x86_64 (nodesource)
Requires: libm.so.6(GLIBC_2.27)(64bit)
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
Thanks in advance!
I think AWS LightSail Amazon Linux 2 supports node version <=16.x,
So we want to install node version <=16, I installed node version 16 and it works!!
Here are the steps followed,
Step 1:- Configure Yum Repository
$ sudo yum install -y gcc-c++ make
$ curl -sL https://rpm.nodesource.com/setup_16.x | sudo -E bash -
Step 2:– Install Node.js on Amazon Linux
$ sudo yum install -y nodejs
Step 3 – Check Version
$ node -v
$ npm -v
My solution to fix this problem, you must erase cache with this command:
sudo rm -R /var/cache/yum/x86_64/2/nodesource/
Now, you can download the correct version:
curl -sL https://rpm.nodesource.com/setup_16.x | sudo -E bash -
And now you can install:
sudo yum install -y nodejs

NGINX is giving error when i try to install

I am trying to install nginx in
Amazon Linux AMI
but when i try to run command
sudo yum install nginx
error is below
Loaded plugins: langpacks, priorities, update-motd
Resolving Dependencies
--> Running transaction check
---> Package nginx.x86_64 0:1.14.0-1.el6.ngx will be installed
--> Processing Dependency: libpcre.so.0()(64bit) for package: nginx-1.14.0-1.el6.ngx.x86_64
--> Finished Dependency Resolution
Error: Package: nginx-1.14.0-1.el6.ngx.x86_64 (nginx)
Requires: libpcre.so.0()(64bit)
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
I had this exact same problem. Check if you have a file like /etc/yum.repos.d/nginx.repo.
The Nginx install instructions tell us to create such a file and that it should look like this:
[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/rhel/$releasever/$basearch/
gpgcheck=0
enabled=1
Those instructions also tell us
Due to differences between how CentOS, RHEL, and Scientific Linux populate the $releasever variable, it is necessary to manually replace $releasever with either 5 (for 5.x) or 6 (for 6.x), depending upon your OS version.
So you need to replace $releasever with the appropriate version of your OS. But when using Amazon Linux AMI (or, in my case, the Azure version), it's not easy to tell what this is.
I found that sudo yum install nginx only worked when I replaced $releasever with 7. When I used 6 instead, I got the exact error as you. Hope this helps!
First run $ sudo yum update -y and after that try to install, if still facing same issue then try with $ sudo yum install nginx --skip-broken

Unable to install GConf2 in AWS EC2 AMI

I have setup an AWS EC2 instance [Amazon Linux AMI 2017.03.1 (HVM)] and whenever I try to check the version of chromedriver (downloaded 2.30 from here, has enough privileges to run also because stat -c "%a %n" chromedriver gives 755 chromedriver ) using the command
chromedriver --version
I get the below error :
error while loading shared libraries: libgconf-2.so.4:
cannot open shared object file: No such file or directory
Also the result of ldd chromedriver is :
libgconf-2.so.4 => not found
I came to know that the above library is provided by GConf2 (refer here)
So I ran the command yum install Conf2
and I am stuck with the below error :
# yum install GConf2
Loaded plugins: priorities, update-motd, upgrade-helper
amzn-main | 2.1 kB 00:00:00
amzn-updates | 2.3 kB 00:00:00
No package GConf2 available.
Error: Nothing to do
Note :
I am running the commands as a root user!
Tried to do yum clean all
and yum update and updated all the packages and still getting the
error
Also tried yum provides */libgconf-2.so.4 , getting error : Loaded plugins: priorities, update-motd, upgrade-helper No matches found
I installed the Gconf2 following this

Error Installing phpmyadmin on CentOS

I get the this error when i try yo install phpmyadmin on CentOS 6.5 VPS using this.
COMMAND :
sudo yum install phpmyadmin
ERROR :
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.solarvps.com
* epel: epel.mirror.constant.com
* extras: mirror.wiredtree.com
* rpmforge: repoforge.mirror.constant.com
* updates: mirrors.lga7.us.voxel.net
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package phpmyadmin.noarch 0:2.11.11.3-2.el6.rf will be installed
--> Processing Dependency: php-mbstring >= 4.1.0 for package: phpmyadmin-2.11.11.3-2.el6.rf.noarch
--> Running transaction check
---> Package php-mbstring.x86_64 0:5.3.3-27.el6_5 will be installed
--> Processing Dependency: php-common(x86-64) = 5.3.3-27.el6_5 for package: php-mbstring-5.3.3-27.el6_5.x86_64
--> Finished Dependency Resolution
Error: Package: php-mbstring-5.3.3-27.el6_5.x86_64 (updates)
Requires: php-common(x86-64) = 5.3.3-27.el6_5
Installed: php-common-5.4.30-1.el6.remi.x86_64 (#remi)
php-common(x86-64) = 5.4.30-1.el6.remi
Available: php-common-5.3.3-26.el6.x86_64 (base)
php-common(x86-64) = 5.3.3-26.el6
Available: php-common-5.3.3-27.el6_5.x86_64 (updates)
php-common(x86-64) = 5.3.3-27.el6_5
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
Somebody please Help. Thanx in advance
You've installed a more recent PHP version (5.4.30-1) from another source (#remi) than the officials (base) repository provides. Now you're trying to install the phpMyAdmin package, which depends on php-mbstring. php-mbstring is the actual problem here -- it's being automatically installed because phpmyadmin depends on it, but the version you're attempting to install isn't compatible with the rest of your PHP installation.
The solution is easy, though, since remi also provides phpmyadmin (quite a bit more recent version than you're attempting to install, too!). Just install phpmyadmin and php-common from the remi repository like you installed PHP. There are some instructions at http://blog.famillecollet.com/pages/Config-en if you forgot, but you managed to install the upgraded PHP already so you should be able to get the remi phpmyadmin installed pretty easily.
OR....
Download phpMyAdmin from http://www.phpmyadmin.net and uncompress it to your web root and forget about the package. php-mbstring isn't strictly required to run the application anyway, so you don't even need to worry about that part as long as you meet the other requirements.
You installed php5.4 from remi repository.
phpmyadmin needs php to work; but you are installing phpmyadmin from the official repository and that phpmyadmin version needs php5.3.
I guess you don't want to go back to php5.3, so just run this command:
yum --enablerepo=remi install phpmyadmin
If you didn't add remi repositories to you CentOS, you will have to previously run:
sudo rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
sudo rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm

How can I solve this Sphinx search dependency issue?

I'm trying to install Sphinx search on a CentOS VPS via SSH but I keep getting dependency issues that I can't seem to resolve.
Here's the OS I'm using:
cat /etc/redhat-release
CentOS 6.4 (Final)
uname -a
Linux host.example.com 2.6.32-042stab074.10 #1 SMP Fri Mar 1 09:18:44 MSK 2013 i686 i686 i386 GNU/Linux
This to me looks like I need the 32-bit CentOS 6 rpm so I tried to install it with this command:
sudo yum install http://sphinxsearch.com/files/sphinx-2.0.8-1.rhel6.i386.rpm
but I get the following error message:
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.advancedhosters.com
* extras: centos.mirror.constant.com
* updates: mirror.lug.udel.edu
base | 3.7 kB 00:00
extras | 3.5 kB 00:00
updates | 3.4 kB 00:00
Setting up Install Process
sphinx-2.0.8-1.rhel6.i386.rpm | 5.6 MB 00:30
Examining /var/tmp/yum-root-oMekz6/sphinx-2.0.8-1.rhel6.i386.rpm: sphinx-2.0.8-1.rhel6.i386
Marking /var/tmp/yum-root-oMekz6/sphinx-2.0.8-1.rhel6.i386.rpm to be installed
Resolving Dependencies
--> Running transaction check
---> Package sphinx.i386 0:2.0.8-1.rhel6 will be installed
--> Processing Dependency: libmysqlclient.so.16 for package: sphinx-2.0.8-1.rhel6.i386
--> Processing Dependency: libmysqlclient.so.16(libmysqlclient_16) for package: sphinx-2.0.8-1.rhel6.i386
--> Finished Dependency Resolution
Error: Package: sphinx-2.0.8-1.rhel6.i386 (/sphinx-2.0.8-1.rhel6.i386)
Requires: libmysqlclient.so.16
Error: Package: sphinx-2.0.8-1.rhel6.i386 (/sphinx-2.0.8-1.rhel6.i386)
Requires: libmysqlclient.so.16(libmysqlclient_16)
You could try using --skip-broken to work around the problem
** Found 2 pre-existing rpmdb problem(s), 'yum check' output follows:
frontpage-2002-SR1.2.i386 has missing requires of libexpat.so.0
sendmail-cf-8.14.4-8.el6.noarch has missing requires of sendmail = ('0', '8.14.4', '8.el6')
No matter what I try I always seem to be missing libmysqlclient.so.16.
Any idea where I can find this package?
yum install mysql-devel
should do it.
Install the remi repository:
[http://blog.famillecollet.com/pages/Config-en]
Enterprise Linux 6 (with EPEL) i386 or x86_64
wget http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm
then install compat-mysql51
yum --enablerepo=remi install compat-mysql51
then install sphinx from the rpm downloaded
yum localinstall sphinx-2.1.2-1.rhel6.SYSTEM-VERSION.rpm
Use the SphinxSearch docker files (docker hub link) to easily install SphinxSearch.
Grab it:
docker pull leodido/sphinxsearch:latest
If you want to see how to compile from source (which I recommend as the better mode to install SphinxSearch), look into them - e.g., here.

Resources