Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ fsync(2) — UTek W2.3

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

sync(2)

sync(8)

update(8)



FSYNC(2)                COMMAND REFERENCE                FSYNC(2)



NAME
     fsync - synchronize a file's in-core state with that on disk

SYNOPSIS
     fsync(fd)
     int fd;

DESCRIPTION
     Fsync causes all modified data and attributes of fd to be
     moved to a permanent storage device.  This normally results
     in all in-core modified copies of buffers for the associated
     file to be written to a disk.

     Fsync should be used by programs which require a file to be
     in a known state--for example, in building a simple
     transaction facility.

DIAGNOSTICS
     The fsync fails if:

     [EBADF]
         Fd is not a valid descriptor.

     [EIO]
         An I/O error occurred while reading from or writing to
         the file system.

     [EINVAL]
         Fd refers to a socket, not to a file.

RETURN VALUE
     Upon successful completion, a value of 0 is returned.
     Otherwise, a value of -1 is returned and errno is set to
     indicate the error.

CAVEATS
     The current implementation of this call is expensive for
     large files.

SEE ALSO
     sync(2), sync(8), update(8).














Printed 10/17/86                                                1





































































%%index%%
na:72,96;
sy:168,176;
de:344,522;
di:866,359;
rv:1225,236;
ca:1461,131;
se:1592,130;
%%index%%000000000118

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026