<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://try-as400.pocnet.net/index.php?action=history&amp;feed=atom&amp;title=System_Files%3AQFILEMCD</id>
	<title>System Files:QFILEMCD - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://try-as400.pocnet.net/index.php?action=history&amp;feed=atom&amp;title=System_Files%3AQFILEMCD"/>
	<link rel="alternate" type="text/html" href="http://try-as400.pocnet.net/index.php?title=System_Files:QFILEMCD&amp;action=history"/>
	<updated>2026-08-15T02:55:53Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.9</generator>
	<entry>
		<id>http://try-as400.pocnet.net/index.php?title=System_Files:QFILEMCD&amp;diff=1780&amp;oldid=prev</id>
		<title>Friedkiwi: Correct the header field at 0x26: it carries the system serial number, not a build id</title>
		<link rel="alternate" type="text/html" href="http://try-as400.pocnet.net/index.php?title=System_Files:QFILEMCD&amp;diff=1780&amp;oldid=prev"/>
		<updated>2026-08-08T20:38:12Z</updated>

		<summary type="html">&lt;p&gt;Correct the header field at 0x26: it carries the system serial number, not a build id&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 22:38, 8 August 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l5&quot;&gt;Line 5:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 5:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Both files are containers of [[Data Structures:LID|LIDs]], but at different granularities, and the relationship between them is described under &amp;#039;&amp;#039;Two directories, two granularities&amp;#039;&amp;#039; below.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Both files are containers of [[Data Structures:LID|LIDs]], but at different granularities, and the relationship between them is described under &amp;#039;&amp;#039;Two directories, two granularities&amp;#039;&amp;#039; below.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The figures quoted here come from one V4R4 image of 472,846,336 bytes (451&amp;amp;thinsp;MiB). Treat structure as general and numbers as release-specific; the format is &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;known to have survived at least to V7R2 with the same shape&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The figures quoted here come from one V4R4 image of 472,846,336 bytes (451&amp;amp;thinsp;MiB). Treat structure as general and numbers as release-specific; the format is &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;unchanged from V4R4 through V7R4, across install media and SAVSYS output alike&lt;/ins&gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Header ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Header ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l16&quot;&gt;Line 16:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 16:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|&amp;lt;code&amp;gt;0x1C&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|&amp;lt;code&amp;gt;0x1C&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|32-bit total size of the payload area — see below&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|32-bit total size of the payload area — see below&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;. Confirmed on three independent samples&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|&amp;lt;code&amp;gt;0x26&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|&amp;lt;code&amp;gt;0x26&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|Release &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;and build string&lt;/del&gt;, EBCDIC&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|Release &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;level, then the &#039;&#039;&#039;system serial number&#039;&#039;&#039;&lt;/ins&gt;, EBCDIC&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|&amp;lt;code&amp;gt;0x50&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|&amp;lt;code&amp;gt;0x50&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l28&quot;&gt;Line 28:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 28:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;release &lt;/del&gt;string in &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;this &lt;/del&gt;image &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;is&lt;/del&gt;:&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The string in &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;a V4R4 &lt;/ins&gt;image &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;reads&lt;/ins&gt;:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l34&quot;&gt;Line 34:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 34:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The first &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;part identifies &lt;/del&gt;the release and build. The ten digits &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;that follow &lt;/del&gt;parse naturally as a timestamp of the form &amp;lt;code&amp;gt;YYMMDDHHMM&amp;lt;/code&amp;gt;, &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;which would make this &lt;/del&gt;backup 2026-06-07 14:17 &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;— plausible, since the image was produced by a SAVSYS on a running machine rather than shipped by IBM&lt;/del&gt;. That &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;reading &lt;/del&gt;is an inference from the shape of the field.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;and in a V7R4 one taken by SAVSYS from a running machine:&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;pre&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;V7R4M021-7886W&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;/pre&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;The first &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;field is &lt;/ins&gt;the release and &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;modification level. &#039;&#039;&#039;The five characters after the hyphen are the system serial number.&#039;&#039;&#039; That is not an inference: the owner of the V7R4 machine confirms its serial is &amp;lt;code&amp;gt;7886W&amp;lt;/code&amp;gt;.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;On &#039;&#039;&#039;installation media&#039;&#039;&#039; the same field carries a &lt;/ins&gt;build &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;or media tag instead — a V7R4 install ISO reads &amp;lt;code&amp;gt;V7R4M021-821BV&amp;lt;/code&amp;gt; — so what the field means depends on how the image was produced. Both forms are five characters, which makes them easy to confuse.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;blockquote&amp;gt;&#039;&#039;&#039;Note!&#039;&#039;&#039; A LIC backup is therefore &#039;&#039;&#039;not anonymous&#039;&#039;&#039;: it records the serial number of the machine it came from&lt;/ins&gt;. The &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;serial is also one of the values the system password is keyed on (see [[CISC AS/400 LIC Tapes]]), so treat these files as identifying if you share them.&amp;lt;/blockquote&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;In the V4R4 sample the &lt;/ins&gt;ten digits &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;after the serial &lt;/ins&gt;parse naturally as a timestamp of the form &amp;lt;code&amp;gt;YYMMDDHHMM&amp;lt;/code&amp;gt;, &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;making that &lt;/ins&gt;backup 2026-06-07 14:17. That &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;part &#039;&#039;&#039;&lt;/ins&gt;is&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&#039;&#039;&#039; &lt;/ins&gt;an inference from the shape of the field&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;, and the V7R4 sample carries binary rather than digits in the same place, so the layout after the serial is not fixed&lt;/ins&gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;blockquote&amp;gt;&amp;#039;&amp;#039;&amp;#039;Note!&amp;#039;&amp;#039;&amp;#039; The header is &amp;#039;&amp;#039;&amp;#039;not&amp;#039;&amp;#039;&amp;#039; a fixed 192 (&amp;lt;code&amp;gt;0xC0&amp;lt;/code&amp;gt;) bytes, despite older format notes saying so. The IBM legal banner runs on well past that point, and in this V4R4 image the directory does not begin until &amp;lt;code&amp;gt;0x1C0&amp;lt;/code&amp;gt;. A parser should locate the directory by scanning for the first 64-byte-aligned block that has the shape of an entry, rather than seeking to a constant.&amp;lt;/blockquote&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;blockquote&amp;gt;&amp;#039;&amp;#039;&amp;#039;Note!&amp;#039;&amp;#039;&amp;#039; The header is &amp;#039;&amp;#039;&amp;#039;not&amp;#039;&amp;#039;&amp;#039; a fixed 192 (&amp;lt;code&amp;gt;0xC0&amp;lt;/code&amp;gt;) bytes, despite older format notes saying so. The IBM legal banner runs on well past that point, and in this V4R4 image the directory does not begin until &amp;lt;code&amp;gt;0x1C0&amp;lt;/code&amp;gt;. A parser should locate the directory by scanning for the first 64-byte-aligned block that has the shape of an entry, rather than seeking to a constant.&amp;lt;/blockquote&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key tryas400:diff:1.41:old-1771:rev-1780:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>Friedkiwi</name></author>
	</entry>
	<entry>
		<id>http://try-as400.pocnet.net/index.php?title=System_Files:QFILEMCD&amp;diff=1771&amp;oldid=prev</id>
		<title>Friedkiwi: Document the QFILEMCD / COPYDIR container: header, directory, segment extraction (via create-page on MediaWiki MCP Server)</title>
		<link rel="alternate" type="text/html" href="http://try-as400.pocnet.net/index.php?title=System_Files:QFILEMCD&amp;diff=1771&amp;oldid=prev"/>
		<updated>2026-08-08T17:04:39Z</updated>

		<summary type="html">&lt;p&gt;Document the QFILEMCD / COPYDIR container: header, directory, segment extraction (via create-page on MediaWiki MCP Server)&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;&amp;lt;code&amp;gt;QFILEMCD&amp;lt;/code&amp;gt;&amp;#039;&amp;#039;&amp;#039; is the larger of the two container files found on AS/400 SAVSYS and Licensed Internal Code installation media. It is a backup of &amp;#039;&amp;#039;&amp;#039;SLIC&amp;#039;&amp;#039;&amp;#039; itself — the System Licensed Internal Code that sits below OS/400 — stored as a small number of very large memory segments. Its internal format is called &amp;#039;&amp;#039;&amp;#039;&amp;lt;code&amp;gt;COPYDIR&amp;lt;/code&amp;gt;&amp;#039;&amp;#039;&amp;#039; after the eyecatcher at offset zero.&lt;br /&gt;
