Linux/Tipps/Gentoo/Bugs: Unterschied zwischen den Versionen

Zeile 52: Zeile 52:
   then
   then


==PXE mit NFS-Options in nfsroot und genkernel-3.4.10-r2==
==PXE mit NFS-Options in nfsroot und genkernel==
http://bugs.gentoo.org/show_bug.cgi?id=262915
http://bugs.gentoo.org/show_bug.cgi?id=262915


Zeile 60: Zeile 60:
In diesem Fall versuchen die Scripts '''<Pfad>,<NFS-Options>''' zu mounten, was dann natürlich fehlschlägt.
In diesem Fall versuchen die Scripts '''<Pfad>,<NFS-Options>''' zu mounten, was dann natürlich fehlschlägt.


'''Workaround''':
===Workaround für genkernel-3.4.10-r2===
 
Patch von http://bugs.gentoo.org/show_bug.cgi?id=262915 anwenden und Kernel/initrd mit genkernel neu erstellen:
Patch von http://bugs.gentoo.org/show_bug.cgi?id=262915 anwenden und Kernel/initrd mit genkernel neu erstellen:
  --- /usr/share/genkernel/generic/initrd.scripts.orig    2009-03-17 19:44:39.000000000 +0100
  --- /usr/share/genkernel/generic/initrd.scripts.orig    2009-03-17 19:44:39.000000000 +0100
Zeile 79: Zeile 78:
  +                              good_msg "Attempting to mount NFS root on ${NFSROOT} with options ${NFSOPTIONS}"
  +                              good_msg "Attempting to mount NFS root on ${NFSROOT} with options ${NFSOPTIONS}"
  +                              mount -t nfs -o ${NFSOPTIONS} ${NFSROOT} ${NEW_ROOT}
  +                              mount -t nfs -o ${NFSOPTIONS} ${NFSROOT} ${NEW_ROOT}
                                if [ "$?" = '0' ]
                                then
                                        REAL_ROOT="/dev/nfs"
===Workaround für genkernel-3.4.10-904===
--- /usr/share/genkernel/defaults/initrd.scripts.orig  2009-06-14 18:17:51.000000000 +0200
+++ /usr/share/genkernel/defaults/initrd.scripts        2009-06-12 23:25:56.000000000 +0200
@@ -245,8 +245,14 @@
                                        bad_msg "NFS Mounting failed. Is the path corrent ?"
                                fi
                        else
-                              good_msg "Attempting to mount NFS root on ${NFSROOT}"
-                              mount -t nfs -o ro,nolock,rsize=1024,wsize=1024 ${NFSROOT} ${NEW_ROOT}
+                                NFSOPTIONS=${NFSROOT#*,}
+                                NFSROOT=${NFSROOT%%,*}
+                                if [ "${NFSOPTIONS}" = "${NFSROOT}" ]
+                                then
+                                        NFSOPTIONS="ro,nolock,rsize=1024,wsize=1024"
+                                fi
+                                good_msg "Attempting to mount NFS root on ${NFSROOT} with options ${NFSOPTIONS}"
+                                mount -t nfs -o ${NFSOPTIONS} ${NFSROOT} ${NEW_ROOT}
                                 if [ "$?" = '0' ]
                                 if [ "$?" = '0' ]
                                 then
                                 then
1.108

Bearbeitungen