# US 2016/0253353 A1 · Index record-level locking for record-oriented file systems

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2016/0253353 A1
- Document ID: US20160253353A1
- Status: Published application
- Kind: A1
- Application number: 15/150,163
- Filed: 2016-05-09
- Published: 2016-09-01
- Earliest claimed: 2013-03-15
- Assignees: International Business Machines Corporation
- Applicants: International Business Machines Corporation
- Inventors: Debra J. Benjamin-Deckert; Lawrence L. T. Law; Terri A. Menendez
- Web page: https://patentgrep.com/patent/US20160253353A1

## CPC

- G06F 16/1774: {Locking methods, e.g. locking methods for file systems allowing shared and concurrent access to files}
- G06F 16/13: File access structures, e.g. distributed indices (arrangements of input from, or output to, record carriers G06F3/06)
- G06F 16/1727: {Details of free space management performed by the file system (saving storage space on storage systems G06F3/0608; management of blocks in storage devices G06F3/064)}
- G06F 16/2246: {Trees, e.g. B+trees}
- G06F 16/2365: {Ensuring data consistency and integrity}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

In one embodiment, a method includes determining a data node corresponding to a data record to be inserted/updated in an index structure of a record-oriented file system, creating a lock on a corresponding data node, splitting the corresponding data node sequentially into two data nodes and storing the data record in one of the two data nodes in response to the corresponding data node not having free space sufficient to store/update the data record, storing a high key of the first of the two data nodes to a parent index node, splitting the parent index node sequentially into two index nodes in response to the parent index node not having free space sufficient to store/update the high key of the first of the two data nodes, and storing the high key of the first of the two data nodes in one of the two index nodes.

## Claims

### Claim 1

A system, comprising:
a processor; and
logic integrated with and/or executable by the processor, the logic being configured to cause the processor to:
determine a data node corresponding to a data record to be inserted and/or updated in an index structure of a record-oriented file system;
create a lock on the corresponding data node;
in response to a determination that the corresponding data node does not have free space sufficient to store and/or update the data record:
split the corresponding data node sequentially into two data nodes;
store the data record in one of the two data nodes; and
store a high key of a first of the two data nodes to a parent index node prior to a high key of the corresponding data node in response to a determination that the parent index node comprises free space sufficient to store the high key of the first of the two data nodes; and
in response to a determination that the parent index node does not have free space sufficient to store and/or update the high key of the first of the two data nodes:
split the parent index node sequentially into two index nodes; and
store the high key of the first of the two data nodes in one of the two index nodes.

### Claim 2 (depends on 1)

The system as recited in claim 1, wherein the file system is a virtual storage access method (VSAM) system, wherein a control interval (CI) comprises data nodes, and wherein a control area (CA) comprises index nodes.

### Claim 3 (depends on 1)

The system as recited in claim 1, wherein the logic is further configured to cause the processor to:
relinquish the lock on affected index nodes above the parent index node after updating affected pointers therein; and
relinquish the lock on the corresponding data node after storing and/or updating the data record.

### Claim 4 (depends on 1)

The system as recited in claim 1, wherein the corresponding data node is determined by traversing from a root of the index structure down to the corresponding data node.

### Claim 5 (depends on 1)

The system as recited in claim 1, wherein the logic configured to determine the data node corresponding to the data record to be inserted and/or updated further causes the processor to:
determine a key for the data record;
determine the corresponding data node which has the high key that is higher than the data record's key, with the proviso that a previously adjacent data node to the corresponding data node has a high key which is lower than the data record's key; and
select the corresponding data node.

### Claim 6 (depends on 1)

The system as recited in claim 1, wherein the logic is further configured to cause the processor to determine the high key of the first of the two data nodes.

### Claim 7

