Questions and answers about Linux Command interview
Linux Command lines, as well as the use of Linux commands for Linuxshell interaction, are the most attractive part of Linux and one of the most common topics in the interview. In this article, we will ask 10 important questions during the interview, which will certainly broaden your knowledge.
1. How to pause a running process and put it in the background (not running )?
Answer: To stop a running process and run it in the background, we can use the combination key Ctrl + Z.
2. What is the minimum number of partitions required for Linux installation and how to view the system startup information?
Answer: A single/root partition is sufficient to execute all system tasks. However, we strongly recommend that you install Linux using at least three partitions:/root,/boot, And/swap. An IDE Hard Drive supports up to 63 partitions, and a SCSI hard drive supports more than 15 partitions.
To check the startup information, run cat or dmesg as follows:
# Cat/var/log/messages
Or
# Dmesg
3. What is the daemon name for tracking system events on your Linux machine?
Answer: 'syslogd' is used to track system information and store tracing logs in specific log files.
4. What are the minimum requirements for running the 'fsck' command in the/root partition?
Answer: The/root partition must be mounted in read-only mode, not read-write mode.
5. How do I copy the/home directory to another directory hierarchically?
Answer: The 'cpio' command in Linux is effective. 'Cpio' can be used to copy the hierarchical structure of files and directories to another location.
6. in Linux, how does one automatically replace log files?
Answer: 'logrotate' provides the Automatic Log replacement function.
7. How do I know who is arranging work in Linux?
Answer: You can use the 'at' command with the '-l' option to find out.
8. How can I view the contents of a tar package without interrupting the tar package?
Answer: Use 'tar-tvf '. Option 'T' (display content), 'V' (detailed report of file information processed by tar), and 'F' (use of file or device)
9. What is a page error and how does it happen?
Answer: when a program requests data that does not exist in the memory, a page error occurs, resulting in the program stopping.
10. What is the code returned in the program?
Answer: The Returned Code is a shell feature. The Returned Code shows the State of the program. After a successful program is executed, '0' is returned. & can be used to determine the application to be executed first.