wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Linux Essentials Quiz 2

Total questions: 14

Worksheet time: 11mins

Name
Class
Date
1.

Which of the following characters in a shell indicates the shell is running with superuser (root) privileges?

a)

~

b)

#

c)

$

d)

>

2.

Which symbol can be used with the cd command to change the current directory to the current user's home directory?

a)

~

b)

#

c)

$

d)

>

3.

Which character starts a comment line in a shell script file?

a)

~

b)

#

c)

$

d)

>

4.

When creating a bash script, which of the following must be placed in the first line to make it executable?

a)

~!/tmp/exe

b)

&!/etc/sh

c)

$!/var/log

d)

#!/bin/bash

5.

Which of the following linux commands will display processes that are running on the operating system? (Choose two)

a)

ps aux

b)

cat

c)

top

d)

powershell

6.

You want to view the last tools installed by a user with the apt command. Which file contains this information?

a)

/var/log/apt/history.log

b)

/etc/apt/sources.list

c)

/var/lib/apt/lists/installed_packages

d)

/usr/share/apt/recent_installs

7.

Instead of using password-based authentication, which option is more secure for connecting to a remote server?

a)

Telnet

b)

Open authentication

c)

Rsa-based authentication

d)

Key-based authentication

8.

Which tool or protocol allows us to establish key-based authentication for connecting to a remote server?

a)

SSH key pairs

b)

TLS key

c)

SNMP keys

d)

FTP

9.

How can you create SSH key pairs with the RSA type and 4096 bits?

a)

ssh-create -t rsa -b 4096

b)

ssh-generate -rsa -b 4096

c)

ssh rsa 2048

d)

ssh-keygen -t rsa -b 4096

10.

When generating SSH key pairs using ssh-keygen, which files are created for authentication purposes?

a)

auth_rsa and auth_rsa.pub

b)

private_key and public_key

c)

id_rsa and id_rsa.pub

d)

ssh_private and ssh_public

11.

Which key is shared with a remote server to establish secure communication using SSH?

a)

Session key

b)

Public key

c)

Private key

d)

Symmetric key

12.

Which of the following is the result of "ls -l" command for the "test.txt" file?

"test.txt" is a regular file.

  • It is owned by the user "player", and the group "team" has access to it.

  • The file is empty (0 bytes).

  • The file can be read by anyone but can only be modified by the owner, "player."

  • The file's last modification time was on February 5th at 10:43 AM.

a)

drw-r--r-- 1 team player 0 Feb 5 10:43 test.txt

b)

-r--r--rwx 1 player team 0 Feb 5 10:43 test.txt

c)

-rw-r--r-- 1 player team 0 Feb 5 10:43 test.txt

d)

-rw-r--r-- 1 other other 0 Feb 5 10:43 test.txt

13.

A special permission is commonly used for /tmp directory in a linux file system.

Because it is a shared directory where all users can write, but they should not delete or modify each other’s files. Which of the following is the special permission for /tmp directory?

a)

sticky bit

b)

setUID

c)

setGID

d)

chmod

14.

The output of "ls -ld /tmp" command is as follows:

drwxrwxrwt 13 root root 4096 Feb 25 04:00 /tmp

Which parameter indicates that the sticky bit is set on the /tmp directory?

a)

d

b)

t

c)

root

d)

w