कर्नेल टेंट वैल्यू का क्या अर्थ है?


20

रनिंग cat /proc/sys/kernel/taintedवर्तमान कर्नेल टेंट वैल्यू (बेस 10 में) प्रिंट करता है। मेरी समझ यह है कि यह मूल्य एक बिटफील्ड है, जहां प्रत्येक बिट एक विशेष प्रकार के टेंट की अनुपस्थिति या उपस्थिति को इंगित करता है। आप बिट्स का उपयोग करके निकाल सकते हैं

python3 -c 'from pprint import pprint; pprint(list(zip(range(50), reversed(bin(int(open("/proc/sys/kernel/tainted").read()))[2:]))))'

मैंने प्रलेखन के लिए खोज की है, लेकिन मैंने जो देखा है वह केवल बिट्स 0 के अर्थ की पहचान करता है। 10. उदाहरण के लिए, http://www.kernel.org/doc/Documentation/sysctl/kernel.txt कहता है:

tainted:

Non-zero if the kernel has been tainted. Numeric values, which can be
ORed together. The letters are seen in "Tainted" line of Oops reports.

     1 (P):  A module with a non-GPL license has been loaded, this
             includes modules with no license.
             Set by modutils >= 2.4.9 and module-init-tools.
     2 (F): A module was force loaded by insmod -f.
            Set by modutils >= 2.4.9 and module-init-tools.
     4 (S): Unsafe SMP processors: SMP with CPUs not designed for SMP.
     8 (R): A module was forcibly unloaded from the system by rmmod -f.
    16 (M): A hardware machine check error occurred on the system.
    32 (B): A bad page was discovered on the system.
    64 (U): The user has asked that the system be marked "tainted". This
            could be because they are running software that directly modifies
            the hardware, or for other reasons.
   128 (D): The system has died.
   256 (A): The ACPI DSDT has been overridden with one supplied by the user
            instead of using the one provided by the hardware.
   512 (W): A kernel warning has occurred.
  1024 (C): A module from drivers/staging was loaded.
  2048 (I): The system is working around a severe firmware bug.
  4096 (O): An out-of-tree module has been loaded.
  8192 (E): An unsigned module has been loaded in a kernel supporting module
            signature.
 16384 (L): A soft lockup has previously occurred on the system.
 32768 (K): The kernel has been live patched.
 65536 (X): Auxiliary taint, defined and used by for distros.
131072 (T): The kernel was built with the struct randomization plugin.

मैंने linux-docपैकेज स्थापित करके और खोलकर उबंटू कर्नेल के लिए प्रलेखन देखने की भी कोशिश की zless /usr/share/doc/linux-doc/sysctl/kernel.txt.gz, लेकिन यह अभी भी केवल 1024 तक ही सूचीबद्ध है।

मेरे मामले में, मैं डिफ़ॉल्ट पीएई कर्नेल (3.2.0-36-जेनेरिक-पा) प्रीसीज़ पर चला रहा हूं। मैं भी बिट सेट 12 देख रहा हूं।

उबंटू गुठली पर दागी बिट्स का क्या मतलब है, इसके लिए पूरा दस्तावेज कहां है?

जवाबों:


15

देख रहे हैं panic.c:

/**
 *      print_tainted - return a string to represent the kernel taint state.
 *
 *  'P' - Proprietary module has been loaded.
 *  'F' - Module has been forcibly loaded.
 *  'S' - SMP with CPUs not designed for SMP.
 *  'R' - User forced a module unload.
 *  'M' - System experienced a machine check exception.
 *  'B' - System has hit bad_page.
 *  'U' - Userspace-defined naughtiness.
 *  'D' - Kernel has oopsed before
 *  'A' - ACPI table overridden.
 *  'W' - Taint on warning.
 *  'C' - modules from drivers/staging are loaded.
 *  'I' - Working around severe firmware bug.
 *  'O' - Out-of-tree module has been loaded.
 *  'E' - Unsigned module has been loaded.
 *  'L' - A soft lockup has previously occurred.
 *  'K' - Kernel has been live patched.
 *
 *      The string is overwritten by the next call to print_tainted().
 */

6
kernel.txtअब इन अंतिम दो झंडे के दस्तावेज।
तोबू
हमारी साइट का प्रयोग करके, आप स्वीकार करते हैं कि आपने हमारी Cookie Policy और निजता नीति को पढ़ और समझा लिया है।
Licensed under cc by-sa 3.0 with attribution required.