Friday, December 15, 2017

Error : pecl/pecl_http requires PHP (version >= 7.0.0), installed version is 5

Not able to install STOMP extension in XAMPP

Solution :

Current stable version of stomp is 2.0 which supports php 7.0, 
if we run

pecl install stomp
or
/opt/lampp/bin/pecl install stomp

it installs stomp-2.0 by default which needs php 7.0 so we need to install stomp which supports php 5.x,


Run :
pecl install stomp-1.0.9
or
/opt/lampp/bin/pecl install stomp-1.0.9

Stomp 1.0.9 is for php 5.x versions.
Now you should not get php version error.

Tuesday, November 7, 2017

phpmyadmin exporting html in place of sql

Solution :

Add/Uncomment following attribute in php.ini

max_input_vars = 5000
Restart Apache.

FATAL: Peer authentication failed for user "postgres"

psql dump database from other user without loginto postgres user

$ whoami
ubuntu

$ pg_dump -U postgres dbname > db.sql
FATAL:  Peer authentication failed for user "postgres"


Solution :

sudo nano /etc/postgresql/9.4/main/pg_hba.conf

Change

local   all             postgres                                peer
to
local   all             postgres                                trust


Restart postgresql.