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

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

sync2(2)

Contents


NAME    [Toc]    [Back]

       sync2  -  Flush  file system metadata and data from memory
       buffers to disk

SYNOPSIS    [Toc]    [Back]

       #include <sys/mount.h>

       int sync2(
               unsigned int POLICY,
               char *path );

PARAMETERS    [Toc]    [Back]

       Flush the file system memory buffers to disk. The argument
       is  one of the following: Flush all memory buffers. Specifying
 this flag causes the function to behave the same  as
       the  sync()  function.   See  sync(2).   Flush  all memory
       buffers except those under smooth sync control.  The  name
       of  a  UFS  file  system  or  AdvFS  fileset.  Specify the
       optional path parameter when you want to have  the  POLICY
       act  only on that file system instead of all file systems.
       Specify a NULL argument when you want to have  the  POLICY
       act on all file systems.

DESCRIPTION    [Toc]    [Back]

       The sync2() function causes file system data to be flushed
       (written) to disk. Which memory  buffers  are  flushed  to
       disk depends on the POLICY argument.

       If  the  policy is SYNC_SYNCPOLICY, all memory buffers are
       flushed to disk. If the policy  is  SYNC_SMOOTHSYNCPOLICY,
       all  memory buffers except those under smooth sync control
       are flushed to disk.

       To which file systems the POLICY argument applies  depends
       on  the  path  argument.   To apply the policy to one file
       system, name it in the path argument.  To apply the policy
       to all file systems, specify the path argument as NULL.

       The  writing,  although scheduled, is not necessarily complete
 upon return from the sync2() function.

       See the description of  the  smoothsync_age  attribute  in
       sys_attrs_vfs(5) for the definition of the smooth sync age
       period. See the  description  of  the  M_SMSYNC2  flag  in
       mount(2)  for  information on enabling an alternate smooth
       sync policy.

SEE ALSO    [Toc]    [Back]

      
      
       Commands: sync(8)

       Functions: mount(2), sync(2)

       Others: standards(5), sys_attrs_vfs(5)



                                                         sync2(2)
[ Back ]
 Similar pages
Name OS Title
sync Tru64 Flush file system metadata and data from memory buffers to disk.
dbc_min_pct HP-UX minimum percentage of memory used for caching file I/O data and metadata
dbc_max_pct HP-UX maximum percentage of memory to be used for caching file I/O data and metadata
VOP_FSYNC FreeBSD flush file system buffers for a file
krs_flush HP-UX flush kernel registry services data to disk
cdfs Tru64 The Compact Disk-Read Only Memory File System (CDFS)
sync Linux flush filesystem buffers
vinvalbuf OpenBSD flush and invalidate all buffers associated with a vnode
verify Tru64 Checks the AdvFS on-disk metadata structures
update OpenBSD flush internal filesystem caches to disk frequently
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service