"which" command in Linux

which is a powerful command used in SSH environment to find out path of perl script, php executables, sendmail and many other linux utilities.

Try the following in SSH:


which php

>>> Results: /usr/local/bin/php
(Results will reflect according to your server settings)

which perl

>>> Results: /usr/local/bin/perl
(Results will reflect according to your server settings)

You can try this command for sendmail and other script locations.


  • 647 Users Found This Useful

Was this answer helpful?

Related Articles

How Can I Test My Website Before Switching DNS?

It is always important to test your website on a new web host before you change the Nameservers...

What are the Differences Between Forward Proxy and Reverse Proxy?

Generally, there are two types of proxy servers available which are Forward Proxy and Reverse...

How to modify a hosts file in Windows 7, Windows 8/10, Mac OS and Ubuntu?

By Editing Host File, you can point IP Address for a Domain in your local system.   Windows 7 :...

How to check Ping Report from Windows 7, 8 and 10?

You can use our Ping testing tool to test Ping alert from your local system to our Denver...

How to enable "I'm Under Attack" mode in CloudFlare Panel?

Cloudflare provides additional protection called "I m under attack" for a website which is under...