rcp(1) 맨 페이지 - 윈디하나의 솔라나라

개요

섹션
맨 페이지 이름
검색(S)

rcp(1)

rcp(1)                           User Commands                          rcp(1)

NAME
       rcp - remote file copy

SYNOPSIS
       rcp [-p] filename1 filename2


       rcp [-pr] filename... directory

DESCRIPTION
       Caution -




         All  data  exchanges over this protocol are performed without encryp‐
         tion, and have no protection against spoofing or snooping of traffic.
         The in.rshd server is disabled by default on Oracle Solaris and  most
         other  modern  operating systems, and both the in.rshd server and the
         rcp command may be removed in future versions of Oracle Solaris.  Use
         of the scp(1) or sftp(1) utilities is strongly recommended instead.



       The  rcp command copies files between machines. Each filename or direc‐
       tory argument is either a remote file name of the form:

         hostname:path



       or a local file name (containing no : (colon) characters, or  /  (back‐
       slash) before any : (colon) characters).


       The  hostname  can  be an IPv4 or IPv6 address string. See inet(4P) and
       inet6(4P). Since IPv6 addresses already contain  colons,  the  hostname
       should be enclosed in a pair of square brackets when an IPv6 address is
       used.  Otherwise, the first occurrence of a colon can be interpreted as
       the separator between hostname and path. For example,

         [1080::8:800:200C:417A]:tmp/file



       If a filename is not a full path name, it is  interpreted  relative  to
       your  home directory on hostname. A path on a remote host can be quoted
       using \, ", or ', so that the metacharacters are interpreted remotely.


       rcp does not prompt for passwords. It  uses  your  current  local  user
       name, which must be accepted on hostname to allow remote command execu‐
       tion by rsh(1).


       rcp  handles  third party copies, where neither source nor target files
       are on the current machine. Hostnames can also take the form

         username@hostname:filename



       to use username rather than your current local user name  as  the  user
       name  on  the  remote host. File names that are not full path names are
       interpreted relative to the home directory of the user named  username,
       on the remote host.

OPTIONS
       The following options are supported:

       -p    Attempts  to  give  each copy the same modification times, access
             times, modes, and ACLs if applicable as the original file.


       -r    Copies each subtree rooted at filename; in this case the destina‐
             tion must be a directory.


EXIT STATUS
       The following exit values are returned:

       0     All files were copied successfully.


       >0    An error occurred.



       See the NOTES section for caveats on the exit code.

ATTRIBUTES
       See attributes(7) for descriptions of the following attributes:

       tab() box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) ATTRIBUTE  TYPEAT‐
       TRIBUTE   VALUE   _  Availabilitynetwork/legacy-remote-bsd-utilities  _
       CSIEnabled _ Interface StabilityObsolete


SEE ALSO
       cpio(1), ftp(1), rlogin(1), rsh(1), rsync(1), scp(1), sftp(1),  tar(1),
       inet(4P), inet6(4P), ip6(4P), hosts.equiv(5), attributes(7), in.rshd(8)

NOTES
       rcp  is meant to copy between different hosts. Attempting to rcp a file
       onto itself, as with:

         example% rcp /tmp/file myhost:/tmp/file



       results in a severely corrupted file.


       rcp might not correctly fail when the target of a copy is  a  file  in‐
       stead of a directory.


       rcp   can  become  confused  by  output  generated  by  commands  in  a
       $HOME/.profile or other shell startup file on the remote host.


       rcp requires that the source host have permission to  execute  commands
       on the remote host when doing third-party copies.


       rcp does not properly handle symbolic links. Use rsync(1), or tar(1) or
       cpio(1)  piped to ssh to obtain remote copies of directories containing
       symbolic links or named pipes.


       If you forget to quote metacharacters intended for the remote host, you
       get an incomprehensible error message.


       rcp fails if you copy ACLs to a file system that does not support ACLs.


       rcp is CSI-enabled except for the handling of username,  hostname,  and
       domain.


       When  rcp is used to perform third-party copies where either of the re‐
       mote machines is not running Solaris, the exit code  cannot  be  relied
       upon. That is, errors could occur when success is reflected in the exit
       code,  or  the copy could be completely successful even though an error
       is reflected in the exit code.


       This technology may be removed in a future release of Oracle Solaris.

HISTORY
       Support for Kerberos, including the options -a, -k, -K, -PN,  -PO,  and
       -x,  was added in Solaris 10 3/05 and removed in Oracle Solaris 11.4.0.
       Prior to Solaris 10, a kerberized version was available in the Sun  En‐
       terprise Authentication Mechanism (SEAM) add-on package for Solaris.


       Support for IPv6 was added in Solaris 8.


       The  rcp command, including support for the options -p and -r, has been
       present since the initial release of Solaris.

Oracle Solaris 11.4               28 Jun 2023                           rcp(1)
맨 페이지 내용의 저작권은 맨 페이지 작성자에게 있습니다.
RSS ATOM XHTML 5 CSS3