PIWIK GeoIP (PECL) giving unknown location - matomo

I have installed piwik successfuly on my system. But geoIP location is not working. I have followed guide at piwik FAQ to configure GeoIP Geo location by PECL extention. But is is always showing
According to this provider, your current location is:
Unknown
I have also placed GeoIPCity.dat in /.../piwik/misc/ but same error. I have also tried GeoIP (Php) but nothing changed. What is the problem. I am using centos on my server.

Related

Moodle unable to access using domainName

Installing MOODLE_33_STABLE origin/MOODLE_33_STABLE on Ubuntu 16.04.2
I am able to install it and , access it with my vm's ip,
but when i try to change
$CFG->wwwroot = 'http://ipaddress'
to
$CFG->wwwroot = 'http://somerandomname.com'
in config.php,
i am unable to access it using somerandomname.com in my lan.
i have also mapped the vm ip in hosts file of both apache2 and of the other systems in lan, still it shows HTTP ERROR 502, in chrome.
and Host not found when i check the chrome console.
if i am missing something guide me.
i want to access the moodle installed on my VM across my local connection with some domainname rather than the IP .
Thank you.
Sounds like you have to try classical debugging:
Try to access your moodle instance on the specific port, using eg. telnet
telnet somerandomname.com 80
Delete browser cache or open the URL in your incognito mode
Check the apache error log on Ubuntu: /var/log/apache2/error.log.
Check out further possibilities which are causing this 502 error:
https://www.lifewire.com/502-bad-gateway-error-explained-2622939

Windows + Xampp + CakePHP - Composer throws error on update

I am trying to create a local development environment on a Windows machine using Xampp. Xampp has been setup correctly and I am able to access localhost, locahost/phpmyadmin and a virtual host I created domain.local. This Virtual Host is a CakePHP application that I had been running on a Linux Box (nginx). I use that code to setup the site, but when I try to run
php composer.phar update
to have composer download all dependencies, I get the following error:
Fatal error: Class 'Cake\Composer\Installer\PluginInstaller' not found in
phar://C:/Users/admin/Documents/Sites/domain.local/website/composer.phar/src/Composer/Plugin/PluginManager.php
on line 244
I have tried a bunch of things without success.
Also to note php composer.phar self-update, runs without issue.
Not sure what to do at this point. Any help is appreciated.
After more tryouts, I finally decided to delete the vendor folder and surprisingly it fixed my issue. Composer downloaded all dependencies and everything works as expected.

How to set upload_tmp_dir in Plesk

I was trying to set upload_tmp_dir variable for one of my domain I added following entries
root#host1 /var/www/vhosts/vw-forum.pl/conf # cat vhosts.conf
php_admin_value upload_tmp_dir /tmp
Then I refreshed configuration
/usr/local/psa/admin/sbin/httpdmng --reconfigure-domain vw-forum.pl
but in the end in php info it`s showing
upload_tmp_dir no value no value
Pls advice how to fix this..
I have find out an answer it should be changed in PLesk Panel for particula domain
PHP settings tab for domain As "Additional configuration directives"
My phpinfo also shows no value in upload_tmp_dir. However, as I've learned today from the error logs, you have to manually configure Plesk to accept that respective dir in the open_basedir PHP setting.
mod_fcgid: stderr: PHP Warning: Unknown: open_basedir restriction in effect. File(/tmp) is not within the allowed path(s): (…)
I have just done so and can upload fine now, even though phpinfo still shows no value for that entry.

displaying html page through apache

i am using ubuntu and i have a html page named first.html at home/sanu directory and i have apache2 installed and running.i want host this page through apache from my pc how can i do that. (My pc's IP is :218.248.80.51) .i have tried to access "http://218.248.80.51/sanu/first.html" but its not working(Google Chrome could not connect to 218.248.80.51) in my browser.plz help me.
By default Apache points to /var/www on ubuntu, it would required extra configuration to get it to point at your home directory. Try moving your html file there, then you should be able to access it through your browser at http://localhost/first.html
To host the page for public viewing you'd need to configure your pc's & router's firewalls correctly to allow port 80.

Google App Engine: Sendmail, command not found

I'm trying to get sendmail working on localhost. The problem is that the app engine has det wrong path to sendmail, since it throws the error: /bin/sh: sendmail: command not found
Using Mac OS X, the path to sendmail is: /usr/sbin/sendmail
Does anyone know how to change this?
..fredrik
I don't know how to change it but a symlink will do the job. I had the same problem and this solved it:
sudo ln -s /usr/sbin/sendmail /usr/bin/sendmail
Another option is to configure your local AppEngine runtime to use an external SMTP server.
According to the documentation,
The web server will use the sendmail
command to send email messages, with
your installation's default
configuration
If it uses NETINFO to determine the location of sendmail, the full path to sendmail.cf is stored as the value of the "sendmail.cf" property in the "/locations/sendmail" subdirectory of NETINFO, so try to set the value of this property to "/usr/sbin/sendmail.cf" (without the quotes)
Hope it helps

Resources