CompTIA LX0-102 Linux Part 2 Certification Practice Exam Set 3

Which of the following commands is used to deactivate a network interface?


Options are :

  • net
  • netdown
  • ifdown
  • .ipdown

Answer : ifdown

Which of the following statements about crontab are true? (Select TWO).


Options are :

  • hourly is the same as "0 * * * *".
  • Changing a crontab requires a reload/restart of the cron daemon.
  • . Every user may have their owncrontab.
  • The cron daemon reloads crontab files automatically when necessary.

Answer : . Every user may have their owncrontab. The cron daemon reloads crontab files automatically when necessary.

Suppose that the command netstat -a hangs for a long time without producing output. An administrator might suspect:


Options are :

  • A problem with NIS
  • A problem with DNS
  • A problem with NFS
  • A problem with routing

Answer : A problem with DNS

Which of the following should the permission settings be for /etc/passwd and /etc/shadow?


Options are :

  • /etc/passwD. -rw-r--r-- /etc/shadow: -r--------
  • /etc/passwD. -r-------- /etc/shadow: -r--------}
  • /etc/passwD. -r-------- /etc/shadow: -rw-r--r--
  • /etc/passwD. -rw-r--r-- /etc/shadow: -rw-r--r--

Answer : /etc/passwD. -rw-r--r-- /etc/shadow: -r--------

CompTIA Network+ (N10-007) 6 Practice Exams and Simulations Set 2

Which of the following is the main difference between the batch and at commands?


Options are :

  • The batch command will run when system load is low. The at command runs at a specific time.
  • The batch command will run multiple times.The at command will only run once.
  • The at command reads commands from standard input. The batch command requires a command line argument.
  • The at command emails results to the user. The batch command logs results to syslog.

Answer : The batch command will run when system load is low. The at command runs at a specific time.

Which of the following commands will print the exit value of the previous command to the screen in bash?


Options are :

  • echo $exit
  • echo $?
  • echo $#
  • echo $status

Answer : echo $?

How is the file format of /etc/crontab different from a normal crontab file? (Select TWO).


Options are :

  • A normal crontab file allows for environment variable substitution.
  • The /etc/crontab file can specify a year field.
  • The /etc/crontab file has a user field for commands
  • A normal crontab file must be installed with the crontab command.

Answer : The /etc/crontab file has a user field for commands A normal crontab file must be installed with the crontab command.

Which of the following looks like a correct entry in the /etc/hosts file?


Options are :

  • localhost 127.0.0.1 localhost.localdomain
  • 127.0.0.1 localhost.localdomainlocalhost
  • localhostlocalhost.localdomain 127.0.0.1
  • localhost.localdomainlocalhost 127.0.0.1

Answer : 127.0.0.1 localhost.localdomainlocalhost

The correct crontab entry to execute the script chklog three times per month between 3 p.m. and 5 p.m.:


Options are :

  • * 3, 4, 5 1 * * chklog
  • 0 15, 16, 17 1 * * chklog
  • 3 15, 16, 17 * * * chklog
  • 3 3, 4, 5 1 * * chklog

Answer : 0 15, 16, 17 1 * * chklog

Which of the following find commands will print out a list of suid root files in /usr?


Options are :

  • find /usr -ls \*s\* -u root
  • find /usr -uid 0 -perm +4000
  • find -type suid -username root -d /usr
  • find -user root +mode +s /usr

Answer : find /usr -uid 0 -perm +4000

CompTIA Cyber Security Analyst (CySA+) Practice Exams 2019 Set 9

In the following command and its output, echo $$ 12942 which of the following is 12942?


Options are :

  • The process ID of the echo command.
  • The process ID of the last backgrounded command.
  • The process ID of the current shell.
  • The process ID of the last command executed.

Answer : The process ID of the current shell.

Which of the following programs uses the hosts.allow file to perform its main task of checking for access control restrictions to system services?


Options are :

  • inetd
  • fingerd
  • tcpd
  • mountd

Answer : tcpd

Which of the following commands will provide locale-specific information about a system and its environment?


Options are :

  • getlocale
  • loconfig
  • .tzconfig
  • .locale

Answer : .locale

Which of the following statements is true regarding the following /etc/resolv.conf file? search example.com nameserver 208.77.188.166 nameserver 208.77.188.167


Options are :

  • example.com will be appended to host names when they do not contain dots.
  • If DNS queries to the localhost fail, the server 208.77.188.166 will be queried.
  • There is a syntax error.
  • example.com will be appended to all host lookups.

