How to update PHP in Cent OS 6.8? - linux

I try to update PHP 5.5 to up using command:
sudo rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
Retrieving
https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
warning: /var/tmp/rpm-tmp.4xrPQL: Header V3 RSA/SHA256 Signature, key
ID 352c64e5: NOKEY error: Failed dependencies: epel-release = 6 is
needed by (installed) remi-release-6.8-1.el6.remi.noarch epel-release
= 6 is needed by (installed) ius-release-1.0-14.ius.centos6.noarch
How can I fix this?

You should epel for CentOS 6 not 7:
sudo yum install php-common
sudo rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
sudo rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm
sudo yum install php70w php70w-opcache
sudo yum install php70w-fpm php70w-opcache
sudo yum install yum-plugin-replace
sudo yum replace php-common --replace-with=php70w-common
sudo yum install php70w-opcache
# remove old php-cli
sudo yum remove php-cli
sudo rm -rf /usr/bin/php
sudo yum -y install php70w-cli
For more informations check this link

Related

installing puppeteer 2 elastickbeanstalk

I can't deploy puppeteer on aws AWS Elastic Beanstalk.
I'm getting the following error:
Failed to launch the browser process!\n/var/app/current/node_modules/puppeteer/.local-chromium/linux-722234/chrome-linux/chrome: /lib64/libdbus-1.so.3: no version information available (required by /usr/lib64/libatk-bridge-2.0.so.0)\n/var/app/current/node_modules/puppeteer/.local-chromium/linux-722234/chrome-linux/chrome: /lib64/libdbus-1.so.3: no version information available (required by /usr/lib64/libatspi.so.0)\n/var/app/current/node_modules/puppeteer/.local-chromium/linux-722234/chrome-linux/chrome: symbol lookup error: /var/app/current/node_modules/puppeteer/.local-chromium/linux-722234/chrome-linux/chrome: undefined symbol: g_type_class_adjust_private_offset\n\n\nTROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/master/docs/troubleshooting.md\n"
Did anyone had the same issue and managed to solve it?
finally I solved it with this:
packages:
yum:
compat-libtiff3: []
commands:
chrome:
command: curl https://intoli.com/install-google-chrome.sh | bash
You need to add a number of shared libs, see https://github.com/puppeteer/puppeteer/issues/765#issuecomment-358111805
You will also need 'sudo yum install -y mesa-libgbm.x86_64'
And looks like it works only for puppeteer2.0.0, later version fails with https://github.com/puppeteer/puppeteer/issues/5379
This worked for me !
Connected remotly via SSH in elastic beanstalk
eb ssh {environment_name}
Install Google Chrome
curl https://intoli.com/install-google-chrome.sh | bash
Source :
https://dev.to/achimoraites/a-developers-guide-to-run-puppeteer-on-elastic-beanstalk-no-ubuntu-linux-4pl5
Solved it with the following post-build script after trying a whole bunch of different packages / versions.
Tested on Amazon Linux 2, Node.JS v16, puppeteer v15.3.0
#!/bin/bash
# Put this in your Amazon Elastic Beanstalk repo
# Tested on Amazon Linux 2, Node.JS v16, puppeteer v15.3.0
# File path: .platform/hooks/postdeploy/01_install_libs.sh
sudo amazon-linux-extras install epel -y
cd node_modules/puppeteer/
cd .local-chromium/linux-*/chrome-linux
sudo yum install cups-libs dbus-glib libXrandr libXcursor libXinerama cairo cairo-gobject pango libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev libcups2
sudo rpm -ivh --nodeps --replacepkgs http://mirror.centos.org/centos/7/os/x86_64/Packages/atk-2.28.1-2.el7.x86_64.rpm
sudo rpm -ivh --nodeps http://mirror.centos.org/centos/7/os/x86_64/Packages/at-spi2-atk-2.26.2-1.el7.x86_64.rpm
sudo rpm -ivh --nodeps http://mirror.centos.org/centos/7/os/x86_64/Packages/at-spi2-core-2.28.0-1.el7.x86_64.rpm
sudo rpm -ivh --nodeps http://dl.fedoraproject.org/pub/archive/fedora/linux/releases/20/Fedora/x86_64/os/Packages/g/GConf2-3.2.6-7.fc20.x86_64.rpm
sudo rpm -ivh --nodeps http://dl.fedoraproject.org/pub/archive/fedora/linux/releases/20/Fedora/x86_64/os/Packages/l/libXScrnSaver-1.2.2-6.fc20.x86_64.rpm
sudo rpm -ivh --nodeps http://dl.fedoraproject.org/pub/archive/fedora/linux/releases/20/Fedora/x86_64/os/Packages/l/libxkbcommon-0.3.1-1.fc20.x86_64.rpm
sudo rpm -ivh --nodeps http://dl.fedoraproject.org/pub/archive/fedora/linux/releases/20/Fedora/x86_64/os/Packages/l/libwayland-client-1.2.0-3.fc20.x86_64.rpm
sudo rpm -ivh --nodeps http://dl.fedoraproject.org/pub/archive/fedora/linux/releases/20/Fedora/x86_64/os/Packages/l/libwayland-cursor-1.2.0-3.fc20.x86_64.rpm
sudo rpm -ivh --nodeps http://dl.fedoraproject.org/pub/archive/fedora/linux/releases/20/Fedora/x86_64/os/Packages/g/gtk3-3.10.4-1.fc20.x86_64.rpm
sudo rpm -ivh --nodeps http://dl.fedoraproject.org/pub/archive/fedora/linux/releases/16/Fedora/x86_64/os/Packages/gdk-pixbuf2-2.24.0-1.fc16.x86_64.rpm
sudo yum install -y chromium
Gist: https://gist.github.com/lucashenning/8f6807eab8b5d99caafd2a507f770ba1

