<< Back to man.ChinaUnix.net

4. Useful FreeBSD Commands

If you've come from a Windows background, here are a few commands that will help you find your way around.

Finding Files Using FreeBSD

Make sure the locate database is updated after you install packages. This will let you find files that have been recently installed.

Update the locate database:

#/usr/libexec/locate.updatedb

Now you can find files by running the locate command, an example is listed below.

# locate check_oracle
/usr/local/libexec/nagios/check_oracle
/usr/ports/net-mgmt/nagios-plugins/work/nagios-plugins-1.4/contrib/check_oracle_instance.pl
/usr/ports/net-mgmt/nagios-plugins/work/nagios-plugins-1.4/contrib/check_oracle_tbs
/usr/ports/net-mgmt/nagios-plugins/work/nagios-plugins-1.4/plugins-scripts/check_oracle
/usr/ports/net-mgmt/nagios-plugins/work/nagios-plugins-1.4/plugins-scripts/check_oracle.sh

You probably won't have check_oracle on your system yet, this is just to illustrate how the command works.