Answer : example.com will be appended to host names when they do not contain dots.

Which of the following commands should be used to print a listing of email in the system's mail queue?


Options are :

  • lpq
  • mlq
  • mailq
  • sendmail -l

Answer : mailq

On a dual boot system, every time the system is booted back into Linux the time has been set backward by one day. Which of the following commands will correct the problem?


Options are :

  • hwclock --systohc --localtime
  • ntpdate pool.ntp.org
  • date -d '+ 1 day
  • time hwclock

Answer : hwclock --systohc --localtime

CompTIA Security+ Cert. (SY0-501): Practice Tests 2019 Set 5

Which of the following lines would an administrator find in the file /etc/resolv.conf?


Options are :

  • hosts: files, dns
  • domain mycompany.com
  • 192.168.168.4 dns-server
  • order hosts, bind

Answer : domain mycompany.com

An administrator suspects that a gateway machine on the network has failed but they are unsure which machine. Which of the following commands will help locate the problem?


Options are :

  • netstat
  • nslookup
  • traceroute
  • .ps
  • ifconfig

Answer : traceroute

Which of the following configuration files should be modified to set default shell variables for all users?


Options are :

  • /etc/profile
  • /etc/bashrc
  • /etc/skel/.bashrc
  • ~default/.bash_profile

Answer : /etc/profile

Which of the following commands is used to hold keys during a login session to be used for automatic authentication while logging in to other machines using ssh?


Options are :

  • sshd
  • ssh-add
  • ssh-agent
  • ssh-keygen

Answer : ssh-agent

Which of the following configuration files does sudo read when determining if a user is permitted to run applications with root privileges?


Options are :

  • /etc/groups
  • /etc/sudo.conf
  • /etc/passwd
  • /etc/sudoers

Answer : /etc/sudoers

Which of the following statements would create a default route using a gateway of 192.168.1.1?


Options are :

  • netstat -add default gw
  • route default 192.168.1.1
  • route add default gw 192.168.1.1
  • ip route default 192.168.1.1

Answer : route add default gw 192.168.1.1

A senior executive asked an administrator to change the default background of the executive’s machine, which uses XDM. Which of the following files would the administrator edit to achieve this?


Options are :

  • /etc/X11/defaults.conf
  • /etc/X11/xdm/Defaults
  • /etc/X11/xdm/Xsetup
  • ./etc/X11/xdm.conf

Answer : /etc/X11/xdm/Xsetup

Which of the following commands will print the exit value of the previous command to the screen in bash?


Options are :

  • echo $?
  • echo $exit
  • echo $status
  • echo $#

Answer : echo $?

CompTIA JK0-019 E2C Network Media & Topologies Practice Exam Set 2

Which of the following directories in a user's home contains configuration files and key rings for GPG?


Options are :

  • ~/.gpg/
  • ~/gpg.d/
  • ~/.gnupg/
  • ~/gnupg/

Answer : ~/.gnupg/

Which of the following lines from /etc/X11/xorg.conf indicates that fonts can be found on a font server?


Options are :

  • FontPath= server
  • FontPath "unix/:7100"
  • Fonts "unix/:7100"
  • Fonts= server

Answer : FontPath "unix/:7100"

Which of the following commands should be added to /etc/bash_profile to change the language of messages from an internationalised program to Portuguese (pt)? (Select TWO).


Options are :

  • export MESSAGE="pt"
  • export LC_MESSAGES="pt"
  • export LANGUAGE="pt"
  • export LANG="pt"

Answer : export LC_MESSAGES="pt" export LANG="pt"

What keyword is missing from this code sample of a shell script? ____ i in *.txt; do echo $i done


Options are :

  • until
  • loop
  • while
  • for

Answer : for

Which of the following is pool.ntp.org?


Options are :

  • A community website used to discuss the localization of Linux.
  • A website which provides binary and source packages for the OpenNTPD project.
  • A deprecated feature for maintaining system time in the Linux kernel.
  • A virtual cluster of various timeservers.

Answer : A virtual cluster of various timeservers.

All of the following are Mail Transport Agents EXCEPT:


Options are :

  • mail
  • exim
  • qmail
  • sendmail
  • postfix

Answer : mail

Comptia A+ (220-801) Certification Exam Practice Test Set 5

Comment / Suggestion Section
Point our Mistakes and Post Your Suggestions