How to find where php.ini is in Linux

WBOY
Release: 2022-03-21 16:57:05
Original
4478 people have browsed it

In Linux, you can use the find command to find where "php.ini" is. The function of this command is to find files in the specified directory. Use the "name" parameter to set query conditions. You can search based on the file name. , the syntax is "sudo find / -name 'php.ini'".

How to find where php.ini is in Linux

#The operating environment of this tutorial: linux7.3 system, Dell G3 computer.

How to find where php.ini is in Linux

Use sudo find / -name 'php.ini' command, the example is as follows:

How to find where php.ini is in Linux

Linux find command is used to find files in the specified directory. Any string preceding the parameter will be treated as the name of the directory to be searched. If you use this command without setting any parameters, the find command will search for subdirectories and files in the current directory. And all found subdirectories and files will be displayed.

Grammar

find   path   -option   [   -print ]   [ -exec   -ok   command ]   {} \;
Copy after login

Parameter description:

find determines path and expression according to the following rules. The first - (), ! on the command line is path. , followed by expression. If path is an empty string, the current path is used. If expression is an empty string, -print is used as the default expression. There are as many as twenty or thirty options available in

expression. Only the most commonly used ones are introduced here.

-mount, -xdev: Only check files in the same file system as the specified directory, avoid listing files in other file systems

-amin n: In the past n minutes Read

-anewer file: A file that has been read later than file file

-atime n: A file that has been read in the past n days

-cmin n : Files that have been modified in the past n minutes

-cnewer file : Files that are newer than file file

-ctime n : Files that have been modified in the past n days

-empty: empty file -gid n or -group name: gid is n or group name is name

-ipath p, -path p: file whose path name matches p, ipath will Ignore case

-name name, -iname name: The file name matches name. iname will ignore case

-size n : The file size is n units, b represents a block of 512 bytes, c represents the number of characters, k represents kilo bytes, and w is two bytes.

-type c : The file type is c.

Related recommendations: "Linux Video Tutorial"

The above is the detailed content of How to find where php.ini is in Linux. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!