In Linux, it is important to check the installation path (address) of a software. For example, if a file's quick start item is deleted, you need to create a quick start item, or you want to delete or add an installation file, the command of the installation path of the file should be used in many places. Here we will introduce the Linux command for viewing the file installation path (address. 1. view the file installation path: because there are more than one place where the software is installed, check the file security first.
LinuxMediumViewA softwareInstallation Path(Address) is sometimes very important. For example, if a file's quick start item is deleted, you need to create a quick start item, or you want to delete or add an installation file, the command of the installation path of the file should be used in many places.
Here we will introduce you to LinuxView the file installation path (address) command.
1. view the file installation path:
Since there are more than one place for software installation, let's first check all the paths (addresses) for file installation ).
Here we useOracleFor example. For example, if I have installed Oracle, but I don't know where the files are installed and in which folders, you can use the following command to view all the file paths.
Enter at the terminal:
whereis oracle
Press Enter. if you have installed Oracle, the file installation address will be displayed, for example, my display (the installation address may be different)
oracle: /usr/bin/oracle /usr/lib/oracle /usr/share/oracle /usr/share/man/man1/oracle.1.gz
It can be seen that Oracle is installed in a directory.
If you have not installed Oracle or Oracle, the file path is not displayed. Only prompt:
oracle:
2. query the path of the running file:
If you only need to query the address of the file running file, you can directly use the following command (or take Oracle as an example ):
which oracle
The result is displayed as follows:
/usr/bin/oracle