Difference between physical and logical file systems in OS
In this article, you will learn the difference between physical and logical file systems. But before discussing the differences, you must know about the physical and logical file systems.
What is the Physical File System?
Physical files have the real data saved on an iSeries system and describe how the data is to be displayed to or retrieved from a program. They only have one type of record and one or more members. A field-level description or a record-level description can be used to describe records in database files.
The field-level description defines the fields of the record. On the other hand, the record-level description defines the length of the record. Program-described files are database files that are prepared with record-level descriptions. Externally specified files are database files that are prepared with field-level descriptions. It means that the fields in the record must be described in your ILE C/C++ software.
Externally specified or an ILE C/C++ program can use program-described files. If the program requires an externally described file, the ILE C/C++ compiler may extract data from it and automatically add field information to it. The field information does not need to be defined in your program. A keyed sequence access path can exist for a physical file. It means that data is given to an ILE C/C++ program in a specific sequence that is based on various key fields in the file.
What is the Logical File System?
A logical file represents or perspectives multiple physical files. Logical files don't have data. They have a description of the records found in multiple physical files. Multi-format logical files are logical files that contain various formats.
If your program is processing a logical file with multiple record formats, you may use the _Rformat() function to specify which format to use. Some operations on logical files are not allowed. When you open a logical file for stream and record file processing using the open modes W, W+, WB, WB+, WR, or WR+, the file is opened but not cleared. A field-level description or a record-level description can be used to describe records in iSeries database files.
The record's field-level description describes all fields and how they are organized in this record. Database files built with a field-level description are externally described because the fields' description and layout are preserved within the database file rather than in your ILE C/C++ software.
Key differences between the Physical and Logical File System
Here, you will learn the various key differences between Physical and Logical File Systems. Various differences between Physical and Logical File Systems are as follows:
Head-to-head comparison between Physical and Logical File System
Here, you will learn the head-to-head comparisons between the Physical and the Logical File System. The main differences between the Physical and the Logical File System are as follows: