why "php -i|grep php.ini" is not finding the correct path to php.ini?

I know that my php.ini is located at /etc/php.ini but when i run php -i|grep php.ini I get this output

Configuration File (php.ini) Path => /usr/local/lib

there's nothing in that directory and i know where my php.ini is located, so why am i getting this output?


When you run "which php" what does it give as an answer? How did you install php? It sounds like you have 2 versions of php running on your server.