I used linux command watch sensors to watch my sensors before. However I have installed many packages and now watch command watches for changes in current directory. How can I run watch sensors as before? (I would prefer to have stayed the new watch directory command)

~# type -a watch
watch is /usr/local/bin/watch
watch is /usr/bin/watch

~$ dpkg -S $(which watch)
dpkg-query: no path found matching pattern /usr/local/bin/watch

~# apt-cache policy procps
  Installed: 1:3.3.9-1ubuntu2.2
  Candidate: 1:3.3.9-1ubuntu2.2
  Version table:
 *** 1:3.3.9-1ubuntu2.2 0
        500 http://ua.archive.ubuntu.com/ubuntu/ trusty-updates/main amd64 Packages
        100 /var/lib/dpkg/status
     1:3.3.9-1ubuntu2 0
        500 http://ua.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages

Seems like watch now is a node.js script. How can I run linux watch command?

  • 1
    Please edit your question and show us the output of type watch and dpkg -S $(which watch).
    – terdon
    Nov 9, 2015 at 22:13
  • Seems you have installed watch locally..the question is whether the watch from procps is still there....What are the outputs of apt-cache policy procps and type -a watch?
    – heemayl
    Nov 10, 2015 at 7:51

1 Answer 1


As seen, your PATH contains /usr/local/bin before /usr/bin, hence the watch you have installed by compiling locally (/usr/local/bin/watch) is having the precedence over original watch (/usr/bin/watch). Another very unlikely case is that /usr/bin is not in your PATH.

You have some solution options now:

  • Rename the local watch (/usr/local/bin) as something else, given renaming won't create any problem

  • Edit your PATH to have /usr/bin before /usr/local/bin, again if would create no problem:

  • Make an alias:

    alias watch=/usr/bin/watch
  • Use full path:

  • Great answer. I have chosen option 1 (renamed /usr/local/bin/watch to fs_watch
    – Solvek
    Nov 10, 2015 at 9:08

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .