Check API

This is the integrity-checking API. More...


Data Structures

struct  jfsck_result
 The result of a jfsck() run. More...

Defines

#define J_CLEANUP   1
 Perform a journal cleanup.

Enumerations

enum  jfsck_return {
  J_ESUCCESS = 0, J_ENOENT = -1, J_ENOJOURNAL = -2, J_ENOMEM = -3,
  J_ECLEANUP = -4, J_EIO = -5
}
 jfsck() return values. More...

Functions

enum jfsck_return jfsck (const char *name, const char *jdir, struct jfsck_result *res, unsigned int flags)
 Check and repair the given path.


Detailed Description

This is the integrity-checking API.

Define Documentation

#define J_CLEANUP   1

Perform a journal cleanup.

Used in jfsck().

See also:
jfsck()

Definition at line 501 of file libjio.h.


Enumeration Type Documentation

jfsck() return values.

See also:
jfsck()
Enumerator:
J_ESUCCESS  Success.
J_ENOENT  No such file or directory.
J_ENOJOURNAL  No journal associated with the given file.
J_ENOMEM  Not enough free memory.
J_ECLEANUP  Error cleaning the journal directory.
J_EIO  I/O error.

Definition at line 71 of file libjio.h.


Function Documentation

enum jfsck_return jfsck ( const char *  name,
const char *  jdir,
struct jfsck_result res,
unsigned int  flags 
)

Check and repair the given path.

The file MUST NOT be in use by any other thread or process. This requirement will be lifted in future releases.

Parameters:
name path to the file to check
jdir journal directory of the given file, use NULL for the default
res structure where to store the result
flags flags that change the checking behaviour, currently only J_CLEANUP is supported, which removes the journal directory after a successful recovery
See also:
struct jfsck_result
Returns:
0 on success, < 0 on error, with the following possible negative values from enum jfsck_return: J_ENOENT if there was no such file with the given name, J_ENOJOURNAL if there was no journal at the given jdir, J_ENOMEM if memory could not be allocated, J_ECLEANUP if there was an error cleaning the journal, J_EIO if there was an I/O error.


Generated on Sat Sep 12 13:33:29 2009 for libjio (public) by  doxygen 1.5.8