System Administration Commands removef(1M)
NAME
removef - remove a file from software database
SYNOPSIS
removef [ [-M] -R rootpath] [-V fsfile] pkginst path...
removef [ [-M] -R rootpath] [-V fsfile] -f pkginst
DESCRIPTION
removef informs the system that the user, or software,
intends to remove a pathname. Output from removef is the
list of input pathnames that may be safely removed (no other
packages have a dependency on them).
OPTIONS
The following options are supported:
-f
After all files have been processed, removef should be
invoked with the -f option to indicate that the removal
phase is complete.
-M
Instruct removef not to use the $rootpath/etc/vfstab
file for determining the client's mount points. This
option assumes the mount points are correct on the
server and it behaves consistently with Solaris 2.5 and
earlier releases.
-R rootpath
Define the full path name of a directory to use as the
rootpath. All files, including package system informa-
tion files, are relocated to a directory tree starting
in the specified rootpath. The rootpath may be speci-
fied when installing to a client from a server (for
example, /export/root/client1).
removef inherits the value of the PKGINSTALROT
environment variable. (See ENVIRONMENT VARIABLES,
below.) If PKGINSTALROT is set, such as when the -R
option is used with pkgadd(1M) or pkgrm(1M), there is no
need to use the removef -R option.
Note -
SunOS 5.11 Last change: 30 Oct 2007 1
System Administration Commands removef(1M)
The root file system of any non-global zones must not
be referenced with the -R option. Doing so might dam-
age the global zone's file system, might compromise
the security of the global zone, and might damage the
non-global zone's file system. See zones(5).
-V fsfile
Specify an alternative fsfile to map the client's file
systems. For example, used in situations where the
$rootpath/etc/vfstab file is non-existent or unreli-
able.
OPERANDS
The following operands are supported:
path
The pathname to be removed.
pkginst
The package instance from which the pathname is being
removed.
EXAMPLES
Example 1 Using removef
The following example uses the removef command in an
optional pre-install script:
echo "The following files are no longer part of this package
and are being removed."
removef $PKGINST /myapp/file1 /myapp/file2
while read pathname
do
echo "$pathname"
rm -f $pathname
done
removef -f $PKGINST exit 2
ENVIRONMENT VARIABLES
removef inherits the value of the following environment
variable. This variable is set when pkgadd(1M) or pkgrm(1M)
SunOS 5.11 Last change: 30 Oct 2007 2
System Administration Commands removef(1M)
is invoked with the -R option.
PKGINSTALROT
If present, defines the full path name of a directory to
use as the system's PKGINSTALROT path. All product
and package information files are then looked for in the
directory tree, starting with the specified
PKGINSTALROT path. If not present, the default sys-
tem path of / is used.
EXIT STATUS
0
Successful completion.
>0
An error occurred.
ATRIBUTES
See attributes(5) for descriptions of the following attri-
butes:
ATRIBUTE TYPE ATRIBUTE VALUE
Availability SUNWcsu
SEE ALSO
pkginfo(1), pkgmk(1), pkgparam(1), pkgproto(1), pkgtrans(1),
installf(1M), pkgadd(1M), pkgask(1M), pkgchk(1M), pkgrm(1M),
attributes(5), largefile(5)
NOTES
Package commands are largefile(5)-aware. They handle files
larger than 2 GB in the same way they handle smaller files.
In their current implementations, pkgadd(1M), pkgtrans(1)
and other package commands can process a datastream of up
to 4 GB.
SunOS 5.11 Last change: 30 Oct 2007 3
|