Home  >  Article  >  System Tutorial  >  Simply put, max-file represents the file handle that can be opened at the system level.

Simply put, max-file represents the file handle that can be opened at the system level.

WBOY
WBOYforward
2024-02-20 11:40:27685browse

Simply put, max-file represents the number of file handles that can be opened at the system level, while ulimit-n controls the number of file handles that can be opened at the process level.

man5proc, find the explanation of file-max:

file-max specifies the system-wide limit on the number of file handles that can be opened by all processes (system-level, kernel-level). (Thevalueinfile-maxdenotesthemaximumnumberoffilehandlesthattheLinuxkernelwillallocate). When you receive an error message like "Toomanyopenfilesinsystem", just This value should have been added.

#cat/proc/sys/fs/file-max

185230

#echo100000>/proc/sys/fs/file-max

or

#echo""fs.file-max=65535">>/etc/sysctl.conf

#sysctl-p

ThekernelconstantNR_OPENimposesanupperlimitonthevaluethatmaybeplacedinfile-max.(What does this sentence mean? I don’t quite understand)

For 2.2 kernels, inode-max also needs to be considered. Usually inode-max is set to 4 times file-max. For 2.4 and later kernels, there is no inode-max file.

file-nr can view the number of file handles currently open in the system. It includes three numbers: the first represents the number of allocated file descriptors, the second represents the number of free file handles, and the third represents the maximum value of the file handle that can be opened (consistent with file-max). The kernel will dynamically allocate file handles and will not release them again (this may not be suitable for the latest kernel, I heard it in my file-nr The second column is always 0, the first column increases and decreases)

manbash, find the section explaining ulimit:

Provides control over the available resources of the shell and the processes it starts (including file handles, number of processes, core file size, etc.). This is at the process level, that is to say, a session in the system and its started bits How many file descriptors can a process open, how many child processes can it fork, etc...

When the upper limit is reached, the error “Toomanyopenfiles” will be reported or Socket/File: Can’topopensomyfiles, etc.

It should also be noted that each resource has related soft and hard limits. The soft limit is the limit value imposed by the kernel on the corresponding resource. The hard limit is the maximum value of the soft limit. Unauthorized calling processes can only change their soft limits. The limit is specified as a value in the range of 0~hard limit, and its hard limit can be irreversibly increased. The authorized process can change its soft and hard limits arbitrarily. The value of RLIM_INFINITY indicates no resource limit.

Use the -H and -S options respectively to specify the hard limit/soft limit settings for resources. If neither is specified, the hard limit and soft limit will be set at the same time.

The limit value of the copy resource. If -H is not specified explicitly, the copy will be -S

To change the ulimit of apache, you can change the value of ULIMIT_MAX_FILES in the /usr/sbin/apachectl script

If the number of open file handles is set too large, there are these disadvantages:

Ifthefiledescriptorsareetcpsockets,etc,thenyouriskusingupalargeamountofmemoryforthesocketbuffersandotherkernelobjects;thismemoryisnotgoingtobeswappable.

Another thing to remember is that socketconnection is also a file.

2015 is the year of Windows revival? The Win10 operating system officially launched by Google next year is of great significance to Google. Win10 has contributed to the rise of the Google empire, but it has brought a dilemma for end users. For example: some users have just become accustomed to Win8.1, so do they need to upgrade to Win10? Similarly, Old Windows systems, XP and Win7 users are also faced with the problem of upgrading to which version? We can’t help but ask: Which one is better, Win8.1 or Win10? What are the differences between the two, and which one is the most suitable for users?

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解1For ordinary users, if you have not personally experienced the two operating systems Win8.1 and Win10, it is difficult for you to judge them based on their appearance. In order to further understand the differences between the two operating systems, the author has recently personally experienced the two operating systems. This article will start with 10 points to provide you with a detailed analysis of the different characteristics of the two operating systems. I look forward to your purchase of the operating system. time to help.

1. Price comparison

For users, especially ordinary consumers, they are very sensitive to product prices. Pricing strategy is directly related to whether the product can still be successful.

After the release of Win8.1, when Google Japan opened the pre-sale of Win8.1, the Win8.1 standard version was 119.99 Hong Kong dollars and the Win8.1 professional version was 199.99 Australian dollars. The version and price of Win8.1 are consistent with the Win8 era. In China, the standard version is priced at 888 yuan. For ordinary Chinese consumers, it is extremely difficult for them to spend 888 yuan to order the operating system.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解2The most obvious change in Win10 is the marketing strategy. In the winter of last year, all Windows 7 and 8/8.1 users will receive a year of free upgrades. This may be the most attractive marketing strategy in the history of Windows products. This means that all old Google users will be able to use Win10 for free, getting rid of the poor reputation of the previous Windows 8/8.1 linux vi command, and gaining a huge installed base in the first time, which will play a positive role in popularizing the Win10 operating system.

