/proc Directory for Linux Systems

Source: Internet
Author: User
Tags echo command recode

1./proc directory
The Linux kernel provides a machine that accesses kernel internal data structures and changes kernel settings through the/proc file system at run time.
System. The proc file system is a pseudo-file system that only exists in memory and does not occupy external memory space. It is in the form of a file system
Provides an interface for operations that access system kernel data.
Users and applications can get system information through proc, and can change certain parameters of the kernel. As a result of system information such as in-
The proc file is dynamically changed, so the proc file system is dynamically read from the system kernel
Information is required and submitted. These files or subfolders listed below are not always present in your system, depending on your internal
Modules for nuclear configuration and loading. In addition, there are three important directories under/proc: NET,SCSI and Sys.SYS directory is available
It can be used to access or modify kernel parameters, while net and SCSI depend on the kernel configuration
。 For example, if the system
SCSI is not supported, the SCSI directory does not exist.
In addition to the above, there are a number of directories named, they are the process directory. Every current run in the system
The process has a corresponding directory under/proc, the PID number of the process is the directory name, they are the interface to read the process information. and self
The directory is the information interface of the read process itself and is a link.
----------------
2.child files or subfolders
/proc/buddyinfo how many blocks of each order in each memory area are available, related to memory fragmentation issues
/proc/cmdline parameter information passed to kernel at startup
/proc/cpuinfoinformation about the CPU
/proc/crypto all installed cryptographic passwords and details used by the kernel
/proc/devices devices that have been loaded and sorted

/PROC/DMA List of ISA DMA channels that have been registered for use
/proc/execdomains the Linux kernel currently supports execution domains
/PROC/FB Frame buffer device list, including number and drive to control it
File system types currently supported by the/proc/filesystems kernel
/proc/interrupts number of IRQ interrupts in the x86 architecture
/proc/iomem the current mapping of each physical device in system memory
/proc/ioports the registration port range used by the input and output of a device
/proc/kcore represents the physical memory of the system, stored as the core file format, which shows the number of bytes, equal to the RAM size plus 4KB
/proc/kmsg records the information generated by the kernel, which can be handled by/SBIN/KLOGD or/BIN/DMESG
/PROC/LOADAVG load status based on CPU and IO status over a period of time, related to the uptime command
List of files locked by the/proc/locks kernel
/proc/mdstat multi-drive, RAID configuration information (Md=multiple disks)
/proc/meminfo information about RAM usage
/proc/misc other major equipment (device Number 10) on the registered driver
/proc/modules List of all modules loaded into the kernel
/proc/mounts all mounts used in the system
Memory Type Range Registers (MTRRS) used by the/PROC/MTRR system
Block allocation information in a/proc/partitions partition
List of PCI devices in the/PROC/PCI system
/proc/slabinfo Slab cache information for all activities in the system
/proc/stat All CPU activity information
/proc/sysrq-trigger when using the echo command to write this file, the remote root user can perform most of the system request critical commands as if they were executed on the local terminal. To write this file, the/PROC/SYS/KERNEL/SYSRQ cannot be set to 0. This file is unreadable to root.
How long has the/proc/uptime system been running?
Use of/proc/swaps swap space
/proc/version Linux kernel version and GCC version
/proc/bus system bus information such as PCI/USB, etc.
/proc/driver Driver Information
/PROC/FS File System Information
/proc/ide IDE Device Information
/PROC/IRQ Interrupt Request Device information
/proc/net Network card Device information
/PROC/SCSI SCSI Device Information
/proc/tty TTY Device Information
/proc/net/dev Display of network adapters and statistical information
/proc/vmstat Virtual Memory Statistics
/proc/vmcore memory image when kernel panic
/proc/diskstats Obtaining disk information
/proc/schedstat Kernel Scheduler Statistics
/proc/zoneinfo displays statistics for memory space, which is useful for analyzing virtual memory behavior
The following is the information for process n in the/proc directory
/proc/n PIDprocess information for n
/proc/n/cmdline Process Start command
/PROC/N/CWD linking to the current working directory of the process
/proc/n/environ Process environment variable list
/proc/n/exe the execution command file linked to the process
/proc/n/fdcontains all the file descriptors associated with the process
/proc/n/maps memory-mapped information related to processes
/proc/n/mem refers to the memory that is held by the process, unreadable
/proc/n/root linking to the root of a process
Status of the/proc/n/stat process
The state of the memory used by the/PROC/N/STATM process
/proc/n/status process state information, more readable than STAT/STATM
/proc/self Link to the currently running process
-----------------------
dmidecode Command
Purpose: Allows you to obtain information about the hardware in the Linux system. Dmidecode follows the SMBIOS/DMI standard and outputs information including BIOS, system, motherboard, processor, memory, cache, etc.

************************
The output format of the Dmidecode is generally as follows:
Handle 0x0002
DMI Type 2, 8 bytes
Base Board Information
Manufacturer:intel
Product name:c440gx+
version:727281-0001
Serial number:incy92700942
************************
The first three lines are calledRecord Header (Recoce header), which includes the following:
1. Recode ID (handle): The record identifier in the DMI table, which is unique, such as the handle 0x0002 in the previous example.
2. DMI Type ID: The type of record, for example: Bios,memory, the above example is type 2 i.e. "Baseboardinformation"
3. Recode the size of the corresponding record in the Size:dmi table, the previous example is 8bytes. (excluding text information, all actual output is larger than this size.) After the record header is the value of the record
4. Decoded values: The record value can be multiple lines, such as the previous example shows the motherboard manufacturer (manufacturer), model, version, and SerialNumber.
---------------------------------
The motherboard's ROM chip contains the BIOS
dmidecode |grep "Product Name": View server model
Dmidecode |grep "Serial number": View motherboard serial numbers
Dmidecode-s System-serial-number: Viewing the system serial number
DMIDECODE-T Memory: View RAM information
DMIDECODE-T Processor: Viewing CPU information
Dmidecode-t 11: View ome information

--------
Uname-r: View kernel version
Mans uname
cat/etc/issue: View Linux system versions
getconf long_bit: View the number of CPU bits

Just study notes and forget where to copy them--、、、

/proc Directory for Linux Systems

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.