Linux Test 1 — Questions and Answers
Question 1: Which of the following commands is used to determine a system's current IP address?
- Showip
- Ifconfig (Correct answer)
- Less/proc/net/ipconfig
- Ipconfig
Correct answer: Ifconfig
Explanation: <br> The network management program ifconfig (interface configuration) is used to configure network interfaces. In Linux operating systems, it is used to configure and monitor network interfaces. You may use ifconfig to assign IP addresses, enable and disable interfaces, manage ARP cache, and routes, among other things.
Question 2: Which of the following Ubuntu releases is the most stable and suitable for commercial use?
- Xubuntu Server
- LTS (Correct answer)
- Ubuntu Vanilla
- Xubuntu
Correct answer: LTS
Explanation: <br> LTS is an abbreviation for Long Term Support. Long Term Support refers to a release that is supported for a longer period of time than ordinary releases.
Question 3: Which of the following is a digital data transfer interface that combines audio and video?
- HDMI (Correct answer)
- VGA
- ATI
- DVI
Correct answer: HDMI
Explanation: <br> High Definition Multimedia Interface (HDMI) is the acronym for High Definition Multimedia Interface. It's a proprietary audio-video interface that can send compressed or uncompressed digital audio and uncompressed video data. HDMI is a video standard that can be used to replace previous analog video standards.
Question 4: A Linux machine does not have Internet connectivity. Which command displays information about the system's network gateway?
- Gateway
- Route (Correct answer)
- Ifconfig
- Traceroute
Correct answer: Route
Explanation: <br> The route command is part of the net-tools package in Linux, which also contains ifconfig, iwconfig, and other well-known networking tools. The route command, like the rest of the net-tools suite, has been replaced by the ip route command.
Question 5: What command is used to erase or delete a file without receiving a confirmation message?
- Rm (Correct answer)
- Rm-f
- Remove
- Del
Correct answer: Rm
Explanation: <br> When rm is used only with the names of one or more files, it deletes them all without requesting the user's confirmation. Assuming that all three files are located in the current directory (i.e., the directory in which the user is now working), rm would immediately destroy the files called file1, file2, and file3:
Question 6: To clear the command prompt window, what command is used?
- Clearit
- Clear (Correct answer)
- Clr
- Clrwin
Correct answer: Clear
Explanation: <br> CLS Command Clears Command Prompt Screen You can type cls command line in Command Prompt window and push Enter button after opening Command Prompt on Windows 10 and entering numerous command lines on the screen. In Windows 10, this will clear the CMD screen. In the Command Prompt window, all previously input commands will be cleared.
Question 7: How would you display a list of all the files and folders in the current directory?
- Ls (Correct answer)
- Listfiles
- List
- Listout
Correct answer: Ls
Explanation: <br> In Linux and other Unix-based operating systems, the ls program is used to list files and directories. The ls command is one of many Linux commands that may be used to list files or directories via the command line interface.
Question 8: The command is used to create a new directory is ________
- Newdir
- Mkdir (Correct answer)
- Mk/dir
- Create dir
Correct answer: Mkdir
Explanation: <br> To make a directory, use the command mkdir. The command mkdir stands for "make directory." Just after that, type the name of the directory (folder) you want to create.
Question 9: To create an empty file, use the ______ command.
- Create
- Intouch
- Touch (Correct answer)
- Mtfile
Correct answer: Touch
Explanation: <br> The touch command is a typical command in the UNIX/Linux operating system for creating, changing, and modifying file timestamps. In the Linux system, there are two separate commands for creating a file, which are as follows: command for cats: It's used to make a content-filled file.
Which of the following commands is used to determine a system's current IP address?