Unix Technical Forum

Can ufsrestore restore files to a ZFS file system?

This is a discussion on Can ufsrestore restore files to a ZFS file system? within the comp.unix.solaris forums, part of the Solaris Operating System category; --> I have a Sun Blade 2000 running Solaris 10 update 5 which is fitted with a pair of 137 ...


Go Back   Unix Technical Forum > Unix Operating Systems > Solaris Operating System > comp.unix.solaris

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 05-10-2008, 01:57 PM
Dave
 
Posts: n/a
Default Can ufsrestore restore files to a ZFS file system?

I have a Sun Blade 2000 running Solaris 10 update 5 which is fitted with
a pair of 137 GB FC-AL disks. One of the disks is used as /export/home
and has only one UFS file system on it.

I have created a level 0 dump of this file system using ufsdump and
saved it to a file which I've stored in a ZFS pool created with a pair
of 1 TB USB disks.

Can I destroy the data on the UFS file system, create a ZFS pool on that
disk, then restore the data from a file created with ufsdump? (The file
is stored on a mirrored pair of 1 TB USB disks). The fact the command
has *ufs* in the name rather suggests this is not going to be possible
and ufsrestore will not work.

Is there a recommended way to change from UFS -> ZFS? I see a few things
on the web, but most are dated 2005.

What else could be used to back up the UFS file system and restore it to
a file system created in a ZFS pool? Since its not a system disk, tar
might work, although I'd need to check any largfile issues, as there are
several files over 2 GB in size. Perhaps cp -pr or similar?




Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 05-10-2008, 01:57 PM
Andrew Gabriel
 
Posts: n/a
Default Re: Can ufsrestore restore files to a ZFS file system?

In article <48258e37@212.67.96.135>,
Dave <foo@coo.com> writes:
> I have a Sun Blade 2000 running Solaris 10 update 5 which is fitted with
> a pair of 137 GB FC-AL disks. One of the disks is used as /export/home
> and has only one UFS file system on it.
>
> I have created a level 0 dump of this file system using ufsdump and
> saved it to a file which I've stored in a ZFS pool created with a pair
> of 1 TB USB disks.
>
> Can I destroy the data on the UFS file system, create a ZFS pool on that
> disk, then restore the data from a file created with ufsdump? (The file
> is stored on a mirrored pair of 1 TB USB disks). The fact the command
> has *ufs* in the name rather suggests this is not going to be possible
> and ufsrestore will not work.


It will work -- ufsrestore just uses standard user level
filesystem interfaces to write files. (This is not true of
ufsdump, so ufsdump only works on ufs filesystems.) I'm not
certain what will happen with any extended attributes since UFS
and ZFS don't handle them the same way, but I don't imagine
anything else would do a better job of converting them either.

> Is there a recommended way to change from UFS -> ZFS? I see a few things
> on the web, but most are dated 2005.
>
> What else could be used to back up the UFS file system and restore it to
> a file system created in a ZFS pool? Since its not a system disk, tar
> might work, although I'd need to check any largfile issues, as there are
> several files over 2 GB in size. Perhaps cp -pr or similar?


I would stick with ufsdump/ufsrestore. I'm not sure anything
else will correctly deal with sparse files (likely end up as
non-sparse files occupying more disk space).

--
Andrew Gabriel
[email address is not usable -- followup in the newsgroup]
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 05-10-2008, 01:57 PM
Dave
 
Posts: n/a
Default Re: Can ufsrestore restore files to a ZFS file system?

Andrew Gabriel wrote:
> In article <48258e37@212.67.96.135>,
> Dave <foo@coo.com> writes:
>> I have a Sun Blade 2000 running Solaris 10 update 5 which is fitted with
>> a pair of 137 GB FC-AL disks. One of the disks is used as /export/home
>> and has only one UFS file system on it.
>>
>> I have created a level 0 dump of this file system using ufsdump and
>> saved it to a file which I've stored in a ZFS pool created with a pair
>> of 1 TB USB disks.
>>
>> Can I destroy the data on the UFS file system, create a ZFS pool on that
>> disk, then restore the data from a file created with ufsdump? (The file
>> is stored on a mirrored pair of 1 TB USB disks). The fact the command
>> has *ufs* in the name rather suggests this is not going to be possible
>> and ufsrestore will not work.

>
> It will work -- ufsrestore just uses standard user level
> filesystem interfaces to write files. (This is not true of
> ufsdump, so ufsdump only works on ufs filesystems.) I'm not
> certain what will happen with any extended attributes since UFS
> and ZFS don't handle them the same way, but I don't imagine
> anything else would do a better job of converting them either.
>
>> Is there a recommended way to change from UFS -> ZFS? I see a few things
>> on the web, but most are dated 2005.
>>
>> What else could be used to back up the UFS file system and restore it to
>> a file system created in a ZFS pool? Since its not a system disk, tar
>> might work, although I'd need to check any largfile issues, as there are
>> several files over 2 GB in size. Perhaps cp -pr or similar?

>
> I would stick with ufsdump/ufsrestore. I'm not sure anything
> else will correctly deal with sparse files (likely end up as
> non-sparse files occupying more disk space).
>



Thanks a lot. I'll try that later today. If there are any problems, I
can always create the file system as ufs again.

I guess Sun should add the fact ufsrestore will work on zfs file systems
into the ufsrestore man page. I'll submit that as an RFE.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 05-10-2008, 02:12 PM
Oscar del Rio
 
Posts: n/a
Default Re: Can ufsrestore restore files to a ZFS file system?

Dave wrote:
> I guess Sun should add the fact ufsrestore will work on zfs file systems
> into the ufsrestore man page. I'll submit that as an RFE.


ufsrestore can write to ANY filesystem, including nfs, tmpfs, zfs, etc



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 05-11-2008, 08:36 PM
Alain
 
Posts: n/a
Default Re: Can ufsrestore restore files to a ZFS file system?

Dave a écrit :
> I have created a level 0 dump of this file system using ufsdump and

Why not use pax ?
save: pax -w -f savefile.pax /export/home
restore: pax -r -p e -f savefile.pax


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 05-11-2008, 08:36 PM
Dave
 
Posts: n/a
Default Re: Can ufsrestore restore files to a ZFS file system?

Alain wrote:
> Dave a écrit :
>> I have created a level 0 dump of this file system using ufsdump and

> Why not use pax ?
> save: pax -w -f savefile.pax /export/home
> restore: pax -r -p e -f savefile.pax
>
>




I was not even aware of 'pax', although found the man page:

User Commands pax(1)

NAME
pax - portable archive interchange


Actually, as Andrew Gabriel said, it does work with ufsrestore. In fact,
I'm using ZFS on /export/home now, after restoring from a file created
with ufsdump.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 05-16-2008, 01:32 PM
Wolfgang
 
Posts: n/a
Default Re: Can ufsrestore restore files to a ZFS file system?

Dave schrieb:
> Alain wrote:
>> Dave a écrit :
>>> I have created a level 0 dump of this file system using ufsdump and

>> Why not use pax ?
>> save: pax -w -f savefile.pax /export/home
>> restore: pax -r -p e -f savefile.pax
>>
>>

>
>
>
> I was not even aware of 'pax', although found the man page:

AFAIK:
pax is a sort of posix conform tar ...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 02:43 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com