Author: mckusick
Date: Tue Jan 17 01:14:56 2012
New Revision: 230250
URL: http://svn.freebsd.org/changeset/base/230250

Log:
  There are several bugs/hangs when trying to take a snapshot on a UFS/FFS
  filesystem running with journaled soft updates. Until these problems
  have been tracked down, return ENOTSUPP when an attempt is made to
  take a snapshot on a filesystem running with journaled soft updates.
  
  MFC after: 2 weeks

Modified:
  head/sys/ufs/ffs/ffs_snapshot.c

Modified: head/sys/ufs/ffs/ffs_snapshot.c
==============================================================================
--- head/sys/ufs/ffs/ffs_snapshot.c     Tue Jan 17 01:08:01 2012        
(r230249)
+++ head/sys/ufs/ffs/ffs_snapshot.c     Tue Jan 17 01:14:56 2012        
(r230250)
@@ -225,10 +225,18 @@ ffs_snapshot(mp, snapfile)
        ump = VFSTOUFS(mp);
        fs = ump->um_fs;
        sn = NULL;
+       /*
+        * At the moment, journaled soft updates cannot support
+        * taking snapshots.
+        */
+       if (MOUNTEDSUJ(mp)) {
+               vfs_mount_error(mp, "%s: Snapshots are not yet supported when "
+                   "running with journaled soft updates", fs->fs_fsmnt);
+               return (EOPNOTSUPP);
+       }
        MNT_ILOCK(mp);
        flag = mp->mnt_flag;
        MNT_IUNLOCK(mp);
-
        /*
         * Need to serialize access to snapshot code per filesystem.
         */
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to