logtail command not found

In this troubleshooting guide we learn how to fix logtail command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

logtail: command not found

or when using sudo you get the following error message

sudo: logtail: command not found

Solutions to logtail: command not found

How To Fix logtail: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu logtail is provided by logtail package.

logtail is:

This program will read in a standard text file and create an offset marker when it reads the end. The offset marker is read the next time logtail is run and the text file pointer is moved to the offset location. This allows logtail to read in the next lines of data following the marker. This is good for marking log files for automatic log file checkers to monitor system events.

The package also provides logtail2, which better deals with rotated log files: If logtail2 finds that the inode of the file was changed, it assumes that the log has been rotated, and tries to find the file it was rotated to using heuristic plugins. If it finds the file, it will print the remainder of the file starting at the offset saved to the offset file. If a file with the correct inode was not found, logtail2 will only print the new file in its entirety before writing a new offset file.

To fix this problem, we can install more using the command below.

sudo apt-get -y install logtail

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install logtail.

sudo apt -y install logtail

Or if you have aptitude installed you can use the following command.

sudo aptitude install logtail

Summary

In this tutorial we learn how to fix logtail command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.