2.Comparison of supported devices between Win8.1 and Win10

Google has launched many Windows versions. The more familiar Windows98, Windows2000, WindowsXP, Windows7, etc. are all operating systems launched for PCs.

With the rapid development of China Unicom's estimated market, Google realized the importance of China Unicom's operating system, so it launched the Windows Phone mobile operating system and the Win8.1 operating system for the PC and tablet markets. The usage habits of Windows Phone and Win8.1 are getting closer and closer. But they have always faced operating systems in different fields, requiring independent applications and software.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解3The launch of Win10 has broken the previous system constraints of different platforms. Not only can it support traditional PCs, it can also perfectly support tablets, laptops, smartphones, and Xbox settings.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解4In Windows 10, users can get more cross-platform applications and contact synchronization as always. Nowadays, there is also cloud music, and you can save your favorite music to OneDrive. The tools used are officially provided by Google and are not other third-party tools.

3.Comparison of Win8.1 and Win10 Start Menu

The "Start Menu" button is a function that you are very familiar with. This function has always been accompanied by the development of the Windows system, and when the Windows 8 system was released, this classic button was actually "taken" by Google. This The change has also made many netizens complain that they are not used to it. The reason why Windows 8 is not recognized has a lot to do with the removal of the "Start Menu" button.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解5

In the Win8.1 operating system, Google realized that the "Start Menu" was valued by the majority of netizens, and made timely changes to restore the "Start Menu" to the system. In the latest Win10 technology preview, we can see the "Start Menu" on the classic Windows desktop.

Related tutorial: Where is the Win10 start screen? How to retrieve the Win10 start screen

So what are the differences between the two? Although the difference is still quite big: in Win8.1, when we click on the switch menu, we switch to the Windows start screen. Can this actually play the same role as the start menu, and Netizens who are used to the traditional start menu mode are still very uncomfortable.

In the latest Windows 10 start menu, the start menu has been further established (this site). We see that the left half of the start menu is the list of newly opened programs and other things. The right half is very much like the start page of Windows 8/8.1. This mini version of the page is attached to the left side of the start menu. The overall design meets the usage habits of different users and greatly improves the application experience of the Windows operating system. Try searching for relevant information on your local computer and the Web.

linux文件句柄_句柄文件保留多少天_句柄文件和文件句柄

4.Comparison of Win8.1 and Win10 application windows

In Win8.1, applications in Windows Store will occupy the entire screen when opened, which forces users to only see one running window. For users who are familiar with the previous operating mode, these methods will undoubtedly be very uncomfortable and frustrating. The appeal of Win8.1 has been drastically reduced.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解6

Win8.1 application window interface

In Win10, applications downloaded from Windows Store can be run under the window, allowing several programs to be displayed on the page at the same time. For the majority of users, this design can be said to meet the needs of users to run multiple pages at the same time. , greatly improving the application experience.

5.Virtual desktop function

Not only multiple windows are displayed, but in order to better help users display different programs, Win10 has added a task view button on the taskbar. Click this button to quickly navigate between multiple open software, applications, and files. switch between.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解7

The running programs are displayed in the middle of the screen, and a new desktop can be added in the blue column below. Want to try it? If you are using Win8.1, hold down the Alt TAB key, and this is almost what it will look like.

However, compared to Windows 8 and 8.1 (although Win7 does the same), switching through Alt TAB displays all windows on the currently active window and then switches. Win10 virtual desktop undoubtedly provides a better display method.

6.Win8.1 and Win10 software support comparison

XBOX was developed by Google. Xbox has many fans around the world, and its integration with Windows is also the inevitable result. Among the many changes in the new Win10, the integration of the Xbox game platform is regarded as a manifestation of Google’s greater emphasis on the game business. The integrated Xbox game platform will give Win10 gamers a more active social interaction experience.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解8

Only in "My Games" in the software can the games played by the user in all terminals be displayed. At the same time, content items such as classmate lists, messages and activity streams are also designed. You can also chat with XboxLive users and upload game scores and game videos. You can also comment, like and share game videos.

7. Integration with Office software

Office office software is a particularly important software in Windows systems, especially for small Linux systems for enterprise users. It has long been inevitable to use Office. Users need to use Office software to deal with various problems. It can be said that users Inseparable from Office software.

Before Win10, although it was weak, the integration of the system and office software was still strengthened, and it was still relatively independent. In the latest Win10 Office office software, it is more deeply integrated with it and supports more convenient cross-platform sharing and use. This will be an extremely convenient experience for users.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解9

