Education  >  EXAM  >  Linux Essentials - Practice Exam Questions and Answers (All)

Linux Essentials - Practice Exam Questions and Answers

Document Content and Description Below

If you wanted to disable a second network interface in Linux, what command would you enter at the shell? ifdown eth0 ifdown eth1 ifconfig disable eth1 ifdown - ANSWER ifdown eth1 You ha ... ve been editing a configuration file using vi. You realize that you've made many mistakes and need to quit without saving the changes so that you can start over. Which command will allow you to do this? :q :q! :exit :s - ANSWER :q! ("colon Q Bang!") What directory would the ~ character represent? Another user's home directory. The home directory of our currently logged in user. Take us to the home directory of the root user. The /var directory. - ANSWER The home directory of our currently logged in user. What is the default shell for most Linux distributions? csh bash sh zsh - ANSWER bash You need to troubleshoot a hardware issue. Which command would let you view the kernel ring buffer to see what hardware was just added? cat /var/log/boot.log tail lastlog dmsg | less head /var/log/messages - ANSWER dmsg | less (driver messages) "dmsg pipe less" Which of the following sections give a brief review of the syntax used for a particular command or utility within a man page? REVIEW SYNOPSIS SYNTAX DESCRIPTION - ANSWER SYNOPSIS In which directory could you add files so that a newly created user will automatically have them when they first log in? /etc/skel /etc/profile.d /etc/default /etc/.skel - ANSWER /etc/skel (correct?) Which of the following provides binary files containing prewritten code elements or interfaces that programmers can call when writing Linux programs? Libraries Bash shell profiles Kernel modules The kernel - ANSWER Libraries You are running the ping command to see if a particular host is up. How would you specify to the ping command that only five packets get sent to the remote host? ping --count 5 host.example.com ping -c 5 host.example.com ping 5 host.example.com ping -n 5 host.example.com - ANSWER ping -c 5 host.example.com (-c = count, number of times can vary) You need to verify that a remote host with a hostname of dns2.linuxacademy.com is up and running. Which of the following commands would you enter at the shell prompt to do this? finger dns2.linuxacademy.com netstat -a dns2.linuxacademy.com netstat -s dns2.linuxacademy.com ping dns2.linuxacademy.com - ANSWER ping dns2.linuxacademy.com While using vi to edit a file in command mode, you try to use the BACKSPACE key to delete a word, but nothing happens. What's wrong? You need to use CTRL-BACKSPACE You need to reboot your computer. You need to switch to normal mode. You have to switch to insert mode. - ANSWER You have to switch to insert mode. Which command would uncompress the contents of the file 'important.bz2'? gunzip (for .gz only) tar (this is not a zip-type file) bunnyzip2 (does not exist) bunzip2 *** bz2 is the key to this answer... use bunzip for bz files!!! - ANSWER bunzip2 gunzip (wrong!!!) it's for gzipped files (.gz) only, and tar does not provide compression on it's own. Bunnyzip2 is not a valid command (it's a typo!) How would you add a new user account to a system? useradd newguy new user newguy user add newguy groupadd newguy - ANSWER useradd newguy Which software development model is considered to be less structured than the others? Cathedral Bazaar Scrum Hierarchy - ANSWER Bazaar Which command in a script would display the text "hello world" to the screen, followed by a new line? print "hello world" printf "hello world" echo "hello world" display "hello world" - ANSWER echo "hello world" Which file(s) are used for DNS resolution? (Choose 2) /etc/dns /etc/hosts /etc/resolv.conf /etc/resolve - ANSWER /etc/hosts /etc/resolv.conf An application has the following permissions set on it: rw-r--r-- Yet it does not run. Why is that? 'Other" has read access to it There is no execute permission set The application is in the wrong directory The application is not in the $PATH - ANSWER There is no execute permission set What protocol is used by network programs/applications that need very low latency and, therefore, can tolerate a degree of unreliability? SMTP Internet Message Protocol User Datagram Protocol Transmission Control Protocol - ANSWER User Datagram Protocol - UDP is a 'connection-less' protocol and does not require an acknowledgement (no check for reliability) from the receiving end of the communication. Transmission Control Protocol (TCP) ?? NO!!!!! How would you set permissions on a newly created script so that it could be executed. chown u+x script.sh chmod u-x script.sh chmod u+x script.sh chown u-x script.sh - ANSWER chmod u+x script.sh +x means add execute -x means remove execute What is the proper syntax for creating a parent directory, followed by a child subdirectory? mkdir -r dir1/dir2 mkdir -c dir1/dir2 mkdir -p dir1/dir2 mkdir dir1/dir2 - ANSWER mkdir -p dir1/dir2 (make directory switch p [for parent] then parent name slash child name) You need to create a symbolic link from a file located at /usr/share/doc/manual to a link in your home directory named 'manual'. Which command would we use to achieve this? ln -s~/manual/usr/share/doc/manual ln -s/usr/share/doc/manual ~/manual ln ~/manual/usr/share/doc/manual ln /usr/share/doc/manual ~/manual - ANSWER ln -s/usr/share/doc/manual ~/manual (link -s [for symbolic] /usr/share/doc path, to home directory known as tilde /manual) While working in the command line console, not running X Windows, you suddenly need access to another shell to do another task. You don't want to quit or halt the current application. What might you do to run both your other functions in a shell while still running your current application? You can press ALT-F2 or CTRL-ALT-F2 to open an alternate console screen and access a new shell session. You can press CTRL-SHIFT-F6 to automatically open a new shell session without pausing your current running program. You can't do this. You will have to first quit the current program and then run your next task. You can press CTRL-PAUSE on your keyboard to pause the running program while we access the shell prompt. - ANSWER You can press ALT-F2 or CTRL-ALT-F2 to open an alternate console screen and access a new shell session. You need to search for man pages that relate to the Postfix service. Which command will do this? (Choose 2 correct answers) which postfix man -k postfix apropos postfix search postfix - ANSWER apropos postfix man -k postfix (you must be root to use this) Which directory contains filesystem management utilities such as cp or mv? /bin and /usr/bin [Show More]

Last updated: 3 years ago

Preview 1 out of 27 pages

Buy Now

Instant download

We Accept:

Payment methods accepted on Scholarfriends (We Accept)
Preview image of Linux Essentials - Practice Exam Questions and Answers document

Buy this document to get the full access instantly

Instant Download Access after purchase

Buy Now

Instant download

We Accept:

Payment methods accepted on Scholarfriends (We Accept)

Reviews( 0 )

$10.00

Buy Now

We Accept:

Payment methods accepted on Scholarfriends (We Accept)

Instant download

Can't find what you want? Try our AI powered Search

80
0

Document information


Connected school, study & course


About the document


Uploaded On

Sep 09, 2022

Number of pages

27

Written in

All

Seller


Profile illustration for MARKALLAN
MARKALLAN

Member since 3 years

58 Documents Sold

Reviews Received
5
2
0
0
1
Additional information

This document has been written for:

Uploaded

Sep 09, 2022

Downloads

 0

Views

 80

Document Keyword Tags

Recommended For You

Get more on EXAM »

$10.00
What is Scholarfriends

Scholarfriends.com Online Platform by Browsegrades Inc. 651N South Broad St, Middletown DE. United States.

We are here to help

We're available through e-mail, Twitter, Facebook, and live chat.
 FAQ
 Questions? Leave a message!

Follow us on
 Twitter

Copyright © Scholarfriends · High quality services·