No package certbot available

I'm trying to install certbot on RHEL server.
Instructions to enable epel-release
# yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
then
# subscription-manager repos --enable "rhel-*-optional-rpms" --enable "rhel-*-extras-rpms"
epel-release-7-11 was installed.
# yum install certbot
Loaded plugins: product-id, search-disabled-repos, subscription-manager
No package certbot available.
Error: Nothing to do
I even downloaded rpm manually from
fedora project epel
removed and cleared all cache. But install package is not available.
For future reference, I could install executing the following lines:
sudo yum -y install yum-utils
sudo yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
sudo yum-config-manager --enable rhui-REGION-rhel-server-extras rhui-REGION-rhel-server-optional
sudo yum install certbot
https://certbot.eff.org/lets-encrypt/centosrhel7-other
It's success for me.
before install certbot, I execute the following lines:
yum remove epel-release
yum clean all
then execute the following lines:
sudo yum -y install yum-utils
sudo yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
sudo yum-config-manager --enable rhui-REGION-rhel-server-extras rhui-REGION-rhel-server-optional
sudo yum install certbot
For me with same error just using this command simply solved the problem:
yum install epel-release
seems other sugesstions are a little excessive or unrelated.
Go to /etc/yum.repo.d/epel.repo and delete # before the "baseurl" and save it.
after that:
yum install certbot
on this way my problem was solved
In EC2 Amazon Linux do
$ sudo amazon-linux-extras install epel
then do
$ sudo yum install certbot

Odoo11 install on CentoOS7

I just bought new VPS server installed CentOS7 and tried to install Odoo11 on my server.
So I researched some articles and tried following.
// Install requirement packages
[root#odoo ~]# yum update -y
[root#odoo ~]# yum install epel-release -y
[root#odoo ~]# yum install fontconfig libpng libX11 libXext libXrender xorg-x11-fonts-Type1 xorg-x11-fonts-75dpi wkhtmltopdf yum-utils -y
// Install PostgreSQL
[root#odoo ~]# yum install postgresql-server -y
[root#odoo ~]# postgresql-setup initdb
[root#odoo ~]# systemctl enable postgresql
[root#odoo ~]# systemctl start postgresql
// Install Odoo
[root#odoo ~]# yum-config-manager --add-repo=https://nightly.odoo.com/11.0/nightly/rpm/odoo.repo
[root#odoo ~]# yum install odoo -y
After run last command, I get error.
...
Error: Package: odoo-11.0.post20171110-1.noarch (odoo-nightly)
Requires: python3-psutil Error: Package: odoo-11.0.post20171110-1.noarch (odoo-nightly)
Requires: python3-requests Error: Package: odoo-11.0.post20171110-1.noarch (odoo-nightly)
Requires: python3-greenlet
...
How can I fix this?
This was due to python3 dependency missing problem though I installed python3 successfully on CentOS.
Finally, I restarted server and it solved the problem. I'm not sure exactly why restart was required.

How do delete deb package with dependencies

I'm trying to delete linux kernel deb package using command sudo dpkg -r linux-header-3.19.8.992 but fails saying dependencies are there
sudo apt-get purge <package-name>
sudo apt-get autoremove
sudo apt-get remove packagename
or
sudo dpkg -r package_name
for more info https://askubuntu.com/questions/22200/how-to-uninstall-a-deb-package

Dependency issue: sun-java6-jdk (bindiff)

I am trying to install bindiff. When I try to install through archive manager I am welcomed by the following message "Dependency is not satisfiable: sun-java6-jre". (I am running ubuntu 12.10)
I have tried adding a repository
sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"
sudo add-apt-repository ppa:ferramroberto/java
This did not work.
I also currently have java 7 installed, and have done sudo apt-get update
I tried "sudo apt-get install sun-java6-jdk" and I receive the following:
sudo apt-get install sun-java6-jdk Reading package lists... Done Building dependency tree
Reading state information... Done Package sun-java6-jdk is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source
E: Package 'sun-java6-jdk' has no installation candidate
SOLVED:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get remove java-common
sudo apt-get install oracle-java6-installer
sudo apt-get purge java common
Use the following terminal commands:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get remove java-common
sudo apt-get install oracle-java6-installer
sudo apt-get purge java common

Resources