ctfilblkif
ctfilblkif will block, or unblock a specified FairCom DB file. The default behavior is to block access to the specified file. Pass the -u option to unblock a file.
Operational Model:
Usage
ctfilblkif [-s server][-f filename][-u][-m] {-p password|-a authfile}
Example:
Block new transactions and allow active transactions 3 seconds to complete before blocking the mark.dat file:
ctfilblkif -f mark.dat -n -t 3
Manual Reopen
The ctfilblkif utility now supports an option (-m) to block a file with the reopen option. This means that when the file is unblocked, those connections that had the file open when it was blocked must "manually" reopen the file (e.g., the application must explicitly reopen the file).
Example 1:
Block the file with the reopen option:
ctfilblkif -f mydatafile.dat -m -p ADMIN -s FAIRCOMS
Example 2:
Unblock the file. The connections that originally had the file open must reopen the file:
ctfilblkif -f mydatafile.dat -u -p ADMIN -s FAIRCOMS
Note: FairCom does not guarantee preserving the state of a transaction, locks, ISAM context when a file is blocked and then unblocked, even if using the auto open option. Because ISAM context information is lost when the file is blocked, an error 590 may be returned after the file has been blocked and unblocked using ctFBautopen or when using ctfilblkif utility, which uses this mode.
Authentication File
This utility supports the use of an encrypted password file. Encrypted password files keep user IDs and passwords from plain view when the utility is used within a script file. They are created with the ctcmdset utility. The plain text form of the file should be:
; User Id
USERID ADMIN
; User Password
PASSWD <pass>
Use the -1 option to specify the name of the encrypted file. Use the -a option to specify the name of the encrypted file.
See also