⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 1179-1180.html

📁 linux-unix130.linux.and.unix.ebooks130 linux and unix ebookslinuxLearning Linux - Collection of 12 E
💻 HTML
字号:
<HTML>

<HEAD>

<TITLE>Linux Complete Command Reference:File Formats:EarthWeb Inc.-</TITLE>

</HEAD>

<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
<SCRIPT>
<!--
function displayWindow(url, width, height) {
        var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>

 -->




<!-- ISBN=0672311046 //-->

<!-- TITLE=Linux Complete Command Reference//-->

<!-- AUTHOR=Red Hat//-->

<!-- PUBLISHER=Macmillan Computer Publishing//-->

<!-- IMPRINT=Sams//-->

<!-- CHAPTER=05 //-->

<!-- PAGES=1103-1208 //-->

<!-- UNASSIGNED1 //-->

<!-- UNASSIGNED2 //-->



<P><CENTER>

<a href="1178-1178.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="1181-1182.html">Next</A></CENTER></P>







<A NAME="PAGENUM-1179"><P>Page 1179</P></A>



<TABLE>



<TR><TD>

pci

</TD><TD>

This is a listing of all PCI devices found during kernel initialization and their configuration.

</TD></TR><TR><TD>

scsi

</TD><TD>

A directory with the SCSI mid-level pseudo-file and various SCSI low-level driver

directories, which contain a file for each SCSI host in this system, all of which give the status of some

part of the SCSI IO subsystem. These files contain ASCII structures and are therefore readable

with cat.

</TD></TR><TR><TD>

</TD><TD>

You can also write to some of the files to reconfigure the subsystem or switch certain features

on or off.

</TD></TR><TR><TD>

scsi/scsi

</TD><TD>

This is a listing of all SCSI devices known to the kernel. The listing is similar to the one

seen during bootup. scsi currently supports only the single device command, which allows root

to add a hot-plugged device to the list of known devices.

</TD></TR><TR><TD>

</TD><TD>

An echo `scsisingledevice1 0 5 0'&gt;

/proc/scsi/scsi will cause host scsi1 to scan on

SCSI channel 0 for a device on ID 5 LUN 0. If there is already a device known on this address or

the address is invalid, an error will be returned.

</TD></TR><TR><TD>

drivername

</TD><TD>

drivername can currently be

NCR53c7xx, aha152x, aha1542, aha1740, aic7xxx,

buslogic, eata_dma, eata_pio, fdomain, in2000,

pas16, qlogic, scsi_debug, seagate, t128, u15-24f,

ultrastor, or wd7000. These directories show up for all drivers that registered at least one SCSI HBA.

Every directory contains one file per registered host. Every host-file is named after the number

the host got assigned during initialization.

</TD></TR><TR><TD>

</TD><TD>

Reading these files will usually show driver and host configuration, statistics, and so on.

</TD></TR><TR><TD>

</TD><TD>

Writing to these files allows different things on different hosts. For example, with the

latency and nolatency commands, root can switch on and off command latency measurement code

in the eata_dma driver. With the lockup and unlock commands, root can control bus

lockups simulated by the scsi_debug driver.

</TD></TR><TR><TD>

self

</TD><TD>

This directory refers to the process accessing the

/proc filesystem and is identical to the /proc directory named by the process ID of the same process.

</TD></TR><TR><TD>

stat

</TD><TD>

kernel/system statistics.

</TD></TR><TR><TD>

cpu 3357 0 4313 1362393

</TD><TD>

The number of jiffies (1/100ths of a second) that the system spent in user mode, user

mode with low priority (nice), system mode, and the idle task. The last value should be 100 times

the second entry in the uptime pseudo-file.

</TD></TR><TR><TD>

disk 0 0 0 0

</TD><TD>

The four disk entries are not implemented at this time. I'm not even sure what this should

be because kernel statistics on other machines usually track both transfer rate and I/Os per

second and this only allows for one field per drive.

</TD></TR><TR><TD>

page 5741 1808

</TD><TD>

The number of pages the system paged in and the number that were paged out (from disk).

</TD></TR><TR><TD>

swap 1 0

</TD><TD>

The number of swap pages that have been brought in and out.

</TD></TR><TR><TD>

intr 1462898

</TD><TD>

The number of interrupts received from the system boot.

</TD></TR><TR><TD>

ctxt 115315

</TD><TD>

The number of context switches that the system underwent.

</TD></TR><TR><TD>

btime 769041601

</TD><TD>

Boot time in seconds since the epoch (January 1, 1970).

</TD></TR><TR><TD>

sys

</TD><TD>

This directory (present since 1.3.57) contains a number of files and subdirectories

corresponding to kernel variables. These variables can be read and sometimes modified using the

proc filesystem and using the sysctl(2) system call. Presently, there are subdirectories

kernel, net, and vm that each contain more files and subdirectories.

</TD></TR><TR><TD>

kernel

</TD><TD>

This contains the files domainname,

file-max, file-nr, hostname, inode-max, inode-nr,

osrelease, ostype, panic, real-root-dev,

securelevel, and version, with function fairly clear from

the name.

</TD></TR><TR><TD>

</TD><TD>

The (read-only) file file-nr gives the number of files presently opened. The file

file-max gives the maximum number of open files the kernel is willing to handle. If 1024 is not enough

for you, try echo 4096 &gt;

/proc/sys/kernel/file-max.

</TD></TR><TR><TD>

</TD><TD>

Similarly, the files inode-nr and

inode-max indicate the present and the maximum number

of inodes.

</TD></TR></TABLE>





<A NAME="PAGENUM-1180"><P>Page 1180</P></A>





<TABLE>



<TR><TD>

</TD><TD>

The files ostype, osrelease, and version give substrings of

/proc/version.

</TD></TR><TR><TD>

</TD><TD>

The file panic gives r/w access to the kernel variable

panic_timeout. If this is zero, the kernel will loop on a panic; if nonzero, it indicates that the kernel should autoreboot after this number

of minutes.

</TD></TR><TR><TD>

</TD><TD>

The file securelevel seems rather meaningless at present; root is just too powerful.

</TD></TR><TR><TD>

uptime

</TD><TD>

This file contains two numbers: the uptime of the system (seconds) and the amount of

time spent in idle process (seconds).

</TD></TR><TR><TD>

version

</TD><TD>

This string identifies the kernel version that is currently running. For instance:

</TD></TR><TR><TD>

</TD><TD>

<!-- CODE SNIP //-->

<PRE>

Linux version 1.0.9 (quinlan@phaze) #1 Sat May 14 01:51:54 EDT 1994

</PRE>

<!-- END CODE SNIP //-->

</TD></TR></TABLE>



<P><B>

SEE ALSO

</B></P>



<!-- CODE //-->

<PRE>

cat(1), find(1), free(1), mount(1), ps(1), tr(1), uptime(1), readlink(2), mmap(2), chroot(2), syslog(2), hier(7), arp(8),

dmesg(8), netstat(8), route(8), ifconfig(8), procinfo(8) and much more

</PRE>

<!-- END CODE //-->





<P><B>

CONFORMS TO

</B></P>



<P>This roughly conforms to a Linux 1.3.11 kernel. Please update this as necessary! Last updated for Linux 1.3.11.

</P>



<P><B>

CAVEATS

</B></P>



<P>Note that many strings (the environment and command line) are in the internal format, with subfields terminated by

null bytes, so you might find that things are more readable if you use

od -c or tr &quot;\000&quot; &quot;\n&quot; to read them.

</P>



<P>This manual page is incomplete, possibly inaccurate, and is the kind of thing that needs to be updated very often.

</P>



<P><B>

BUGS

</B></P>



<P>The /proc filesystem may introduce security holes into processes running with

chroot(2). For example, if /proc is mounted in the

chroot hierarchy, a chdir(2) to /proc/1/root will return to the original root of the filesystem. This may be considered

a feature instead of a bug because Linux does not yet support the

fchroot(2) call.

</P>



<P>22 July 1996

</P>



<H3><A NAME="ch05_ 49">

protocols

</A></H3>



<P>protocols&#151;The protocols definition file.

</P>



<P><B>

DESCRIPTION

</B></P>



<P>This file is a plain ASCII file, describing the various DARPA Internet protocols that are available from the

TCP/IP subsystem. It should be consulted instead of using the numbers in the ARPA include files or, even worse, just guessing

them. These numbers will occur in the protocol field of any IP header.

</P>



<P>Keep this file untouched because changes would result in incorrect IP packages. Protocol numbers and names are specified

by the DDN Network Information Center.

</P>



<P>Each line is of the following format:

</P>



<!-- CODE SNIP //-->

<PRE>

protocol number aliases ...

</PRE>

<!-- END CODE SNIP //-->



<P>The fields are delimited by spaces or tabs. Empty lines and lines starting with a hash mark

(#) are ignored. Remainder of lines are also ignored from the occurrence of a hash mark.

</P>



<P>The field descriptions are

</P>



<TABLE>



<TR><TD>

protocol

</TD><TD>

The native name for the protocol&#151;for example,

ip, tcp, or udp.

</TD></TR><TR><TD>

number

</TD><TD>

The official number for this protocol as it will appear within the IP header.

</TD></TR><TR><TD>

aliases

</TD><TD>

Optional aliases for the protocol.

</TD></TR></TABLE>









<P><CENTER>

<a href="1178-1178.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="1181-1182.html">Next</A></CENTER></P>







</td>
</tr>
</table>

<!-- begin footer information -->







</body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -