Skip Navigation Links | |
Exit Print View | |
Oracle Solaris 11.1 Administration: Devices and File Systems Oracle Solaris 11.1 Information Library |
1. Managing Removable Media (Tasks)
2. Writing CDs and DVDs (Tasks)
4. Dynamically Configuring Devices (Tasks)
5. Managing USB Devices (Tasks)
6. Using InfiniBand Devices (Overview/Tasks)
9. Administering Disks (Tasks)
11. Configuring Storage Devices With COMSTAR (Tasks)
12. Configuring and Managing the Oracle Solaris Internet Storage Name Service (iSNS)
13. The format Utility (Reference)
14. Managing File Systems (Overview)
15. Creating and Mounting File Systems (Tasks)
16. Configuring Additional Swap Space (Tasks)
17. Copying Files and File Systems (Tasks)
Commands for Copying File Systems
Copying Directories Between File Systems (cpio Command)
How to Copy Directories Between File Systems (cpio)
Copying Files and File Systems to Tape
Copying Files to Tape (tar Command)
How to Copy Files to a Tape (tar)
How to List the Files on a Tape (tar)
How to Retrieve Files From a Tape (tar)
Copying Files to a Tape With the pax Command
How to Copy Files to a Tape (pax)
Copying Files to Tape With the cpio Command
How to Copy All Files in a Directory to a Tape (cpio)
How to List the Files on a Tape (cpio)
How to Retrieve All Files From a Tape (cpio)
How to Retrieve Specific Files From a Tape (cpio)
$ tar cvf - filenames | ssh remote-host dd of=/dev/rmt/n obs=block-size
Creates a tape archive, lists the files as they are archived, and specifies the tape device.
Provides additional information about the tar file entries.
Represents a placeholder for the tape device.
Identifies the files to be copied. Separate multiple files with spaces.
Pipes the tar command's output to a remote system.
Represents the output device.
Represents the blocking factor.
Example 17-10 Copying Files to a Remote Tape Drive (tar and dd)
# tar cvf - * | ssh mercury dd of=/dev/rmt/0 obs=126b password: a answers/ 0 tape blocks a answers/test129 1 tape blocks a sc.directives/ 0 tape blocks a sc.directives/sc.190089 1 tape blocks a tests/ 0 tape blocks a tests/test131 1 tape blocks 6+9 records in 0+1 records out
$ cd /var/tmp
$ ssh remote-host dd if=/dev/rmt/n | tar xvBpf -
Indicates a secure shell that is started to extract the files from the tape device by using the dd command.
Indicates the input device.
Pipes the output of the dd command to the tar command, which is used to restore the files.
$ ls -l
Example 17-11 Extracting Files From a Remote Tape Drive
$ cd /var/tmp $ ssh mercury dd if=/dev/rmt/0 | tar xvBpf - password: x answers/, 0 bytes, 0 tape blocks x answers/test129, 48 bytes, 1 tape blocks 20+0 records in 20+0 records out x sc.directives/, 0 bytes, 0 tape blocks x sc.directives/sc.190089, 77 bytes, 1 tape blocks x tests/, 0 bytes, 0 tape blocks x tests/test131, 84 bytes, 1 tape blocks $ ls -l