Purpose
Debugs an Oracle ACFS file system.
Syntax and Description
acfsdbg -h
acfsdbg [-r] [-l] volume_device
Table 16-86 contains the options available with the acfsdbg command.
Table 16-86 Options for the acfsdbg command
| Option | Description | 
|---|---|
| 
 
  | 
 Prints out the usage message which displays the various options that are available when invoking the   | 
| 
 
  | 
 Operates in read-only mode. No data is modified on the file system and all write commands are disabled. If the device is mounted anywhere,   | 
| 
 
  | 
 Processes kernel log files. The default is to not process the log files.  | 
| 
 
  | 
 Specifies the device name of the volume.  | 
acfsdbg is an extension to fsck and acfschkdsk, and is an interactive program that views and modifies on disk structures of the file system. This command is intended for experienced development and support engineers to examine on disk structures to diagnose problems. Use with caution.
When acfsdbg is started, it displays a command prompt. At the command prompt, you can enter the subcommands listed in Table 16-87.
You can also use acfsdbg for scripts by echoing acfsdbg subcommands with a shell pipe to the acfsdbg binary.
By default the file system is not modified when running the tool. If the -l option is used, the file system metadata in the transaction logs is applied before the interactive disk block dump session. The volume device must specify a volume with a dismounted Oracle ACFS file system. If the volume device has a mounted Oracle ACFS file system, acfsdbg displays an error message and exits.
You must be the administrator or a member of the Oracle ASM administrator group to run acfsdbg.
Subcommands
Table 16-87 lists the subcommands of acfsdbg.
Table 16-87 Subcommands for acfsdbg
| Option | Description | Syntax | 
|---|---|---|
| 
 
  | 
 Calculates simple arithmetic expressions Valid operators: + - * / % & | ^ ~ << >> White space starts a new expression 0-1 represents a negative 1  | 
 
 
  | 
| 
 
  | 
 Generates and replaces checksum in header Header offset can be an expression as used by the  White space starts a new header offset Command is disabled in read-only mode  | 
 
 
  | 
| 
 
  | 
 Closes the open handle to the device  | 
 
  | 
| 
 
  | 
 Echoes text on command line to stdout  | 
 
  | 
| 
 
  | 
 Displays the specified File Entry TAble (FETA) entry  | 
 
 
  | 
| 
 
  | 
 Displays help message  | 
 
  | 
| 
 
  | 
 Displays structure at disk offset  | 
 
 
  | 
| 
 
  | 
 Opens a handle to a device. The default is the volume device name entered on the command line  | 
 
  | 
| 
 
  | 
 Sets the context of commands to the primary file system  | 
 
  | 
| 
 
  | 
 Sets the prompt to the specified string  | 
 
  | 
| 
 
  | 
 Exits the   | 
 
  | 
| 
 
  | 
 Reads value from offset The default size to read in is 8 bytes The default count to read is 1  | 
 
 
  | 
| 
 
  | 
 Sets the context of commands to the specified snapshot  | 
 
  | 
| 
 
  | 
 Writes hexadecimal, octal, or decimal values at the disk offset, estimating how many bytes to write based on value size or number of digits in leading 0 hexadecimal values The disk offset can be an expression used by the  Numeric values can also be an expression as used by the  This command is disabled in read-only mode  | 
 
 
  | 
Examples
Example 16-78 shows the use of the acfsdbg subcommand.
Example 16-78 Using the acfsdbg command
$ /sbin/acfsdbg /dev/asm/voume1-123
acfsdbg: version                   = 11.2.0.3.0
Oracle ASM Cluster File System (ACFS) On-Disk Structure Version: 39.0
The ACFS volume was created at  Mon Mar  2 14:57:45 2011
acfsdbg> 
acfsbdg> calculate 60*1024
    61,440
    61440
    61440
    0xf000
    0170000
    1111:0000:0000:0000
acfsdbg> prompt "acfsdbg test>"
acfsdbg test>
echo "offset 64*1024" | acfsdbg /dev/asm/volume1-123