r1024 - in html/trunk: faq lfs

justin at linuxfromscratch.org justin at linuxfromscratch.org
Thu Jul 7 14:42:20 PDT 2005


Author: justin
Date: 2005-07-07 15:42:18 -0600 (Thu, 07 Jul 2005)
New Revision: 1024

Modified:
   html/trunk/faq/index.html
   html/trunk/lfs/faq.html
Log:
[www] Update FAQ entry for 'which distro' and added entry for 'no more ptys' error.  Thanks to Archaic.

Modified: html/trunk/faq/index.html
===================================================================
--- html/trunk/faq/index.html	2005-07-06 22:05:33 UTC (rev 1023)
+++ html/trunk/faq/index.html	2005-07-07 21:42:18 UTC (rev 1024)
@@ -118,6 +118,7 @@
 	<li id="alpha-fixes"><a href="../lfs/faq.html#alpha-fixes">Is there information about LFS on the Alpha?</a></li>
 	<li id="cross-compile"><a href="../lfs/faq.html#cross-compile">How do I cross compile LFS?</a></li>
 	<li id="dos-text"><a href="../lfs/faq.html#dos-text">What's a DOS format text file?</a></li>
+        <li id="no-ptys"><a href="../lfs/faq.html#no-ptys">The system has no more ptys. Ask your system administrator to create more.</a></li>
 </ul>
 
 <h3 id="generrors"><a href="../lfs/faq.html#generrors">General compilation errors</a></h3>

Modified: html/trunk/lfs/faq.html
===================================================================
--- html/trunk/lfs/faq.html	2005-07-06 22:05:33 UTC (rev 1023)
+++ html/trunk/lfs/faq.html	2005-07-07 21:42:18 UTC (rev 1024)
@@ -106,6 +106,7 @@
 	<li><a href="#config-not-gnu-c">checking whether we are using GNU C... no</a></li>
 	<li><a href="#cannot-find-lc">ld: cannot find -lc</a></li>
 	<li><a href="#where-ncurses-mandrake">Where's libncurses.a in Mandrake?</a></li>
+        <li><a href="#no-ptys">The system has no more ptys.  Ask your system administrator to create more.</a></li>
 </ul>
 
 <h3><a href="#packerrors">Package-specific errors</a></h3>
@@ -262,7 +263,7 @@
 <dl>
 	<dt id="what-dist">What distribution should I use to start from?</dt>
 		<dd>
-			<p>Any recent distribution should be fine. If you have problems, try installing and/or updating the development packages. (Look for ones starting in "gcc", "glibc", or "libstdc++" or ending in "-dev".). If you want to make use LFS as your main system and you wish to install it without first installing a distribution, try <a href="http://www.knopper.net/knoppix/index-en.html">Knoppix</a> or <a href="packages.html">an LFS boot cd</a>.</p>
+			<p>Most relatively recent distributions should be fine. Do not use Fedora Core 4 or any other distribution that contains gcc-4.0. This compiler was just released, and many packages will require patches and/or may break. For distributions that do not use gcc-4.0, make sure you have installed and/or updated the development packages. (Look for ones starting in "gcc", "glibc", or "libstdc++" or ending in "-dev".). If you want to use LFS as your main system and you wish to install it without first installing a distribution, try the <a href="http://beta.linuxfromscratch.org/livecd/">LFS LiveCD</a> or <a href="http://www.knopper.net/knoppix/index-en.html">Knoppix</a>.</p>
 		</dd>
 	<dt id="kernel-modules">How do I compile a kernel or set up modules?</dt>
 		<dd>
@@ -446,6 +447,45 @@
 		<dd>
 			<p>In Mandrake/RPMS2/libncurses5-devel-5.2-16mdk.1586.rpm on Disk 2. Version numbers might be a little different for you. (If you're missing libcurses.a (no "n"), reread the book's instructions for bash more carefully.)</p>
 		</dd>
+        <dt id="no-ptys">The system has no more ptys.  Ask your system administrator to create more.</dt>
+                <dd>
+                        <p>If you run</p>
+                            <ul class="code">
+                                <li>expect -c "spawn ls"</li>
+                            </ul>
+                        <p>and get the following error:</p>
+                            <ul class="code">
+                                <li>The system has no more ptys.</li>
+                                <li>Ask your system administrator to create more.</li>
+                            </ul>
+                        <p>then your linux distribution is either not setup to use Unix98 PTYs or to use the /dev/pts file system.</p>
+                        <p>The solution my require recompiling your kernel. First, go to your kernel's source directory and look at the .config file. If you do not have a .config file, and you are running the pre-compiled kernel that was installed with rpm, aptget, or whatever your distribution uses, then you need to seek support from your distribution's support FAQ's, mailing lists or IRC channels.</p>
+                        <p>If you do have a .config file, look inside it for the following 2 options:</p>
+                            <ul class="code">
+                                <li>CONFIG_UNIX98_PTYS=y</li>
+                                <li>CONFIG_DEVPTS_FS=y</li>
+                            </ul>
+                        <p>If either of these has 'n' instead of 'y', then change it and recompile the kernel.</p>
+                        <p>If they both have 'y', then you probably will not have to recompile the kernel.</p>
+                        <p>Next, we need to ensure that the system is actually using both Unix98 PTYs and the /dev/pts file system.</p>
+                        <p>First, look for a device called /dev/ptmx.  If it doesn't exist, create it with:</p>
+                            <ul class="code">
+                                <li>mknod /dev/ptmx c 5 2</li>
+                            </ul>
+                        <p>Then, whether is existed or you just created it, run:</p>
+                            <ul class="code">
+                                <li>chmod 666 /dev/ptmx</li>
+                            </ul>
+                        <p>Next, ensure that there is a directory called /dev/pts.  The permissions should be 755.  Create it and/or chmod it if needed.</p>
+                        <p>The final setup is to add the following line to /etc/fstab:</p>
+                            <ul class="code">
+                                <li>devpts    /dev/pts    devpts    gid=5,mode=620    0  0</li>
+                            </ul>
+                        <p>NOTE:  Look for the tty group in /etc/group and note the group id number.  Change the gid=5 option to match the group id number of the tty group.  The group id of 5 is just an example and may differ on your system.</p>
+                        <p>Now that everything is setup, you have two options.</p>
+                        <p>1.  Mount /dev/pts and test it by rerunning the above expect command.</p>
+                        <p>2.  Reboot the computer and test it by rerunning the above expect command.</p>
+                </dd>
 </dl>
 <p><a href="#header">Back to the top.</a></p>
 




More information about the website mailing list