Re: ZFS snapshot question - can I separate out some area later?

2010-06-30 Thread krad
On 29 June 2010 19:33, Martin Cracauer craca...@cons.org wrote:

 I created a raidz ZFS that is mounted on /mnt/backup

 It has subdirectories (not ZFS filesystems or volumes) like:
 /mnt/backup/wavehh
 /mnt/backup/joker
 [etc]

 I started taking snapshots long ago, and the snapshots are of
 backup@date, that means top level.
 NAME  USED  AVAIL  REFER  MOUNTPOINT
 bac...@firstwithunk  6.85G  -   455G  -
 bac...@20090922  3.75G  -   452G  -
 bac...@20091022   999M  -   480G  -
 bac...@200910223 2.63G  -   482G  -
 bac...@20100209  9.10G  -   522G  -
 bac...@20100210  2.86G  -   543G  -
 bac...@20100603  26.6K  -   513G  -

 Now, I want to store data there that is *not* part of future snapshots
 taken in that set.  Instead the new directory should have it's own set
 of snapshots, at different times.

 Is that something I can still do? Given that I currently snapshotted
 at top level?

 If I just `zfs create`d
  /mnt/backup/recordings
 and start storing data there, will that be outside the other areas's
 snapshots? I tried doing this but I can't snapshot in there:
 ~(wings)10# zfs snapshot backup/recordi...@test1
 cannot create snapshot 'backup/recordi...@test1': dataset is busy

 %%

 To clarify more, the structure now looks like this
 1) /mnt/backup/wavehh   # just subdir
 2) /mnt/backup/joker# just subdir
 3) /mnt/backup/newstuff # `zfs create`d filesystem or volume

 So I want 1 and 2 in the future snapshots of backup, and newstuff
 should have it's own set of snapshots.

 Am I out of luck after having started to snapshot at top level?

 Martin
 --
 %%%
 Martin Cracauer craca...@cons.org   http://www.cons.org/cracauer/
 FreeBSD - where you want to go, today.  http://www.freebsd.org/
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to 
 freebsd-questions-unsubscr...@freebsd.org


something else must be going on as what you are doing is valid

$ mkfile 1G test
$ zpool create test $PWD/test
$ zpool list
NAME SIZE   USED  AVAILCAP  HEALTH  ALTROOT
system   145G  85.1G  59.9G58%  ONLINE  -
test1016M72K  1016M 0%  ONLINE  -
zdump372G   189G   183G50%  ONLINE  -
$ zfs snapshot t...@a
$ mkdir /test/a /test/b /test/c
$ zfs snapshot t...@b
$ zfs create test/d
$ touch /test/a/a /test/b/a /test/c/a /test/d/a
$ zfs snapshot test/d...@a
$ zfs list -t snapshot | grep test
t...@a  16K  -18K  -
t...@b  20K  -22K  -
test/d...@a  0  -18K  -
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


ZFS snapshot question - can I separate out some area later?

2010-06-29 Thread Martin Cracauer
I created a raidz ZFS that is mounted on /mnt/backup

It has subdirectories (not ZFS filesystems or volumes) like:
/mnt/backup/wavehh
/mnt/backup/joker
[etc]

I started taking snapshots long ago, and the snapshots are of
backup@date, that means top level.
NAME  USED  AVAIL  REFER  MOUNTPOINT
bac...@firstwithunk  6.85G  -   455G  -
bac...@20090922  3.75G  -   452G  -
bac...@20091022   999M  -   480G  -
bac...@200910223 2.63G  -   482G  -
bac...@20100209  9.10G  -   522G  -
bac...@20100210  2.86G  -   543G  -
bac...@20100603  26.6K  -   513G  -

Now, I want to store data there that is *not* part of future snapshots
taken in that set.  Instead the new directory should have it's own set
of snapshots, at different times.

Is that something I can still do? Given that I currently snapshotted
at top level?

If I just `zfs create`d
  /mnt/backup/recordings
and start storing data there, will that be outside the other areas's
snapshots? I tried doing this but I can't snapshot in there:
~(wings)10# zfs snapshot backup/recordi...@test1
cannot create snapshot 'backup/recordi...@test1': dataset is busy

%%

To clarify more, the structure now looks like this
1) /mnt/backup/wavehh   # just subdir
2) /mnt/backup/joker# just subdir
3) /mnt/backup/newstuff # `zfs create`d filesystem or volume

So I want 1 and 2 in the future snapshots of backup, and newstuff
should have it's own set of snapshots.

Am I out of luck after having started to snapshot at top level?

Martin
-- 
%%%
Martin Cracauer craca...@cons.org   http://www.cons.org/cracauer/
FreeBSD - where you want to go, today.  http://www.freebsd.org/
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Snapshot question

2004-06-30 Thread Cordula's Web
[Does a snapshot change between backup and verify?]

http://docs.freebsd.org/cgi/mid.cgi?20040629135105.GB27491

