In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)05/31 Report--
This article shows you how to achieve GNU core utility analysis, the content is concise and easy to understand, can definitely brighten your eyes, through the detailed introduction of this article, I hope you can get something.
What most Linux system administrators need to do can be found in GNU coreutils or util-linux.
Many of the most basic and commonly used tools for Linux system administrators are mainly included in two sets of utilities: the GNU Core Utility (coreutils) and util-linux. Their basic functions allow system administrators to perform many tasks of managing Linux systems, including managing and manipulating text files, directories, data streams, storage media, process control, file systems, and so on.
These tools are indispensable, because without them, it is impossible to do any useful work on a Unix or Linux computer. In view of their importance, let's study them.
GNU coreutils
To understand the origins of the GNU core utility, we need to take a short trip on a time machine back to the early days of Unix at Bell Labs. Unix was written so that Ken Thompson, Dennis Ritchie, Doug McIlroy, and Joe Ossanna could continue their work on the large multitasking and multi-user computer project Multics: developing a little thing called "Space Travel" game. As today, it seems that gamers are always driving the development of computing. This new operating system is more limited than Multics, because only two users can log in at a time, so it is called Unics (LCTT: the meaning of multi- prefix is separate). The name was later changed to Unix.
Over time, Unix became so successful that Bell Labs basically gave it to the university at first, and then to the company for media and shipping fees. In those days, system-level software was shared between organizations and programmers, because at the system management level, they worked hard to achieve a common goal.
In the end, the bosses of AT&T decided that they should make money on Unix and start using more restrictive and expensive licenses. This happens at a time when software becomes more proprietary, restricted, and closed, and since then it has become impossible to share software with other users and organizations.
Some people don't like this situation, so they use free software to fight it. Richard M. Stallman (RMS), he leads a group of "rebels" trying to write an open, freely available operating system, which they call the GNU operating system. This group created the GNU utility, but did not produce a viable kernel.
When Linus Torvalds starts writing and compiling the Linux kernel, he needs a very basic set of system utilities to start doing something slightly useful. The kernel does not provide commands or any type of command shell, such as Bash, which is of no use in itself, so Linus uses the free GNU core utilities and recompiles them for Linux. This gives him a complete, even fairly basic, operating system.
You can learn all about the core GNU utility by typing the command info coreutils on the terminal command line. The following list of core utilities is part of this information page. These utilities are grouped by function to make it easy to find; in the terminal, select the group you want to know more, and then press enter.
* Output of entire files:: cat tac nl od base32 base64* Formatting file contents:: fmt pr fold* Output of parts of files:: head tail split csplit* Summarizing files:: wc sum cksum b2sum md5sum sha1sum sha2* Operating on sorted files:: sort shuf uniq comm ptx tsort* Operating on fields:: cut paste join* Operating on characters:: tr expand unexpand* Directory listing:: ls dir vdir dircolors* Basic operations:: Cp dd install mv rm shred* Special file types:: mkdir rmdir unlink mkfifo mknod ln link readlink* Changing file attributes:: chgrp chmod chown touch* Disk usage:: df du stat sync truncate* Printing text:: echo printf yes* Conditions:: false true test expr* Redirection:: tee* File name manipulation:: dirname basename Pathchk mktemp realpath* Working context:: pwd stty printenv tty* User information:: id logname whoami groups users who* System context:: date arch nproc uname hostname hostid uptime* SELinux context:: chcon runcon* Modified command invocation:: chroot env nice nohup stdbuf timeout* Process control:: kill* Delaying:: sleep* Numeric operations:: factor numfmt seq
There are 102 utilities in this list. It covers many of the functions required to perform basic tasks on a Unix or Linux host. However, many basic utilities are missing, such as the mount and umount commands that are not in this list. These commands and many other commands that are not in the GNU core utility can be found in util-linux.
Util-linux
The util-linix utility package contains many other commands commonly used by system administrators. These utilities are released by the Linux kernel organization, and almost every one of these 107 commands comes from what would have been three separate collections-- fileutils, shellutils, and textutils,2003-- which were merged into a single package: util-linux.
Agetty fsck.minix mkfs.bfs setpriv blkdiscard fsfreeze mkfs.cramfs setsid blkid fstab mkfs.minix setterm blockdev fstrim mkswap sfdisk cal getopt more su cfdisk hexdump mount sulogin chcpu hwclock mountpoint swaplabel chfn Ionice namei swapoff chrt ipcmk newgrp swapon chsh ipcrm nologin switch_root colcrt ipcs nsenter tailf col isosize partx taskset colrm kill pg tunelp column last pivot_root Ul ctrlaltdel ldattach prlimit umount ddpart line raw unshare delpart logger readprofile utmpdump dmesg login rename uuidd eject look renice uuidgen fallocate losetup reset vipw fdformat lsblk resizepart wall fdisk Lscpu rev wdctl findfs lslocks RTC Alarm whereis findmnt lslogins runuser wipefs flock mcookie script write fsck mesg scriptreplay zramctl fsck.cramfs mkfs setarch
Some of these utilities have been eliminated and are likely to be kicked out of the collection at some point in the future. You should check Wikipedia's util-linux page for information about many of these utilities, and the man page provides more information about these commands.
Together, this collection of two Linux utilities, the GNU core utility and util-linux, provides the basic utilities needed to manage the Linux system. In the course of studying this article, I found several interesting utilities that I never knew. Many of these commands are rarely needed, but they are indispensable when you need them.
There are more than 200 Linux utilities in these two collections. Although there are many more commands for Linux, these are required to manage the basic functions of a typical Linux host.
The above content is how to implement the GNU core utility analysis, have you learned the knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.