Replace all occurances of 'pkgng' with 'pkg' in the handbook
Kept existing xml:id's to avoid breaking external links to the documentation Sanitized the documentation of references to pkg_add Fix an incorrect variable name: daily_backup_pkgng_enable should be daily_backup_pkgdb_enable Fix a linebreak in the middle of a variable name Clarify that pkg2ng is not a required step on newer systems Approved by: bcr Sponsored by: ScaleEngine Inc.
This commit is contained in:
parent
12eae1c8b1
commit
9ebd6001cc
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=45559
1 changed files with 37 additions and 37 deletions
|
@ -37,7 +37,7 @@
|
||||||
|
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>How to manage binary packages using
|
<para>How to manage binary packages using
|
||||||
<application>pkgng</application>.</para>
|
<application>pkg</application>.</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
|
||||||
<listitem>
|
<listitem>
|
||||||
|
@ -102,7 +102,7 @@
|
||||||
<para>A &os; package contains pre-compiled copies of all the
|
<para>A &os; package contains pre-compiled copies of all the
|
||||||
commands for an application, as well as any configuration files
|
commands for an application, as well as any configuration files
|
||||||
and documentation. A package can be manipulated with the
|
and documentation. A package can be manipulated with the
|
||||||
<application>pkgng</application> commands, such as
|
<application>pkg</application> commands, such as
|
||||||
<command>pkg install</command>.</para>
|
<command>pkg install</command>.</para>
|
||||||
|
|
||||||
<para>A &os; port is a collection of files designed to automate
|
<para>A &os; port is a collection of files designed to automate
|
||||||
|
@ -407,11 +407,11 @@ Info: Lists information about open files (similar to fstat(1))</screen>
|
||||||
<para>At the present time, &os; is transitioning toward a new
|
<para>At the present time, &os; is transitioning toward a new
|
||||||
method of package management. Users
|
method of package management. Users
|
||||||
may wish to investigate the benefits of using
|
may wish to investigate the benefits of using
|
||||||
<link linkend="pkgng-intro">PKGng</link> to manage third-party
|
<link linkend="pkgng-intro">pkg</link> to manage third-party
|
||||||
software on &os;. This section describes the traditional method
|
software on &os;. This section describes the traditional method
|
||||||
for managing binary packages and only applies to those users
|
for managing binary packages and only applies to those users
|
||||||
who have not yet migrated to the
|
who have not yet migrated to the
|
||||||
<application>pkgng</application> format.</para>
|
<application>pkg</application> format.</para>
|
||||||
|
|
||||||
<para>This method of package management uses a package database
|
<para>This method of package management uses a package database
|
||||||
directory, <filename>/var/db/pkg</filename>,
|
directory, <filename>/var/db/pkg</filename>,
|
||||||
|
@ -619,30 +619,30 @@ docbook =
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<sect1 xml:id="pkgng-intro">
|
<sect1 xml:id="pkgng-intro">
|
||||||
<title>Using <application>pkgng</application> for Binary Package
|
<title>Using <application>pkg</application> for Binary Package
|
||||||
Management</title>
|
Management</title>
|
||||||
|
|
||||||
<para><application>pkgng</application> is the next generation
|
<para><application>pkg</application> is the next generation
|
||||||
replacement for the traditional &os; package management tools,
|
replacement for the traditional &os; package management tools,
|
||||||
offering many features that make dealing with binary packages
|
offering many features that make dealing with binary packages
|
||||||
faster and easier.</para>
|
faster and easier.</para>
|
||||||
|
|
||||||
<para><application>pkgng</application> is not a replacement for
|
<para><application>pkg</application> is not a replacement for
|
||||||
port management tools like
|
port management tools like
|
||||||
<package>ports-mgmt/portmaster</package> or
|
<package>ports-mgmt/portmaster</package> or
|
||||||
<package>ports-mgmt/portupgrade</package>. These tools can be
|
<package>ports-mgmt/portupgrade</package>. These tools can be
|
||||||
used to install third-party software from both binary packages
|
used to install third-party software from both binary packages
|
||||||
and the Ports Collection, while
|
and the Ports Collection, while
|
||||||
<application>pkgng</application> installs only binary
|
<application>pkg</application> installs only binary
|
||||||
packages.</para>
|
packages.</para>
|
||||||
|
|
||||||
<sect2 xml:id="pkgng-initial-setup">
|
<sect2 xml:id="pkgng-initial-setup">
|
||||||
<title>Getting Started with
|
<title>Getting Started with
|
||||||
<application>pkgng</application></title>
|
<application>pkg</application></title>
|
||||||
|
|
||||||
<para>&os; 8.4 and later includes a bootstrap utility
|
<para>&os; 8.4 and later includes a bootstrap utility
|
||||||
which can be used to download and install
|
which can be used to download and install
|
||||||
<application>pkgng</application>, along with its manual
|
<application>pkg</application>, along with its manual
|
||||||
pages.</para>
|
pages.</para>
|
||||||
|
|
||||||
<para>To bootstrap the system, run:</para>
|
<para>To bootstrap the system, run:</para>
|
||||||
|
@ -650,7 +650,7 @@ docbook =
|
||||||
<screen>&prompt.root; <userinput>/usr/sbin/pkg</userinput></screen>
|
<screen>&prompt.root; <userinput>/usr/sbin/pkg</userinput></screen>
|
||||||
|
|
||||||
<para>For earlier &os; versions,
|
<para>For earlier &os; versions,
|
||||||
<application>pkgng</application> must instead be installed
|
<application>pkg</application> must instead be installed
|
||||||
from the Ports Collection or as a binary package.</para>
|
from the Ports Collection or as a binary package.</para>
|
||||||
|
|
||||||
<para>To install the port, run:</para>
|
<para>To install the port, run:</para>
|
||||||
|
@ -659,24 +659,25 @@ docbook =
|
||||||
&prompt.root; <userinput>make</userinput>
|
&prompt.root; <userinput>make</userinput>
|
||||||
&prompt.root; <userinput>make install clean</userinput></screen>
|
&prompt.root; <userinput>make install clean</userinput></screen>
|
||||||
|
|
||||||
<para>To install the binary package, run:</para>
|
<para>When upgrading an existing system that originally used the
|
||||||
|
older package system, the database must be converted to the
|
||||||
<screen>&prompt.root; <userinput>pkg_add -r pkg</userinput></screen>
|
new format, so that the new tools are aware of the already
|
||||||
|
installed packages. Once <application>pkg</application> has
|
||||||
<para>Once <application>pkgng</application> is installed, the
|
been installed, the
|
||||||
package database must be converted from the traditional format
|
package database must be converted from the traditional format
|
||||||
to the new format by running this command:</para>
|
to the new format by running this command:</para>
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>pkg2ng</userinput></screen>
|
<screen>&prompt.root; <userinput>pkg2ng</userinput></screen>
|
||||||
|
|
||||||
<para>This step is not required for new installations that do
|
<note><para>This step is not required for new installations that
|
||||||
not yet have any third-party software installed.</para>
|
do not yet have any third-party software
|
||||||
|
installed.</para></note>
|
||||||
|
|
||||||
<important>
|
<important>
|
||||||
<para>This step is not reversible. Once the package database
|
<para>This step is not reversible. Once the package database
|
||||||
has been converted to the <application>pkgng</application>
|
has been converted to the <application>pkg</application>
|
||||||
format, the traditional <literal>pkg_*</literal> tools
|
format, the traditional <literal>pkg_*</literal> tools
|
||||||
should not be used.</para>
|
should no longer be used.</para>
|
||||||
</important>
|
</important>
|
||||||
|
|
||||||
<note>
|
<note>
|
||||||
|
@ -689,28 +690,28 @@ docbook =
|
||||||
</note>
|
</note>
|
||||||
|
|
||||||
<para>To ensure that the &os; Ports Collection registers
|
<para>To ensure that the &os; Ports Collection registers
|
||||||
new software with <application>pkgng</application>, and not
|
new software with <application>pkg</application>, and not
|
||||||
the traditional packages format, &os; versions earlier than
|
the traditional packages format, &os; versions earlier than
|
||||||
10.<replaceable>X</replaceable> require this line in
|
10.<replaceable>X</replaceable> require this line in
|
||||||
<filename>/etc/make.conf</filename>:</para>
|
<filename>/etc/make.conf</filename>:</para>
|
||||||
|
|
||||||
<programlisting>WITH_PKGNG= yes</programlisting>
|
<programlisting>WITH_PKGNG= yes</programlisting>
|
||||||
|
|
||||||
<para>The <application>pkgng</application> package management
|
<para>The <application>pkg</application> package management
|
||||||
system uses a package repository for most operations. The
|
system uses a package repository for most operations. The
|
||||||
default package repository location is defined in
|
default package repository location is defined in
|
||||||
<filename>/usr/local/etc/pkg.conf</filename> or by the
|
<filename>/usr/local/etc/pkg.conf</filename> or by the
|
||||||
<envar>PACKAGESITE</envar> environment variable, which
|
<envar>PACKAGESITE</envar> environment variable, which
|
||||||
overrides the configuration file.</para>
|
overrides the configuration file.</para>
|
||||||
|
|
||||||
<para>Additional <application>pkgng</application>
|
<para>Additional <application>pkg</application>
|
||||||
configuration options are described in pkg.conf(5).</para>
|
configuration options are described in pkg.conf(5).</para>
|
||||||
|
|
||||||
<para>Usage information for <application>pkgng</application> is
|
<para>Usage information for <application>pkg</application> is
|
||||||
available in pkg(8) or by running
|
available in pkg(8) or by running
|
||||||
<command>pkg</command> without additional arguments.</para>
|
<command>pkg</command> without additional arguments.</para>
|
||||||
|
|
||||||
<para>Each <application>pkgng</application> command argument is
|
<para>Each <application>pkg</application> command argument is
|
||||||
documented in a command-specific manual page. To read the
|
documented in a command-specific manual page. To read the
|
||||||
manual page for <command>pkg install</command>, for example,
|
manual page for <command>pkg install</command>, for example,
|
||||||
run either of these commands:</para>
|
run either of these commands:</para>
|
||||||
|
@ -721,7 +722,7 @@ docbook =
|
||||||
|
|
||||||
<para>The rest of this section demonstrates common binary
|
<para>The rest of this section demonstrates common binary
|
||||||
package management tasks which can be performed using
|
package management tasks which can be performed using
|
||||||
<application>pkgng</application>. Each demonstrated command
|
<application>pkg</application>. Each demonstrated command
|
||||||
provides many switches to customize its use. Refer to a
|
provides many switches to customize its use. Refer to a
|
||||||
command's help or man page for details and more
|
command's help or man page for details and more
|
||||||
examples.</para>
|
examples.</para>
|
||||||
|
@ -737,7 +738,7 @@ docbook =
|
||||||
package.</para>
|
package.</para>
|
||||||
|
|
||||||
<para>For example, to see which version of
|
<para>For example, to see which version of
|
||||||
<application>pkgng</application> is installed, run:</para>
|
<application>pkg</application> is installed, run:</para>
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>pkg info pkg</userinput>
|
<screen>&prompt.root; <userinput>pkg info pkg</userinput>
|
||||||
pkg-1.1.4_1</screen>
|
pkg-1.1.4_1</screen>
|
||||||
|
@ -825,7 +826,7 @@ Proceed with deleting packages [y/N]: <userinput>y</userinput>
|
||||||
|
|
||||||
<para>Occasionally, software vulnerabilities may be discovered
|
<para>Occasionally, software vulnerabilities may be discovered
|
||||||
in third-party applications. To address this,
|
in third-party applications. To address this,
|
||||||
<application>pkgng</application> includes a built-in auditing
|
<application>pkg</application> includes a built-in auditing
|
||||||
mechanism. To determine if there are any known
|
mechanism. To determine if there are any known
|
||||||
vulnerabilities for the software installed on the system,
|
vulnerabilities for the software installed on the system,
|
||||||
run:</para>
|
run:</para>
|
||||||
|
@ -855,7 +856,7 @@ Deinstalling ca_root_nss-3.15.1_1... done</screen>
|
||||||
<title>Backing Up the Package Database</title>
|
<title>Backing Up the Package Database</title>
|
||||||
|
|
||||||
<para>Unlike the traditional package management system,
|
<para>Unlike the traditional package management system,
|
||||||
<application>pkgng</application> includes its own package
|
<application>pkg</application> includes its own package
|
||||||
database backup mechanism. To manually back up the contents
|
database backup mechanism. To manually back up the contents
|
||||||
of the package database, run the following command, replacing
|
of the package database, run the following command, replacing
|
||||||
<replaceable>pkgng.db</replaceable> with a suitable file
|
<replaceable>pkgng.db</replaceable> with a suitable file
|
||||||
|
@ -863,16 +864,15 @@ Deinstalling ca_root_nss-3.15.1_1... done</screen>
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>pkg backup -d <replaceable>pkgng.db</replaceable></userinput></screen>
|
<screen>&prompt.root; <userinput>pkg backup -d <replaceable>pkgng.db</replaceable></userinput></screen>
|
||||||
|
|
||||||
<para>Additionally, <application>pkgng</application> includes
|
<para>Additionally, <application>pkg</application> includes
|
||||||
a &man.periodic.8; script to automatically perform a daily
|
a &man.periodic.8; script to automatically perform a daily
|
||||||
back up of the package database. This functionality is
|
back up of the package database. This functionality is
|
||||||
enabled if <literal>daily_backup_pkgng_enable</literal> is
|
enabled if <literal>daily_backup_pkgdb_enable</literal> is
|
||||||
set to <literal>YES</literal> in &man.periodic.conf.5;.</para>
|
set to <literal>YES</literal> in &man.periodic.conf.5;.</para>
|
||||||
|
|
||||||
<tip>
|
<tip>
|
||||||
<para>To disable the periodic script from backing up the
|
<para>To disable the periodic script from backing up the
|
||||||
package database, set <literal>daily_backup_pkgdb_
|
package database, set <literal>daily_backup_pkgdb_enable</literal> to <literal>NO</literal> in
|
||||||
enable</literal> to <literal>NO</literal> in
|
|
||||||
&man.periodic.conf.5;.</para>
|
&man.periodic.conf.5;.</para>
|
||||||
</tip>
|
</tip>
|
||||||
|
|
||||||
|
@ -885,7 +885,7 @@ Deinstalling ca_root_nss-3.15.1_1... done</screen>
|
||||||
<sect2 xml:id="pkgng-clean">
|
<sect2 xml:id="pkgng-clean">
|
||||||
<title>Removing Stale Packages</title>
|
<title>Removing Stale Packages</title>
|
||||||
|
|
||||||
<para>By default, <application>pkgng</application> stores
|
<para>By default, <application>pkg</application> stores
|
||||||
binary packages in a cache directory defined by
|
binary packages in a cache directory defined by
|
||||||
<envar>PKG_CACHEDIR</envar> in pkg.conf(5). When upgrading
|
<envar>PKG_CACHEDIR</envar> in pkg.conf(5). When upgrading
|
||||||
packages with <command>pkg upgrade</command>, old versions
|
packages with <command>pkg upgrade</command>, old versions
|
||||||
|
@ -901,7 +901,7 @@ Deinstalling ca_root_nss-3.15.1_1... done</screen>
|
||||||
|
|
||||||
<para>Software within the &os; Ports Collection can
|
<para>Software within the &os; Ports Collection can
|
||||||
undergo major version number changes. To address this,
|
undergo major version number changes. To address this,
|
||||||
<application>pkgng</application> has a built-in command to
|
<application>pkg</application> has a built-in command to
|
||||||
update package origins. This can be useful, for example, if
|
update package origins. This can be useful, for example, if
|
||||||
<package>lang/php5</package> is renamed to
|
<package>lang/php5</package> is renamed to
|
||||||
<package>lang/php53</package> so that
|
<package>lang/php53</package> so that
|
||||||
|
@ -1014,7 +1014,7 @@ Deinstalling ca_root_nss-3.15.1_1... done</screen>
|
||||||
&prompt.root; <userinput>make install clean</userinput></screen>
|
&prompt.root; <userinput>make install clean</userinput></screen>
|
||||||
|
|
||||||
<para>If the ports tree is not available, or
|
<para>If the ports tree is not available, or
|
||||||
<application>pkgng</application> is being used to manage
|
<application>pkg</application> is being used to manage
|
||||||
packages, <application>Subversion</application> can be
|
packages, <application>Subversion</application> can be
|
||||||
installed as a package:</para>
|
installed as a package:</para>
|
||||||
|
|
||||||
|
@ -1361,7 +1361,7 @@ The deinstallation will free 229 kB
|
||||||
<xref linkend="ports-using-portsnap-method"/> or
|
<xref linkend="ports-using-portsnap-method"/> or
|
||||||
<xref linkend="ports-using-subversion-method"/>. On &os; 10
|
<xref linkend="ports-using-subversion-method"/>. On &os; 10
|
||||||
and later, or if the system has been converted to
|
and later, or if the system has been converted to
|
||||||
<application>pkgng</application>, the following command will
|
<application>pkg</application>, the following command will
|
||||||
list the installed ports which are out of date:</para>
|
list the installed ports which are out of date:</para>
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>pkg version -l "<"</userinput></screen>
|
<screen>&prompt.root; <userinput>pkg version -l "<"</userinput></screen>
|
||||||
|
|
Loading…
Reference in a new issue