The yes command prints it’s argument repeatedly until killed. If no argument is given, it will print y until killed.
It seeemed useless right? Well, not exactly. If we have a script or a command that expects an answer Yes/No to continue, we can use the yes command to provide the answer.
yes No | script or command
If you read the man pages, you will always find some fun and interesting facts about Linux commands. Today we will look at the chkconfig command. chkconfig is mostly found in Red Hat family and its derivatives. Ever wondered the origin of the chkconfig command?
According to the man page in RHEL 6.x, the chkconfig command is inspired by the chkconfig command in IRIX which is a UNIX variant developed by SGI and no longer in production. Here’s the chkconfig man page from IRIX 6.5 and here are some examples of chkconfig in IRIX.