ERROR: Unable to load libphutil - php

We have setup running Phabricator in one of our servers. Today I upgrade it by following the standard steps given in "https://secure.phabricator.com/book/phabricator/article/upgrading/" upgrade note.
When I try to start pdh using systemctl start phabricator-phd it get fails.
Error is
ERROR: Unable to load libphutil. Update your PHP 'include_path' to include the parent directory of libphutil/.
I tried other different way to start it but all of the giving this same error.
Hope someone can help me to solve this issue.

in the folder where arcanist/ is
git clone https://github.com/phacility/libphutil.git
This solved my problem.

Using git clone https://github.com/phacility/libphutil.git like #Youngjae Ji recommends doesn't work anymore. Take a look at that repo now. There's nothing in it! https://github.com/phacility/libphutil. A work-around seems to be the following, however:
sudo apt install libphutil then dpkg -L libphutil to see where it's located on your system. Once you find out where it is (ex: /usr/share/libphutil), symbolically link to it in arcanist as follows: ln -s /usr/share/libphutil path_to_arcanist/externals/includes. Now it should work.

Typically phd is restarted via bin/phd restart. Does this work? If yes, then the issue is your startup script. If no, then Phabricator likely wasn't installed correctly.

Fixed.
It was a permission issue. below fixed it.
chmod g+rX,o+rX libphutil/ -Rc
chmod g+rX,o+rX arcanist/ -Rc
chmod g+rX,o+rX phabricator/ -Rc

I have met the same problem.One way to solve: just put libphutil, arcanist, phabricator(the websever started) on same path

Related

How to install PHP5 on Openshift?

I am trying to install PHP5 using the instructions available here.
However, when I perform: nohup ${OPENSHIFT_REPO_DIR}/misc/make.sh &, I get a:
nohup: failed to run command .../make.sh: Permission denied message on top of nohup: ignoring input and appending output to nohup.out.
I have tried sudo, but I don't have access as sudo (of course).
Does anyone have clear, complete and operational instructions to install PHP5 on Openshift?
Seems that you are using Windows, or you just lost the permission information.
Choose one solution:
Try fetching files by git clone.
I just updated this repo. Try it out! It's easier now! (Follow the new README instructions)

Cannot install composer on OS X Yosemite the proper way

I'm following this tutorial. I need to install Laravel but I can not get pass through Composer.
Running a line like curl -sS https://getcomposer.org/installer | php is relatively easy.
I also moved it: sudo mv composer.phar /usr/local/bin/composer. I have added the PATH (export PATH="$PATH:~/.composer/vendor/bin”) by editing my .bash_profile, but no results. I can't get it to work.
Is there anyone who knows how to install composer properly?
Did you execute command?
export ~/.bash_profile
after editing this file (also reboot can be as alternative)?
Of course as quick hack you can use either php ~/.composer/vendor/bin/composer
or write hardcoded alias in ~/.bash_profile:
alias composer="~/.composer/vendor/bin/composer"
and after editing do not forget to execute export ~/.bash_profile
also check permissions if your current user can execute this file
I really appreciate all the answers above. They all helped to a final answer.
It seems that creating an alias inside the .bash_profile with the right path was solution. As of right now I can type "composer" and it will run.
The route points directly to where my composer.phar is currently installed.
A reboot was necessary as well.
alias composer="usr/local/bin/composer/composer.phar"

"Error in exception handler" seen on fresh install

Just installed by the spec of the doc's larval. I am running on Ubuntu with Nginx as my server. Once I got it installed all I see is a white page and nothing else other than the words
Error in exception handler
In my actual error logs I see
Options FollowSymLinks or SymLinksIfOwnerMatch is off which implies that RewriteRule directive is forbidden: /var/www/vhosts/dir/dir/dir/dir.com/public/index.pl
note: that I replaced the dir path here, with dir/dir/dir/dir...
Neither of which lead me to any conclusive examples of how to fix it or trouble shoot it. Soo. I am coming here hoping someone can help me solve this so I can attempt to use Laravel
Ok, I am sure this will not answer everyones question to this problem, nor is it a solution I am fully happy with. I will have to research my server a little more for a better answer.
All in all what I ended up finding out through some digging is a particular directory needed to have write access. So for me to do that with my current server settings was to
sudo chmod -R guo+w app/storage
from the command line to allow global write privileges to the app/storage directory
I generally the artisan serve with sudo. This will give artisan all the permissions it needs and won't make any security troubles as well.
so instead starting artisan serve with:
$ php artisan serve
try using:
$ sudo php artisan serve
thus you wont have to make any permission changes

Laravel 4 PHP Not Found

I am trying to setup my first laravel project. I am running XAMPP for Linux (LAMPP) and I installed composer in /opt/lampp/bin/php.
I then cd /opt/lampp/htdocs
I then run: /opt/lampp/bin/php composer.phar create-project laravel/laravel new_proj --prefer-dist
Everything seems to be going great for the install then I get
Script php artisan optimize handling the post-install-cmd event returned with an error
[Runtime Exception]
Error Output: sh: 1: php: not found
I have PHP 5.4.
I think I understand the error but I don't know Laravel well enough to solve this. I have searched for this and can't seem to find an answer.
Also I can't seem to find a good starting point for trying to install this on XAMPP for Linux (LAMPP). Any help here would be greatly appreciated.
Problem was that I did not specify
/opt/lampp/bin
in my Path so it could not find PHP and more specifically it could not find the version of PHP that I was using in LAMPP. So I added
Path=$PATH:/opt/lampp/bin
to my ~/.bashrc file then I was able to successfully install laravel. Next issue that came up after that was setting permissions on the appropriate folders.
Permissions Problem, See Below:
Set permission for your project folder: sudo chmod 755 -R laravel_proj_name
Set permission for your project storage folder:
sudo chmod o+w -R laravel_proj_name/app/storage
Refresh Page, Good to Go!
I think the problem is that the PHP CLI binary is not in your path. Try adding it to your path or putting a symbolic link into /usr/bin or some other appropriate place.

phpredis on fedora 12

I am trying to install phpredis to work with my php.
But the thing is, every time I try to get it to work, my error_log sends this error:
[code]PHP Fatal error: Class 'Redis' not found in /var/www/html/testme.php on line 5[/code]
I have downloaded the source code from http://github.com/owlient/phpredis
and then
phpize
./configure
make && make install
but still not working.
What can I do now?
specifically, created a redis.ini:
$ cat /etc/php5/apache2/conf.d/redis.ini
;configure the redis module
extension=redis.so
I filed a github issue, hopefully they'll make it create the ini automatically, or at least explain in the install instructions:
https://github.com/owlient/phpredis/issues/94
I got it to work.
I had to give the full path in php.ini, restarted httpd and voila it works :D

Categories