A computer program product comprising a computer readable storage medium having program instructions embodied therewith, wherein the computer readable storage medium is not a transitory signal per se, the embodied program instructions readable/executable by a processor to cause the processor to:
determine, using the processor, a data node corresponding to a data record to be inserted and/or updated in an index structure of a record-oriented file system;
create, using the processor, a lock on the corresponding data node;
in response to a determination that the corresponding data node does not have free space sufficient to store and/or update the data record:
split, using the processor, the corresponding data node sequentially into two data nodes;
store, using the processor, the data record in one of the two data nodes; and
store, using the processor, a high key of a first of the two data nodes to a parent index node prior to a high key of the corresponding data node in response to a determination that the parent index node comprises free space sufficient to store the high key of the first of the two data nodes; and
in response to a determination that the parent index node does not have free space sufficient to store and/or update the high key of the first of the two data nodes:
split, using the processor, the parent index node sequentially into two index nodes; and
store, using the processor, the high key of the first of the two data nodes in one of the two index nodes.

### Claim 8 (depends on 7)

The computer program product as recited in claim 7, wherein the file system is a virtual storage access method (VSAM) system, wherein a control interval (CI) comprises data nodes, and wherein a control area (CA) comprises index nodes.

### Claim 9 (depends on 7)

The computer program product as recited in claim 7, wherein the program instructions readable/executable by the processor are further configured to cause the processor to:
relinquish, using the processor, the lock on affected index nodes above the parent index node after updating affected pointers therein; and
relinquish, using the processor, the lock on the corresponding data node after storing and/or updating the data record.

### Claim 10 (depends on 7)

The computer program product as recited in claim 7, wherein the corresponding data node is determined by traversing from a root of the index structure down to the corresponding data node.

### Claim 11 (depends on 7)

The computer program product as recited in claim 7, wherein the program instructions readable/executable by the processor to determine, using the processor, the data node corresponding to the data record to be inserted and/or updated further causes the processor to:
determine, using the processor, a key for the data record;
determine, using the processor, the corresponding data node which has a high key that is higher than the data record's key, with the proviso that a previously adjacent data node to the corresponding data node has a high key which is lower than the data record's key; and
select, using the processor, the corresponding data node.

### Claim 12 (depends on 7)

The computer program product as recited in claim 7, wherein the program instructions readable/executable by the processor are further configured to cause the processor to determine, using the processor, the high key of the first of the two data nodes.

### Claim 13

A method, comprising:
determining a data node corresponding to a data record to be inserted and/or updated in an index structure of a record-oriented file system;
creating a lock on a corresponding data node;
in response to a determination that the corresponding data node does not have free space sufficient to store and/or update the data record:
splitting the corresponding data node sequentially into two data nodes;
storing the data record in one of the two data nodes; and
storing a high key of a first of the two data nodes to a parent index node prior to a high key of the corresponding data node in response to a determination that the parent index node comprises free space sufficient to store the high key of the first of the two data nodes; and
in response to a determination that the parent index node does not have free space sufficient to store and/or update the high key of the first of the two data nodes:
splitting the parent index node sequentially into two index nodes; and
storing the high key of the first of the two data nodes in one of the two index nodes.

### Claim 14 (depends on 13)

The method as recited in claim 13, wherein the file system is a virtual storage access method (VSAM) system, wherein a control interval (CI) comprises data nodes, and wherein a control area (CA) comprises index nodes.

### Claim 15 (depends on 13)

The method as recited in claim 13, further comprising:
relinquishing the lock on affected index nodes above the parent index node after updating affected pointers therein; and
relinquishing the lock on the corresponding data node after storing and/or updating the data record.

### Claim 16 (depends on 13)

The method as recited in claim 13, wherein the corresponding data node is determined by traversing from a root of the index structure down to the corresponding data node.

### Claim 17 (depends on 13)

The method as recited in claim 13, wherein the determining the data node corresponding to the data record to be inserted and/or updated comprises:
determining a key for the data record;
determining the corresponding data node which has the high key that is higher than the data record's key, with the proviso that a previously adjacent data node to the corresponding data node has a high key which is lower than the data record's key; and
selecting the corresponding data node.

### Claim 18 (depends on 13)

The method as recited in claim 13, further comprising determining the high key of the first of the two data nodes.