Kevin A. Pieckiel wrote:
 cd /
 mksnap_ffs /var /var/.snap/backup.snap
 mdconfig -a -t vnode -f /var/.snap/backup.snap -u 6
 mount -r /dev/md6 /mnt/backup/root.var
 tar -cvf ${BACKUP_DEVICE} --totals --preserve \
 --blocking-factor ${BACKUP_BLOCKSIZE} --block-number --multi-volume \
 --new-volume-script ${PROGROOT}/next.sh \
 --newer-mtime ${TIMESTAMP} ${BACKUP_FLAGS} \
 ${BACKUP_PATHS}  ${LOGFILE} 21
 tar --compare -f ${BACKUP_DEVICE} --blocking-factor ${BACKUP_BLOCKSIZE} \
 --multi-volume --new-volume-script ${PROGROOT}/next.sh  ${COMPAREFILE} 21
 umount /mnt/backup/root.var
 mdconfig -d -u 6
 rm -f /var/.snap/backup.snap
 
 Here, BACKUP_PATHS is set as follows:
 
 BACKUP_PATHS=/mnt/backup

Strange. I can't reproduce this bug. All snapshots I'm taking on
a very active FS are still 100% stable. Since you're mounting the
snapshot read-only, nothing _should_ change. Anyone else experiencing
this behaviour?

-cpghost.

-- 
Cordula's Web. http://www.cordula.ws/

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Snapshot question

2004-06-29 Thread Kevin A. Pieckiel
Greetings!

I use filesystem snapshots when I backup my filesystems.  I backup to tape
and I ALWAYS read back the backup and compare it to the snapshot to verify
the data was written correctly.

I use FreeBSD 5.2.1-p6, and my tape drive is an Exabyte M2 drive.

When I do my compare of my tape against my snapshot, it's not uncommon for
one or two files (always the same files) to be different.  The most usual
culprit being my winbindd_cache.tdb file for Samba.  I thought the snapshot
would not change over time as the files on the filesystem change.  Does this
definitively indicate this particular file isn't being written to tape
correctly most nights?  (Yes, I *AM* backing up my snapshot and comparing
the backup to my snapshot, not the live filesystem.)

I doubt it, since I've gotten differences in this file on four different
tapes, all brand new.  What does this mean?  Is there a problem, or am I
missing something?

Thanks,
Kevin
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Snapshot question

2004-06-29 Thread Cordula's Web
[EMAIL PROTECTED] wrote:
 When I do my compare of my tape against my snapshot, it's not uncommon for
 one or two files (always the same files) to be different.  The most usual
 culprit being my winbindd_cache.tdb file for Samba.  I thought the snapshot
 would not change over time as the files on the filesystem change.  Does this
 definitively indicate this particular file isn't being written to tape
 correctly most nights?  (Yes, I *AM* backing up my snapshot and comparing
 the backup to my snapshot, not the live filesystem.)

Are you sure you are comparing against the correct snapshot? If you use
dump -L, the snapshot is created, opened, and immediately unlinked,
then the open file is saved. After dump exits, the snapshot file is
pysically released.

Are you creating a snapshot manually? What commands do you use exactly?

-- 
Cordula's Web. http://www.cordula.ws/

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Snapshot question

2004-06-29 Thread Kevin A. Pieckiel
On Tue, Jun 29, 2004 at 04:56:54PM +0200, Cordula's Web wrote:
 Are you sure you are comparing against the correct snapshot? If you use
 dump -L, the snapshot is created, opened, and immediately unlinked,
 then the open file is saved. After dump exits, the snapshot file is
 pysically released.
 
 Are you creating a snapshot manually? What commands do you use exactly?

I'm actually using tar because my data store is larger than my tapes,
and I can't find a way to get dump to change tapes for me automatically
(something akin to tar's --new-volume-script parameter).

The relevant commands I use are as follows (this just shows the /var
parittion, but I make snapshots and mount all important partitions
in /mnt/backup before I run tar):

cd /
mksnap_ffs /var /var/.snap/backup.snap
mdconfig -a -t vnode -f /var/.snap/backup.snap -u 6
mount -r /dev/md6 /mnt/backup/root.var
tar -cvf ${BACKUP_DEVICE} --totals --preserve \
--blocking-factor ${BACKUP_BLOCKSIZE} --block-number --multi-volume \
--new-volume-script ${PROGROOT}/next.sh \
--newer-mtime ${TIMESTAMP} ${BACKUP_FLAGS} \
${BACKUP_PATHS}  ${LOGFILE} 21
tar --compare -f ${BACKUP_DEVICE} --blocking-factor ${BACKUP_BLOCKSIZE} \
--multi-volume --new-volume-script ${PROGROOT}/next.sh  ${COMPAREFILE} 21
umount /mnt/backup/root.var
mdconfig -d -u 6
rm -f /var/.snap/backup.snap

Here, BACKUP_PATHS is set as follows:

BACKUP_PATHS=/mnt/backup
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]