CS183 Midterm Review Exam Flashcards

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/49

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

50 Terms

1
New cards

What is the role of the systemd process during system boot?

A. It creates the filesystem

B. It manages user logins

C. It spawns all other processes as PID 1

D. It only manages timers

C

2
New cards

Which section of a systemd unit file specifies dependencies and required targets?

A. [Service]

B. [Install]

C. [Unit]

D. [Dependencies]

C

3
New cards

What signal is typically used to terminate a systemd service cleanly?

A. TERM

B. INT

C. QUIT

D. KILL

C

4
New cards

What does the chmod u=rwx,g=rx,o=r myfile command do?

A. Sets all permissions for all users

B. Grants full permissions to the group

C. Assigns specific permissions to user, group, and others

D. Removes write access for everyone

C

5
New cards

What Linux command is used to view the current status of processes in real time?

A. ps

B. strace

C. grep

D. top

D

6
New cards

What special file system entry refers to the parent directory?

A. .

B. ~

C. ..

D. /

C

7
New cards

Which file system component defines a hierarchy of object names?

A. API

B. Namespace

C. Security Model

D. Implementation

B

8
New cards

The root user (UID 0) is required to supply passwords when using su to switch to another user.

False

9
New cards

Only root can kill non-essential processes using the halt command.

False

10
New cards

systemctl can be used to both investigate and enable/disable systemd units.

True

11
New cards

The setuid permission allows a program to be executed with the privileges of the file's owner.

True

12
New cards

Sticky bit settings are ignored on normal files.

True

13
New cards

The crontab file is shared by all users on the system.

False

14
New cards

strace can attach to a running process and trace its system calls.

True

15
New cards

What is the PID of the initial process started by the Linux kernel?

A. 0

B. 1

C. 100

D. It varies on each boot

B

16
New cards

Anything managed by systemd is called a "unit."

True

17
New cards

Which of the following is not a section in a standard systemd unit file?

A. [Unit]

B. [Service]

C. [Install]

D. [Boot]

D

18
New cards

The systemctl command is used to modify and inspect systemd unit files.

True

19
New cards

Which flag allows you to view logs from a previous boot using journalctl?

A. -p

B. -u

C. -b

D. -r

C

20
New cards

The halt command powers off the system by default.

False

21
New cards

Which strategy can be used when the system fails to boot normally?

A. Use single-user mode

B. Format the disk

C. Disable systemd

D. Upgrade the kernel remotely

A

22
New cards

Only the root user can perform administrative operations like configuring network interfaces.

True

23
New cards

In the permission string drwxr-xr-x, what does the d indicate?

A. Device

B. Directory

C. Default

D. Deleted

B

24
New cards

The command chmod +x myfile adds execute permission to a file.

True

25
New cards

Which UID is used to determine access permissions?

A. Real UID

B. Effective UID

C. Saved UID

D. Backup UID

B

26
New cards

The root account logs every command it runs automatically.

False

27
New cards

The nosuid mount option disables:

A. Reading files

B. Executing setuid and setgid programs

C. Writing to the disk

D. System updates

B

28
New cards

The su command allows root to switch to any user without a password.

True

29
New cards

Which file defines what commands users can execute using sudo?

A. /etc/sudoers

B. /etc/passwd

C. /usr/sudo.conf

D. /var/log/sudo.log

A

30
New cards

Changing the root password to * disables root login.

True

31
New cards

Which of the following is an example of modern access control?

A. Role-based Access Control (RBAC)

B. File-based Access Control (FBAC)

C. Manual Access Control (MAC)

D. Static Access Control (SAC)

A

32
New cards

Processes in UNIX can be managed using the same tools regardless of whether they are system or user processes.

True

33
New cards

Which of the following is not tracked by the Process Control Block (PCB)?

A. Address Space Map

B. CPU Temperature

C. Execution Priority

D. Signal Mask

B

34
New cards

A process's allocated memory includes code, libraries, variables, and a stack.

True

35
New cards

Threads within a process share:

A. CPU context only

B. Their own memory space

C. The process’s memory space

D. Nothing

C

36
New cards

Niceness is a measure of process priority where lower values mean higher priority.

True

37
New cards

Where is a user’s crontab file typically located?

A. /var/spool/cron

B. /etc/cron.d

C. /usr/local/crontab

D. /tmp/crontab

A

38
New cards

Systemd timers require two files: a timer and a service.

True

39
New cards

Which version of kill sends a signal to processes by name?

A. kill

B. killall

C. pkill

D. Both B and C

D

40
New cards

The ps aux command displays user-friendly process information.

True

41
New cards

Which command can adjust a process's priority on the fly?

A. ps

B. nice

C. renice

D. strace

C

42
New cards

The strace tool shows system calls and kernel responses made by a process.

True

43
New cards

Which is not a main component of a filesystem?

A. Namespace

B. Implementation

C. API

D. Device Driver

D

44
New cards

An absolute path always starts with /.

True

45
New cards

Which file lists filesystems to be mounted at boot?

A. /etc/fstab

B. /boot/mount.conf

C. /etc/mounttab

D. /var/mntlist

A

46
New cards

Symbolic links can reference files across different file systems.

True

47
New cards

Which file type is used for communication between local processes?

A. Regular file

B. Named pipe

C. Local domain socket

D. Block device

C

48
New cards

Only the most specific permission applies when a user fits into multiple categories (user, group, all).

True

49
New cards

What is the octal value for the sticky bit?

A. 1000

B. 2000

C. 4000

D. 777

A

50
New cards