I recently installed the Bitnami Phabricator VM, and I’ve run into a major issue that made it relatively impossible to use phabricator.
After SEVERAL hours of fiddling, searching, and doing whatever I could to fix the following error that I kept getting when trying to push to a Git repository on the Phabricator instance:
remote: STDERR remote: git: error while loading shared libraries: libiconv.so.2: cannot open shared object file: No such file or directory
I realized that the shared library libiconv was not installed on the system. The fix involves downloading the library from GNU, compiling, and installing it. The library can be found here https://www.gnu.org/software/libiconv/. Here are the steps needed to fix the issue:
While logged in as the bitnami user, I used
sudo su before performing any of the following commands:
First, get libiconv from GNU using wget (be sure to check if there is a newer version available):
# wget https://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.11.tar.gz
Extract the file using tar:
# tar -xzvf libiconv-1.11.tar.gz
CD into the directory
# cd libiconv-1.11
Configure the location for the library to be installed into (this may take some time)
# ./configure --prefix=/usr/local
Build the library (this may take some time)
Install the library (this may also take some time)
# make install
Add /usr/local/lib to /etc/ld.so.conf
# echo "/usr/local/lib" >> /etc/ld.co.conf
# sudo ldconfig
And thats it! Reboot the VM just to be sure, and everything should work. Ideally, if the bitnami debian image had libiconv installed by default this wouldn’t be an issue. The image I used didn’t have that shared library unfortunately.
Hope this helps!