• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

more: command not found

by admin

Both the less and more commands are similar in that they enable you to display the contents of a file and page through those contents if they extend beyond the screen. The less command typically has additional features that more doesn’t, but newer versions of more have added some of those features. While you’re free to use either command, the less command is generally preferred.

Syntax

The syntax of the more command is:

$ more [options] {file names}

If you encounter the below error while running the more command:

less: command not found

you may try installing the below package as per your choice of distribution:

Distribution Command
OS X brew install util-linux
Debian apt-get install util-linux
Ubuntu apt-get install util-linux
Alpine apk add util-linux
Arch Linux pacman -S util-linux
Kali Linux apt-get install util-linux
CentOS yum install util-linux
Fedora dnf install util-linux
Raspbian apt-get install util-linux

more Command Examples

1. Open a file:

$ more path/to/file

2. Open a file displaying from a specific line:

$ more +line_number path/to/file

3. Display help:

$ more --help

4. Go to the next page:

[Space]

5. Search for a string (press `n` to go to the next match):

/something

6. Exit from more command:

q

7. Display help about interactive commands:

h

less V/s more

Because more is relatively old, most will argue that less is far superior. The less command is similar to more, but less will allow you to navigate back and forth between paged results. So yes, it’s an old joke, but from now on, and wherever possible, always know that less really does mean more.

Filed Under: Linux

Some more articles you might also be interested in …

  1. Nginx load balancing
  2. Configuring sudo to Enable Commands for Non-Root Users in Linux
  3. How to Clone Linux disk partition over network using dd
  4. mycli Command Examples in Linux
  5. avahi-browse Command Examples in Linux
  6. logger Command Examples in Linux
  7. What is Soft Links and Hard Links in Linux File System
  8. Understanding mpathconf Utility to configure DM-Multipath
  9. rmmod Command Examples in Linux
  10. openfortivpn: command not found

You May Also Like

Primary Sidebar

Recent Posts

  • diffstat: Create a histogram from the output of the diff command
  • diffoscope: Compare files, archives, and directories
  • diff-pdf: Tool for comparing two PDFs
  • dict: Command line dictionary using the DICT protocol

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright