118 lines
7.9 KiB
HTML
118 lines
7.9 KiB
HTML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE html
|
|
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html lang="en-us" xml:lang="en-us">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
|
<meta name="security" content="public" />
|
|
<meta name="Robots" content="index,follow" />
|
|
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
|
|
<meta name="DC.Type" content="concept" />
|
|
<meta name="DC.Title" content="File systems" />
|
|
<meta name="abstract" content="i5/OS PASE programs can access any file or resource that is accessible through the integrated file system, including objects in the QSYS.LIB and QOPT file systems." />
|
|
<meta name="description" content="i5/OS PASE programs can access any file or resource that is accessible through the integrated file system, including objects in the QSYS.LIB and QOPT file systems." />
|
|
<meta name="DC.Relation" scheme="URI" content="rzalfinteract.htm" />
|
|
<meta name="DC.Relation" scheme="URI" content="rzalfdataconv.htm" />
|
|
<meta name="DC.Relation" scheme="URI" content="../ifs/rzaaxkickoff.htm" />
|
|
<meta name="copyright" content="(C) Copyright IBM Corporation 2000, 2006" />
|
|
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 2000, 2006" />
|
|
<meta name="DC.Format" content="XHTML" />
|
|
<meta name="DC.Identifier" content="rzalffilesystems" />
|
|
<meta name="DC.Language" content="en-us" />
|
|
<!-- All rights reserved. Licensed Materials Property of IBM -->
|
|
<!-- US Government Users Restricted Rights -->
|
|
<!-- Use, duplication or disclosure restricted by -->
|
|
<!-- GSA ADP Schedule Contract with IBM Corp. -->
|
|
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
|
|
<link rel="stylesheet" type="text/css" href="./ic.css" />
|
|
<title>File systems</title>
|
|
</head>
|
|
<body id="rzalffilesystems"><a name="rzalffilesystems"><!-- --></a>
|
|
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
|
|
<h1 class="topictitle1">File systems</h1>
|
|
<div><p><span class="keyword">i5/OS™</span> PASE programs
|
|
can access any file or resource that is accessible through the integrated
|
|
file system, including objects in the QSYS.LIB and QOPT file systems.</p>
|
|
<div class="section"><h4 class="sectiontitle">Buffered input and output</h4><p>Input
|
|
and output to and from external devices is buffered on <span class="keyword">i5/OS</span>;
|
|
it is handled by input and output processors that deal with blocks of data.
|
|
Conversely, operating systems, such as AIX<sup>®</sup> and Linux<sup>®</sup>, typically operate with character-by-character
|
|
(unbuffered) input and output. On <span class="keyword">i5/OS</span>,
|
|
only certain input and output signals (for example, the Enter key, function
|
|
keys, and system request) send an interrupt to the system.</p>
|
|
</div>
|
|
<div class="section"><h4 class="sectiontitle">Data conversion support</h4><p><span class="keyword">i5/OS</span> PASE programs pass ASCII (or
|
|
UTF-8) path names to the <span class="apiname">open()</span> function to open byte stream
|
|
files, where the name is automatically converted to the encoding scheme used
|
|
by <span class="keyword">i5/OS</span>, but any data
|
|
read or written from the open file is not converted.</p>
|
|
</div>
|
|
<div class="section"><h4 class="sectiontitle">Use of file descriptors</h4><p>The <span class="keyword">i5/OS</span> PASE run time normally uses
|
|
ILE C run time support for files stdin, stdout, and stderr, which provide
|
|
consistent behavior for <span class="keyword">i5/OS</span> PASE
|
|
and ILE programs.</p>
|
|
</div>
|
|
<div class="section"><p><span class="keyword">i5/OS</span> PASE
|
|
and ILE C use the same streams for standard input and output (stdin, stdout,
|
|
and stderr). <span class="keyword">i5/OS</span> PASE
|
|
programs always access standard input and output using file descriptors 0,
|
|
1, and 2. ILE C, however, does not always use integrated file descriptors
|
|
for stdin, stdout, and stderr, so <span class="keyword">i5/OS</span> PASE
|
|
provides a mapping between <span class="keyword">i5/OS</span> PASE
|
|
file descriptors and descriptors in the integrated file system. Because of
|
|
this mapping, <span class="keyword">i5/OS</span> PASE
|
|
programs and ILE C programs can use different descriptor numbers to access
|
|
the same open file.</p>
|
|
<p>You can use the <span class="keyword">i5/OS</span> PASE
|
|
extension on the <tt>fcntl</tt> function, F_MAP_XPFFD, to assign an <span class="keyword">i5/OS</span> PASE descriptor to an ILE
|
|
number. This is useful if your <span class="keyword">i5/OS</span> PASE
|
|
application needs to do file operations for an ILE descriptor that was not
|
|
created by <span class="keyword">i5/OS</span> PASE.</p>
|
|
<p>An i5/OS system-unique
|
|
extension to the <span class="apiname">fstatx()</span> function, STX_XPFFD_PASE, allows
|
|
an <span class="keyword">i5/OS</span> PASE program to
|
|
determine the integrated file system descriptor number for an <span class="keyword">i5/OS</span> PASE
|
|
file descriptor. Special values (negative numbers) are returned for any <span class="keyword">i5/OS</span> PASE descriptor attached to
|
|
ILE C runtime support for files stdin, stdout, and stderr.</p>
|
|
<p>If the ILE
|
|
environment variable QIBM_USE_DESCRIPTOR_STDIO is set to Y or I when the Qp2RunPase()
|
|
API is called, <span class="keyword">i5/OS</span> PASE
|
|
synchronizes file descriptors 0, 1, and 2 with the integrated file system
|
|
so that both <span class="keyword">i5/OS</span> PASE
|
|
and ILE C programs use the same descriptor numbers for files stdin, stdout,
|
|
and stderr. When operating in this mode, if either <span class="keyword">i5/OS</span> PASE
|
|
code or ILE C code closes or reopens file descriptor 0, 1, or 2, the change
|
|
affects stdin, stdout, and stderr processing for both environments.</p>
|
|
<p><span class="keyword">i5/OS</span> PASE run time generally does
|
|
no character encoding conversion for data read or written through <span class="keyword">i5/OS</span> PASE file descriptors (including
|
|
sockets), except that ASCII-to-EBCDIC conversion is done (between the <span class="keyword">i5/OS</span> PASE CCSID and job default
|
|
CCSID) for data read from ILE C stdin or written to ILE C stdout and stderr.</p>
|
|
<p>Two
|
|
environment variables control the automatic translation of stdin, stdout,
|
|
and stderr:</p>
|
|
<ul><li>The variable that generally applies is QIBM_USE_DESCRIPTOR_STDIO. When
|
|
set to Y, the ILE runtime uses file descriptor 0, 1, or 2 for these files.</li>
|
|
<li>The <span class="keyword">i5/OS</span> PASE
|
|
system-specific environment variable is QIBM_PASE_DESCRIPTOR_STDIO. It has
|
|
values of B for binary and T for text.</li>
|
|
</ul>
|
|
<p>ASCII-to-EBCDIC conversion for <span class="keyword">i5/OS</span> PASE
|
|
stdin, stdout, and stderr is disabled if the ILE environment variable QIBM_USE_DESCRIPTOR_STDIO
|
|
is set to Y and QIBM_PASE_DESCRIPTOR_STDIO is set to B (allowing binary data
|
|
to be read from stdin and written to stdout or stderr). The default for QIBM_PASE_DESCRIPTOR_STDIO
|
|
is T for text. This value causes translation of EBCDIC to ASCII.</p>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="rzalfinteract.htm" title="As you customize your i5/OS PASE programs to use i5/OS functions, you need to consider the ways in which your program will interact with them.">How i5/OS PASE programs interact with i5/OS</a></div>
|
|
</div>
|
|
<div class="relconcepts"><strong>Related concepts</strong><br />
|
|
<div><a href="rzalfdataconv.htm" title="Most operating systems, such as AIX and Linux, use ASCII character encoding. Most i5/OS functions use EBCDIC character encoding. You can specify a coded character set identifier (CCSID) value for some i5/OS object types to identify a specific encoding for character data in the object.">Data encoding</a></div>
|
|
</div>
|
|
<div class="relinfo"><strong>Related information</strong><br />
|
|
<div><a href="../ifs/rzaaxkickoff.htm">Integrated file system</a></div>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html> |