Solved

How do I copy files from a Sun Solaris to an external hard drive

Posted on 2009-04-09
7
662 Views
Last Modified: 2013-12-27
Hi,

I have a external hard drive(USB connected to my sun solaris 10 server)....It see's the drive and I"m trying to copy data from sun solaris machine to the external hard drive. What commands do I use to do this...

Do I use ufsdump or just use  cp to copy  the files.
0
Comment
Question by:anthony
  • 3
  • 2
  • 2
7 Comments
 
LVL 22

Expert Comment

by:blu
ID: 24110551
Unless there is something unusual about the files, just use the cp command.
0
 

Author Comment

by:anthony
ID: 24110753
I copying the entire Sun file system...

Can just do cp /dev/rmt/c1t0d0s0 /rmdisk/unnamed_rmdisk
0
 
LVL 22

Expert Comment

by:blu
ID: 24111070
Are you sure you meant /dev/rmt and not /dev/dsk or /dev/rdsk?  No, you don't want to use cp if you are copying the
whole disk like that. In that case ufsdump would be a better choice, but the external disk  should already be formatted with a UFS file system.
0
Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

 
LVL 40

Expert Comment

by:omarfarid
ID: 24111857
you need to have the disk partitioned (use format command) and then create a file system on the selected partition (use newfs) and then mounted on a dir (use mount) and then you can use ufsdump and ufsrestore to copy files from your system filesystems to that new file system
0
 
LVL 22

Expert Comment

by:blu
ID: 24112576
It would be a good idea if you explained exactly what you are trying to accomplish.
0
 

Author Comment

by:anthony
ID: 24133700
I'm coping the entire sun file structure on the external hard drive...How can I ufsdump commands to point to the external hard drive..
0
 
LVL 40

Accepted Solution

by:
omarfarid earned 500 total points
ID: 24134307
the steps were given in earlier posting:

- partition the external disk, run

format
then choose number that corresponds to external disk
then choose p(artition)
then select a slice to set start and size
save and exit

- then create a file system on the new slice using newfs command, e.g.

newfs /dev/rdsk/c0d6t0s1 (put the real disk slice name)

- then mount the new slice with the command mount, e.g.

mount /dev/dsk/c0d6t0s1 /mnt

- run

ufsdump -0f - /path | (cd /mnt ; ufsrestore xf - )

- if your system is more than one file system then you need to create as many as partitions on the new disk as above
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

My previous tech tip, Installing the Solaris OS From the Flash Archive On a Tape (http://www.experts-exchange.com/articles/OS/Unix/Solaris/Installing-the-Solaris-OS-From-the-Flash-Archive-on-a-Tape.html), discussed installing the Solaris Operating S…
FreeBSD on EC2 FreeBSD (https://www.freebsd.org) is a robust Unix-like operating system that has been around for many years. FreeBSD is available on Amazon EC2 through Amazon Machine Images (AMIs) provided by FreeBSD developer and security office…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question