sdate command not found

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

Introduction

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

sdate: command not found

or when using sudo you get the following error message

sudo: sdate: command not found

Solutions to sdate: command not found

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

In Ubuntu sdate is provided by sdate package.

sdate is:

sdate wraps the libc localtime() and gmtime() functions to output the eternal september 1993 date.

sdate works like fakeroot (on which its code is based) by setting LD_PRELOAD to a wrapper library.

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

sudo apt-get -y install sdate

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

You can also use apt command to install sdate.

sudo apt -y install sdate

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

sudo aptitude install sdate

Summary

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