Linux CLI - Searching and Finding
You run
locate *.log but get no results, even though you know log files exist. What is the likely problem?locate *.log but get no results, even though you know log files exist. What is the likely problem?locate *.log, the shell tries to expand *.log to matching files in the current directory before running locate.*.log files, the shell expands to those specific names (e.g., locate error.log access.log), so locate searches only for exact matches to those names system-wide, missing other .log files and causing incomplete or no results. The correct way is to quote the pattern: locate '*.log'.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions