*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> freezefs (2)              
Title
Content
Arch
Section
 

freezefs(2)

Contents


NAME    [Toc]    [Back]

       freezefs  -  The freezefs() API causes the specified fileset's
 domain to enter into a metadata stable state, causes
       a  previously  frozen  fileset's  domain  to resume normal
       activity, or queries the freeze  state  of  the  fileset's
       domain. All the filesets in the AdvFS domain are affected.

SYNOPSIS    [Toc]    [Back]

       #include <sys/mount.h>

       int freezefs {
                     char *mountPoint,
                     u_long optionFlags,
                     int timeout };

       );

PARAMETERS    [Toc]    [Back]

       Points to  a  null-terminated  string  that  contains  the
       appropriate  mount  point  of  the file system.  Specifies
       what action to take on the specified file system.

              FS_Q_QUERY


              Queries the freeze state and indicates  whether  or
              not the domain is frozen by way of the return code.

              FS_Q_FREEZE


              Places the  filesystem  in  a  metadata  consistent
              state  and  guarantees that it stays that way until
              thawed. All metadata, which could be spread  across
              multiple   volumes  or  logical  units  (LUNS),  is
              flushed to disk and does not change for  the  duration
 of the freeze.

              FS_Q_THAW


              Causes  a  previously  frozen  fileset's  domain to
              resume normal activity.

              timeout


              Specifies the maximum time allowed  for  the  fileset's
 domain to remain frozen:

              > 0


              Specifies the timeout value in seconds.

              = 0


              Uses  the  default  timeout  specified  in  the vfs
              stanza        of        /etc/sysconfigtab        as
              freezefs_default_timeout.   If   not  specified  in
              /etc/sysconfigtab, freezefs uses 60 seconds.

              < 0


              Specifies no timeout. The fileset's domain  remains
              frozen until explicitly thawed.


       Certain  system  events  on a cluster will cause automatic
       thaws regardless of timeout  value.  See  DESCRIPTION  for
       more information.

DESCRIPTION    [Toc]    [Back]

       To allow coherent hardware snapshots in multivolume domain
       configurations, filesystem  metadata  must  be  consistent
       across all volumes when the individual volumes are snapped
       or cloned.  These configurations include both  multivolume
       AdvFS domains and multivolume LSM logical volumes.

       The  FS_Q_FREEZE  option  to  the  freezefs API places the
       filesystem in a metadata-consistent state  and  guarantees
       that  it  stays that way until thawed. All metadata, which
       could be spread across multiple volumes or  logical  units
       (LUNs),  is  flushed  to  disk and does not change for the
       duration of the freeze.

       The filesystem thaws either by timing  out  or  explicitly
       with  the  FS_Q_THAW option to the freezefs() API.  If you
       are running a cluster  configuration,  shutting  down  any
       node  or  the  failure  of  any  node  will  also thaw the
       filesystem.

       The exact nature of the freezefs API  depends  on  whether
       you are running on a single system or a cluster.

       Single System

       When  you  freeze  a  filesystem,  any in-process metadata
       updates are allowed to finish. Filesystem operations  that
       do  not  modify  metadata  are  allowed while frozen. Some
       operations will work normally even if the target fileset's
       domain  is  frozen,  for  example: Read No-extending write
       Stat

       Filesystem operations that modify  metadata  are  blocked.
       The  following  operations  will block if the target fileset's
 domain is frozen,  for  example:  Mount  of  fileset
       rmvol Extending write mkfset / rmfset

       The  following filesystem operations will fail immediately
       if the target filesystem  (that  is,  domain)  is  frozen:
       Mount update of fileset Unmount of fileset

       Cluster

       When you freeze a filesystem in a clustered configuration,
       all in-process filesystem operations are allowed  to  complete.
   Some  filesystem  operations  are  allowed  while
       frozen. The following operations,  which  do  not  require
       metadata  updates,  will  work normally even if the target
       filesystem is frozen.  Read Stat

       Most  new  filesystem  operations  are  blocked  when  the
       filesystem  is frozen.  Operations that have the potential
       for requiring metadata updates will block  if  the  target
       filesystem is frozen, for example: Write chmod Link

       Some  filesystem  operations  will fail immediately if the
       target domain is frozen, for example: Unmount  of  fileset
       Mount  (update)  of fileset User-initiated planned relocation
 User-initiated forced unmount addvol rmvol

       The freezefs() API posts an event manager (EVM) event when
       a  file  system  is frozen or thawed. Use the evmwatch and
       evmshow commands to determine if any file systems  in  the
       cluster are frozen. See EXAMPLES.

NOTES    [Toc]    [Back]

       At  present,  freezefs  and  thawfs  functionality is only
       implemented for AdvFS filesystems.

       Using the freezefs() API for a single mount point  affects
       all filesets in the domain.

       In  a  cluster configuration, some system events may cause
       an automatic thaw regardless of the  timeout  option.  See
       the DESCRIPTION section for more information.

RESTRICTIONS    [Toc]    [Back]

       You  must be root user to run freezefs and thawfs.  The /,
       /usr and /var file systems cannot be frozen.

EXIT STATUS    [Toc]    [Back]

       Success FS_Q_FREEZE and FS_Q_THAW

              Not frozen FS_Q_QUERY Frozen  FS_Q_QUERY  An  error
              occurred.

ERRORS    [Toc]    [Back]

       The freezefs is not supported by the filesystem specified.
       The filesystem is not mounted.  Not  enough  memory.   The
       file system is already frozen freezefs, or

              The  file  system is not frozen thawfs.  The caller
              does not have  root  privilege.   Option  not  supported.

EXAMPLES    [Toc]    [Back]

       To freeze a file system: #include
           extern errno;
           ...
           char *mp;
           u_long flags;
           int timeout, rc;
           ...

           mp = "/oracle";         /* filesystem to freeze */
           flags = FS_Q_FREEZE;    /* freeze flag          */
           timeout = 0;            /* use default timeout  */
           ...
           errno = 0;
           rc = freezefs(mp, flags, timeout);
           if (rc = -1) {
               error
           }
           .
           .
           .
           PERFORM WORK ON FROZEN FILE SYSTEM
           .
           .
           .
           flags = FS_Q_THAW;      /* thaw flag            */
           errno = 0;
           rc = freezefs(mp, flags, timeout);
           if  (rc  =  -1) {          /* If error on thaw, cannot
       rely on the intial freeze */
               error
           }


SEE ALSO    [Toc]    [Back]

      
      
       Commands: freezefs(8), thawfs(8)



                                                      freezefs(2)
[ Back ]
 Similar pages
Name OS Title
freezefs Tru64 The freezefs utility causes the specified fileset's domain to enter into a metadata stable state. Al...
thawfs Tru64 The freezefs utility causes the specified fileset's domain to enter into a metadata stable state. Al...
rmfset Tru64 Removes a fileset or a clone fileset from an AdvFS file domain
mkfset Tru64 Creates a fileset in an existing AdvFS domain
advfs_get_fset_quotas Tru64 Obtains fileset quotas for an AdvFS fileset
advfs_set_fset_quotas Tru64 Sets fileset quotas for an AdvFS fileset
advfs_rmfset Tru64 Removes a fileset or a clone fileset
setboot HP-UX display and modify boot variables in stable storage
renamefset Tru64 Rename an existing AdvFS fileset
advfs_clonefset Tru64 Creates a read-only copy of an active fileset
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service