Solved

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

Posted on 2009-04-09
7
672 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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
Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

 
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

The Ultimate Checklist to Optimize Your Website

Websites are getting bigger and complicated by the day. Video, images, custom fonts are all great for showcasing your product/service. But the price to pay in terms of reduced page load times and ultimately, decreased sales, can lead to some difficult decisions about what to cut.

Question has a verified solution.

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

Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. jgh@FreeBSD.org Please see http://www.freebsd.org/doc/en_US.ISO8859-1/articles/freebsd-update-server/ for the updated article. It is avail…
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 how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
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…

696 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