How to Install mlocate (locate and updatedb Commands) on CentOS 7

As root:

yum -y update
Then let’s install mlocate and any required packages:
yum -y install mlocate
The following command will update the search databases:
mlocate installs a cron job that will run daily to update search databases at:

VI – Display line number

To set it as env variable in .exrc file, default location = home dir

[server ~]$ cd
[server ~]$ pwd
[server ~]$ ls -al .exrc
ls: cannot access .exrc: No such file or directory
[server ~]$ echo “set number” > .exrc
[server ~]$ cat .exrc
set number

Or else, while editing:
:set nember
(to enable)

:set nonumber
(to disable)