uux(1) uux(1) 名称 uux - UUCP を用いて、リモートマシン上でコマンドを実行する 書式 uux [ options ] command 解説 uux コマンドは、リモートマシン上でコマンドを実行する場合や、リモートシ ステム上のファイルを用いてローカルシステム上でコマンドを実行するため に 用 いられます。コマンドは、即座に実行されるわけではなく、 uucico (8) デ ーモンが他のシステムを呼び出してジョブを実行するまでは、キューイング さ れ ます。デーモンは、 -r または --nouucico オプションを指定して本コマン ドを実行しない限りは、自動的に走り出します。 実際にコマンドを実行するのは、 uuxqt (8) デーモンです。 引数に指定されたファイルは、リモートシステムから、実際にコマンド実行 を 行 うシステムに集められます。標準入力についても同様です。標準出力は、リ モートシステム上のファイルに出力されます。 リモートシステム上でコマンド実行をする場合は、コマンド名の前に、シス テ ム名と "!" マークをつけます。システム名がない場合には、ローカルシステム 上でのコマンド実行であるとみなされます。 "!" マークを含む各引数は、ファイル名であるとみなされます。 "!" マークの 前 はファイルが存在するシステム名を、後にはファイルへのパス名を記述しま す。システム名がない場合には、ローカルシステム上のファイルであるとみ な さ れます。この場合、コマンドの実行されるリモートシステムへファイル転送 が発生します。パスが絶対パスでない場合、現在のローカルシステム上の作 業 デ ィレクトリ名がそのパス名の前に付加されます。この場合、リモートシステ ム上で無効なパスとなってしまうかも知れません。また、パス名として ~/ が 先 頭 に 付加されている場合、これは UUCP パブリックディレクトリ (通常は /usr/spool/uucppublic) からの相対パスであるとみなされます。 一 般 的 に 、~name で始まるディレクトリは、その名前のユーザのホームディレクトリか らの相対パスであるとみなされます。 標準入出力は、普通にリダイレクトされます。パス名の中に "!" を含む場合は 、 そのファイルはリモートシステム上にあるものとして扱われます。リダイレ クトキャラクタを使う場合には、シェルで解釈されずに uux に渡されるように 、 ク ォ ートしなくてはなりません。また、追加書き込みのリダイレクション (>>) は使用できません。 指定された全てのファイルは、コマンド実行前に、1つのディレクトリに集めら れ ます。これは、各ファイルは異なるベースネームを持つ必要があるというこ とを意味します。例えば、 uux ’sys1!diff sys2!~user1/foo sys3!~user2/foo >!foo.diff’ は、コマンド実行時に失敗します。なぜなら、両方のファイルが sys1 に同 一 のファイル名 foo でコピーされるからです。 引数を括弧で括ることで "!" が解釈されるのを防ぐことができます。これは、 uucp コマンドをリモートシステム上で実行する際に有用です。 コマンド名なしの実行要求 (例えば uux sys! ) は、指定したシステム 用 の poll ファイルを作成します。 オプション 以下のオプションが uux で使用可能です。 -,-p, --stdin 標準入力から読み込み、それをコマンド実行時の標準入力として使います 。 -c, --nocopy ローカルファイルをスプールディレクトリにコピーしません。デフォルト はこの設定です。もし、 uucico (8) デーモンの実行前にファイルが消去 されてしまった場合、コピーは失敗します。ファイルは、 uucico (8) デ ー モンと uux を起動したユーザの両者から読み込み可能でなければなり ません。 -C, --copy ローカルファイルをスプールディレクトリにコピーします。 -l, --link ローカルファイルをスプールディレクトリの下にハードリンクします。フ ァイルがスプールディレクトリと異なる物理デバイス上に存在する場合、 リンクは張れません。この場合、 -c または --nocopy オプションが指定 されていない限り、スプールディレクトリの下に対象ファイルをコピーし ます (言い替えると、 --link を使うとデフォルトが --nocopy か ら --copy にかわるということです)。ファイルが uucico (8) デーモンの処 理前に変更された場合、転送されるファイルは変更後のファイルになりま す 。ファイルは、 uucico (8) デーモンと uux を起動したユーザの両者 から読み込み可能でなければなりません。 -g grade, --grade grade ファイル転送コマンドの優先度を設定します。高い優先度を持つジョブが 先 に実行されます。優先度は、高い順に 0 ... 9 A ... Z a ... z とな っています。 -n, --notification=no ジョブの結果を通知するメールを送りません。たとえジョブが失敗しても です。 -z, --notification=error エ ラー発生時に、ジョブのステータスに関するメールを送ります。 Tay- lor UUCP の uuxqt を含む多くの uuxqt デーモンでは、この動作はデ フ ォルトです。このような場合、 --notification=error は何の効果もあり ません。しかし、 --notification=error オプションを設定していないと ジ ョ ブ が 成 功 し た場合にメールを送る uuxqt デーモンもあれば、 --notification=error オプションを指定しないとジョブが失敗した時 に メールを送ってくれないという uuxqt デーモンもあります。 -r, --nouucico uucico (8) デーモンを即時には実行しません。後で処理されるように要 求をキューに貯めるだけです。 -j, --jobid ジョブ id を標準出力に表示します。ジョブ id は、各ファイルコピー操 作を行うよう要求されるたびに生成されます。これらのファイルコピー操 作は、 uustat (1) の --kill スイッチで jobid を渡すことでを用い る ことで取り消し可能ですが、そうするとそのジョブは終了不能になります 。 -a address, --requestor address 指定した E-mail アドレスに対してジョブのステータスを報告します。 -x type, --debug type 特定のデバッグタイプを有効にします。タイプ と し て は 、abnormal, chat, handshake, uucp-proto, proto, port, config, spooldir, exe- cute, incoming, outgoing があります。 uux で意味があるのは、abnor- mal, config, spooldir, execute の 4 つだけです。本オプションでは、 コンマで区切ることで複数のデバッグタイプが指定可能です。デバッグタ イ プをカンマで区切って複数指摘することもできますし、 --debug オプ ションを複数個指定することも可能で、たくさんのデバッグタイプを一度 に 設 定 す る こ と ができます。例えば、 --debug 2 という指定は、 --debug abnormal,chat と同じ意味です。 -I file, --config file 使用するコンフィギュレーションファイルを設定します。ただし、本オプ シ ョンが使用可能かどうかは、 uux がどのようにコンパイルされたかに よります。 -v, --version バージョン情報を表示して終了します。 --help ヘルプメッセージを表示して終了します。 使用例 uux -z - sys1!rmail user1 コマンド‘‘rmail user1’’ を、システム sys1 上で実行します。コマンドへ の 入 力 データは、標準入力が用いられます。ジョブが失敗した場合、 mail (1) コマンドによってメッセージが送られてきます。 uux ’diff -c sys1!~user1/file1 sys2!~user2/file2 >!file.diff’ システム sys1 とシステム sys2 上にあるファイルを取得し、 diff を実行 し た上で、カレントディレクトリのファイル file.diff に結果を格納します。こ れがきちんと働くためには、カレントディレクトリが uuxqt (8) デーモンによ って書き込める状態でなければなりません。 uux ’sys1!uucp ~user1/file1 (sys2!~user2/file2)’ uucp を sys1 上で実行し、sys1 上のファイル file1 を sys2 上にコピーしま す。この例では、クォート用の括弧の使い方を示してあります。 制限 リモートシステムでは、実行が許可されていないコマンドがあるかもしれま せ ん 。多くのリモートシステムでは、 rmail と rnews しか実行を許可していま せん。 オプションのうちいくつかは、リモートシステム上の uuxqt (8) デーモンの能 力に依存します。 関連ファイル こ れらのファイル名は、コンパイル時もしくはコンフィギュレーションファイ ルで変更されうるため、一例にすぎません。 /usr/lib/uucp/config - 初期化ファイル /usr/spool/uucp - UUCP スプールディレクトリ /usr/spool/uucp/Log - UUCP ログファイル /usr/spool/uucppublic - デフォルトの UUCP パブリックディレクトリ 関連項目 mail(1), uustat(1), uucp(1), uucico(8), uuxqt(8) バグ 複数のシステムにまたがって、ファイル参照をすることはできません。 --jobid オプションを使うと、ジョブ id が非常に多く出力されてしまいま す 。 また、リモートファイルを必要とするローカル実行要求をキャンセルする良 い方法は存在しません。 作者 Ian Lance Taylor (ian@airs.com) Taylor UUCP 1.06 uux(1)
UUX(1P) POSIX Programmer’s Manual UUX(1P)
PROLOG
This manual page is part of the POSIX Programmer’s Manual. The Linux
implementation of this interface may differ (consult the corresponding
Linux manual page for details of Linux behavior), or the interface may
not be implemented on Linux.
NAME
uux - remote command execution
SYNOPSIS
uux [-np] command-string
uux [-jnp] command-string
DESCRIPTION
The uux utility shall gather zero or more files from various systems,
execute a shell pipeline (see Shell Commands ) on a specified system,
and then send the standard output of the command to a file on a speci-
fied system. Only the first command of a pipeline can have a system-
name! prefix. All other commands in the pipeline shall be executed on
the system of the first command.
The following restrictions are applicable to the shell pipeline pro-
cessed by uux:
* In gathering files from different systems, pathname expansion shall
not be performed by uux. Thus, a request such as:
uux "c99 remsys!~/*.c"
would attempt to copy the file named literally *.c to the local system.
* The redirection operators ">>", "<<", ">|", and ">&" shall not be
accepted. Any use of these redirection operators shall cause this
utility to write an error message describing the problem and exit
with a non-zero exit status.
* The reserved word ! cannot be used at the head of the pipeline to
modify the exit status. (See the command-string operand description
below.)
* Alias substitution shall not be performed.
A filename can be specified as for uucp; it can be an absolute path-
name, a pathname preceded by ~ name (which is replaced by the corre-
sponding login directory), a pathname specified as ~/ dest ( dest is
prefixed by the public directory called PUBDIR; the actual location of
PUBDIR is implementation-defined), or a simple filename (which is pre-
fixed by uux with the current directory). See uucp for the details.
The execution of commands on remote systems shall take place in an exe-
cution directory known to the uucp system. All files required for the
execution shall be put into this directory unless they already reside
on that machine. Therefore, the application shall ensure that non-local
filenames (without path or machine reference) are unique within the uux
request.
The uux utility shall attempt to get all files to the execution system.
For files that are output files, the application shall ensure that the
filename is escaped using parentheses.
The remote system shall notify the user by mail if the requested com-
mand on the remote system was disallowed or the files were not accessi-
ble. This notification can be turned off by the -n option.
Typical implementations of this utility require a communications line
configured to use the Base Definitions volume of IEEE Std 1003.1-2001,
Chapter 11, General Terminal Interface, but other communications means
may be used. On systems where there are no available communications
means (either temporarily or permanently), this utility shall write an
error message describing the problem and exit with a non-zero exit sta-
tus.
The uux utility cannot guarantee support for all character encodings in
all circumstances. For example, transmission data may be restricted to
7 bits by the underlying network, 8-bit data and filenames need not be
portable to non-internationalized systems, and so on. Under these cir-
cumstances, it is recommended that only characters defined in the
ISO/IEC 646:1991 standard International Reference Version (equivalent
to ASCII) 7-bit range of characters be used and that only characters
defined in the portable filename character set be used for naming
files.
OPTIONS
The uux utility shall conform to the Base Definitions volume of
IEEE Std 1003.1-2001, Section 12.2, Utility Syntax Guidelines.
The following options shall be supported:
-p Make the standard input to uux the standard input to the com-
mand-string.
-j Write the job identification string to standard output. This job
identification can be used by uustat to obtain the status or
terminate a job.
-n Do not notify the user if the command fails.
OPERANDS
The following operand shall be supported:
command-string
A string made up of one or more arguments that are similar to
normal command arguments, except that the command and any file-
names can be prefixed by system-name!. A null system-name shall
be interpreted as the local system.
STDIN
The standard input shall not be used unless the ’-’ or -p option is
specified; in those cases, the standard input shall be made the stan-
dard input of the command-string.
INPUT FILES
Input files shall be selected according to the contents of command-
string.
ENVIRONMENT VARIABLES
The following environment variables shall affect the execution of uux:
LANG Provide a default value for the internationalization variables
that are unset or null. (See the Base Definitions volume of
IEEE Std 1003.1-2001, Section 8.2, Internationalization Vari-
ables for the precedence of internationalization variables used
to determine the values of locale categories.)
LC_ALL If set to a non-empty string value, override the values of all
the other internationalization variables.
LC_CTYPE
Determine the locale for the interpretation of sequences of
bytes of text data as characters (for example, single-byte as
opposed to multi-byte characters in arguments).
LC_MESSAGES
Determine the locale that should be used to affect the format
and contents of diagnostic messages written to standard error.
NLSPATH
Determine the location of message catalogs for the processing of
LC_MESSAGES .
ASYNCHRONOUS EVENTS
Default.
STDOUT
The standard output shall not be used unless the -j option is speci-
fied; in that case, the job identification string shall be written to
standard output in the following format:
"%s\n",
コロナウイルスの日ごとの感染者数・死者数をグラフ化してみました。どの国が増加傾向にあり、どの国が終息に向かっているかを視覚化しています。
Copyright(C) linux-cmd.com All Rights Reserved. Author Takayuki Yukawa