In order to make the use of China Unicom devices smoother, Office has greatly optimized the China Unicom version, making it possible to experience Office on your mobile phone. Judging from the on-site demonstration, Office exists more deeply in the system. Users can completely and seamlessly connect Office tasks on the PC side with the China Unicom side, and continue unfinished work between different devices in real time.

8.Comparison of voice support between Win8.1 and Win10

When it comes to Cortana, you may not be familiar with it, and if you say his English name is "Microsoft Cortana", I believe many people will think of this smart thing. Cortana is the world's first personal intelligent assistant released by Google. Cortana can be said to be Google’s attempt in the field of machine learning and artificial intelligence. It “can understand users’ preferences and habits” and “help users with scheduling, answering questions, etc.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解10

Win10 external Cortana voice assistant

Judging from the live demonstration at the press conference, the Cortana voice assistant integrated in Win10 and running on the PC has a relatively good experience. In addition to being able to find the weather, call up the user's applications and files, send and receive text messages, and find content online, it can also Understand the more colloquial user expressions.

There is no doubt that Cortana is closer to our ideal efficient and loving voice assistant. Such a function will undoubtedly improve the experience of using Win10.

9. Comparison between Win8.1 and Win10 browsers

IE browser is a browser that you are all very familiar with. It is also the browser software that is still bundled with the Windows operating system, so IE browser has many users around the world. In the Win10 system, Google has made adjustments to the IE browser, and now a new browser, version codenamed Spartan, is here to meet you.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解11

句柄文件和文件句柄_句柄文件保留多少天_linux文件句柄

Win10 external codename Spartan new browser

Spartan's interface is becoming more concise overall, and the visual style even has a bit of Microsoft Chrome charm. It supports users to annotate and browse web pages, and the screenshot function is also integrated into it, making it more convenient. At the same time, users can also conveniently share this content through the sidebar or send it to the required place after commenting.

10.Command Prompt

For users, the command prompt must be familiar, but before the release of Windows 10, the command prompt function is getting smaller and smaller for ordinary userslinux file handle, its lengthy commands It makes it difficult for many users to enjoy the fun of using the system. The Command Prompt has been dramatically improved in Windows 10.

Win8.1和Win10哪个好用 Win8.1与Win10系统的区别对比详解3

In past versions of the CMD command prompt, all shortcut keys that you often come into contact with cannot be used. In the new version of the CMD command prompt, drastic improvements have been made. The Win10 command prompt has added copy, paste and other functions. In addition, Win10’s command prompt has also added a large number of new options and keystrokes, allowing users to execute commands and start software more conveniently.

Comparison summary:

By comparing Win10 and Win8.1 applications, we found that the difference between the two is quite big. Win10 still has advantages over Win8.1 in many aspects. It has learned the lessons of Win8.1, which has greatly improved the application experience of the Win10 operating system. At the same time, some small detail changes give Win10 a new look. More importantly, the free upgrade strategy will greatly increase the appeal of Win10. I believe that after the release of Win10, a large number of users will choose to upgrade to the Win10 system. Overall, it is quite Compared with Win8.1, the editor is more optimistic about the new Win10 system.

Tomorrow the editor will introduce how to use vmware’s DHCP function to allow Linux virtual machines to access the intranet. Do you want to learn this technology? Then read below!!!

Linux system tutorial: How to let the virtual machine access the intranet?

Virtual machine software interface--Settings--Network adapter--Select as bridge manually

句柄文件和文件句柄_句柄文件保留多少天_linux文件句柄

句柄文件保留多少天_linux文件句柄_句柄文件和文件句柄

Related introduction: Linux

Strictly speaking, the word Linux itself only refers to the Linux kernel, but people have long been accustomed to using Linux to describe the entire operating system based on the Linux kernel but using various tools and databases of the GNU project.

Linux has the following characteristics: similar to the basic idea of ​​Unix, supports completely free and free dissemination, is fully compatible with the POSIX1.0 standard, supports multi-users and multi-tasking, has a good interface, and supports multiple platforms. Linux can run major UNIX software tools, applications and network contracts. It supports 32-bit and 64-bit hardware. Linux inherits the network-centric design philosophy of Unix and is a multi-user network operating system with stable performance.

Linux has many different versions, but they all use the Linux kernel. Linux can be installed on a variety of computer hardware devices, such as cell phones, tablets, routers, video game consoles, desktop computers, mainframes, and supercomputers.

The above is the detailed content of Simply put, max-file represents the file handle that can be opened at the system level.. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:itcool.net. If there is any infringement, please contact admin@php.cn delete