Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
PKG-CHECK(8)		     System Manager's Manual		    PKG-CHECK(8)

NAME
     pkg check -- sanity check installed packages

SYNOPSIS
     pkg check -d|-s|-m [-nqvy] -a
     pkg check -d|-s|-m [-nqvy] [-Cgix] pattern

     pkg check --{dependencies,checksums,metadata}
	 [--{dry-run,quiet,verbose,yes}] --all
     pkg check --{dependencies,checksums,metadata}
	 [--{dry-run,quiet,verbose,yes}]
	 [--{case-sensitive,glob,case-insensitive,regex}] pattern

DESCRIPTION
     pkg  check  -d  or pkg check --dependencies checks for and installs missing
     dependencies.

     pkg check -m or pkg check --metadata checks for metadata discrepancies  be-
     tween the recorded state in pkgdb and the filesystem.

     pkg  check  -s or pkg check --checksums detects installed packages with in-
     valid checksums.  An invalid checksum can be caused by data  corruption  or
     tampering.

OPTIONS
     These options are supported by pkg check:

     -a, --all	   Process all packages.

     -C, --case-sensitive
		   Use case sensitive standard or regular expression (-x) match-
		   ing	  with	  pattern.    This   is   the	default   unless
		   CASE_SENSITIVE_MATCH has been set to false in pkg.conf.

     -d, --dependencies
		   Checks for and installs missing dependencies

     -g, --glob    Treat pattern as a shell glob pattern.

     -i, --case-insensitive
		   Use case insensitive  standard  or  regular	expression  (-x)
		   matching with pattern.

     -m, --metadata
		   Checks  for metadata discrepancies between the recorded state
		   in pkgdb and the filesystem.

     -n, --dry-run
		   Only check for missing dependencies, do not install them.

     -s, --checksums
		   Detects installed packages with invalid checksums

     -v, --verbose
		   Be verbose.

     -q, --quiet   Suppress most output, except for error messages and data that
		   the command explicitly requests.  This is primarily	intended
		   for scripting use.

     -x, --regex   Treat  pattern as a regular expression, using the "modern" or
		   "extended" syntax described in re_format(7).

     -y, --yes	   Assume "yes" when asked for	confirmation  before  installing
		   missing dependencies.

ENVIRONMENT
     These  environment  variables  affect  the  execution  of	pkg  check.  See
     pkg.conf(5) for additional information.

     PKG_DBDIR

     CASE_SENSITIVE_MATCH

FILES
     See pkg.conf(5).

EXAMPLES
     Test for missing dependencies needed by nano, installing any that are miss-
     ing:

	   pkg check -d nano

     Test the checksums of all installed packages to make  sure  none  are  cor-
     rupted:

	   pkg check -sa

     If corrupted packages are found, they can be reinstalled using:

	   pkg install -f <package-name>

SEE ALSO
     pkg_checksum(3),  pkg_create(3), pkg_printf(3), pkg_repo_create(3), pkg_re-
     pos(3),   pkg-keywords(5),   pkg-lua-script(5),   pkg-repository(5),   pkg-
     script(5),  pkg-triggers(5), pkg.conf(5), pkg(8), pkg-add(8), pkg-alias(8),
     pkg-annotate(8),  pkg-audit(8),  pkg-autoremove(8),  pkg-checksum(8),  pkg-
     clean(8),	pkg-config(8),	pkg-create(8), pkg-delete(8), pkg-fetch(8), pkg-
     help(8), pkg-info(8), pkg-install(8),  pkg-key(8),  pkg-lock(8),  pkg-plug-
     ins(8),  pkg-query(8),  pkg-register(8),  pkg-repo(8), pkg-repositories(8),
     pkg-rquery(8), pkg-rwhich(8), pkg-search(8), pkg-set(8), pkg-shell(8), pkg-
     shlib(8),	pkg-ssh(8),  pkg-stats(8),  pkg-triggers(8),  pkg-unregister(8),
     pkg-update(8),   pkg-updating(8),	 pkg-upgrade(8),   pkg-version(8),  pkg-
     which(8)

FreeBSD ports 15.quarterly	   May 2, 2024			    PKG-CHECK(8)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=pkg-check&sektion=8&manpath=FreeBSD+15.1-RELEASE+and+Ports.quarterly>

home | help