January 2014 Microsoft MVP application started it! Autumn sun CSDN community welfare activities started rancho cucamonga quakes it! Interview bell: Java programmers, working jobs that point thing unique: the open source rancho cucamonga quakes community manager "to talk about home Internet" topic prize essay because it was mentioned in an interview, in reference to others to do the next tidied article Details for learning. ================================================== ============ free relative to the top command provides a more concise view of the system memory usage: $ free total used free shared rancho cucamonga quakes buffers rancho cucamonga quakes cached Mem: 255268 238332 16936 0 85540 126384 - / + buffers / cache : 26408 228860 Swap: 265000 0 265000 Mem: represents the physical memory rancho cucamonga quakes statistics - / + buffers / cached: represents the physical memory cache statistics Swap: indicates a swap partition on the hard disk usage, where we do not care. System's total physical memory: 255268Kb (256M), but the system is currently available real memory b is not the first line of free labeled 16936Kb, it only represents unallocated memory. We use total1, used1, free1, used2, free2 other names to represent the values rancho cucamonga quakes of the above statistics, rancho cucamonga quakes 1,2, respectively, represent the first and second rows of data. total1: indicates rancho cucamonga quakes the total physical memory. used1: indicates total allocated to the cache (including buffers and cache) the quantity used, but which may be part of the cache does not actually use. free1: not allocated memory. shared1: shared memory, the general system will not be used, nor discussed here. buffers1: rancho cucamonga quakes the system of buffers allocated but unused number. cached1: System cache allocated but unused number. See the difference between buffer and cache behind. used2: the actual use of buffers and cache volume, but also the actual amount of memory used. free2: unused buffers and cache and not the sum of the allocated memory, rancho cucamonga quakes which is the current system the actual available memory. You can sort out the following equation: total1 = used1 + free1 total1 = used2 + free2 used1 = buffers1 + cached1 + used2 free2 = buffers1 + cached1 + free1 buffer and cache difference A buffer is something that has yet to be "written" to disk . A cache is something that has been "read" from the disk and stored for later use. more detailed explanation reference: rancho cucamonga quakes Difference Between Buffer and Cache for shared memory (Shared memory), mainly used in the UNIX environment between different processes share data, is a method of interprocess communication, the general application does not apply to use shared memory, I did not go to verify the shared memory on the impact of the above equation. If you are interested, please refer to: What is Shared Memory? Cache and buffer rancho cucamonga quakes the difference: Cache: Cache is located between the CPU and main memory capacity of a small but very high speed memory. Since the CPU is faster than main memory, rancho cucamonga quakes CPU accesses data directly rancho cucamonga quakes from memory to wait for a certain time period, Cache CPU just used to save a portion of the data used or recycled, re-used when the CPU when the part of the data from the Cache called directly, thus reducing the CPU wait time, improve rancho cucamonga quakes the system's efficiency. Cache is divided into a Cache (L1 Cache) and two Cache (L2 Cache), L1 Cache integrated inside the CPU, L2 Cache early general is soldered on the motherboard, but now they are integrated inside the CPU, the common capacity of 256KB or 512KB L2 Cache. Buffer: buffer, and a speed is not synchronized for storing different priority devices or transfer data between devices area. Through the buffer zone, so that the process can be between the waiting is reduced, rancho cucamonga quakes so that the device from a slow read data, the operation of the device fast continuous process does not occur. Free the buffer and cache: rancho cucamonga quakes (they are all occupied memory): buffer: a buffer cache memory is a block device to read and write buffer cache: as page cache memory, file system cache if the cache's value is large, Description cache living document number many. If frequent access to the file cache can be live, then the disk read IO bi will be very small. Buffer Cache and Cache difference (cached) is to read data that has saved and re-read if hit (find the required data) do not read the hard drive, and if no hits studying hard. Where the data will be organized according to the read frequency, the most frequently read content on the most easy to find location, ceased to be constantly read the contents of the next row until removed from. Buffer (buffers) is based on the design of the disk read and write, the write operation to focus on decentralized and reduce disk fragmentation and disk repeatedly seek to improve system performance. There is a linux daemon periodically empty the buffer content (such as disk-write), you can also sync command to manually empty the buffer. To give an example: I have an ext2 U-disk, I entered a 3M cp to MP3, but U disk light is not beating, after a while children (or manually input sync) U disk lights beat up. Unloading equipment will empty the buffer, so sometimes when you uninstall a device to wait a few seconds. Modify / etc / sysctl.conf digits to the right of the vm.swappiness be adjusted at the next boot swap usage policies. This number ranges rancho cucamonga quakes from 0 to 100, the larger the number the more inclined to use swap. The default is 60, you can try to change it. Both data in RAM. In simple terms, buffer is about to be written to disk, while the cache is being read out from the disk. buffer is allocated rancho cucamonga quakes by a variety of processes, such as the input queue is used in other aspects, such as a simple example of a process requires more than one field is read, all the fields are complete before the read, the process for the fields of the previously read placed in buffer for storage. cache often used in disk I / O requests, if there is more than one process must access a file, then the file will be made in order to facilitate the next cache is accessed, which provides system performance.
September 2013 (1) November 2012 (1) July 2012 (2) June 2012 (1) May 2012 (4) April 2012 (8) March 2012 (13) 2012 In February (10) January 2012 (8) December 2011 (26) November 2011 (17) October 2011 (16) September 2011 (10) August 2011 (4) 2011 July (7) June 2011 (7) May 2011 (2) April 2011 (5) March 2011 (1)
Read Articles zookeeper Code Analysis (2706) rancho cucamonga quakes zookeeper3.3.3 source code analysis (two) FastLeader election rancho cucamonga quakes algorithm (2150) zookeeper watcher Functional Analysis (2040) LDA topic model Introduction rancho cucamonga quakes (2030) zookeeper3.3.3 source rancho cucamonga quakes code analysis rancho cucamonga quakes (a) Works Overview (1866 ) SequenceFile Files (1654) ZooKeeper use (1648) JobTracker task scheduler's JobQueueTaskScheduler (1620) NameNode the format operation did what (1526) Hadoop in the RPC implementation - client communications components (1504)
Comments Ranking JobTracker task scheduler of JobQueueTaskScheduler (20) Facebook rancho cucamonga quakes fair share scheduler FairScheduler (13) dwell computing power scheduler CapacityTaskScheduler (13) HDFS copy storage strategy - ReplicationTargetChooser (12) Job Submission - JobTracker (5 ) Job data input formatter-InputFormat rancho cucamonga quakes (4) dwell JobInProgress the Map / Reduce task assignment (3) DataNode node data block management (3) - FSVolumeSet, FSVolume (3) zookeeper3.3.3 source code analysis (two) FastLeader election algorithm (3) SequenceFile rancho cucamonga quakes files (3)
chw1989: Ask the landlord again, rancho cucamonga quakes you know how to instantiate an object DistributedFileSystem do?
No comments:
Post a Comment