&lt;br /&gt;
Practically, this is the file to reach for if you want to read the machine&amp;#039;s own code without touching a running system. Its segments are a byte-for-byte image of what the link loader maps into memory, so an address recovered from a crash, a trace or a [[SRC|system reference code]] can be looked up directly in a file on your workstation. The companion file [[System Files:QFILEIML]] carries the loadable IOP, adapter and service processor microcode instead.&lt;br /&gt;
&lt;br /&gt;
Both files are containers of [[Data Structures:LID|LIDs]], but at different granularities, and the relationship between them is described under &amp;#039;&amp;#039;Two directories, two granularities&amp;#039;&amp;#039; below.&lt;br /&gt;
&lt;br /&gt;
The figures quoted here come from one V4R4 image of 472,846,336 bytes (451&amp;amp;thinsp;MiB). Treat structure as general and numbers as release-specific; the format is known to have survived at least to V7R2 with the same shape.&lt;br /&gt;
&lt;br /&gt;
== Header ==&lt;br /&gt;
{|class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!Offset&lt;br /&gt;
!Contents&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;0x00&amp;lt;/code&amp;gt;&lt;br /&gt;
|Eyecatcher &amp;lt;code&amp;gt;COPYDIR&amp;amp;nbsp;&amp;lt;/code&amp;gt; in EBCDIC (&amp;lt;code&amp;gt;C3 D6 D7 E8 C4 C9 D9 40&amp;lt;/code&amp;gt;), a zero byte, then the two EBCDIC characters &amp;lt;code&amp;gt;00&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;0x1C&amp;lt;/code&amp;gt;&lt;br /&gt;
|32-bit total size of the payload area — see below&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;0x26&amp;lt;/code&amp;gt;&lt;br /&gt;
|Release and build string, EBCDIC&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;0x50&amp;lt;/code&amp;gt;&lt;br /&gt;
|Licensed Internal Code banner, EBCDIC, in 48-character chunks&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;0x1C0&amp;lt;/code&amp;gt;&lt;br /&gt;
|Start of the directory&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The release string in this image is:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
V4R4M044-C6295  2606071417&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The first part identifies the release and build. The ten digits that follow parse naturally as a timestamp of the form &amp;lt;code&amp;gt;YYMMDDHHMM&amp;lt;/code&amp;gt;, which would make this backup 2026-06-07 14:17 — plausible, since the image was produced by a SAVSYS on a running machine rather than shipped by IBM. That reading is an inference from the shape of the field.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;blockquote&amp;gt;&amp;#039;&amp;#039;&amp;#039;Note!&amp;#039;&amp;#039;&amp;#039; The header is &amp;#039;&amp;#039;&amp;#039;not&amp;#039;&amp;#039;&amp;#039; a fixed 192 (&amp;lt;code&amp;gt;0xC0&amp;lt;/code&amp;gt;) bytes, despite older format notes saying so. The IBM legal banner runs on well past that point, and in this V4R4 image the directory does not begin until &amp;lt;code&amp;gt;0x1C0&amp;lt;/code&amp;gt;. A parser should locate the directory by scanning for the first 64-byte-aligned block that has the shape of an entry, rather than seeking to a constant.&amp;lt;/blockquote&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The 32-bit field at &amp;lt;code&amp;gt;0x1C&amp;lt;/code&amp;gt; holds &amp;lt;code&amp;gt;0x1C2F0000&amp;lt;/code&amp;gt;, which is exactly the end of the last segment&amp;#039;s data. It is a total-payload-size field and makes a good consistency check after parsing the directory: accumulate the entries and you should arrive at the same number.&lt;br /&gt;
&lt;br /&gt;
== The directory ==&lt;br /&gt;
The directory is a run of 64-byte entries beginning at &amp;lt;code&amp;gt;0x1C0&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{|class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!Offset&lt;br /&gt;
!Size&lt;br /&gt;
!Field&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x00&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&lt;br /&gt;
|Always zero in observed data&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x08&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&lt;br /&gt;
|Flags. See the bit-numbering warning below&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x10&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&lt;br /&gt;
|SLS address of the saved segment&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x18&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&lt;br /&gt;
|Segment attributes; the top 16 bits carry the useful value&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x20&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&lt;br /&gt;
|Always zero in observed data&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x28&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&lt;br /&gt;
|Offset to the segment data, &amp;#039;&amp;#039;&amp;#039;absolute from the start of the file&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x30&amp;lt;/code&amp;gt;&lt;br /&gt;
|4&lt;br /&gt;
|Segment length, in &amp;#039;&amp;#039;&amp;#039;raw bytes&amp;#039;&amp;#039;&amp;#039; — not blocks&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x34&amp;lt;/code&amp;gt;&lt;br /&gt;
|4&lt;br /&gt;
|Always zero in observed data&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;+0x38&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&lt;br /&gt;
|Always zero in observed data&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Two details cause most of the trouble people have with this structure, and both were originally got wrong here:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Flags use IBM&amp;#039;s MSB-first bit numbering.&amp;#039;&amp;#039;&amp;#039; Older notes describe the field as &amp;lt;code&amp;gt;bbt 0:3&amp;lt;/code&amp;gt;, and a reader used to LSB-first numbering will look in the bottom nibble and find nothing. Bit 0 is the &amp;#039;&amp;#039;most&amp;#039;&amp;#039; significant bit, so the value lives in the &amp;#039;&amp;#039;&amp;#039;top&amp;#039;&amp;#039;&amp;#039; nibble of the 8-byte field. A normal entry reads &amp;lt;code&amp;gt;0x1000000000000000&amp;lt;/code&amp;gt;; the end-of-directory marker reads &amp;lt;code&amp;gt;0xF000000000000000&amp;lt;/code&amp;gt;.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;The data offset is absolute.&amp;#039;&amp;#039;&amp;#039; It is measured from the start of the file, not from the end of the directory. Reading it as relative shifts every extracted segment by the size of the directory, which produces code that disassembles almost plausibly and is wrong everywhere.&lt;br /&gt;
&lt;br /&gt;
In this image the directory holds &amp;#039;&amp;#039;&amp;#039;32 entries&amp;#039;&amp;#039;&amp;#039;, with the terminator at &amp;lt;code&amp;gt;0x9C0&amp;lt;/code&amp;gt; and the directory ending at &amp;lt;code&amp;gt;0xA00&amp;lt;/code&amp;gt;. The first entry has a data offset of zero, which means the header and directory physically occupy the first &amp;lt;code&amp;gt;0xA00&amp;lt;/code&amp;gt; bytes of the first segment&amp;#039;s stored image. This is expected rather than a bug, but a tool that extracts that segment will see the container&amp;#039;s own header at the front of it.&lt;br /&gt;
&lt;br /&gt;
Segment lengths are consistently a whole number of 4&amp;amp;thinsp;KiB pages less than a power-of-two boundary: &amp;lt;code&amp;gt;0xFFF000&amp;lt;/code&amp;gt; is 16&amp;amp;thinsp;MiB minus one page, &amp;lt;code&amp;gt;0x7FF000&amp;lt;/code&amp;gt; is 8&amp;amp;thinsp;MiB minus one page, and so on.&lt;br /&gt;
&lt;br /&gt;
== Contents of a typical backup ==&lt;br /&gt;
The 32 segments of this image, with names from a community-maintained SLS address reference. Where the name column is blank, the segment&amp;#039;s purpose has not been established.&lt;br /&gt;
&lt;br /&gt;
{|class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!SLS address&lt;br /&gt;
!Length&lt;br /&gt;
!Name&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFB1 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFB2 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFB3 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFB5 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFC1 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader — LIC Code&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFC2 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader — LIC Data&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFC3 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader — LIC Code (2)&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFC4 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader — LIC Code (3)&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFC5 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader — LIC Code (4)&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFC6 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader — LIC Code (5)&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFC7 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Mixed — component code and NLS text pools&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFC8 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&amp;amp;thinsp;MiB&lt;br /&gt;
|Mixed — bignum/JVM code and NLS text pools&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFF1 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|4&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader TOC&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFF2 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Service LID&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFF4 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Service LID (2)&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFFE 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|15&amp;amp;thinsp;MiB&lt;br /&gt;
|Pageable BLA&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFD1 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader Information&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFD2 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader Information, Code, Data&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFD3 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Link Loader Information (2)&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFD4 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|Mixed — JVM strings and DST debug symbol table&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF90 010000&amp;lt;/code&amp;gt;&lt;br /&gt;
|60&amp;amp;thinsp;KiB&lt;br /&gt;
|LID Directory&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF91 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|LID NUC2 A-Side&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF92 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|LID NUC2 B-Side&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF93 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|LID NUC1 A-Side&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF94 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|LID NUC1 B-Side&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF95 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF96 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF9A 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF9B 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|8&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFA1 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|LID Manager&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFFA2 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&amp;lt;code&amp;gt;FFFFFFFF69 000000&amp;lt;/code&amp;gt;&lt;br /&gt;
|16&amp;amp;thinsp;MiB&lt;br /&gt;
|IDE&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
So a backup of this shape is the SLIC boot and loader nucleus: link loader code and data, the loader&amp;#039;s table of contents, the LID subsystem&amp;#039;s own bookkeeping, and both IPL sides of the two nucleus LIDs. It is not the whole of the machine&amp;#039;s code.&lt;br /&gt;
&lt;br /&gt;
=== A and B sides ===&lt;br /&gt;
Several segments appear twice, distinguished as &amp;#039;&amp;#039;A-side&amp;#039;&amp;#039; and &amp;#039;&amp;#039;B-side&amp;#039;&amp;#039;. An AS/400 keeps two copies of its Licensed Internal Code so that an update can be applied to one while the other remains a fallback. A normal, unattended IPL runs the &amp;#039;&amp;#039;&amp;#039;B side&amp;#039;&amp;#039;&amp;#039;, so B is what a running machine is executing and B is what static analysis should be done against. Because the two sides are normally near-identical, a byte comparison against the A side is not evidence that A is the live one — the test only means something on a segment that actually differs between them.&lt;br /&gt;
&lt;br /&gt;
== Two directories, two granularities ==&lt;br /&gt;
A common source of confusion is that &amp;lt;code&amp;gt;QFILEMCD&amp;lt;/code&amp;gt; appears to have two completely different directory formats. It does, and they nest:&lt;br /&gt;
&lt;br /&gt;
* The &amp;#039;&amp;#039;&amp;#039;coarse&amp;#039;&amp;#039;&amp;#039; level is &amp;lt;code&amp;gt;COPYDIR&amp;lt;/code&amp;gt;&amp;#039;s own directory, documented above: 64-byte entries, one per 16&amp;amp;thinsp;MiB-class memory segment, 32 of them.&lt;br /&gt;
* The &amp;#039;&amp;#039;&amp;#039;fine&amp;#039;&amp;#039;&amp;#039; level is a catalogue of individual LIDs, thousands of entries, using the 32-byte record described at [[Data Structures:LID]].&lt;br /&gt;
&lt;br /&gt;
The fine level is not a second header in the file. It is simply &amp;#039;&amp;#039;&amp;#039;the contents of one particular segment&amp;#039;&amp;#039;&amp;#039; — the one named &amp;#039;&amp;#039;LID Directory&amp;#039;&amp;#039;, at &amp;lt;code&amp;gt;FFFFFFFF90 010000&amp;lt;/code&amp;gt;. Extract that segment and you find, after a preamble of about 1536 bytes, an EBCDIC &amp;lt;code&amp;gt;Directory.&amp;lt;/code&amp;gt; eyecatcher, a version label, and then the records. In this image the label reads &amp;lt;code&amp;gt;v4r4m01204.0.03&amp;lt;/code&amp;gt;, which is the same label carried by [[System Files:QFILEIML]] — a quick way to confirm that two files came off the same media.&lt;br /&gt;
&lt;br /&gt;
That is also why tools which dump this file emit two dissimilar-looking listings: a short table of large memory extents, and a long list of LIDs. They are two levels of one structure, not two formats.&lt;br /&gt;
&lt;br /&gt;
== Extracting a segment ==&lt;br /&gt;
The practical recipe, and the reason this file is worth knowing about:&lt;br /&gt;
&lt;br /&gt;
# Read the &amp;lt;code&amp;gt;COPYDIR&amp;lt;/code&amp;gt; eyecatcher at offset 0 to confirm the format.&lt;br /&gt;
# Find the directory by scanning 64-byte-aligned offsets for the first entry-shaped block, rather than assuming &amp;lt;code&amp;gt;0xC0&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;0x1C0&amp;lt;/code&amp;gt;.&lt;br /&gt;
# Walk entries until the flags field has &amp;lt;code&amp;gt;0xF&amp;lt;/code&amp;gt; in its &amp;#039;&amp;#039;&amp;#039;top&amp;#039;&amp;#039;&amp;#039; nibble.&lt;br /&gt;
# For the segment you want, seek to the data offset &amp;#039;&amp;#039;&amp;#039;as an absolute file offset&amp;#039;&amp;#039;&amp;#039; and read &amp;#039;&amp;#039;length&amp;#039;&amp;#039; raw bytes.&lt;br /&gt;
# Load the result at its SLS address in a disassembler. The bytes are what the link loader maps, so addresses match.&lt;br /&gt;
&lt;br /&gt;
Step 5 is the payoff. A 64-bit address such as &amp;lt;code&amp;gt;FFFFFFFFC6 1F1690&amp;lt;/code&amp;gt; can be typed straight into the DST &amp;#039;&amp;#039;Display/Alter storage&amp;#039;&amp;#039; panel on a live machine of the same build, and the sixteen rows it displays will match the extracted file byte for byte. Static and live analysis share one address space, which means you can do the slow work offline and use the machine only for confirmation.&lt;br /&gt;
&lt;br /&gt;
Two caveats on addresses. They are per-&amp;#039;&amp;#039;&amp;#039;build&amp;#039;&amp;#039;&amp;#039;, not per-release, so comparisons are only meaningful between identical builds; the same class sits at a quite different address on a V5R4 machine. And the SLS address recorded in the directory is the address the segment was &amp;#039;&amp;#039;&amp;#039;saved from&amp;#039;&amp;#039;&amp;#039;, which is not always where it runs — the resident nucleus segment, for instance, is stored in the container under the SID of the B-side nucleus LID rather than its runtime SID.&lt;br /&gt;
&lt;br /&gt;
== Reading the code ==&lt;br /&gt;
Once a segment is loaded, two structures make it navigable, and both are worth knowing because they turn addresses into names:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Traceback trailers.&amp;#039;&amp;#039;&amp;#039; Every compilation unit ends its code with a &amp;lt;code&amp;gt;TBTB&amp;lt;/code&amp;gt; trailer, and many carry the module&amp;#039;s name. A trailer names a whole compilation unit rather than a single function, so a hit means &amp;quot;this address is inside module X&amp;quot;, not &amp;quot;this address is function X&amp;quot;.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Link-loader descriptor blocks.&amp;#039;&amp;#039;&amp;#039; Considerably richer: one block per procedure, carrying the entry address at &amp;lt;code&amp;gt;+0x08&amp;lt;/code&amp;gt; and the name in EBCDIC at &amp;lt;code&amp;gt;+0x38&amp;lt;/code&amp;gt;. Names beginning with &amp;lt;code&amp;gt;#&amp;lt;/code&amp;gt; are SLIC-internal modules; the rest are C++ mangled symbols.&lt;br /&gt;
&lt;br /&gt;
Merging both across every segment of this V4R4 image yields roughly 184,000 named records, which is enough to name a substantial fraction of any address you encounter. See [[SRC]] for how to use that to get from a reference code back to a module.&lt;br /&gt;
&lt;br /&gt;
Calls between modules do not go through a conventional dispatch table, which surprises people disassembling SLIC for the first time. An external call is a two-instruction sequence — &amp;lt;code&amp;gt;ori r11,r13,&amp;#039;&amp;#039;ordinal&amp;#039;&amp;#039;&amp;lt;/code&amp;gt; followed by &amp;lt;code&amp;gt;bla&amp;lt;/code&amp;gt; into a transfer vector at the very top of the address space — and the 16-byte stub it lands on computes the target arithmetically. There is no table to read off; the ordinal &amp;#039;&amp;#039;is&amp;#039;&amp;#039; the callee&amp;#039;s word offset within a window, and the stub supplies the window. The stub constants cannot be derived and must be read from a dump of the transfer vector.&lt;br /&gt;
&lt;br /&gt;
== The trailing page ==&lt;br /&gt;
The payload area ends at &amp;lt;code&amp;gt;0x1C2F0000&amp;lt;/code&amp;gt;, but the file is one 4&amp;amp;thinsp;KiB page longer than that. The final page is not padding: it holds 468 non-zero 8-byte records, which appear to be address-and-value pairs.&lt;br /&gt;
&lt;br /&gt;
They fall into two clear populations. The first 110 are in ascending address order with a value of 8, addressing the &amp;#039;&amp;#039;Link Loader — LIC Data&amp;#039;&amp;#039; segment among others. The remaining 256 are identical to each other: the same address &amp;lt;code&amp;gt;0xFE911220&amp;lt;/code&amp;gt;, in the &amp;#039;&amp;#039;Pageable BLA&amp;#039;&amp;#039; segment, paired with the value &amp;lt;code&amp;gt;0x48000002&amp;lt;/code&amp;gt; — which as PowerPC is a branch-absolute to zero, the shape of a deliberately poisoned entry.&lt;br /&gt;
&lt;br /&gt;
This has the flavour of a fixup or relocation list applied after the segments are restored, but that is a guess from shape alone. It is recorded here because it is real, reproducible and unexplained, and because a parser that assumes the file ends with the payload will silently ignore it.&lt;br /&gt;
&lt;br /&gt;
== Open questions ==&lt;br /&gt;
* The purpose of the trailing page.&lt;br /&gt;
* The header bytes other than the eyecatcher, size field, release string and banner.&lt;br /&gt;
* The meaning of the segment attribute field&amp;#039;s top 16 bits, which take values &amp;lt;code&amp;gt;0x0001&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;0x0040&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;0x0080&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;0x0100&amp;lt;/code&amp;gt; and correlate loosely with segment size.&lt;br /&gt;
* Names for the nine segments left blank in the table above.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
* [[System Files:QFILEIML]]&lt;br /&gt;
* [[Data Structures:LID]]&lt;br /&gt;
* [[SRC]]&lt;br /&gt;
* [[CISC AS/400 LIC Tapes]]&lt;br /&gt;
&lt;br /&gt;
== Footnotes ==&lt;br /&gt;
&amp;lt;references /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category: System Internals]]&lt;/div&gt;</summary>
		<author><name>Friedkiwi</name></author>
	</entry>
</feed>