SFU Win32 Console Tools
This document lists the key Windows Services For UNIX utilities that can run
from a Windows command prompt.
autodfs
NAME
autodfs - Windows command-line utility to read automount maps and create
Distributed File System (DFS) links
SYNOPSISautodfs -r DfsRoot [-p DfsPath] -v AutomountFile
DESCRIPTION
The autodfs Windows command-line utility uses information in UNIX files
called automount maps to create DFS links. The file must follow the format shown
below. You must also use the Windows DFS administrative tools to create the DFS root
before you run autodfs.
The autodfs command accepts the following arguments and options:
-r DfsRoot
Specifies the name of the DFS root to which you want to add DFS links.
-p DfsPath
Specifies a node of the DFS root under which links to automount entries
are created. If DfsPath is not specified, automount links are created under the
DFS root.
-v
Turns on verbose output to display status messages.
AutoMountFile
The path to the automount file.
Automount file format
The lines in the automount file must follow this format:
MountPoint flags ServerPathToShare
MountPoint
The name of the file or volume to which you want to create a link.
flags
If flags are included in the file, they must be preceded by a minus sign (-).
The autodfs command ignores all flags.
ServerPathToShare
The path to the network file system (NFS) share.
basename
NAME
basename - Windows command-line utility to return file-name portion of path
name
SYNOPSISbasename string [suffix]
DESCRIPTION
The basename Windows command-line utility treats the string argument as a
path name. The string is converted to the file name corresponding to the last path-name
component in string, and then the suffix string, if present, is removed. The basename
command does this by performing actions equivalent to the following steps, in order:
1. If string consists entirely of a combination of slash (/) or backslash (\) characters,
string is set to the last character in string, and the remaining steps are skipped.
2. If there are any trailing slash or backslash characters in string, they are removed.
3. If there are any slash or backslash characters remaining in string, the prefix of
string up to and including the last slash or backslash character in string is
removed.
4. If the suffix operand is present, is not identical to the characters remaining in
string, and is identical to a suffix of the characters remaining in string, the suffix
string is removed from the end of string. Otherwise, string is not modified by this
step. It is not considered an error if suffix is not found in string.
The resulting string is written to standard output.
The basename(1w) command exits 0 on success, and >0 if an error occurs.
bgjob
NAME
bgjob - Windows command-line utility to run programs in the background
through Telnet Server
SYNOPSISbgjob {-h | command }
DESCRIPTION
The bgjob(1w) Windows command-line utility starts a process on a computer
running Telnet Server that continues to run after you end your Telnet session. Normally,
jobs started in a Telnet session are terminated when the session ends.
The bgjob utility takes the following arguments:
command
Specifies the command (and any required arguments) that should continue
to run after the Telnet session has closed.
-h
Displays help for the bgjob utility.
EXAMPLE
To start a Windows command that locates all dynamic-link libraries on the C:
drive and records the results in a file, type:
bgjob cmd.exe /c dir /b /s c:\*.dll > %temp%\dll.lst
cat
NAME
cat - Windows command-line utility to concatenate and print files
SYNOPSIScat [-benstuv] [file ...]
DESCRIPTION
The cat(1w) Windows command-line utility is an implementation of the Interix
cat(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see cat(1).
chgrp
NAME
chgrp - Windows command-line utility to change group
SYNOPSISchgrp [-fhR] group file...
DESCRIPTION
The chgrp(1w) Windows command-line utility is an implementation of the
Interix chgrp(1) command that you can run at a Windows command prompt. The file
argument must use Windows file-name and path syntax. For more information, see
chgrp(1).
chmod
NAME
chmod - Windows command-line utility to change file modes
SYNOPSISchmod [-R] mode file ...
DESCRIPTION
The chmod(1w) Windows command-line utility is an implementation of the
Interix chmod(1) command that you can run at a Windows command prompt. The file
argument must use Windows file-name and path syntax. For more information, see
chmod(1).
chown
NAME
chown - Windows command-line utility to change file owner and group
SYNOPSISchown [-fhR] [owner][:group] file ...
DESCRIPTION
The chown(1w) Windows command-line utility is an implementation of the
Interix chown(1) command that you can run at a Windows command prompt. The file
argument must use Windows file-name and path syntax. For more information, see
chown(1).
cp
NAME
cp - Windows command-line utility to copy files
SYNOPSIScp [-Rr] [-fip] src target
cp [-Rr] [-fip] src1 ... srcN directory
DESCRIPTION
The cp(1w) Windows command-line utility is an implementation of the Interix
cp(1) command that you can run at a Windows command prompt. The source_file,
target_file, and target_directory arguments must use Windows file-name and path
syntax. For more information, see cp(1).
cron
NAME
cron - Windows command-line utility to control Cron service
SYNOPSIScron [-install | -remove | -start | -stop | -help]
DESCRIPTION
The cron(1w) Windows command-line utility controls the Cron service, which
runs commands at specified dates and times.
The following arguments determine the action that the cron utility takes:
-install
Adds Cron service to the list of available Windows services.
-remove
Removes Cron service from the list of available Windows services.
-start
Starts (activates) Cron service.
-stop
Stops (deactivates) Cron service.
-help
Displays usage information.
SEE ALSO
Using Cron
crontab(1w)
crontab
NAME
crontab - Windows command-line utility to schedule periodic jobs to run in the
background
SYNOPSIScrontab [file] [-p]
crontab [-e|-l|-r] [-p]
DESCRIPTION
The crontab(1w) Windows command-line utility creates or changes your crontab
file. The crontab file contains a list of commands along with notation indicating when
each command is to be run. You can add the crontab file with one specified by file (or
standard input if you do not specify file), or you can use the command crontab -e to edit
the file directly.
You must be logged on as a member of the Administrators group to run the
crontab(1w) utility unless an administrator has given you cron privileges by placing your
user name in the cron.allow file or if your user name does not appear in the cron.deny file
and cron.allow does not exist.
The crontab(1w) utility takes the following options:
-e
Edits your crontab file; if there is no file, creates an empty one to edit.
-l
Lists your crontab file.
-r
Removes your crontab file.
-p
Prompts for and stores your password to run your tasks.
Format of the crontab file
A crontab file contains instructions to the Windows-based Cron service in the
form: at this time and day, run this command. Users who are allowed to run jobs that use
the Cron service have their own crontab file, which is located in %systemroot
%System32\Drivers\Etc\Cron\Crontabs.
Lines that begin with the number sign (#) are comments, which the Cron service
ignores. Do not include a comment on the same line as a command because it is treated as
part of the command.
A crontab command line consists of five time or date fields, each field separated
by spaces, and a sixth field, the command, completing the line. The command-line form
is as follows:
minute hour day_of_month month day_of_week command_string
Allowed field values
Except for the command string, you must specify all values as numeric; do not
use month and day names. The following values are allowed for the specified fields:
Field Allowed values
minute 0-59
hour 0-23
day_of_month 1-31
month 1-12
day_of_week 0-6 (corresponding to Sunday through Saturday)
A field can also be an asterisk (*), which matches any allowed value for the field.
For example, an asterisk in the day_of_week field matches any day of the week.
You can express values as a combination of lists (1,3,7) and ranges (8-10). For
example, "0-6,9,12,15,18-23" in the hour field would start a command hourly beginning
at midnight until 6:00, every three hours from 9:00 to 15:00, and then hourly again from
18:00 until 23:00. Expressing the value as a step formula is not supported.
The command field specifies the command that the Cron Service should run.
Everything following the day_of_week field is the command line, which is run by the
Windows command shell (Cmd.exe).
Note
Setting environment variables in the Windows crontab file is not supported.
Example crontab entries
# run at 14:15 on the first of every month
15 14 1 * * C:\cronjobs\monthlyjob.cmd
# run five minutes after midnight, every day
5 0 * * * C:\cronjobs\dailymidnight.cmd >> C:\cronlogs\
dailymidnight.log
# run at 22:00 on weekdays to back up customer data
0 22 * * 1-5 xcopy \customer h:\backup\customer /s /e /k /i
SEE ALSO
Using Cron
cron(1w)
cut
NAME
cut - Windows command-line utility to cut out the selected fields of each line of a
file
SYNOPSIScut -b list [-n] [-] | [file...]
cut -c list [-] | [file...]
cut -f list [-d delim] [-s] [-] | [file...]
DESCRIPTION
The cut(1w) utility cuts out bytes (-b option), characters (-c option), or character-
delimited fields (-f option) from each line in one or more files, concatenates them, and
writes them to the standard output.
The option-argument list must be a comma-separated list of positive numbers and
ranges. Ranges can be expressed in three forms. The first is two positive numbers
separated by a hyphen (-) (low-high), which represents all fields from the first number to
the second number. The second is a positive number preceded by a hyphen (-high), which
represents all fields from field number 1 to that number. The third is a positive number
followed by a hyphen (low-), which represents that number to the last field. The elements
in the list can be repeated, overlapped, and specified in any order.
OPTIONS
The cut utility supports the following options:
-b
Cuts based on a list of bytes. Each selected byte is the output unless the -n
option is also specified. It is not an error to select bytes absent in the input line.
-c
Cuts based on a list of characters. Each selected character is the output. It
is not an error to select characters absent in the input line.
-d
Sets the field delimiter to the character delim. The default is the TAB
character.
-f
Cuts based on a list of fields, assumed to be separated in the file by a
delimiter character (see the -d option). Each selected field is the output. Output
fields are separated by a single occurrence of the field-delimiter character. Lines
with no field delimiter are passed through intact unless the -s option is specified.
It is not an error to select fields absent in the input line.
-n
Does not split characters. When the -n option is specified with the -b
option, each element in list of the form low-high (hyphen-separated numbers) is
modified as follows:
If the byte selected by low is not the first byte of a character, low is
decremented to select the first byte of the character originally selected by
low.
If the byte selected by high is not the last byte of a character, high is
decremented to select the last byte of the character prior to the character
originally selected by high, or zero if there is no prior character.
If the resulting range element has high equal to zero or low greater than
high, the list element is dropped from list for that input line without
causing an error.
Each element in list of the form low- is treated as above, with high set to
the number of bytes in the current line, not including the terminating
newline character.
Each element in list of the form -high is treated as above, with low set to 1.
Each element in list of the form num (a single number) is treated as above
with low set to num and high set to num.
-s
When used with the -f option, -s suppresses lines with no delimiter
characters. Unless specified, lines with no delimiters are passed through
untouched.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
date
NAME
date - Windows command-line utility to set or display date and time
SYNOPSISdate [-u] [-r seconds] [+format]
date [-u] -t [[[[[CC]yy]mm]dd]HH]MM[.SS] [+format]
date [-u] [+format] mmddHHMM[yy]
DESCRIPTION
The date(1w) Windows command-line utility is an implementation of the Interix
date(1) command that you can run at a Windows command prompt. For more
information, see date(1).
diff
NAME
diff - Windows command-line utility to give the differences of two files
SYNOPSISdiff [-c | -e | -f | -C n] [-br] file1 file2
DESCRIPTION
The diff(1w) utility compares the contents of file1 and file2 and writes a list of
changes necessary to convert file1 into file2 to the standard output. No output is produced
if the files are identical.
The diff utility supports the following options:
-b
Causes any amount of white space at the end of a line to be treated as a
single newline character (that is, the white-space characters preceding the newline
character are ignored); the other strings of white-space characters, except newline
characters, compare as equal.
-c
Produces output in a form that provides three lines of context.
-C
Produces output in a form that provides n lines of context (where n is
interpreted as a positive decimal integer).
-e
Produces output in a form suitable as input for the ed utility, which can be
used to convert file1 into file2.
-f
Produces output in an alternative form, similar in format to the -e option,
but unsuitable as input for the ed utility, and in the opposite order.
-r
Applies diff recursively to files and directories of the same name when
file1 and file2 are both directories.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
SEE ALSO
sdiff(1w)
dirname
NAME
dirname - Windows command-line utility to return directory portion of path name
SYNOPSISdirname string
DESCRIPTION
The dirname(1w) Windows command-line utility is an implementation of the
Interix dirname(1) command that you can run at a Windows command prompt. The
string argument must use Windows file-name and path syntax. For more information, see
dirname(1).
dos2unix
NAME
dos2unix - Windows command-line utility to convert text files with MS-DOS-
specific end-of-line (EOL) characters to UNIX-specific EOL characters
SYNOPSISdos2unix {-h | [infile [outfile]]}
DESCRIPTION
The dos2unix(1w) Windows command-line utility converts files that use MS-
DOS-specific end-of-line (EOL) characters to files that use UNIX-specific EOL
characters. MS-DOS uses CR and LF as the EOL character; UNIX uses LF.
The dos2unix command accepts the following option and arguments:
-h
Displays usage information about the command.
infile
The MS-DOS file to be converted. If infile and outfile are not specified,
the program takes input from standard input and sends it to standard output.
outfile
The UNIX output file. If outfile is not specified, the program sends output
to standard output.
Caution
The infile and outfile arguments must specify different files. Otherwise, the
resulting file will be empty.
SEE ALSO
unix2dos(1w)
du
NAME
du - Windows command-line utility to displays disk usage
SYNOPSISdu [-a | -s] [-k] [-x] [-r] [file...]
DESCRIPTION
The du(1w) utility displays the number of blocks for a specified file. If the file
operand is a directory, du displays the number of blocks occupied by the files in the
directory, and recursively for all directories within the specified directory.
When du cannot access files or directories, it reports an error (if the -r option is
specified), and the final exit status is affected. By default, file size is written in 512-byte
units, rounded up to the next 512-byte unit.
The du utility supports the following options:
No option
Reports the size of the directory, and recursively for all directories within
the specified file.
-a
In addition to the default output, the -a option reports the size of each file,
including the files in the subdirectories of the specified file. Regardless of the
presence of the -a option, nondirectories given as file operands are always listed.
-k
Writes the file size in 1,024-byte units, rather than the default 512-byte
units.
-r
Generates messages about files and directories that cannot be accessed.
-s
Reports the total sum for each of the specified files instead of the default
output.
-x
Evaluates only those files that have the same device as file.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
grep
NAME
grep, egrep, fgrep - Windows command-line utility file-pattern searcher
SYNOPSISgrep [-F|-E] [-c|-l|-q] [-hinosvx] -e pattern_list
[-f pattern_file] ... [file ...]
grep [-F|-E] [-c|-l|-q] [-hinosvx] [-e pattern_list]
-f pattern_file ... [file ...]
grep [-F|-E] [-c|-l|-q] [-hinosvx] pattern_list
[-f pattern_file ...] [file ...]
DESCRIPTION
The grep(1w) Windows command-line utility is an implementation of the Interix
grep(1) command that you can run at a Windows command prompt. The pattern_file and
file arguments must use Windows file-name and path syntax. For more information, see
grep(1).
find
NAME
find - Windows command-line utility to walk a file hierarchy
SYNOPSISfind [-L|-P] [-DdHhiXx] [-f file] file [file...] [expression]
DESCRIPTION
The find(1w) Windows command-line utility is an implementation of the Interix
find(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see find(1).
gwshare
NAME
gwshare - Windows command-line utility to manage Gateway for NFS shares
SYNOPSISgwshare
gwshare delete {-a | devicename}
gwshare add -d drivename -n networkresource -s sharename
[-c comment] [-u users] [-m {yes | no}]
[-l {euc-jp|euc-tw|euc-kr|shift-jis|big5|ksc5601|gb2312-
80|ansi]
DESCRIPTION
The gwshare Windows command-line utility adds, lists, and deletes Gateway for
NFS shares.
When used without arguments, gwshare lists all shares.
To remove a specific share, use gwshare delete devicename, where devicename
specifies the drive letter mapped to a Gateway for NFS share. To remove all shares, use
gwshare delete -a.
To create a new share, use gwshare add with the following arguments and
options:
-d drivename
Specifies the drive on which to mount the network file system (NFS)
share.
-n networkresource
Specifies the NFS server and path in universal naming convention (UNC)
format: \\server\share
-s sharename
Specifies the name of the share. Windows clients will be able to access the
gateway through this share name. Thus, if the name of the share is NFSfiles and
the name of the computer running Gateway for NFS is \\gway, Windows clients
will access it as \\gway\NFSfiles.
-c comment
Specifies optional text to display when information about the share is
displayed.
-u users
Specifies the maximum number of users permitted on the share.
-m {yes|no}
Allows or disallows Windows users who do not have accounts mapped to
UNIX accounts by User Name Mapping to access files in the NFS directory.
-l {euc-jp|euc-tw|euc-kr|shift-jis|big5|ksc5601|gb2312-80|ansi}
Specifies the default encoding used for file and directory names and, if
used, must be set to one of the following:
ansi
big5 (Chinese)
euc-jp (Japanese)
euc-kr (Korean)
euc-tw (Chinese)
gb2312-80 (Simplified Chinese)
ksc5601 (Korean)
shift-jis (Japanese)
If this option is set to ansi on systems configured for non-English locales,
the encoding scheme is set to the default encoding scheme for the locale. The
following are the default encoding schemes for the indicated locales:
Japanese: SHIFT-JIS
Korean: KS_C_5601-1987
Simplified Chinese: GB2312-80
Traditional Chinese: BIG5
NOTES
To view the complete syntax for this command, at a command prompt, type:
gwshare /?
The EUC is an encoding scheme that is used to represent multibyte characters in
UNIX. You should enable the EUC set if NFS users using Japanese UNIX
systems can access files on this server.
SEE ALSO
Using Gateway for NFS Configuration
head
NAME
head - Windows command-line utility to display first lines of a file
SYNOPSIShead [-b | -c | -k | -n num] [ file...]
DESCRIPTION
The head(1w) Windows command-line utility is an implementation of the Interix
head(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see head(1).
iconv
NAME
iconv - Windows command-line utility to convert encoded characters to another
code set
SYNOPSISiconv -f fromCode -t toCode [-s char] [file...]
iconv -l
DESCRIPTION
The iconv Windows command-line utility converts the encoding of characters in
file from one coded character set to another, and writes the results to standard output.
The input and output coded character sets are identified by fromCode and toCode.
If the file argument is not specified on the command line, the iconv command reads the
standard input. The result of specifying invalid characters in the input stream is that the
input value is translated to the substitute character. If no conversion exists for a particular
character, it is converted to the substitute character in the target code set.
The iconv utility accepts the following options and arguments:
-f fromCode
Specifies the input code set.
-t toCode
Specifies the output code set.
-s char
Specifies the character to substitute for characters that do not exist in the
output code set. Default is underscore (_).
file...
One or more files that contain the data to be converted.
-l
Displays a list of supported code sets.
kill
NAME
kill - Windows command-line utility to terminate or signal the specified processes
SYNOPSISkill -s signalname pid...
kill -p -s signalname pattern
kill -l
kill [-signalname] pid...
kill -p [-signalname] pattern
kill [-signalnumber] pid...
kill -p [-signalnumber] pattern
DESCRIPTION
The kill(1w) utility terminates or signals the specified processes. It terminates
only the parent process; it does not affect the child processes.
To run this version of kill, on the command line, type kill.exe.
To terminate a process, you might need to have the Debug Programs (SeDebug)
privilege. For information about how to grant this permission, refer to the Windows
operating system documentation.
OPTIONS
The kill utility supports the following options:
-l
Writes all values of supported signal names and their corresponding signal
numbers.
-s signalname
Specifies the signal to send, using one of the symbolic names. Values of
signalname are recognized in a case-independent fashion.
-signalname
Equivalent to -s signalname.
-signalnumber
Specifies a non-negative decimal integer, signalnumber, to kill.
-p
Accepts process names as pattern.
SIGNALS
The kill utility supports the following signals:
9
SIGKILL
15
SIGTERM
PATTERN
The kill utility supports the wildcard characters asterisk (*) and question mark (?)
in the pattern. If pattern is specified instead of process identifiers (PIDs), the -p option
must also be specified.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
SEE ALSO
ps(1w)
sleep(1w)
top(1w)
wait(1w)
ln
NAME
ln - Windows command-line utility to link files
SYNOPSISln [-fs] source_file target_file
ln [-fs] source_file... target_dir
DESCRIPTION
The ln(1w) Windows command-line utility is an implementation of the Interix
ln(1) command that you can run at a Windows command prompt. The source_file,
target_file, and target_dir arguments must use Windows file-name and path syntax. For
more information, see ln(1).
ls
NAME
ls - Windows command-line utility to list directory contents
SYNOPSISls [-aAbcCdFfgilkLmnopqrRstTu1] [file...]
DESCRIPTION
The ls(1w) Windows command-line utility is an implementation of the Interix
ls(1) command that you can run at a Windows command prompt. The file argument must
use Windows file-name and path syntax. For more information, see ls(1).
mapadmin
NAME
mapadmin - Windows command-line utility to manage User Name Mapping
SYNOPSIS
mapadmin [server] [-u usr [-p pword]]
mapadmin [server] [-u usr [-p pword]] {start | stop}
mapadmin [server] [-u usr [-p pword]] config [option...]
mapadmin [server] [-u usr [-p pword]] add -wu WindowsUser
-uu UNIXUser [-setprimary]
mapadmin [server] [-u usr [-p pword]] add -wg WindowsGroup
-ug UNIXGroup [-setprimary]
mapadmin [server] [-u usr [-p pword]] setprimary -wu WindowsUser
[-uu UNIXUser]
mapadmin [server] [-u usr [-p pword]] setprimary -wg WindowsGroup
[-ug UNIXGroup]
mapadmin [server] [-u usr [-p pword]] delete option[...]
mapadmin [server] [-u usr [-p pword]] list option[...]
mapadmin [server] [-u usr [-p pword]] backup filename
mapadmin [server] [-u usr [-p pword]] restore filename
mapadmin [server] [-u usr [-p pword]] adddomainmap -d
WindowsDomain
{-y NISDomain [-n nisServer] | -f path}
mapadmin [server] [-u usr [-p pword]] removedomainmap
-d WindowsDomain -y NISDomain
mapadmin [server] [-u usr [-p pword]] removedomainmap -all
mapadmin [server] [-u usr [-p pword]] listdomainmaps
DESCRIPTION
The mapadmin Windows command-line utility administers User Name Mapping
on the local computer or on a remote computer. If you are logged on with an account that
does not have the privileges required to administer User Name Mapping on the computer,
you can specify a user name and password of an account that does.
In addition to specific command arguments, mapadmin accepts the following
arguments and options:
server
Specifies the remote computer you want to administer.
-u usr
Specifies the user name of the user whose credentials are to be used. It
might be necessary to add the domain name to the user name in the form domain\
username.
-p pword
Specifies the password of the user. If you specify the -u option but omit
the -p option, you are prompted for the user's password.
The specific action that mapadmin performs depends on the command argument
you specify:
start
Starts the User Name Mapping service.
stop
Stops the User Name Mapping service.
config
Specifies general settings for User Name Mapping. The following options
are available with this command argument:
-d domain
Specifies the Windows domain name to be used for simple mapping.
Although this option continues to be supported for the sake of compatibility with
earlier version, you should use adddomainmap instead.
-y nisDomain
Specifies the Network Information Service (NIS) domain to be used for
simple mapping. Although this option continues to be supported for the sake of
compatibility with earlier version, you should use adddomainmap instead. The
following option is available with this option:
-n nisServer
Specifies the NIS server for the NIS domain specified with the -y option.
-r dddd:hh:mm
Specifies the refresh interval for updating from the Windows and NIS
databases in days, hours, and minutes. The minimum interval is 5 minutes.
-f path
Specifies the path where PCNFS passwd and group files are located.
-i yes | no
Turns simple mapping on (yes) or off (no). By default, simple mapping is
on.
add
Creates a new mapping for a user or group. The following options are
available with this command argument:
-wu name
Specifies the name of the Windows user for which a new mapping is being
created.
-uu name
Specifies the name of the UNIX user for which a new mapping is being
created.
-wg group
Specifies the name of the Windows group for which a new mapping is
being created.
-ug group
Specifies the name of the UNIX group for which a new mapping is being
created.
-setprimary
Specifies that the new mapping is the primary mapping.
setprimary
Specifies which mapping is the primary mapping for a UNIX user or
group with multiple mappings. The following options are available with this
command argument:
-wu name
Specifies the Windows user of the primary mapping. If more than one
mapping for the user exists, use the -uu option to specify the primary mapping.
-uu name
Specifies the UNIX user of the primary mapping.
-wg group
Specifies the Windows group of the primary mapping. If more than one
mapping for the group exists, use the -ug option to specify the primary mapping.
-ug group
Specifies the UNIX group of the primary mapping.
delete
Removes the mapping for a user or group. The following options are
available for this command argument:
-wu user
The Windows user for whom the mapping will be deleted, specified as
WindowsDomain\UserName. You must specify either the -wu or the -uu option,
or both. If you specify both options, the particular mapping identified by the two
options will be deleted. If you specify only the -wu option, all mappings for the
specified user will be deleted.
-wg group
The Windows group for which the mapping will be deleted, specified as
WindowsDomain\GroupName. You must specify either the -wg or the -ug option,
or both. If you specify both options, the particular mapping identified by the two
options will be deleted. If you specify only the -wg option, all mappings for the
specified group will be deleted.
-uu user
The UNIX user for whom the mapping will be deleted, specified as
UserName. You must specify either the -wu or the -uu option, or both. If you
specify both options, the particular mapping identified by the two options will be
deleted. If you specify only the -uu option, all mappings for the specified user
will be deleted.
-ug group
The UNIX group for which the mapping will be deleted, specified as
GroupName. You must specify either the -wg or the -ug option, or both. If you
specify both options, the particular mapping identified by the two options will be
deleted. If you specify only the -ug option, all mappings for the specified group
will be deleted.
list
Displays information about user and group mappings. The following
options are available with this command argument:
-all
Lists both simple and advanced mappings for users and groups.
-simple
Lists all simple mapped users and groups.
-advanced
Lists all advanced mapped users and groups. Maps are listed in the order
in which they are evaluated. Primary maps, marked with an asterisk (*), are listed
first, followed by secondary maps, which are marked with a carat (^).
-wu name
Lists the mapping for a specified Windows user.
-wg group
Lists the mapping for a Windows group.
-uu name
Lists the mapping for a UNIX user.
-ug group
Lists the mapping for a UNIX group.
backup
Saves User Name Mapping configuration and mapping data to the file
specified by filename.
restore
Replaces configuration and mapping data with data from the file (specified
by filename) that was created using the backup command argument.
adddomainmap
Adds a simple map between a Windows domain and an NIS domain or
PCNFS passwd and group files. The following options are available for this
command argument:
-d WindowsDomain
Specifies the Windows domain to be mapped.
-y NISDomain
Specifies the NIS domain to be mapped.
-n nisServer
Specifies the NIS server for the NIS domain specified with the -y option.
-f path
Specifies the fully qualified path of directory containing the PCNFS
passwd and group files to be mapped. The files must be located on the computer
being managed, and you cannot use mapadmin to manage a remote computer to
set up maps for PCNFS users and groups.
removedomainmap
Removes a simple map between a Windows domain and an NIS domain.
The following options and argument are available for this command argument:
-d WindowsDomain
Specifies the Windows domain of the map to be removed.
-y NISDomain
Specifies the NIS domain of the map to be removed.
-all
Specifies that all simple maps between Windows and NIS domains are to
be removed. This will also remove any simple map between a Windows domain
and PCNFS passwd and group files.
listdomainmaps
Lists the Windows domains that are mapped to NIS domains or PCNFS
passwd and group files.
If you do not specify a command argument, mapadmin displays the current
settings for User Name Mapping.
For all options that specify a user or group name, the following formats can be
used:
For Windows users, use the form domain\username, \\computer\username, \
computer\username, or computer\username
For Windows groups, use the form domain\groupname, \\computer\groupname, \
computer\groupname, or computer\groupname
For UNIX users, use the form NISdomain\username, username@NISdomain,
PCNFS@username, or PCNFS\username
For UNIX groups, use the form NISdomain\groupname, groupname@NISdomain,
PCNFS@groupname, or PCNFS\groupname
Common options
The following options and arguments can be used with any subcommand:
server
Specifies the remote computer you want to administer.
-u usr
Specifies the user name of the user whose credentials are to be used. It
might be necessary to add the domain name to the user name in the form domain\
username.
-p pword
Specifies the password of the user. If you specify the -u option but omit
the -p option, you are prompted for the user's password.
SEE ALSO
User Name Mapping
mkdir
NAME
mkdir - Windows command-line utility to make directories
SYNOPSISmkdir [-p] [-m mode] directory_name...
DESCRIPTION
The mkdir(1w) Windows command-line utility is an implementation of the
Interix mkdir(1) command that you can run at a Windows command prompt. The
directory_name argument must use Windows file-name and path syntax. For more
information, see mkdir(1).
more
NAME
more - Windows command-line utility to display file on crt terminal
SYNOPSIS
more [-ceisu] [-p command] [-P str] [-n number] [-t tag] [-x tabs]
[-/pattern] [-#] [file... ]
DESCRIPTION
The more(1w) Windows command-line utility is an implementation of the Interix
more(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see more(1).
mount
NAME
mount - Windows command-line utility to mount network file system (NFS)
network shares
SYNOPSISmount [-o option[...]] [-u:username] [-p:password | *]
[{\\computername\sharename | computername:/sharename}]
[devicename | *]
DESCRIPTION
The mount Windows command-line utility mounts the file system identified by
sharename exported by the NFS server identified by ComputerName and associates it
with the drive letter specified by DeviceName or, if an asterisk (*) is used, by the first
available driver letter. Users can then access the exported file system as though it were a
drive on the local computer. When used without options or arguments, mount displays
information about all mounted NFS file systems.
The mount utility is available only if Client for NFS is installed.
The following options and arguments can be used with the mount utility.
-u:username
Specifies the user name to use for mounting the share. If username is not
preceded by a backslash (\), it is treated as a UNIX user name.
-p:password
The password to use for mounting the share. If you use an asterisk (*), you
will be prompted for the password.
-o rsize=[buffersize]
Sets the size in kilobytes of the read buffer. Acceptable values are 1, 2, 4,
8, 16, and 32; the default is 32 KB.
-o wsize=[buffersize]
Sets the size in kilobytes of the write buffer. Acceptable values are 1, 2, 4,
8, 16, and 32; the default is 32 KB.
-o timeout=[seconds]
Sets the time-out value in seconds for a remote procedure call (RPC).
Acceptable values are 0.8, 0.9, and any integer in the range 1-60; the default is
0.8.
-o retry=[number]
Sets the number of retries for a soft mount. Acceptable values are integers
in the range 1-10; the default is 1.
-o mtype=[soft | hard]
Sets the mount type (default is soft). Regardless of the mount type, mount
will return if it cannot immediately mount the share. Once the share has been
successfully mounted, however, if the mount type is hard, Client for NFS will
continue to try to access the share until it is successful. As a result, if the NFS
server is unavailable, any Windows program trying to access the share will appear
to stop responding, or "hang," if the mount type is hard.
-o anon
Mounts as an anonymous user.
-o nolock
Disables locking (default is enabled).
-o casesensitive
Forces file lookups on the server to be case sensitive.
-o fileaccess=mode
Specifies the default permission mode of new files created on the NFS
share. Specify mode as a three-digit number in the form ogw, where o, g, and w
are each a digit representing the access granted the file's owner, group, and the
world, respectively. The digits must be in the range 0-7 with the following
meaning:
0: No access
1: x (execute access)
2: w (write access)
3: wx
4: r (read access)
5: rx
6: rw
7: rwx
Interix utilities and applications do not use these default permissions when
creating a file on the NFS share. Instead, they set permissions according to the
user's default mode settings as set by the umask(1) utility.
-o lang={euc-jp|euc-tw|euc-kr|shift-jis|big5|ksc5601|gb2312-80|ansi}
Specifies the default encoding used for file and directory names and, if
used, must be set to one of the following:
ansi
big5 (Chinese)
euc-jp (Japanese)
euc-kr (Korean)
euc-tw (Chinese)
gb2312-80 (Simplified Chinese)
ksc5601 (Korean)
shift-jis (Japanese)
If this option is set to ansi on systems configured for non-English locales,
the encoding scheme is set to the default encoding scheme for the locale. The
following are the default encoding schemes for the indicated locales:
Japanese: SHIFT-JIS
Korean: KS_C_5601-1987
Simplified Chinese: GB2312-80
Traditional Chinese: BIG5
NOTES
If you make a persistent connection with mount, you must use umount(1w) to
delete the connection. Neither the net use command nor Microsoft Windows Explorer
will delete these connections.
You cannot use mount to create a persistent connection using PCNFS
authentication. Before attempting to use mount with PCNFS authentication, at a
Windows command prompt, type the command net use /persistent:no to disable
persistent connections.
SEE ALSO
Map a network drive
mv
NAME
mv - Windows command-line utility to move files
SYNOPSISmv [-fi] source target
mv [-fi] source ... directory
DESCRIPTION
The mv(1w) Windows command-line utility is an implementation of the Interix
mv(1) command that you can run at a Windows command prompt. The source, target,
and directory arguments must use Windows file-name and path syntax. For more
information, see mv(1).
nfsadmin
NAME
nfsadmin - Windows command-line utility to manage Server for NFS, Client for
NFS, and Gateway for NFS
SYNOPSIS
Server for NFS syntax
nfsadmin server [computer] [-u user [-p pwd]]
nfsadmin server [computer] [-u user [-p pwd]] -l
nfsadmin server [computer] [-u user [-p pwd]] -r {client | all}
nfsadmin server [computer] [-u user [-p pwd]] {start | stop}
nfsadmin server [computer] [-u user [-p pwd]] config option[...]
nfsadmin server [computer] [-u user [-p pwd]] creategroup name
nfsadmin server [computer] [-u user [-p pwd]] listgroups
nfsadmin server [computer] [-u user [-p pwd]] deletegroup name
nfsadmin server [computer] [-u user [-p pwd]] renamegroup oldname
newname
nfsadmin server [computer] [-u user [-p pwd]] addmembers name
host[...]
nfsadmin server [computer] [-u user [-p pwd]] listmembers
nfsadmin server [computer] [-u user [-p pwd]] deletemembers group
host[...]
Client for NFS syntax
nfsadmin client [computer] [-u user [-p pwd]] {start | stop}
nfsadmin client [computer] [-u user [-p pwd]] config option[...]
Gateway for NFS syntax
nfsadmin gw [computer] [-u user [-p pwd]] {start | stop}
nfsadmin gw [computer] [-u user [-p pwd]] config option[...]
DESCRIPTION
The nfsadmin Windows command-line utility administers Server for NFS, Client
for NFS, or Gateway for NFS on the local computer or on a remote computer. If you are
logged on with an account that does not have the required privileges, you can specify a
user name and password of an account that does. The action performed by nfsadmin
depends on the command arguments you specify.
In addition to service-specific command arguments and options, nfsadmin
accepts the following:
computer
Specifies the remote computer you want to administer. You can specify
the computer using a Windows Internet Name Service (WINS) name or a Domain
Name System (DNS) name, or by Internet Protocol (IP) address.
-u user
Specifies the user name of the user whose credentials are to be used. It
might be necessary to add the domain name to the user name in the form domain\
username
-p pwd
Specifies the password of the user specified using the -u option. If you
specify the -u option but omit the -p option, you are prompted for the user's
password.
Administering Server for NFS
Use the nfsadmin server command to administer Server for NFS. The specific
action that nfsadmin server takes depends on the command option or argument you
specify:
-l
Lists all locks held by clients.
-r {client | all}
Releases the locks held by client or, if all is specified, by all clients.
start
Starts the Server for NFS service.
stop
Stops the Server for NFS service.
config
Specifies general settings for Server for NFS. You must supply at least
one of the following options with the config command argument:
auditlocation={eventlog | file | both | none}
Specifies whether events will be audited and where the events will be
recorded. One of the following arguments is required.
eventlog
Specifies that audited events will be recorded only in the Event Viewer
application log.
file
Specifies that audited events will be recorded only in the file specified by
config fname.
both
Specifies that audited events will be recorded in the Event Viewer
application log as well as the file specified by config fname.
none
Specifies that events will not be audited.
fname=file
Sets the file specified by file as the audit file. The default is %sfudir%\log\
nfssvr.log
fsize==size
Sets size as the maximum size in megabytes of the audit file. The default
maximum size is 7 MB.
audit=[+|-]mount [+|-]read [+|-]write [+|-]create [+|-]delete [+|-]locking
[+|-]all
Specifies the events to be logged. To start logging an event, type a plus
sign (+) before the event name; to stop logging an event, type a minus sign (-)
before the event name. If the sign is omitted, the plus sign is assumed. Do not use
all with any other event name.
lockperiod=seconds
Specifies the number of seconds that Server for NFS will wait to reclaim
locks after a connection to Server for NFS has been lost and then reestablished or
after the Server for NFS service has been restarted.
enabletcp={yes | no}
Specifies whether the Transmission Control Protocol (TCP) protocol will
be supported. The default setting is yes.
enableV3={yes | no}
Specifies whether NFS version 3 protocols will be supported. The default
setting is yes.
renewauth={yes | no}
Specifies whether client connections will be required to be reauthenticated
after the period specified by config renewauthinterval. The default setting is no.
renewauthinterval=seconds
Specifies the number of seconds that elapse before a client is forced to be
reauthenticated if config renewauth is set to yes. The default value is 600
seconds.
dircache=size
Specifies the size in kilobytes of the directory cache. The number
specified as size must be a multiple of 4 between 4 and 128. The default directory-
cache size is 128 KB.
translationfile=[file]
Specifies a file containing mapping information for replacing characters in
the names of files when moving them from Windows- to UNIX-based file
systems. If file is not specified, then file-name character translation is disabled.
For more information on file-name character translation and the format of this
file, see File-name character translation. If the value of translationfile is changed,
you must restart the server for the change to take effect.
dotfileshidden={yes | no}
Specifies whether files that are created with names beginning with a
period (.) will be marked as hidden in the Windows file system and consequently
hidden from NFS clients. The default setting is no.
casesensitivelookups={yes | no}
Specifies whether directory lookups will be case sensitive (that is, require
exact matching of character case. When casesensitivelookups is set to yes (the
default), ntfscase is always set to preserve.
ntfscase={lower | upper | preserve}
Specifies whether the case of characters in the names of files in the NTFS
file system will be returned in lowercase, uppercase, or in the form stored in the
directory. The default setting is preserve. This setting cannot be changed if
casesensitivelookups is set to yes.
creategroup name
Creates a new client group, giving it the specified name.
listgroups
Displays the names of all client groups.
deletegroup name
Removes the client group specified by name.
renamegroup oldname newname
Changes the name of the client group specified by oldname to newname
addmembers name host[...]
Adds host to the client group specified by name.
listmembers name
Lists the host computers in the client group specified by name.
deletemembers group host[...]
Removes the client specified by host from the client group specified by
group.
To display the current Server for NFS configuration settings, specify only
nfsadmin server; do not specify a command option or argument.
Administering Client for NFS
Use the nfsadmin client command to administer Client for NFS. The specific
action that nfsadmin client takes depends on the command argument you specify:
start
Starts the Client for NFS service.
stop
Stops the Client for NFS service.
config
Specifies general settings for Client for NFS. You must supply at least one
of the following options with the config command argument:
fileaccess=mode
Specifies the default permission mode of new files created on the NFS
share. Specify mode as a three-digit number in the form ogw, where o, g, and w
are each a digit representing the access granted the file's owner and group and the
world, respectively. The digits must be in the range 0-7 with the following
meaning:
0: No access
1: x (execute access)
2: w (write access)
3: wx (write and execute access)
4: r (read access)
5: rx (read and execute access)
6: rw (read and write access)
7: rwx (read, write, and execute access)
mtype={hard | soft}
Specifies the default mount type. For a hard mount, Client for NFS
continues to retry a failed RPC until it succeeds. For a soft mount, Client for NFS
returns failure to the calling application after retrying the call the number of times
specified by the retry option.
preferTCP={yes | no}
If set to yes, specifies that TCP is the preferred transport protocol; if set to
no (the default), specifies that User Datagram Protocol (UDP) is the preferred
transport protocol.
retry=number
Specifies the number of times to try to make a connection for a soft
mount. This value must be from 1 to 10, inclusive. The default is 1.
timeout=seconds
Specifies the number of seconds to wait for a connection (remote
procedure call). This value must be 0.8, 0.9, or an integer from 1 to 60, inclusive.
The default is 0.8.
rsize=size
Specifies the size, in kilobytes, of the read buffer. This value can be 0.5, 1,
2, 4, 8, 16, or 32. The default is 32.
wsize=size
Specifies the size, in kilobytes, of the write buffer. This value can be 0.5,
1, 2, 4, 8, 16, or 32. The default is 32.
perf=default
Restores the following performance settings to default values:
mtype
preferTCP
retry
timeout
rsize
wsize
fileaccess=mode
Specifies the default permission mode for files created on network file
system (NFS) servers. The mode argument consists of a three digits from 0 to 7
(inclusive) representing the default permissions granted the user, group, and
others (respectively). The digits translate to UNIX-style permissions as follows:
0=none, 1=x, 2=w, 3=wx, 4=r, 5=rx, 6=rw, and 7=rwx. For example,
fileaccess=750 gives rwx permission to the owner, rx permission to the group,
and no access permission to others.
To display the current Client for NFS configuration settings, specify only
nfsadmin client; do not specify an option or argument.
Administering Gateway for NFS
Use the nfsadmin gateway command to administer Gateway for NFS. The
specific action that nfsadmin gateway takes depends on the command argument you
specify:
start
Starts the Gateway for NFS service.
stop
Stops the Gateway for NFS service.
config
Specifies general settings for Gateway for NFS. You must supply at least
one of the following options with the config command argument:
fileaccess=mode
Specifies the default permission mode for files created on NFS servers.
The mode argument consists of a three digits from 0 to 7 (inclusive) representing
the default permissions granted the user, group, and others (respectively). The
digits translate to UNIX-style permissions as follows: 0=none, 1=x, 2=w, 3=wx,
4=r, 5=rx, 6=rw, and 7=rwx. For example, fileaccess=750 gives rwx permission
to the owner, rx permission to the group, and no access permission to others.
To display the current Gateway for NFS configuration settings, specify only
nfsadmin gateway; do not specify an option or argument..
SEE ALSO
Server for NFS
Client for NFS
Gateway for NFS
nfsshare
NAME
nfsshare - Windows command-line utility to control network file system (NFS)
shares
SYNOPSISnfsshare [sharename]
nfsshare /delete {sharename | drive:path | * }
On computers running Windows Server 2003 family, use:
nfsshare [-o option=value...] sharename[=drive:path]
On computers running Windows 2000 or Windows XP, use:
nfsshare [-o option=value...] sharename=drive:path
DESCRIPTION
Without arguments, the nfsshare Windows command-line utility lists all network
file system (NFS) shares exported by Server for NFS. With sharename as the only
argument, nfsshare lists the properties of the NFS share identified by sharename. On
computers running Windows Server 2003 family, options supplied with sharename
modify properties of the existing NFS share identified by sharename. (On other versions
of Windows, the properties of existing shares cannot be changed.) When sharename and
drive:path are provided, nfsshare exports the folder identified by drive:path as
sharename. When the /delete option is used, the specified folder is no longer made
available to NFS clients.
OPTIONS
The nfsshare command accepts the following options and arguments:
-o
Sets an option with a specified value. The option argument can be one or
more of the following:
anon={yes | no}
Specifies whether anonymous (unmapped) users can access the shared
directory. The default is no.
anonuid=uid
Specifies that anonymous (unmapped) users will access the share directory
using uid as their user identifier (UID). The default is -2. The anonymous UID
will be used when reporting the owner of a file owned by an unmapped user, even
if anonymous access is disabled.
anongid=gid
Specifies that anonymous (unmapped) users will access the share directory
using gid as their group identifier (GID). The default is -2. The anonymous GID
will be used when reporting the owner of a file owned by an unmapped user, even
if anonymous access is disabled.
encoding={big5|euc-jp|euc-kr|euc-tw|gb2312-80|ksc5601|shift-jis}
Specifies the default encoding used for file and directory names and, if
used, must be set to one of the following:
big5 (Chinese)
euc-jp (Japanese)
euc-kr (Korean)
euc-tw (Chinese)
gb2312-80 (Simplified Chinese)
ksc5601 (Korean)
shift-jis (Japanese)
If this is option is not set, the default encoding scheme is ANSI or, on
systems configured for non-English locales, the default encoding scheme for the
locale. The following are the default encoding schemes for the indicated locales:
Japanese: SHIFT-JIS
Korean: KS_C_5601-1987
Simplified Chinese: GB2312-80
Traditional Chinese: BIG5
{big5|euc-jp|euc-kr|euc-tw|gb2312-80|ksc5601|shift-jis}=host[:host]...
For individual client computers and client groups, specifies the default
encoding used for file and directory names. See the encoding option for more
information. This option is available only on Windows Server 2003 family.
na
Specifies that no client or group is granted access to the NFS share unless
you explicitly grant it access. This option is available only on Windows
Server 2003 family.
noroot[=host[:host]...]
Denies root access to the shared directory by the clients or client groups
specified by host. Separate client and group names with a colon (:). If you do not
specify a host, root access is denied to all clients and groups for which you do not
explicitly grant root access. See "Notes" for more information about how options
interact when you create a shared directory. This option is available only on
Windows Server 2003 family.
removeclient=host[:host]...
Removes the specified clients from the list of permissions of the shared
directory. Separate client and group names with a colon (:). This option is
available only on Windows Server 2003 family.
ro[=host[:host]...]
Provides read-only access to the shared directory by the clients or client
groups specified by host. Separate client and group names with a colon (:). If you
do not specify a host, read-only access is granted to all clients and groups for
which you do not explicitly grant or deny access. When creating a shared
directory, if you set the ro option for one or more clients but do not set the rw
option, only the clients specified with the ro option can access the shared
directory. See "Notes" for more information about how options interact when you
create a shared directory.
root[=host[:host]...]
Provides root access to the shared directory by the clients or client groups
specified by host. Separate client and group names with a colon (:). If you do not
specify a host, root access is granted to all clients and groups for which you did
not explicitly deny root access. If you do not set the root option when exporting a
folder, no clients have root access to the shared directory. See "Notes" for more
information about how options interact when you create a shared directory.
rw[=host[:host]...]
Provides read/write access to the shared directory by the clients or client
groups specified by host. Separate client and group names with a colon (:). If you
do not specify a host, read/write access is granted to all clients and groups for
which you do not explicitly grant or deny access. When creating a shared directly,
if you set neither the ro nor the rw option, all clients have read-only access to the
shared directory. See "Notes" for more information about how options interact
when you create a shared directory.
/delete
If sharename or drive:path is specified, deletes the specified share.
NOTES
To view the complete syntax for this command, at a command prompt, type:
nfsshare /?
When you create a shared directory, the default permissions that you assign to
client computers depends on the combination of options used when you export the
folder. The following table details some of the combinations of default
permissions that you can set when you create a shared directory. When you use
nfsshare to modify an existing shared directory, only the specified properties are
changed.
Options Permissions
(None) All clients: read-only
-o root All clients: read-only
-o noroot All clients: read-only
-o ro=hosthost: read-only
All other clients: no access
-o rw=hosthost: read/write
All other clients: no access
-o root=hosthost: read/write
All other clients: read-only
-o noroot=host host: read/write
All other clients: read-only
-o root ro=hosthost: read-only
All other clients: read-only
-o noroot ro=hosthost: read-only
All other clients: read-only
-o root rw=hosthost: read/write
All other clients: read-only
-o noroot rw=hosthost: read/write
All other clients: read-only
-o root root=hosthost: read/write
All other clients: read-only
-o noroot noroot=hosthost: read/write
All other clients: read-only
-o rw=host1 root=host2 noroot=host3
host1: read/write
host2: read/write
host3: read/write
All other clients: no access
-o root=host1 root=host2 noroot=host3 host1: read/write
host2: read/write
host3: read/write
All other clients: no access
SEE ALSO
Share a directory
Stop sharing a directory
nfsstat
NAME
nfsstat - Windows command-line utility to display or reset counts of calls made to
Server for NFS
SYNOPSISnfsstat [-z]
DESCRIPTION
When used without the -z option, the nfsstat Windows command-line utility
displays the number of NFS V2, NFS V3, and Mount V3 calls made to the server since
the counters were set to 0, either when the service started or when the counters were reset
using nfsstat -z.
nice
NAME
nice - Windows command-line utility to invoke a utility with a specific priority
SYNOPSISnice [-n increment] utility [argument...]
nice [-increment] utility [argument...]
DESCRIPTION
The nice(1w) utility invokes a utility with a scheduling priority if the user has the
appropriate permission. (Scheduling priority is computed based on the base priority of the
calling process and the specified increment.) If the user lacks the appropriate permission
to increase the scheduling priority, a warning message is written to the standard error but
will not prevent the invocation of the utility or affect the exit status.
To use nice, the user must have permission to increase scheduling priority. For
information about how to grant this permission, refer to the Windows operating system
documentation.
OPTIONS
The nice utility supports the following option:
-n
Specifies how to adjust the scheduling priority of the utility.
ARGUMENTS
The nice utility supports the following arguments:
increment
The increment is a positive or negative decimal integer that is used to
modify the scheduling priority of the utility. Positive increment values cause a
lower or unchanged scheduling priority. Negative increment values cause a higher
or unchanged scheduling priority and require appropriate permissions.
utility
The name of the utility to be invoked.
argument
Any string to be supplied as an argument when invoking utility.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
126
The utility was found but could not be invoked.
127
The utility could not be found.
Note
The scheduling priority is computed based on the base priority of the calling
process and the increment specified. The utility is invoked with this resultant
priority. If the resultant priority value exceeds the range (that is, it is above real
time (32) or below idle (0)), utility is invoked with real-time or idle priority, as
appropriate, and displays a warning message.
EXAMPLES
nice -n -3 myprog.exe
If the default base priority is normal (inherited from the calling process),
myprog.exe is invoked with above-normal priority, subject to the user having appropriate
permissions.
nice -n 3 myprog.exe
If the default base priority is normal (inherited from the calling process),
myprog.exe is invoked with below-normal priority.
nice -n -18 myprog.exe
If the default base priority is high (inherited from the calling process), myprog.exe
is invoked with real-time priority, subject to the user having appropriate permissions.
SEE ALSO
renice(1w)
nis2ad
NAME
nis2ad - Windows command-line utility to migrate maps from Network
Information Service (NIS) to Active Directory directory service
SYNOPSISnis2ad.exe -y NIS_Domain -a AD_domain [options] mapfile
DESCRIPTION
The nis2ad Windows command-line utility transfers the entries in the Network
Information Service (NIS) map source file specified by mapfile located in the UNIX NIS
domain specified by NIS_domain to the Active Directory domain specified by
AD_domain. NIS map source files are the plain text files from which the NIS map
databases are compiled.
The -m option must be specified to perform the actual migration; otherwise,
nis2ad performs the actions it would perform in an actual migration without actually
changing Active Directory, including logging any conflicting entries.
The nis2ad utility accepts the following options and arguments:
-d directoryname
Specifies the name of the directory that contains NIS map source files.
-s server
Specifies the domain controller server hosting Active Directory;
otherwise, uses the current server.
-u user
Specifies the name of a user having administrator permissions on this
computer; otherwise, uses the current user.
-p password
If a password is needed but is not specified, nis2ad prompts the user for
the password.
-f logfile
Specifies the name of the log file. The log file must be on your local
computer. The default is %sfudir%\nis\nis2ad.log.
-c conflictfile
Specifies the file where conflict details are written. The default is %sfudir
%\nis\conflicts.log.
-r {yes|no}
Replaces the object in Active Directory with the object being migrated.
The default is no.
-n
Resolves conflicts by changing the Windows account name in Active
Directory. If objects of different types have the same name, the name of both
objects is changed before the data is migrated.
-t targetContainer
Specifies the target container name. Applicable only when creating a new
NIS domain. If not specified, uses default or uses the container of the target
domain.
-m
Performs the migration. If this option is omitted, the program finds and
reports conflicts, but does not actually perform the migration.
-h/-?
Displays usage information for the command.
Note
The currently logged on user must have write permissions for the folder that will
contain the log and conflict files, even if another user is specified with the -u
option. If necessary, modify the permissions on the folder to grant write access to
the user who will be running the nis2ad utility before running the utility.
SEE ALSO
Server for NIS
nisadmin
NAME
nisadmin - Windows command-line utility to administer Server for NIS
SYNOPSISnisadmin [computer] [-u usr [-p pword]]
nisadmin [computer] [-u usr [-p pword]] mkmaster -d domain
nisadmin [computer] [-u usr [-p pword]] mkslave -d domain -m
server
nisadmin [computer] [-u usr [-p pword]] config option[...]
nisadmin [computer] [-u usr [-p pword]] syncall
nisadmin [computer] [-u usr [-p pword]] start
nisadmin [computer] [-u usr [-p pword]] stop
nisadmin [computer] [-u usr [-p pword]] pause
nisadmin [computer] [-u usr [-p pword]] continue
nisadmin [computer] [-u usr [-p pword]] encryptiontype
-d domain {crypt | md5}
DESCRIPTION
The nisadmin Windows command-line utility administers Server for NIS on the
local computer or on a remote computer. If you are logged on with an account that does
not have the required privileges, you can specify a user name and password of an account
that does. The action performed by nisadmin depends on the command argument you
supply.
In addition to specific command arguments, nisadmin accepts the following
options and arguments:
computer
Specifies the remote computer you want to administer. You can specify
the computer using a WINS or DNS name, or by Internet Protocol (IP) address.
-u usr
Specifies the user name of the user whose credentials are to be used. It
might be necessary to add the domain name to the user name in the form domain\
username.
-p pword
Specifies the password of the user specified using the -u option. If you
specify the -u option but omit the -p option, you are prompted for the user's
password.
The specific action that nisadmin performs depends on the command argument
you specify:
mkmaster
Changes a subordinate (also known as slave) server to a master server.
The following option and argument are required when you use mkmaster:
-d domain
Specifies the name of the domain for which the change is being made.
mkslave
Changes a master server to a subordinate (slave) server. The following
options and arguments are required when you use mkslave:
-d domain
Specifies the name of the domain for which the change is being made.
-m server
Specifies the name of the domain controller to be promoted to master
server.
config
Configures service parameters. You must supply one or more of the
following options when you use config:
pushint=[[days:]hh:]mm
Specifies the interval at which the service checks changes to Network
Information Service (NIS) maps in Active Directory and propagates them to
secondary NIS servers for all domains, in days, hours, and minutes. If hh is
specified, hh must be in the range 0-23 and mm must be in the range 0-59.
logging={n[ormal] | v[erbose]}
Specifies the amount of information to be available in event logs. Specify
normal (or n) to log only failure events; specify verbose (or v) to log failure,
warning, and success events.
syncall
Synchronizes changed maps with subordinate servers immediately.
start
Starts the Server for NIS service.
stop
Stops the Server for NIS service.
pause
Pauses the Server for NIS service.
continue
Continues running the Server for NIS service.
encryptiontype
Specifies the method used to encrypt UNIX passwords for the specified
domain. For domains whose UNIX computers are all running Linux with MD5
encryption, this value can be md5. For domains containing one or more UNIX
computers running any other operating system or encryption method, this value
must be crypt (the default). All computers in the domain must use the same
method.
If you do not supply a command argument, nisadmin displays the current Server
for NIS settings.
SEE ALSO
Server for NIS
nismap
NAME
nismap - Windows command-line utility to manage Network Information Service
(NIS) maps
SYNOPSISnismap add [common_option[...]] -e "mapentry"
[-r {yes | no}] [-c conflictfile] mapname
nismap mod [common_option[...]] -e "mapentry" -k key mapname
nismap del [common_option[...]] -k key mapname
nismap create [common_option[...]] -i fieldnum -g separator [-y]
mapname
DESCRIPTION
The nismap Windows command-line utility manages the Network Information
Service (NIS) map specified by mapname maintained by Server for NIS on a local
computer or a remote computer. If you are logged on with an account that does not have
the required privileges, you can specify the user name and password of an account that
does. The specific action that nismap performs depends on the command argument you
specify.
In addition to specific command arguments, nismap accepts the following
common options and arguments, represented by common_option in the command
synopsis:
-a AD_domain
The name of the NIS domain in Active Directory. This option is not
available for the create command argument.
-f logfile
Specifies the fully qualified path and name of the log file. Logged events
are appended to this file. The default path and file name is %temp%\conflicts.log.
-s server
Specifies the name of the domain controller. The default is the domain
controller of the domain of the computer on which the command is executed.
-u usr
Specifies the user name of the user whose credentials are to be used. It
might be necessary to add the domain name to the user name in the form domain\
username.
-p pword
Specifies the password of the user specified using the -u option. If you
specify the -u option but omit the -p option, you are prompted for the user's
password.
-h/-?
Displays usage information for the command.
The following command arguments are accepted by nismap:
add
Adds a map entry. The following options and arguments are used with
add:
-e "mapentry"
Specifies the new map entry as a string in the appropriate NIS map format.
The string must be enclosed in quotation marks (" ").
-r {yes | no}
Specifies whether the existing object in Active Directory is to be replaced
with this entry. The default is no.
-c conflictfile
Specifies the name of the file in which conflict information is to be
recorded. If this option is not provided, a default file name is used.
mod
Modifies an existing map entry. The following options and arguments are
required with mod
-e "mapentry"
Specifies the replacement map entry as a string in the appropriate NIS map
format. The string must be enclosed in quotation marks (" ").
-k key
Specifies the search key that identifies the map entry to be modified.
del
Deletes an existing map entry. The following option and argument are
required with del:
-k key
Specifies the search key that identifies the map entry to be deleted.
create
Creates a structure for a nonstandard map. The following options and
arguments are required with create:
-i fieldnum
Specifies the field number of the key field.
-g separator
Specifies the character that separates fields in the map.
-y
Specifies that the key is not part of the value for this map.
NOTES
When you use nismap to delete a user, group, or host object, only the UNIX
attributes of the object are deleted from Active Directory. To delete the object
from Active Directory, use the Active Directory administration tools.
Do not use nismap to change a user's password. Use net.exe or the Windows
interface (CTRL+ALT+DELETE) instead. The nismap utility will fail if you
change the passwd entry using the nismap mod command. This value is the
encrypted string of the user's password. If you need to change the passwd entry,
use ypcat(1w) or ypmatch(1w) to retrieve the user's current passwd entry and to
ensure that the password field is identical.
If you try to modify a mail alias using the nismap mod command, Server for NIS
adds the new alias to the original one instead of replacing it. To change the alias,
first use nismap del to delete the original alias, and then use nismap add to add
the modified alias.
SEE ALSO
Server for NIS
od
NAME
od - Windows command-line utility to dump specified files in specified formats
SYNOPSISod [-v] [-A addressbase] [-j skip] [-N count] [-t typestring...]
[-] | [file...]
od [-bcdosx] [-] | [file] [[+]offset[.][b]]
DESCRIPTION
The od(1w) utility writes the contents of its input files to the standard output in a
user-specified format.
The od utility copies sequentially each input file to the standard output,
transforming the input data according to the output types specified by the -t or the -
bcdosx options. If no output type is specified, the default output is as if -t o2 has been
specified.
The type-specifier character a specifies that bytes be interpreted as named
characters from the International Reference Version (IRV) of the International
Organization for Standardization/International Electrotechnical Commission (ISO/IEC)
646:1991 standard. Only the least significant seven bits of each byte are used for this type
specification. Bytes with the values listed in the following table are written using the
corresponding names for those characters.
Va
lue
Na
me
Va
lue
Na
me
Va
lue
Na
me
Va
lue
Na
me
/
000
Nu
l
/
001
so
h
/
002stx
/
003etx
/
004
Eo
t
/
005
en
q
/
006
ac
k
/
007bel
/
010Bs
/
011ht
/
012
lf
or nl
/
013vt
/
014ff
/
015cr
/
016so
/
017si
/
020
Dl
e
/
021
dc
1
/
022
dc
2
/
023
dc
3
/
024
Dc
4
/
025
na
k
/
026
sy
n
/
027etb
/
030
Ca
n
/
031em
/
032
su
b
/
033esc
/
034Fs
/
035gs
/
036rs
/
037us
/
040Sp
/
177del
The /012 value can be written either as lf or nl.
The type-specifier character c specifies that bytes be interpreted as characters.
Printable multibyte characters are written in the area corresponding to the first byte of the
character. Two asterisks (**) are written in the area corresponding to each remaining byte
in the character, as an indication that the character is continued. When either the -j skip or
-N count option is specified along with the c type specifier, and this results in an attempt
to start or finish in the middle of a multibyte character, the result is unspecified.
The input data is manipulated in blocks, where a block is defined as a multiple of
the least common multiple of the number of bytes, transformed by the specified output
types. If the least common multiple is greater than 16, the results are unspecified. Each
input block is written as transformed by each output type, one per written line, in the
order that the output types were specified. If the input block size is larger than the
number of bytes transformed by the output type, the output type sequentially transforms
the parts of the input block. The output from each of the transformations is separated by
one or more blank characters.
If, as a result of the specification of the -N option or end-of-file being reached on
the last input file, input data only partially satisfies an output type, the input is extended
sufficiently with null bytes to write the last byte of the input.
Unless -A n is specified, the first output line produced for each input block is
preceded by the input offset, and is cumulative across input files of the next byte to be
written. The format of the input offset is unspecified. It will not contain any blank
characters, however. It starts at the first character of the output line, and is followed by
one or more blank characters. In addition, the offset of the byte following the last byte
written will be written after all the input data has been processed, but will not be followed
by any blank characters.
If the -A option is not specified, the input offset base is unspecified.
OPTIONS
The od utility supports the following options:
-A addressbase
Specifies the input offset base. The addressbase option-argument is a
character. The options d, o, and x specify that the offset base be written in
decimal, octal, or hexadecimal, respectively. The n option specifies that the offset
not be written.
-b
Interprets bytes in octal. This is equivalent to t-o1.
-c
Interprets bytes as characters specified by the current setting of the
LC_CTYPE category. Certain nongraphic characters appear as C escapes: NUL=\
0, BS=\b, FF=\f, NL=\n, CR=\r, HT=\t. Others appear as three-digit octal
numbers.
-d
Interprets words (two-byte units) in unsigned decimal format. This is
equivalent to t-u2.
-j skip
Jumps over skip bytes from the beginning of the input. The od utility reads
or seeks past the first skip bytes in the concatenated input files. If the combined
input is not at least skip bytes long, od writes a diagnostic message to the standard
error and exits with a nonzero exit status.
By default, the skip option-argument is interpreted as a decimal number.
With a leading 0x or 0X, offset is interpreted as a hexadecimal number.
Otherwise, with a leading 0, offset is interpreted as an octal number. Appending
the option b, k, or m to offset causes it to be interpreted as a multiple of 512,
1,024 or 1,048,576 bytes, respectively. If the skip number is hexadecimal, any
appended b is considered to be the final hexadecimal digit.
-N count
Formats no more than count bytes of input. By default, count is interpreted
as a decimal number. With a leading 0x or 0X, count is interpreted as a
hexadecimal number. Otherwise, with a leading 0, count is interpreted as an octal
number. If count bytes of input (after successfully skipping, if -j skip is specified)
are not available, it is not considered an error. The od utility formats the input that
is available.
-s
Interprets words (2-byte units) in signed decimal format. This is
equivalent to t-d2.
-t typestring
Specifies one or more output types. The typestring option-argument must
be a string specifying the types to be used when writing the input data. The string
must consist of the type specification characters a (named character), c
(character), d (signed decimal), f (floating point), o (octal), u (unsigned decimal),
or x (hexadecimal).
The type specification characters d, f, o, u, and x can be followed by an
optional unsigned decimal integer that specifies the number of bytes to be
transformed by each instance of the output type.
The type specification option f can be followed by optional type characters
F (float), D (double), or L (long double), indicating that the conversion
should be applied to an item of the specified type.
The type specification options d, o, u, and x can be followed by optional
type characters C (char), S (short), I (int), or L (long), indicating that the
conversion should be applied to an item of the specified type.
Multiple types can be concatenated within the same typestring, and
multiple -t options can be specified. Output lines are written for each type
specified in the order in which the type specification characters are
specified.
-v
Writes all input data. Without the -v option, any number of groups of
output lines that are identical to the immediately preceding group of output lines
(except for the byte offsets), are replaced with a line containing only an asterisk
(*).
-x
Interprets words (two-byte units) in hexadecimal format. This is
equivalent to t-x2.
Multiple types can be specified by using multiple -bcdostx options. Output lines
are written for each type specified in the order in which the types are specified.
ARGUMENTS
The od utility supports the following arguments:
file
The path of the file to be written. If no file operands are specified, the
standard input is used. The operand is assumed to be a file if the first character of
file is a plus sign (+), or the first character of the first file operand is numeric, no
more than two operands are given, and none of the -A, -j, -N, or -t options are
specified.
[+]offset[.][b]
The offset argument specifies the offset in the file where dumping
commences. This operand is normally interpreted as octal bytes. If a period or dot
(.) is appended, the offset is interpreted in decimal format. If b is appended, the
offset is interpreted in 512-byte units. If the file argument is omitted, and none of
the -A, -j, -N, or -t options are specified, the offset argument must be preceded by
a plus sign (+).
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
EXAMPLE
If a file containing 128 bytes, with decimal values 0 to 127 in increasing order, is
supplied as standard input to the command:
od -A d -t a
on an implementation using an input block size of 16 bytes, the standard output,
independent of the current locale setting, will be similar to:
0000000 nul soh stx etx eot enq ack bel bs ht nl vt ff cr
so si
0000016 dle dc1 dc2 dc3 dc4 nak syn etb can em sub esc fs gs
rs us
0000032 sp ! " # $ % & ' ( ) * + ,
- . /
0000048 0 1 2 3 4 5 6 7 8 9 : ; < =
> ?
0000064 @ A B C D E F G H I J K L M
N O
0000080 P Q R S T U V W X Y Z [ \ ]
^ _
0000096 ` a b c d e f g h i j k l m
n o
0000112 p q r s t u v w x y z { | }
~ del
0000128
paste
NAME
paste - Windows command-line utility to concatenate the corresponding lines of
files
SYNOPSISpaste [-s] [-d list] file...
DESCRIPTION
The paste(1w) utility concatenates the corresponding lines of the given input files
and writes the resulting lines into the standard output. By default, paste concatenates the
corresponding lines of the input files. The newline character of every line except the line
from the last input file is replaced with a tab character. If an end-of-file condition is
detected on one or more, but not all input files, and the -b option is not specified, paste
behaves as though empty lines were read from the files on which end-of-file was
detected.
OPTIONS
The paste utility supports the following options:
-d list
Each character in the list is an element specifying a delimiter character,
unless the backslash character (\) appears in it. If a backslash appears in the list, it
and one or more characters following it serve as an element that specifies a
delimiter character, described as follows:
\n
Newline character
\t
Tab character
-\
Backslash character
\O
Empty string (not a null character)
These elements specify one or more delimiters that replace the newline
character of the input lines instead of the default tab character. The elements in
the list are used circularly.
When the -s option is specified:
The last newline character in a file is not modified.
The delimiter is reset to the first element of the list after processing each
file operand.
When the -s option is not specified:
The newline character in the file specified by the last file operand is not
modified.
The delimiter is reset to the first element of the list each time a line is
processed from each file.
-s
Concatenates all lines of each separate input file in command-line order.
Unless the -d option is specified, the newline character of every line except the
last line in each input file is replaced with the tab character.
ARGUMENTS
The paste utility supports the following argument:
file
Path of the input file. If a hyphen (-) is specified for one or more files, the
standard input is used. The standard input is read circularly, one line at a time, for
each instance of the hyphen.
The standard input is used only if one or more file operands are a hyphen.
The files specified by the file operand must be text files.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
posix
NAME
posix - Windows command-line utility to start an Interix process with a
controlling terminal
SYNOPSISposix [/p pathname] [/u] [/v[...]] [/c pathname [arguments]]
DESCRIPTION
The posix Windows command-line utility is the tty driver for the Interix
subsystem. It is responsible for starting an Interix process and then managing the tty
keyboard input and display output for the Interix processes which share that device.
The posix command supports the following options, which can be specified using
lowercase or uppercase letters (/c or /C):
/p pathname
Specifies the path name of the Interix program to run. When combined
with the /c option, this allows you to start a program and set the $0 argument to
something other than the path to the program. For example, posix /u /p
/bin/ksh /c -ksh starts the Korn shell /bin/ksh but sets the initial argument to that
shell to be -ksh, which signals the Korn shell that it should behave as though it
were a login shell.
/u
Specifies that the pathname argument provided with the /p or /c options is
given in Interix syntax rather than Windows syntax. This option makes it easier to
run programs using the Interix single-rooted file system. For example, the Korn
shell can be started using posix /u /c /bin/ksh regardless of the Windows
directory in which Windows Services for UNIX is installed.
/v
Controls the display of diagnostic information from the posix utility.
Using /v more than once increases the amount of diagnostic information
displayed.
/c pathname [arguments]
Indicates that the rest of the command line specifies the Interix program to
run and the arguments to be passed to that program. The pathname argument
names the Interix program to execute (see /p) and is provided to the program as
its $0 argument. If used, this must be the last option on the command line.
SEE ALSO
psxrun(1w)
printenv
NAME
printenv - Windows command-line utility to print the values of environment
variables
SYNOPSISprintenv [variable...]
DESCRIPTION
The printenv(1w) utility prints all or part of the environment. If no arguments are
given, printenv prints the entire environment. If one or more variable names are given, it
prints the value of each one that is set, and nothing for each one that is not set.
ARGUMENTS
variable
Name of the environment variable whose value is to be printed.
DIAGNOSTICS
Possible exit-status values are:
0
All specified variables were found.
>0
At least one specified variable was not found.
printf
NAME
printf - Windows command-line utility to format and print data to the standard
output
SYNOPSISprintf format [argument...]
DESCRIPTION
The printf(1w) utility writes formatted operands to the standard output. The
argument operands are formatted under the control of the format string.
ARGUMENTS
The printf(1w) utility accepts the following arguments:
format
A string describing the format used to write the remaining operands. The
format specifications are described in the "Format specifications" section later in
this topic.
argument
These strings are written to the standard output, under the control of
formats. These are treated as strings if the corresponding conversion character is
b, c, or s. Otherwise, it is evaluated as a C constant. Allows leading plus (+) or
minus sign (-).
If an argument operand cannot be completely converted into an internal
value appropriate to the corresponding conversion specification, a diagnostic
message is written to the standard error. In this case, the utility does not exit with
a zero exit status, but continues processing any remaining operands. It writes the
value accumulated at the time the error was detected, to the standard output.
FORMAT SPECIFICATIONS
The format is a character string that contains three types of objects defined as
follows:
Characters
Characters other than escape sequences are copied to the output.
Escape sequences
Represents nongraphic characters. The valid escape sequences and
associated actions are listed as follows:
\\
(Backslash) Prints the backslash character.
\a
(Alert) Attempts to alert the user through audible or visible notification.
\b
(Backspace) Moves the printing position to one column before the current
position, unless the current position is the start of a line.
\f
(Form feed) Moves the printing position to the initial printing position of
the next logical page.
\n
(Newline) Moves the printing position to the start of the next line.
\r
(Carriage return) Moves the printing position to the start of the current
line.
\t
(Tab) Moves the printing position to the next tab position on the current
line. If there are no more tab positions left on the line, the behavior is undefined.
\v
(Vertical tab) Moves the printing position to the start of the next vertical
tab position. If there are no more vertical tab positions left on the page, the
behavior is undefined.
\c
The \c object is not written; it causes the printf utility to ignore any
remaining characters in the string operand containing it, any remaining string
operands, and any additional characters in the format operand.
In addition to the escape sequences, if \ddd is specified (where ddd is an
octal number), it is written as a character with the numeric value specified by the
octal number.
The interpretation of a backslash followed by any other sequence of
characters is unspecified.
Conversion specifications
These specify the output format of each argument. Each conversion
specification is introduced by the percent sign (%). After the percent sign, the
following appear in sequence.
Flags
Zero or more flags, in any order, modifying the meaning of the conversion
specification. The flag characters and their meanings are:
-
The result of the conversion is left-justified within the field.
+
The result of a signed conversion always begins with a sign (+ or -).
Space
If the first character of a signed conversion is not a sign, a space character
is prefixed to the result. This means that if the space character and + flags both
appear, the space character flag is ignored.
#
The value that needs conversion to an alternative form.
For c, d, i, u, and s conversions, the behavior is undefined.
For o conversion, it increases the precision to force the first digit of the
result to be a zero.
For x or X conversion, a nonzero result is prefixed with 0x or 0X,
respectively.
For e, E, f, g, and G conversions, the result always contains a radix
character, even if no digits follow the radix character.
For g and G conversions, trailing zeros are not removed from the result as
they usually are.
0
For d, i, o, u, x, X, e, E, f, g, and G conversions, leading zeros (following
any indication of sign or base) are used to pad to the field width; no space
padding is performed. If the 0 and - flags both appear, the 0 flag is
ignored.
For d, i, o, u, x, and X conversions, if a precision is specified, the 0 flag is
ignored. For other conversions, the behavior is undefined.
Field width
An optional string of decimal digits to specify a minimum field width. For
an output field, if the converted value has fewer bytes than the field width, it is
padded on the left. It is padded on the right if the left-adjustment flag (-),
described as follows, has been given to the field width).
Precision
Gives the minimum number of digits to appear for the d, o, i, u, x, or X
conversions (the field is padded with leading zeros), the number of digits to
appear after the radix character for the e and f conversions, the maximum number
of significant digits for the g conversion; or the maximum number of characters to
be written from a string in s conversion. The precision takes the form of a period
(.) followed by a decimal digit string; a null digit string is treated as zero.
Conversion characters
Conversion characters indicate the type of conversion to be applied. Each
conversion character results in fetching zero or more arguments. The results are
undefined if there are insufficient arguments for the format. If the format is
exhausted while arguments remain, the excess arguments are ignored.
The conversion characters and their meanings are:
d, i, o, u, x, X
The integer argument is written as signed decimal (d or i), unsigned octal
(o), unsigned decimal (u), or unsigned hexadecimal notation (x and (X). The d
and i specifiers convert to signed decimal in the style [-]dddd.
The precision component of the argument specifies the minimum number
of digits to appear. If the value being converted can be represented in fewer digits
than the specified minimum, it is expanded with leading zeros. The default
precision is 1. The result of converting a zero value with a precision of 0 is no
characters.
If both the field width and precision are omitted, the implementation can
precede, follow, or precede and follow numeric arguments of types d, i, and u
with blank characters; arguments of type o (octal) can be preceded with leading
zeros.
f
The floating point number argument is written in decimal notation in the
style [-]ddd.ddd, where the number of digits after the radix character (shown here
as a decimal point) is equal to the precision specification. If precision is omitted
from the argument, six digits are written after the radix character; if precision is
explicitly 0, no radix character appears.
e, E
The floating point number argument is written in the style [-]d.ddde+-2dd,
where there is 1 digit before the radix character (shown here as a decimal point)
and the number of digits after it is equal to the precision. When the precision is
missing, six digits are written after the radix character; if the + flag is 0, no radix
character appears. The E conversion character produces a number with E instead
of e introducing the exponent. The exponent always contains at least two digits. If
the value to be written requires an exponent greater than two digits, however,
additional exponent digits are written as necessary.
g, G
The floating point number argument is written in style f or e (or in style E
in the case of a G conversion character), with precision specifying the number of
significant digits. The style used depends on the value converted: style g is used
only if the exponent resulting from the conversion is less than -4 or greater than or
equal to precision. Trailing zeros are removed from the result. A radix character
appears only if a digit follows it.
c
The character is written. If the string is specified as the argument, the first
character is written.
s
The argument is taken to be a string, and characters from the string are
written until the end of the string, or the number of characters indicated by the
precision specification of the argument is reached. If the precision is omitted from
the argument, it is taken to be infinite. All characters up to the end of the string
are written.
b
The argument is taken to be a string that can contain backslash-escape
sequences. \0ddd, where ddd is an octal number that is converted to a byte with
the numeric value specified by the octal number.
%
Writes a percent sign (%); no argument is converted.
In no case does a nonexistent or insufficient field width cause truncation of a
field. If the result of a conversion is wider than the field width, the field is simply
expanded to contain the conversion result.
The format operand is reused as often as necessary to satisfy the argument
operands. Any extra c or s conversion specifications will be evaluated as if a null string
argument were supplied. Other extra conversion specifications are evaluated as if a zero
argument were supplied. If the format operand contains no conversion specifications and
argument operands are present, the results are unspecified.
If a character sequence in the format operand begins with a percent sign, but does
not form a valid conversion specification, the behavior is unspecified.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
ps
NAME
ps - Windows command-line utility to write information about processes
SYNOPSISps [-A] [-efl] [-G grouplist] [-o format]... [-p proclist] [-u
userlist]
DESCRIPTION
The ps(1w) utility writes information about processes if it has appropriate
permissions to do so.
The ps utility supports the following options:
-A
Writes information for all processes.
-e
Writes information for all processes (equivalent to the -A option).
-f
Generates a full listing. (See the "Format specifications" section later in
this topic for the contents of a full listing.)
-l
Generates a long listing. (See the "Format specifications" section later in
this topic for the contents of a long listing.)
-G
Writes information for processes whose group names are given in
grouplist. The grouplist must be in the form of a blank- or comma-separated list.
-o
Writes information according to the format specification given in format.
Multiple -o options can be specified. The format specification will be interpreted
as the concatenation (separated by space characters) of all the format option-
arguments.
-p
Writes information for processes whose process identifier (ID) numbers
are given in proclist. The proclist must be in the form of a blank- or comma-
separated list.
-u
Writes information for processes whose user names are given in userlist.
The userlist must be in the form of a blank- or comma-separated list.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
FORMAT SPECIFICATIONS
The -o option allows the output format to be specified under user control. When
the -o option is not specified, the fields shown in the following table are displayed. The
letters f and l indicate the option full or long, that causes the corresponding heading to
appear; all means that the heading always appears. Note that these two options (f and l)
determine only the information provided for a process; they do not determine the
processes that are listed.
USER(f,l)
User name
PID (all)
Process ID of the process
PRI (l)
Priority of the process
ADDR (l)
Starting address of the process
SZ (l)
Size of the process in physical memory, in kilobytes
STIME (f)
Start time of the process
COMMAND (all)
Instance name of the process
PAFF(f)
Processor affinity for the process
THRD (f)
Number of threads in the process
F
Flags (octal and additive) associated with the process
S
State of the process
PPID
Process ID of the parent process
NI
Nice value
WCHAN
The event for which the process is waiting or sleeping
TTY
Controlling terminal for the process
TIME (all)
Processor time for the process
C (f,l)
Processor utilization for scheduling
The format specification must be a list of names presented as a single argument
that is separated by a blank or comma. Each variable has a default header. The default
header can be overridden by appending an equal sign (=) and the new text of the header.
The rest of the characters in the argument are used as the header text.
The specified fields are written in the order specified on the command line and
should be arranged in columns in the output. The field widths selected by the system are
at least as wide as the header text (default or overridden value). If the header text is null,
such as -o user=, the field width is at least as wide as the default header text. If all header
text fields are null, no header line is written.
The ps utility supports the following -o format specifications:
ruser
Real user name of the process
user
Effective user name of the process
rgroup
Real group name of the process
group
Effective group name of the process
pid
Decimal value of the process ID
pcpu
Percentage of CPU utilization for the process
vsz
Size of the process in virtual memory, in kilobytes
etime
Elapsed time since the process was started, in the form [[dd-]hh:]mm:ss,
where dd represents the number of days, hh the number of hours, mm the number
of minutes, and ss the number of seconds. The dd field will be a decimal integer.
The hh, mm, and ss fields are two-digit decimal integers padded on the left with
zeros.
comm
Instance name of the process
ppid
Process ID of the parent process
pri
Priority of the process
size
Size of the process in physical memory, in kilobytes
nice
Nice value
time
Processor time for the process
stime
Start time of the process
tty
Controlling terminal for the process
args
Full path of the instance
pgid
Decimal value for the process group ID
addr
Starting address of the process
paff
Processor affinity for the process
tcount
Number of threads in the process
If the -o format is specified, the following will be the default headers:
ruser
RUSER
user
USER
rgroup
RGROUP
group
GROUP
pid
PID
pcpu
%CPU
vsz
VSZ
etime
ELAPSED
comm
COMMAND
ppid
PPID
pri
PRI
size
SIZE
nice
NI
time
TIME
stime
STIME
tty
TTY
args
ARGS
pgid
PGID
addr
ADDR
paff
PAFF
tcount
THRDS
SEE ALSO
kill(1w)
sleep(1w)
top(1w)
wait(1w)
psxrun
NAME
psxrun - Windows command-line utility to start an Interix process without a
controlling terminal
SYNOPSISpsxrun [-p pathname] [-h] [-u]
[-l logfilepath] [--] [arg0 [arg1[...]]]
DESCRIPTION
The psxrun Windows command-line utility starts the Interix process specified by
arg0 without a controlling terminal. In addition, the arg0 argument is passed to the
process as the $0 argument, arg1 is passed as $1, and so on. This is used primarily to start
X Window client programs (which create their own windows) or Interix-based Windows
services (which cannot interact with users). To run X Window client programs, you must
have an X Window server installed and running.
The psxrun utility supports the following options, which must be specified using
lowercase letters:
-p pathname
Specifies the path name of the Interix program to be run instead of arg0.
You can use this to start a program and set the $0 argument to something other
than the actual path to the program. For example, psxrun -u -p
/usr/loca/bin/prog -- -prog starts /usr/local/bin/prog, but sets its initial argument
(arg0) to be -prog. Note the use of the -- option to prevent -prog from being
interpreted as another use of the -p option.
-h
Display usage information.
-u
Specifies that path names are interpreted using Interix syntax rather than
Windows syntax. This makes it easier to run programs using the Interix single-
rooted file system. For example, psxrun -u /bin/xterm would be started
regardless of the directory where Windows Services for UNIX is installed.
-l logfilepath
Specifies that psxrun is to record all diagnostic information in the file
specified by the logfilepath argument.
--
Stop examining the command line. The arguments to the program to be
executed begin immediately after the -- option.
SEE ALSO
posix(1w)
pwd
NAME
pwd - Windows command-line utility to print the current working directory name
SYNOPSISpwd
DESCRIPTION
The pwd(1w) command prints the current working directory name.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
renice
NAME
renice - Windows command-line utility to set the scheduling priorities of running
processes
SYNOPSISrenice [-n increment]
{-g groupname... | -j jobname... | -u username... | [-p]
pid...}
renice {-n increment | nicevalue} [-p] pid... [-g groupname...]
[-p pid...] [-j jobname...] [-u username...]
renice {-n increment | nicevalue} -g groupname... [-g
groupname...]
[-p pid...] [-j jobname...] [-u username...]
renice {-n increment | nicevalue} -u username... [-g groupname...]
[-p pid...] [-j jobname...] [-u username...]
DESCRIPTION
The renice(1w) utility requests that the scheduling priorities of one or more
running processes be changed.
To use renice, the user must have permission to increase scheduling priority. For
information about how to grant this permission, refer to the Windows operating system
documentation.
If increment is specified, the scheduling priority of the process is computed based
on the base priority of the process and the increment specified. If nicevalue is specified, it
is taken as the scheduling priority. The utility is invoked with this scheduling priority. If
this value exceeds the range (above real time (32) or below idle (0)), the utility is invoked
with real time or idle priority as appropriate, and displays a warning message.
The renice utility will not alter the scheduling priorities of any process unless the
user requesting such a change has appropriate permission to do so.
OPTIONS
The renice utility supports the following options:
-n
Specifies how the scheduling priority of the specified process or processes
is to be adjusted.
-p
Interprets all operands as unsigned decimal integer PIDs. If no options are
specified, the -p option is the default.
-u
Interprets all operands as user names.
-g
Interprets all operands as group names.
-j
Interprets all operands as job names.
ARGUMENTS
The renice utility supports the following arguments:
increment
The increment is a positive or negative decimal integer that is used to
modify the scheduling priority of the specified process or processes. Positive
increment values cause a lower scheduling priority. Negative increment values
require appropriate permissions and will cause a higher scheduling priority.
nicevalue
The actual scheduling priority, in the range 0 to 32. The user must have
appropriate permissions to specify a scheduling priority higher than that of the
existing process.
pid
Unique process identifier of a process whose scheduling priority is to be
changed.
username
User name of the process. When a user is reniced, the request applies to all
processes whose user name matches the given username.
groupname
Group name. When a group is reniced, the request applies to all processes
whose user name belongs to the given groupname.
jobname
Job name. When a job is reniced, the request applies to all processes of the
job.
DIAGNOSTICS
Possible exit-status values are:
0
At least one requested process was reniced.
1
No process was reniced.
SEE ALSO
nice(1w)
rm
NAME
rm - Windows command-line utility to remove directory entries
SYNOPSISrm [-dfiPRr] file...
DESCRIPTION
The rm(1w) Windows command-line utility is an implementation of the Interix
rm(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see rm(1).
rmdir
NAME
rmdir - Windows command-line utility to remove directories
SYNOPSISrmdir directory...
DESCRIPTION
The rmdir(1w) Windows command-line utility is an implementation of the
Interix rmdir(1) command that you can run at a Windows command prompt. The
directory argument must use Windows file-name and path syntax. For more information,
see rmdir(1).
rpcinfo
NAME
rpcinfo - Windows command-line utility to list programs on remote computers
SYNOPSIS
List all programs registered with the port mapper:
rpcinfo -p [node]
Request a response from network nodes that have a specified program:
rpcinfo -b program version
Use Transmission Control Protocol (TCP) to call a program:
rpcinfo -t node program [version]
Use User Datagram Protocol (UDP) to call a program:
rpcinfo -u node program [version]
DESCRIPTION
The rpcinfo(1w) Windows utility makes a remote procedure call (RPC) to an
RPC server and reports what it finds.
The rpcinfo utility accepts the following options:
-p [node]
Lists all programs registered with the port mapper on the specified host. If
you do not specify a node (computer) name, the program queries the port mapper
on the local host.
-b program version
Requests a response from all network nodes that have the specified
program and version registered with the port mapper. You must specify both a
program name or number and a version number.
-t node program [version]
Uses the TCP transport protocol to call the specified program. You must
specify both a node (computer) name and a program name. If you do not specify a
version, the program calls all versions.
-u node program [version]
Uses the UDP transport protocol to call the specified program. You must
specify both a node (computer) name and a program name. If you do not specify a
version, the program calls all versions.
rshpswd
NAME
rshpswd - Windows command-line utility to set the local password for Remote
Shell service (rshsvc)
SYNOPSISrshpswd
DESCRIPTION
The rshpswd Windows command prompts for and then sets the Remote Shell
service password for the local user who is currently logged on.
Caution
If you use the rshpswd to store your password on a computer running Remote
Shell service, a user logged on with the same user name in a different domain will
be able to use rsh to run commands on the computer using your user account. For
example, if you are logged on the computer running Remote Shell service as
mydomain\kimz and run rshpswd to store your password, a user logged on as
otherdomain\kimz will be able to run commands on your computer with the same
rights and privileges as mydomain\kimz. This is an inherent limitation of the rsh
protocol and cannot be worked around.
SEE ALSO
rshsvc(1w)
rshsvc
NAME
rshsvc - Windows command-line utility to manage Remote Shell service
SYNOPSISrshsvc -install [-m mappingserver]
rshsvc -remove
rshsvc -start [-m mappingserver] [-p]
rshsvc -stop
DESCRIPTION
The rshsvc Windows command-line utility manages Remote Shell service, the
server side for the TCP/IP utility rsh(1). It works the same way as the UNIX Remote
Shell service. Rsh clients can access this service from both Windows and UNIX
computers.
The action performed by the rshsvc command depends on the command option
you supply. The rshsvc command accepts the following options and arguments:
-install [-m mappingserver]
Installs the service. You can use the following option with -install:
-m mappingserver
Specifies the name of the server running User Name Mapping that will
map Windows and UNIX user accounts. If this option is not specified, no user
mapping is performed.
-remove
Removes the service.
-start [-m mappingserver] [-p]
Starts the service. You can use the following options with -start:
-m mappingserver
Specifies the name of the server running User Name Mapping that will
map Windows and UNIX user accounts. If this option is not specified, no user
mapping is performed.
-p
Specifies that the service is not to use passwords stored locally for users
using the rshpswd(1w) Windows command-line utility.
-stop
Stops the service.
SECURITY
You must have an .rhosts(5) file in the path specified in the registry entry \
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\RshSvc\
RhostsPath. The default path is %SystemRoot%\System32\Drivers\Etc directory.
Caution
Incorrectly editing the registry may severely damage your system. Before making
changes to the registry, you should back up any valued data on the computer.
The .rhosts file should include one or more of the following entries, each on a
separate line:
M1 U1 [U2 U3 ....]
where M1 is the name of the computer from which Rsh client can be run and U1,
U2, and so on are names of the users who are permitted to access the Remote Shell
service.
The Remote Shell service returns an "Access denied" message under the
following conditions:
The Rsh client computer name is not specified in the .rhosts file.
The name of the logged-on user on the Rsh client computer is not present in
the .rhosts files.
A user is trying to access the Remote Shell service from a computer specified in
the .rhosts file for which the service failed to resolve the Internet Protocol (IP)
address.
LIMITATIONS
When the client tries to start a command, the Remote Shell service waits for a
defined length of time for the command to be completed. This time-out period can be
changed by modifying the following registry key: \HKEY_LOCAL_MACHINE\
System\CurrentControlSet\Services\RshSvc\DefaultTimeOut. The default value is
600 seconds.
SEE ALSO
Remote Shell service
User Name Mapping
sdiff
NAME
sdiff - Windows command-line utility to print differences between two files and
merge them interactively
SYNOPSISsdiff [-lrs] [-w n] [-o outfile] file1 file2
DESCRIPTION
The sdiff(1w) utility produces a side-by-side listing of two files, indicating those
lines that are different. Each line of the two files is printed with a blank gutter between
them if the lines are identical. It displays a "less than" sign (<) in the gutter if the line
exists only in file1. It displays a "greater than" sign (>) in the gutter if the line exists only
in file2. It displays a vertical bar (|) if the line exists in both files, but is not identical.
If the -o outfile option is specified, it merges two files and interactively puts the
results in outfile. If file1 is a directory and file2 is not a directory, sdiff compares the file
in file1 whose name matches with file2, and vice versa.
OPTIONS
The sdiff utility supports the following options:
-l
Prints only the left side of any lines that are identical.
-r
Applies sdiff recursively. It is usually applied to two directories.
-s
Does not print identical lines.
-w n
Uses n as the length of the output line. The default value is 130 characters.
-o outfile
Uses the next argument, outfile, as the name of the third file that is created
as a user-controlled merging of file1 and file2. It prints a set of differences as
produced by diff, where the set shares a common gutter character. After printing
each set of differences, a semicolon (;) user prompt is displayed on the screen.
You can then enter the following commands:
l
Only the left column is appended to the output file.
r
Only the right column is appended to the output file.
s
Does not print identical lines (silent mode).
v
Turns off silent mode.
e l
Invokes Notepad and displays the left column.
e r
Invokes Notepad and displays the right column.
e b
Invokes Notepad and concatenates the left and right columns.
e
Invokes Notepad with an empty file.
q
Exits the program.
ARGUMENTS
The sdiff utility supports the following arguments:
file1
It can be a regular file or a directory. If a minus sign (-) is specified, it is
interpreted as the standard input.
file2
It can be a regular file or a directory. If a minus sign (-) is specified, it is
interpreted as the standard input.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
NOTES
In the case of the -o option, the output file that is generated is a Unicode file.
Hence, it is not possible to open the file using edit.com. It can be opened using
Notepad or any other Windows Unicode text editor.
Both the operands file1 and file2 cannot be a minus sign (-) at the same time.
The -o option cannot be applied when both the operands are directories.
SEE ALSO
diff(1W)
sed
NAME
sed - Windows command-line utility stream editor
SYNOPSISsed [-an] command [file...]
sed [-an] [-e command] [-f command_file] [file...]
DESCRIPTION
The sed(1w) Windows command-line utility is an implementation of the Interix
sed(1) command that you can run at a Windows command prompt. The file and
command_filearguments must use Windows file-name and path syntax. For more
information, see sed(1).
sfuadmin
NAME
sfuadmin - Windows command-line utility to manage Windows Services for
UNIX
SYNOPSISsfuadmin [computer] [-u usr [-p pwd]]
sfuadmin [computer] [-u usr [-p pwd]] config option[...]
DESCRIPTION
The sfuadmin(1w) Windows command-line utility administers Windows
Services for UNIX on the local computer or on a remote computer. If you are logged on
with an account that does not have the required privileges, you can specify a user name
and password of an account that does. The action performed by sfuadmin depends on the
command arguments you supply.
In addition to service-specific command arguments and options, sfuadmin
accepts the following:
computer
Specifies the remote computer you want to administer. You can specify
the computer using a WINS or DNS name, or by Internet Protocol (IP) address.
-u usr
Specifies the user name of the user whose credentials are to be used. It
might be necessary to add the domain name to the user name in the form domain\
username
-p pwd
Specifies the password of the user specified using the -u option. If you
specify the -u option but omit the -p option, you are prompted for the user's
password.
The specific action that sfuadmin server takes depends on the command option
or argument you specify:
config
Specifies general settings for Windows Services for UNIX. You must
supply at least one of the following options with the config command argument:
mapsvr=server
Sets server as the User Name Mapping server for all Windows Services
for UNIX components. To specify the computer being administered as the User
Name Mapping server, you can specify localhost as server.
If you do not specify a command option or argument, sfuadmin displays the
Windows Services for UNIX version number and current configuration settings.
showmount
NAME
showmount - Windows command-line utility to display mounted directories
SYNOPSISshowmount {-e | -a | -d} [server]
DESCRIPTION
The showmount(1w) Windows command-line utility displays information about
mounted file systems exported by Server for NFS on the computer specified by server. If
server is not provided, showmount displays information about the computer on which
the showmount command is run.
You must provide one of the following options:
-e
Displays all file systems exported on the server.
-a
Displays all network file system (NFS) clients and the directories on the
server each has mounted.
-d
Displays all directories on the server that are currently mounted by NFS
clients.
SEE ALSO
Server for NFS
sleep
NAME
sleep - Windows command-line utility to suspend execution for a number of
seconds
SYNOPSISsleep time
DESCRIPTION
The sleep(1w) Windows utility suspends execution for at least the number of
seconds specified by the time integer argument.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
SEE ALSO
kill(1w)
ps(1w)
top(1w)
wait(1w)
sort
NAME
sort - Windows command-line utility to sort or merge text files
SYNOPSISsort [-cmubdfinr] [-t char] [-T char]
[-k field1[,field2]]... [ -o output] [file]...
DESCRIPTION
The sort(1w) Windows command-line utility is an implementation of the Interix
sort(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see sort(1).
split
NAME
split - Windows command-line utility to read an input file and write one or more
output files
SYNOPSISsplit [-l linecount] [-a suffixlength] {[-] | [file [name]]}
split -b n[k | m] [-a suffixlength] {[-] | [file [name]]}
split [-linecount] [-a suffixlength] {[-] | [file [name]]}
DESCRIPTION
The split(1w) utility reads an input file and writes one or more output files. The
default size of each output file is 1,000 lines. The -b or -l option can be specified to
modify the size of the output files. Each output file is created with a unique suffix that
consists of suffixlength lowercase letters. The letters of the suffix are used as if they were
a base-26 digit system, with the first suffix to be created consisting all a characters, the
second with a b replacing the last a, and so on, until a name of all z characters is created.
By default, the names of the output files are x, followed by a two-character suffix from
the character set as described above, starting with aa, ab, ac, and so on, up to the suffix
zz, for a maximum of 676 files.
The prefix used for each of the files results from the split operation. If no name
argument is given, x is used as the prefix of the output files.
The split utility supports the following options:
-a
Uses suffixlength letters to form the suffix portion of the file names of the
split file. If the -a option is not specified, the default suffix length is 2.
-b
Splits a file into files of n bytes each. If n is followed by k, it splits the file
into files of n*1,024 bytes each. If n is followed by m, it splits the file into files of
n*1,048,576 bytes each.
-l
Specifies the number of lines in each resulting file. The linecount
argument is an unsigned decimal integer. The default is 1,000. If the input does
not end with a newline character, the partial line is included in the last output file.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
strings
NAME
strings - Windows command-line utility to find printable strings in files and print
to the standard output
SYNOPSISstrings [-a] [-t format] [-n number] [file...]
strings [-] [-t format] [-number] [file...]
DESCRIPTION
The strings(1w) Windows utility looks for printable strings in regular files, and
writes those strings to the standard output. A printable string is any sequence of four (by
default) or more printable characters terminated by a newline or a NULL character.
OPTIONS
The strings utility supports the following options:
- or -a
Scans files in their entirety. If the -a option is not specified, strings scans
only the .data, .rdata, and .edata in PE EXE, PE DLL, and COFF OBJ files.
-n
The user can specify the minimum string length number, where the
number argument is a positive decimal integer. The default is 4. The user can also
specify the minimum string length number without specifying the -n option as -
number.
-t
Writes each string preceded by its byte offset from the start of the file. The
format is dependent on the single character used as the format option-argument.
The format can be either d (decimal), o (octal), or x (hexadecimal).
ARGUMENTS
The strings utility supports the following argument:
file
The path of the regular file to be used as input. If no file operand is
specified, strings reads from the standard input.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
su
NAME
su - Windows command-line utility to allow one to become another user without
logging off
SYNOPSISsu [-] [-c cmd] [-b|-i|-s] [-e] [-v] [-w] [-n]
[{[[user] [-d domain]] | [domain/user]}]
DESCRIPTION
The su(1w) Windows utility requests the password for user (or for Administrator,
if no user is provided), and switches to that user and group identifier (ID) after obtaining
the information. It then executes a command.
To use su, the user must have the following permissions:
Act as part of operating system
Replace a process level token
Increase quotas
Restore files and directories
For information about how to grant these permissions, refer to the Windows
operating system documentation.
For the required privileges, the domain-level policy settings override the local
policy settings. If the domain-level policies do not allow a local administrator to set the
privileges, contact your domain administrator.
OPTIONS
The su utility supports the following options:
-
Loads the user profile.
-c
Accepts the command cmd to carry out in the specified user context. The
default is cmd.exe.
-b
Batch logon. The target user needs SeBatchLogonRight.
-i
Interactive logon. The target user needs SeInteractiveLogonRight. This is
the default logon type.
-s
Service logon. The target user needs SeServiceLogonRight.
-e
Disables environment preparation (inherit parent environment).
-v
Verbose output to stdout.
-w
Does not wait on child.
-n
Does not create new console.
-d
Allows the user to enter the domain name. The default domain is the local
computer.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
NOTES
Not specifying a domain causes account lookup in the following order:
1. Well-known group
2. Built-in group
3. Local accounts
4. Primary domain
5. Trusted domain
Specifying a period or dot (.) as the domain limits the user search to the local
computer.
tail
NAME
tail - Windows command-line utility to display the last part of a file
SYNOPSIStail [-f] [-b number | -c number | -k number | | -m number | -n
number] [file...]
DESCRIPTION
The tail(1w) Windows command-line utility is an implementation of the Interix
tail(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see tail(1).
Note that the -l option, which was supported in Windows Services for UNIX
version 2.x, is no longer supported.
tee
NAME
tee - Windows command-line utility to perform pipe fitting (duplicate standard
input)
SYNOPSIStee [-ai] [file ...]
DESCRIPTION
The tee(1w) Windows command-line utility is an implementation of the Interix
tee(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see tee(1).
telnet
NAME
telnet - Windows user interface to the Telnet protocol
SYNOPSIStelnet [-a] [-e escapeChar] [-f logfile]
[-l user] [-t term] [host [port]]
telnet [-h]
DESCRIPTION
The telnet(1w) Windows command-line utility is used to communicate with a
remote computer using the Telnet protocol. The host argument specifies the name or
Internet Protocol (IP) address of the computer to connect to, and port specifies the port
number to be used (by default, 23). If telnet is run without the host argument, it enters
command mode, indicated by its prompt (telnet). In this mode, it accepts and runs the
Telnet commands listed later in this topic. To enter command mode while connected to a
remote computer, type the escape-key sequence (by default, CTRL+]).
The telnet command accepts the following options:
-e escapeChar
The character used to enter the Telnet command prompt.
-f logfile
Specifies the name of the file to which the Telnet log is written for this
session. If you do not specify the path of the file, it is created in your current
directory.
-l user
The user name to use in logging onto a remote system. The remote system
must support the ENVIRON option.
-t term
The type of terminal to use for the connection. Supported terminal types
are VT100, VT52, ANSI, and VTNT.
-a
Attempts automatic log on. Same as the -l option, except that the current
user's name is used to log on.
-h
Displays Help information.
Telnet commands
The following commands can be used when telnet is in command mode. The
portion of the command name outside the square brackets ([]) is the shortest required
form of the command.
c[lose]
Closes the current connection.
d[isplay]
Displays operating parameters.
o[pen] host [port]
Connects to host on the specified port (port 23 by default). The host
argument can be the name or IP address of the remote computer.
q[uit]
Quits Telnet.
set option
Sets one of the following options:
bsasdel
Backspace will be sent as delete.
codeset option
Available only when the user locale is set to Japanese. Set the current code
set to option, which can be one of the following:
Shift JIS
Japanese EUC
JIS Kanji
JIS Kanji (78)
DEC Kanji
NEC Kanji
The same code set should be set on the remote computer. By default,
Telnet Client uses a raster font. Before accessing a remote computer using one of
these code sets, you must configure Telnet Client to use a TrueType font to ensure
that characters will display properly. For more information, see Configure Telnet
Client to use a TrueType font.
crlf
New-line mode; causes the RETURN key to send 0x0D, 0x0A.
delasbs
Delete will be sent as backspace.
escape character
The escape character to enter Telnet client prompt.
localecho
Turns on localecho.
logfile name
The name of the client log file.
logging
Turns on logging for this session.
mode {console | stream}
The mode of operation.
ntlm
Turns on NTLM authentication.
term {ansi | vt100 | vt52 | vtnt}
The type of terminal you want telnet to emulate.
sen[d] argument
Sends a command or string to the server. If argument is a recognized
command, it is sent as such; otherwise, it is sent as a string. The following
commands are recognized:
ao
Abort output command
ayt
"Are you there?"command
brk
Sends the brk (break) command.
esc
Current escape character
ip
Interrupt process command
synch
Telnet synchronization operation
st[atus]
Displays status information.
u[nset] option
Turns off an option previously set using the set command.
?/h
Displays Help information.
tnadmin
NAME
tnadmin - Windows command-line utility to administer Telnet Server
SYNOPSIStnadmin [server] [-u usr [-p pword]]
tnadmin [server] -s [session]
tnadmin [server] -k session
tnadmin [server] -m session message
tnadmin [server] start [-u usr [-p pword]]
tnadmin [server] stop [-u usr [-p pword]]
tnadmin [server] pause [-u usr [-p pword]]
tnadmin [server] continue [-u usr [-p pword]]
tnadmin [server] config option=value [-u usr [-p pword]]
DESCRIPTION
The tnadmin(1w) Windows command-line utility administers Windows Services
for UNIX Telnet Server on the local computer or on the computer specified by server. If
you are logged on with an account that does not have the required privileges, you can
specify a user name and password of an account that does. You cannot use an Internet
Protocol version 6 (IPv6) address to specify a remote computer to administer, other than
to list sessions (the -s option).
In addition to specific command options and arguments, tnadmin accepts the
following options and arguments:
server
Specifies the remote computer you want to administer. You can specify
the computer using a Windows Internet Name Service (WINS) or Domain Name
System (DNS) name, or by Internet Protocol (IP) address.
-u usr
Specifies the user name of the user whose credentials are to be used. It
might be necessary to add the domain name to the user name in the form domain\
username.
-p pword
Specifies the password of the user designated by the -u option. If you
specify the -u option but omit the -p option, you are prompted for the user's
password.
The action that tnadmin performs depends on the command option or argument
you specify:
-s session
Lists information about the specified session. The session argument is a
session identifier (ID). If session is omitted, information about all sessions is
listed. To use this option to administer a remote computer, you must be logged on
with an account that belongs to the Administrators group on that computer.
-k session
Terminates the specified session. The session argument is either a session
ID or all to terminate all sessions. To use this option to administer a remote
computer, you must be logged on with an account that belongs to the
Administrators group on that computer.
-m session message
Sends the string specified by message to the specified session. If you use
the -u or -p options with this option, place them before the -m option to avoid
sending them as part of the message. The session argument is either a session ID
or all to send the message to all sessions. To use this option to administer a
remote computer, you must be logged on with an account that belongs to the
Administrators group on that computer.
start
Starts the Telnet Server service.
stop
Stops the Telnet Server service.
pause
Pauses the Telnet Server service.
continue
Resumes the Telnet Server service.
config option=value
Specifies general settings for Telnet Server. You must supply at least one
of the following options and values with config:
dom=defaultDomain
Sets the default domain for an unqualified user name.
ctrlakeymap={yes | no}
Specifies whether CTRL+A is interpreted as the ALT key.
timeout=[hh:[mm:]]ss
Specifies how long Telnet Server will wait before disconnecting an idle
session (in hours (hh), minutes (mm), and seconds (ss)) if config timeoutactive is
set to yes.
timeoutactive={yes | no}
Specifies whether idle sessions will be disconnected.
maxfail=value
Sets the maximum number of logon failure attempts before Telnet Server
disconnects the client.
maxconn=value
Sets the maximum number of connections.
port=value
Sets the port number to be used for Telnet sessions.
killall={yes | no}
Specifies whether applications started in a Telnet session will be
terminated when the session is disconnected.
sec=[[+|-]NTLM] [[+|-]passwd]
Sets the authentication mechanism. You can configure Telnet Server to
use NTLM authentication (NTLM), plaintext passwords (passwd), or both.
Precede the mechanism name with a plus sign (+) to enable the mechanism and
with a dash (-) to disable the mechanism.
mode={console | stream}
Specifies the mode of operation. Console mode is useful to run screen-
oriented programs such as vi. Stream mode operates similar to UNIX dumb
terminal types and is not suitable to use with programs such as vi.
If you do not supply a command option or argument, tnadmin displays current
configuration and status information.
NOTE
You can use tnadmin only to administer Telnet Server provided with Windows
Services for UNIX. The tnadmin utility does not work with other Telnet servers.
SEE ALSO
Telnet Server
top
NAME
top - Windows command-line utility to display information about processes
SYNOPSIStop [-d delay] [-q] [-s]
DESCRIPTION
The top(1w) Windows utility displays the system activity and information of the
most CPU-intensive processes on the system in real time. It provides various interactive
commands for manipulating processes, and it sorts the processes by CPU usage and
memory usage.
The top utility supports the following options:
-d
Specifies the delay time between screen updates, in seconds. It can be
changed by using the s interactive command.
-q
This causes top to refresh without any delay. If a user having
administrative permissions invokes top, it runs with the highest possible priority.
-s
This option disables the interactive commands k (kill), r (renice), and s
(update). This is used to run top in secure mode.
FIELD DESCRIPTION
The top utility displays two types of information. One is specific to the CPU and
memory information of the system (top portion), and the other is process-specific
information. They are updated every 5 seconds by default. This delay time can be
changed with the d command-line option or the s interactive command.
The system-specific information has the following fields:
Uptime
Displays the current time and the uptime information. The uptime display
can be toggled by the interactive l (lowercase L) command.
Processes and CPU states
Displays the total number of processes running at the time of the last
update. This also displays the percentage of CPU time used in kernel, user, and
idle mode. This information can be toggled by the interactive t command.
Mem
Displays the statistics of various memory usages. This gives information
about the total available memory, free memory, used memory, total available
swap space, free swap space, and used swap space. It also displays the amount of
cache memory used. This information can be toggled by the interactive m
command.
The process-specific information has the following fields:
COMMAND
Command name of the process
PID
Process ID of the process
USER
User name of the process
TIME
Total CPU time the process has used since it started
%KER
Percentage of the CPU time of the process running in privileged mode
%USE
Percentage of the CPU time of the process running in user mode
PRI
Priority of the process
RSS
Total amount of physical memory used by the process, in kilobytes
SWAP
Size of the swapped-out part of the process
%MEM
Process's share of the physical memory
THD
Number of threads in the process
%CPU
Process's share of the CPU time, expressed as the percentage of total CPU
time
INTERACTIVE COMMANDS
The following single-key commands are recognized while top is running. Some
of these commands are disabled if the s option (run top in secure mode) is given as a
command-line option.
SPACE
Immediately updates the display.
h or ?
Displays the Help screen, giving a brief summary of commands.
k
Kills a process. The user is prompted for the PID of the process to be
killed. When the PID is given, the process of the specified PID is killed if the user
has the appropriate permission. This is not available in secure mode.
n or #
Changes the number of processes to show. The user is prompted for the
number of processes. This overrides automatic determination of the number of
processes to show, which is based on window size measurement.
q
Exits the top utility.
r
Renices the process. This option prompts the user with the PID of the
process and the nice value. If the PID and nice value specified are valid, the
specified process is reniced subject to the user having appropriate permissions.
This command is not available in secure mode.
s
Changes the delay between updates. The user is prompted to enter the
delay time, in seconds. Fractional values are recognized down to microseconds.
Entering 0 (zero) causes continuous updates. The default value is 5 seconds. Note
that low delay time can greatly raise the CPU load, which is not advisable. This is
not available in secure mode.
l
(Lowercase L) Toggles display for uptime information.
m
Toggles display for memory information.
t
Toggles display for processes and CPU state information.
c
Displays full path of the command name of the process. This option
prompts the user with the PID of the process. Specifying the PID displays the path
of the corresponding process.
M
Sorts processes by physical memory usage.
P
Sorts processes by CPU usage.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
SEE ALSO
kill(1w)
ps(1w)
sleep(1w)
wait(1w)
touch
NAME
touch - Windows command-line utility to change file access and modification
times
SYNOPSIStouch [-acm] [-r file] [-t [[CC]YY]MMDDhhmm[.SS]] file...
DESCRIPTION
The touch(1w) Windows command-line utility is an implementation of the Interix
touch(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see touch(1).
tr
NAME
tr - Windows command-line utility to write the translated input characters from
standard input to standard output
SYNOPSIStr [-cs] string1 string2
tr -s [-c] string1
tr -d [-c] string1
tr -ds [-c] string1 string2
DESCRIPTION
The tr(1w) Windows utility copies the standard input to the standard output with
substitution or deletion of the selected characters. The specified options, and the string1
and string2 operands control translations that occur while copying characters and single-
character collating elements.
The operands string1 and string2 (if specified) define two arrays of characters.
You can use the constructs in the following list to specify characters or single-character
collating elements. If any of the constructs result in multicharacter collating elements, tr
excludes, without a diagnostic, those multicharacter elements from the resulting array.
character
Any character not described by one of the following conventions
represents itself.
\octal
Octal sequences can be used to represent characters with specific coded
values. An octal sequence consists of a backslash (\) followed by the longest
sequence of octal characters (01234567). The sequence causes the character
whose encoding is represented by an octal integer to be placed into the array.
\character
The backslash-escape sequences supported are \\, \a, \b, \f, \n, \r, \t, and \
v. The results of using any other character (other than an octal digit) following the
backslash are unspecified.
c-c
Represents the range of collating elements between the range endpoints,
inclusive, as defined by the current setting of the LC_COLLATE locale category.
The starting endpoint must precede the second endpoint in the current collation
order. The characters or collating elements in the range are placed in the array in
ascending collation sequence.
[:class:]
Represents all characters belonging to the defined character class, as
defined by the current setting of the LC_CTYPE locale category. The following
character class names are accepted when specified in string1:
Alnum
Blank
Digit
Lower
Punct
upper
alpha
Cntrl
graph
Space
xdigit
In addition, character class expressions of the form [:name:] are
recognized in those locales where the name keyword has been given a charclass
definition in the LC_CTYPE category. When both the -d and -s options are
specified, any of the character class names will be accepted in string2. Otherwise,
only character class names lower or upper are valid in string2, and then only if
the corresponding character class (upper and lower, respectively) is specified in
the same relative position in string1. Such a specification is interpreted as a
request for case conversion.
When [:lower:] appears in string1 and [:upper:] appears in string2, the
arrays will contain the characters from the toupper mapping in the LC_CTYPE
category of the current locale. When [:upper:] appears in string1 and [:lower:]
appears in string2, the arrays contain the characters from the tolower mapping in
the LC_CTYPE category of the current locale. The first character from each
mapping pair will be in the array for string1, and the second character from each
mapping pair will be in the array for string2 in the same relative position.
Except for case conversion, the characters specified by a character class
expression are placed in the array in an unspecified order. If the name specified
for the class does not define a valid character class in the current locale, the
behavior is undefined.
[=equiv=]
Represents all characters or collating elements belonging to the same
equivalence class as equiv, as defined by the current setting of the LC_COLLATE
locale category. When equiv is used with the combined -d and -s options, an
equivalence class expression is allowed only in string1 or string2. The characters
belonging to the equivalence class are placed in the array in an unspecified order.
[x*n]
Represents n repeated occurrences of the character x. Because this
expression is used to map multiple characters to one, it is valid only when it
occurs in string2. If n is zero or omitted, it is interpreted as large enough to extend
the string2-based sequence to the length of the string1-based sequence. If n has a
leading zero, it is interpreted as an octal value. Otherwise, it is interpreted as a
decimal value.
OPTIONS
The tr utility supports the following options:
No option
When tr is invoked without any options, and with two operands string1
and string2, each input character found in the array specified by string1 is
replaced by the character in the same relative position in the array specified by
string2. When the array specified by string2 is shorter than the one specified by
string1, the results are unspecified.
-cs
When tr is invoked with operands string1 and string2, each input
character not found in the array specified by string1 is replaced by the character
specified by string2. The repeated sequences of the character found in string2 are
then replaced by one occurrence of the same character. The string2 should be of
type [x*n]. If string2 is not of type [x*n], it is neglected and behaves as if only
one operand is specified.
-s
When tr is invoked with only one operand string1, repeated sequences of
the same character found in the array string1 are replaced by one occurrence of
the same character. When tr is invoked with operands string1 and string2, each
input character found in the array specified by string1 is replaced by the character
in the same relative position in the array specified by string2. Then the repeated
sequences of the same character found in the array string2 are replaced by one
occurrence of the same character.
-d
Deletes any character found in string1 from the input.
-cd
When tr is invoked with only one operand string1, all input characters
except those specified by string1 are deleted.
-ds
When tr is invoked with operands string1 and string2, input characters
found in the array specified by string1 are deleted. Then the repeated sequences of
the same character found in the array string2 are replaced by one occurrence of
the same character.
-dsc
When tr is invoked with operands string1 and string2, input characters not
found in the array specified by string1 are deleted. Then the repeated sequences of
the same character found in the array string2 are replaced by one occurrence of
the same character.
ARGUMENTS
The tr utility supports the following arguments:
string1, string2
Translation control strings. Each string represents a set of characters to be
converted into an array of characters used for the translation.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
EXAMPLES
tr -cs "[:alpha:]" "[\n*]"; < file1 > file2
Creates a list of all words in file1 one per line in file2, where a word is taken to be
a maximal string of letters.
tr "[:lower:]" "[:upper:]" < file1
Translates all lowercase characters in file1 to uppercase and writes the results to
the standard output.
tr "[=e=]" e < file1 > file2
Uses an equivalence class to identify accented variants of the base character e in
file1, which are stripped of diacritical marks and written to file2.
umount
NAME
umount - Windows command-line utility to remove network file system (NFS)-
mounted drives
SYNOPSISumount [-f] [{-a | driveletter:[...] | networkmount[...]}]
DESCRIPTION
The umount(1w) Windows command-line utility disconnects the specified NFS-
mounted drive. You must supply at least one of the following options or arguments.
-f
Forces deletion of network file system (NFS) network drives.
-a
Deletes all NFS network drives. If there are active connections, umount
prompts you for confirmation unless you also use the -f option.
driveletter
The letter of the logical drive to be disconnected.
networkmount
The network mount point to be disconnected. This mount must have been
created using the net use Windows command-line utility without specifying a
drive letter.
SEE ALSO
mount(1W)
uname
NAME
uname - Windows command-line utility to display information about the system
SYNOPSISuname [-aHmnpPrsvX]
DESCRIPTION
The uname(1w) Windows command-line utility is an implementation of the
Interix uname(1) command that you can run at a Windows command prompt. For more
information, see uname(1).
When uname is run at a Windows command prompt, the -H option is assumed.
uniq
NAME
uniq - Windows command-line utility to report or filter out repeated lines in a file
SYNOPSISuniq [-c|-d|-u] [-f fields] [-s chars]
[input_file[output_file]]
DESCRIPTION
The uniq(1w) Windows command-line utility is an implementation of the Interix
uniq(1) command that you can run at a Windows command prompt. The input_file and
output_file arguments must use Windows file-name and path syntax. For more
information, see uniq(1).
unix2dos
NAME
unix2dos - Windows command-line utility to convert text files with UNIX-
specific end-of-line (EOL) characters to MS-DOS-specific EOL characters.
SYNOPSISunix2dos {-h | [infile [outfile]]}
DESCRIPTION
The unix2dos Windows command-line utility converts files that use UNIX-
specific end-of-line (EOL) characters to files that use MS-DOS-specific EOL characters.
MS-DOS uses CR and LF as the end-of-line characters; UNIX uses LF.
The unix2dos command accepts the following option and arguments:
-h
Displays usage information about the command.
infile
The MS-DOS file to be converted. If infile and outfile are not specified,
the program takes input from standard input and sends it to standard output.
outfile
The UNIX output file. If outfile is not specified, the program sends output
to standard output.
Caution
The infile and outfile arguments must specify different files. Otherwise, the
resulting file will be empty.
SEE ALSO
dos2unix(1w)
uudecode
NAME
uudecode - Windows command-line utility to decode an encoded file
SYNOPSISuudecode [file]
DESCRIPTION
The uudecode(1w) and uuencode(1w) Windows utilities are used to transmit
binary files over transmission media that support only simple ASCII data.
The uudecode utility decodes back to original format a file that has been encoded
using uuencode.
The uudecode utility reads a file or standard input (if no file is specified) that
includes data created by the uuencode utility. This utility scans the input file, searching
for data compatible with the format specified in uuencode, and attempts to create or
overwrite the file described by the data. The path is contained in that data. The
permissions for the file are the default when the file is created.
If the path of the file to be produced exists, and the user does not have write
permission on that file, uudecode terminates with an error. If the path of the file to be
produced does exist, and the user has write permission on that file, the existing file is
overwritten.
ARGUMENTS
The uudecode utility supports the following argument:
file
The path of the file containing the output of the uuencode utility.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
NOTES
The user who is invoking uudecode must have write permission on any file being
created.
The input files must be files containing the output of uuencode.
The output file will be in the same format as the file originally encoded by
uuencode.
If the input data was produced by uuencode on a system with a different number
of bits per byte than the target system, the results of uudecode are unspecified.
SEE ALSO
uuencode(1w)
uuencode
NAME
uuencode - Windows command-line utility to encode a given binary file
SYNOPSISuuencode [file] decodePathname
DESCRIPTION
The uuencode(1w) Windows utility writes an encoded version of the named input
file (or standard input if no file is specified).
The file is expanded by 35 percent (each three octets become four, plus control
information), causing it to take a longer time to transmit.
The output from uuencode is a text file on the local system. The encoding
algorithm is described in terms of eight-bit quantities, or octets. Because no byte
alignment is implied, it encodes data from machines with any number of bits per byte.
Unless that encoded data is decoded on a computer with the same number of bits per
byte, however, the output might not be useful.
ARGUMENTS
The uuencode utility supports the following argument:
decodePathname
The path of the file into which uudecode places the decoded file. If there
are characters in decodePathname that are not in the portable file name character
set, the results are unspecified.
file
The path of the file to be encoded.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
SEE ALSO
uudecode(1w)
vi
NAME
vi - Windows command-line utility text editor
SYNOPSISvi [-eFlRrv] [-c cmd] [-t tag] [-w size] [file ...]
DESCRIPTION
The vi(1w) Windows command-line utility is an implementation of the Interix
vi(1) command that you can run at a Windows command prompt. The file argument must
use Windows file-name and path syntax, and the files should be in Windows text format
(that is, with lines ending with carriage-return/line-feed characters). When run as a
Windows command-line utility, vi saves files in Windows text format.
For more information, see vi(1).
wait
NAME
wait - Windows command-line utility to wait for the termination of processes or
jobs
SYNOPSISwait {pid... | -j jobname...}
DESCRIPTION
The wait(1w) Windows utility waits for the completion of processes or jobs. If a
list of process identifiers is given, wait waits until all of them have terminated. If a list of
job names is given, wait waits until all the processes belonging to those jobs have
terminated.
OPTIONS
The wait utility supports the following option:
-j
Interprets all operands as job names.
ARGUMENTS
The wait utility supports the following argument:
pid
The unique identifier of a process for which the wait utility has to wait.
jobname
The wait utility waits for the completion of all processes belonging to the
job specified by jobname.
DIAGNOSTICS
The exit status returned by the wait utility will be the exit status of the process
requested by the last pid operand.
The other possible exit-status values are:
126
The wait utility detected an error.
127
The command identified by the last specified pid operand is unknown.
NOTES
If one or more pid operands are specified, which represent unknown process
identifiers (PIDs), wait treats them as if they were known PIDs that exited with
the exit status 127.
SEE ALSO
kill(1w)
ps(1w)
top(1w)
sleep(1w)
wc
NAME
wc - Windows command-line utility to provide word, line, and byte count
SYNOPSISwc [-c|-m [-lsw]] [ file...]
DESCRIPTION
The wc(1w) Windows command-line utility is an implementation of the Interix
wc(1) command that you can run at a Windows command prompt. The file argument
must use Windows file-name and path syntax. For more information, see wc(1).
which
NAME
which - Windows command-line utility to locate a command
SYNOPSISwhich [-a] [-d] command...
DESCRIPTION
The which(1w) Windows utility displays the full path for executable commands
(.exe or .com files) and dynamic-link libraries (.dll files).
If the user does not specify an extension in command, which first appends .exe to
command and searches in the directories listed by the PATH environment variable. If the
search fails, the above procedure is repeated for the extensions .com and then, if the -d
option is specified, .dll.
OPTIONS
The which utility supports the following option:
-a
Displays all matching files from every directory in the PATH environment
variable, not just the first match. This helps reveal conflicts between two files of
the same name.
-d
Searches for files with the .dll extension if a matching file with the .exe
or .com extension is not found.
ARGUMENTS
The which utility supports the following argument:
command
Specifies the command or dynamic-link library whose full path is to be
displayed.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
1
Failure
EXAMPLES
Assume PATH = c:\system\temp;c:\system;c:\...
Assume that test.exe is present in both c:\system\temp and c:\system, and that
test.dll is present in c:\system.
The following illustrates a few commands and the corresponding results:
which test.exe
C:\system\temp\test.exe
which -a test.exe
C:\system\temp\test.exe
C:\system\test.exe
which test
C:\system\temp\test.exe
which -a test
C:\system\temp\test.exe
C:\system\test.exe
C:\system\test.dll
xargs
NAME
xargs - Windows command-line utility to constructs argument lists and invoke a
utility
SYNOPSISxargs [-t] [-p] [-e[eofstr]] [-E eofstr] [-I replstr]
[-i[replstr]] [-L number] [-l [number]]
[-n number [-x]] [-s size] [utility [argument...]]
DESCRIPTION
The xargs(1w) Windows utility constructs a command line consisting of the
specified utility and argument operands. This is followed by as many arguments as will
fit, according to the length and number of constraints specified by the options. The
arguments are read in sequence from the standard input. The xargs utility then invokes
the constructed command line and waits for its completion. This sequence is repeated
until an end-of-file condition is detected on the standard input, or an invocation of a
constructed line returns an exit status of 255.
The xargs utility supports the following options:
-e
eofstr is taken as the logical end-of-file string. Underscore (_) is assumed
for the logical EOF string if neither -e nor -E is specified. The value -e with no
specified eofstr turns off the logical EOF string capability (underscore is taken
literally). The xargs utility reads the standard input until it encounters end-of-file
or the logical EOF string.
-E
Specifies a logical end-of-file string to replace the default underscore. The
xargs utility reads standard input until it encounters end-of-file or the logical EOF
string.
-I
Insert mode. The utility is run for each line from the standard input, taking
the entire line as a single argument and inserting it into initial-arguments for each
occurrence of replstr. A maximum of five arguments in initial-arguments can
each contain one or more instances of replstr. Blanks and tabs at the beginning of
each line are discarded. Constructed arguments cannot exceed 255 bytes. The -I
option forces the -x option. The -I and -i options are mutually exclusive; the last
one specified takes effect.
-i
This option is equivalent to -I [replstr]. The string{} is assumed for replstr
if the option argument is omitted.
-L
The utility is run for each nonempty number lines of arguments from the
standard input. The last invocation of utility will contain fewer lines of arguments
than specified if fewer than number remain. A line is considered to end with the
first newline unless the last character of the line is a blank or a tab. A trailing
blank or tab signals continuation through the next nonempty line. The -L, -l, and -
n options are mutually exclusive; the last one specified takes effect.
-l (Lowercase L)
This option is equivalent to -L number. If number is omitted, 1 (one) is
assumed. The -l option forces the -x option.
-n
Runs utility using as many standard input arguments as possible, up to a
maximum of number (a positive decimal integer) arguments. Fewer arguments are
used if either of the following conditions exist:
The accumulated command-line length exceeds the size specified by the -s
option (or, if there is no -s option, {LINE_MAX(255)}).
The last iteration has fewer than number, but not zero, operands
remaining.
-p
(Prompt mode) Asks the user whether to run utility at each invocation.
Trace mode (-t option) is turned on to print the utility to be run, followed by a
prompt to the standard error. A reply of y (optionally followed by anything) runs
utility. Anything else, including just a carriage return, skips that particular
invocation of utility.
-s
Invokes utility using as many standard input arguments as possible,
yielding a command-line length less than size (a positive decimal integer) bytes.
Fewer arguments will be used if any of the following conditions exist:
The total number of arguments exceeds that specified by the -n option.
The total number of lines exceeds that specified by the -L option.
End-of-file is encountered on the standard input before size bytes are
accumulated.
-t
(Trace mode) The utility and each constructed argument list are echoed to
standard error just prior to their execution.
-x
Causes xargs to terminate if any argument list would be greater than size
characters. The -i, -I, -l, and -L options force the -x option. When none of the
options -i, -I, -l, -L, or -n are specified, the total length of all arguments must be
within the size limit.
DIAGNOSTICS
Possible exit-status values are:
0
Successful completion
126
The utility was found but could not be invoked.
127
The utility could not be found.
Exit code of the invoked utility
One or more of the invocations of utility returned a nonzero status.
ypcat
NAME
ypcat - Windows command-line utility to print values of all keys in an NIS map
SYNOPSISypcat [-k] [-t] [-h nisServer] [-d domain] mapname
ypcat -x
DESCRIPTION
The ypcat(1w) Windows command-line utility prints the values of all keys from
the Network Information Service (NIS) database specified by mapname, which can be a
map name or a map nickname.
The ypcat command accepts the following options and arguments:
-k
Displays map keys. This option is useful with maps in which the values
are null or the key is not part of the value.
-t
Inhibits map nickname translation.
-d domain
Specifies the NIS domain. If this option is not used, the NIS domain is
assumed to be the domain named in the DEFAULT_NIS_DOMAIN environment
variable.
-h nisServer
Specifies the name of the NIS server. If this option is not used, the NIS
server is assumed to be the server named in the NIS_SERVER environment
variable.
-x
Displays the map nickname translation table.
SEE ALSO
ypmatch(1w)
Server for NIS
ypclear
NAME
ypclear - Windows command-line utility to clear the Network Information Service
(NIS) server cache for an NIS map and its dependent maps
SYNOPSISypclear [-d domainName] [-t] [-h nisServer] mapname
ypclear -x
DESCRIPTION
The ypclear(1w) Windows command-line utility tells the specified Network
Information Service (NIS) server in a specified domain that a map has changed and that
the server should clear its cache. Without this notification, the NIS server can sometimes
serve out-of-date information. Running ypclear should not usually be necessary, but if an
NIS server is serving out-of-date information, ypclear should correct the problem.
The ypclear command accepts the following options and arguments:
-d domain
Specifies the NIS domain. If this option is not used, the NIS domain is
assumed to be the domain named in the DEFAULT_NIS_DOMAIN environment
variable.
-t
Inhibits map nickname translation.
-h nisServer
Specifies the name of the NIS server. If this option is not used, the NIS
server is assumed to be the server named in the NIS_SERVER environment
variable.
-x
Displays the map nickname translation table.
SEE ALSO
Server for NIS
ypmatch
NAME
ypmatch - Windows command-line utility to display the values of one or more
keys from a Network Information Service (NIS) map
SYNOPSISypmatch [-k] [-t] [-d domain] [-h nisServer] key[...] mapname
ypmatch -x
DESCRIPTION
The ypmatch(1w) Windows command-line utility displays the values one or
more keys from the Network Information Service (NIS) map specified by mapname,
which may be a map name or a map nickname.
The ypmatch command accepts the following options and arguments:
-k
Displays map keys. This option is useful with maps in which the values
are null or the key is not part of the value.
-t
Inhibits map nickname translation.
-d domain
Specifies the NIS domain. If this option is not used, the NIS domain is
assumed to be the domain named in the DEFAULT_NIS_DOMAIN environment
variable.
-h nisServer
Specifies the name of the NIS server. If this option is not used, the NIS
server is assumed to be the server named in the NIS_SERVER environment
variable. If NIS_SERVER is not set, ypmatch broadcasts the request.
key
The key for which you want to display the value. To display the value of
more than one key, specify the keys separated by spaces. If any key begins with a
slash mark (/), backslash (\) or hyphen (-), these special characters must be
preceded by a backslash (\). For example, if the key name is \mykey, then use \\
mykey.
-x
Displays the map nickname translation table.
SEE ALSO
ypcat(1w)
Server for NIS
yppush
NAME
yppush - Force propagation of a changed Network Information Service (NIS) map
SYNOPSISyppush [-d adNisDomain] [-q] [-t timeout] [-h host[...]] mapname
DESCRIPTION
The yppush(1w) Windows command-line utility sends a request to subordinate
(also known as slave) NIS servers to transfer a new version of the NIS map specified by
mapname from the master NIS server. It is run only on the master NIS server after the
NIS map has been changed. If the -h option is specified, the transfer request is sent only
to the specified server. Otherwise, yppush first constructs a list of NIS server hosts by
reading the ypservers NIS map within the domain. For more information about the
correct format of the ypservers map, see "Notes" later in this topic.
A transfer map request is sent to the NIS server at each host to the transfer agent
at that host (the program that actually moves the map) to call back the master server.
When the attempt has completed (successfully or not), and the transfer agent has sent
yppush a status message, the results can be printed to standard output. Messages are also
printed when a transfer is not possible, for instance when the request message is
undeliverable, or when the time-out period on responses has expired.
The yppush command accepts the following options and arguments:
-d adNisDomain
Specifies the NIS domain. If this option is not used, the NIS domain is
assumed to be the domain named in the DEFAULT_NIS_DOMAIN environment
variable.
-q
Quiet mode. Does not wait for a response from subordinate servers, and
does not report errors.
-t timeout
Specifies a time-out value, in seconds, that yppush will wait for a
response from the subordinate server. This value must be greater than zero. The
default value is 30 seconds.
-h host[...]
The name of the host to notify of the map change. You can specify
multiple host names, separated by spaces. If you do not specify this option, the
notification is sent to all subordinate servers in the domain.
NOTES
Keys within the ypservers map are the ASCII names of the computers on which
the NIS servers run. That is, the ypservers map should contain a list of NIS servers, each
one listed on a separate line. If your ypservers map contains aliases, edit the ypservers
map to contain only the host names of the servers, one per line. The following list is an
example of a valid ypservers map:
ypserver_1
ypserver_2
ypserver_3
SEE ALSO
Server for NIS
Top Related