Docsity

LFS426 Linux Performance Tuning Practice Exam, Exams of Technology

Toggle sidebar
bg1
LFS426 Linux Performance Tuning Practice
Exam
Question 1. Which Linux kernel interface is primarily used to change runtime tunable
parameters without rebooting?
A) /etc/sysconfig
B) /proc/sys and sysctl
C) /boot/grub.cfg
D) /etc/fstab
Answer: B
Explanation: The /proc/sys virtual filesystem together with the sysctl command allows
administrators to read and modify kernel parameters on‑the‑fly.
Question 2. In performance analysis methodology, which step follows “identifying the
performance problem”?
A) Deploying patches
B) Collecting baseline data
C) Rebooting the system
D) Archiving logs
Answer: B
Explanation: After a problem is identified, baseline data is gathered to understand normal
behavior and quantify the deviation.
Question 3. Which type of benchmark isolates the performance of a single hardware
component?
A) Application benchmark
B) Synthetic benchmark
C) Regression benchmark
D) Stress benchmark
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33
pf34
pf35
pf36
pf37
pf38
pf39
pf3a
pf3b
pf3c
pf3d
pf3e
pf3f
pf40
pf41
pf42
pf43
pf44
pf45
pf46
pf47
pf48
pf49
pf4a
pf4b
pf4c
pf4d
pf4e
pf4f
pf50
pf51
pf52
pf53
pf54
pf55
pf56
pf57
pf58
pf59

Partial preview of the text

Download LFS426 Linux Performance Tuning Practice Exam and more Exams Technology in PDF only on Docsity!

Exam

Question 1. Which Linux kernel interface is primarily used to change runtime tunable parameters without rebooting? A) /etc/sysconfig B) /proc/sys and sysctl C) /boot/grub.cfg D) /etc/fstab Answer: B Explanation: The /proc/sys virtual filesystem together with the sysctl command allows administrators to read and modify kernel parameters on‑the‑fly. Question 2. In performance analysis methodology, which step follows “identifying the performance problem”? A) Deploying patches B) Collecting baseline data C) Rebooting the system D) Archiving logs Answer: B Explanation: After a problem is identified, baseline data is gathered to understand normal behavior and quantify the deviation. Question 3. Which type of benchmark isolates the performance of a single hardware component? A) Application benchmark B) Synthetic benchmark C) Regression benchmark D) Stress benchmark

Exam

Answer: B Explanation: Synthetic benchmarks are designed to stress a specific component (CPU, memory, disk) in isolation. Question 4. Which command shows per‑CPU utilization and load averages in real time? A) free B) vmstat C) top D) iostat Answer: C Explanation: top provides a dynamic, real‑time view of CPU usage per core along with system load averages. Question 5. The tuned daemon in Linux is used for: A) Managing firewalls B) Applying predefined performance profiles C) Scheduling cron jobs D) Encrypting file systems Answer: B Explanation: tuned applies system‑wide tuning profiles (e.g., latency‑performance, throughput‑performance) to adjust kernel parameters automatically. Question 6. Which sysctl parameter controls the maximum number of open file descriptors system‑wide? A) fs.file‑max B) vm.max‑map‑count

Exam

B) SCHED_BATCH

C) SCHED_IDLE

D) SCHED_FIFO

Answer: D Explanation: SCHED_FIFO is a first‑in‑first‑out real‑time policy that runs tasks at a fixed priority until they block or yield. Question 10. In cgroups, which subsystem limits the amount of CPU time a group can use? A) memory B) blkio C) cpuacct D) cpuset Answer: C Explanation: The cpuacct controller accounts for CPU usage and can be combined with cpu to enforce limits. Question 11. Which Linux kernel feature enables the use of larger memory pages to reduce TLB misses? A) Transparent Huge Pages (THP) B) Swappiness C) OOM Killer D) KSM Answer: A Explanation: THP automatically allocates 2 MiB pages (on x86) when possible, decreasing page table pressure.

Exam

Question 12. Which command displays detailed memory usage per process, including shared and private memory? A) free B) vmstat C) smem D) top Answer: C Explanation: smem reports proportional set size (PSS) and other memory breakdowns per process. Question 13. NUMA stands for: A) Non‑Uniform Memory Access B) Network Unified Memory Allocation C) New Unified Memory Architecture D) No‑Uplink Memory Access Answer: A Explanation: NUMA describes systems where memory latency varies depending on the processor‑memory pairing. Question 14. Which utility can display per‑device I/O statistics such as read/write throughput and await time? A) iostat B) vmstat C) top D) netstat Answer: A

Exam

D) data=none Answer: B Explanation: data=writeback does not journal file data, only metadata, thus offering higher throughput but risking data loss on power failure. Question 18. Which NFS mount option disables attribute caching to improve consistency? A) sync B) async C) noac D) hard Answer: C Explanation: noac turns off attribute caching, forcing the client to re‑validate file attributes on each operation. Question 19. RAID 5 provides: A) Striping with mirroring B) Striping with parity, tolerant of one disk failure C) Mirroring of all disks D) No redundancy, maximum capacity Answer: B Explanation: RAID 5 distributes parity across disks, allowing reconstruction after a single disk loss. Question 20. Which LVM command creates a new logical volume? A) vgcreate B) lvcreate

Exam

C) pvcreate D) lvextend Answer: B Explanation: lvcreate creates a logical volume within an existing volume group. Question 21. Asynchronous I/O (AIO) is primarily used to: A) Perform I/O operations in the kernel thread context B) Block the calling process until completion C) Increase CPU usage for I/O‑bound workloads D) Provide zero‑copy network transfers only Answer: A Explanation: AIO submits I/O requests that are handled by kernel worker threads, allowing the caller to continue execution. Question 22. Which perf subcommand records a call‑graph for a running process? A) perf stat B) perf top C) perf record - g D) perf report Answer: C Explanation: The - g flag tells perf to capture call‑graph (stack) information while recording. Question 23. The Linux kernel’s ftrace framework is primarily used for: A) Monitoring network traffic B) Tracing kernel function calls and events

Exam

A) powertop B) top C) iotop D) sar Answer: A Explanation: powertop monitors power consumption and provides suggestions to reduce energy use. Question 27. In CPU topology, “hyper‑threading” creates: A) Multiple physical cores per socket B) Logical CPUs that share execution resources C) Separate CPU sockets for each thread D) Independent CPU frequency domains Answer: B Explanation: Hyper‑threading (SMT) presents two logical CPUs per core that share most hardware resources. Question 28. Which BIOS setting can negatively impact Linux performance if disabled? A) VT‑d (IOMMU) B) ACPI C) Intel Turbo Boost D) Secure Boot Answer: C Explanation: Disabling Turbo Boost prevents the CPU from exceeding its base frequency, reducing peak performance.

Exam

Question 29. The C‑state C6 indicates: A) CPU is running at full speed B) CPU is halted with cache flushed, deepest idle state C) CPU frequency is throttled to half D) CPU is in a low‑power sleep but retains cache Answer: B Explanation: C6 is a deep idle state where the core’s cache is flushed and power is minimized. Question 30. Which command shows the current CPU frequency for each core? A) cpufreq-info B) lscpu C) cat /proc/cpuinfo D) dmidecode Answer: A Explanation: cpufreq-info (part of cpufrequtils) reports the active frequency and governor per CPU. Question 31. In Linux, “nice” values affect: A) I/O scheduling priority only B) Memory allocation limits C) CPU scheduling priority for normal tasks D) Network packet priority Answer: C Explanation: The nice value adjusts the static priority of a process under the CFS scheduler.

Exam

Question 35. Which of the following is a valid perf event for measuring cache misses? A) cycles B) instructions C) cache-misses D) branch-faults Answer: C Explanation: The cache-misses event counts the number of cache miss occurrences on the CPU. Question 36. In a virtualized environment, which hypervisor feature most directly impacts disk I/O performance? A) CPU pinning B) vCPU scheduling C) VirtIO block driver D) SR‑IOV networking Answer: C Explanation: The VirtIO block driver provides a paravirtualized interface that reduces overhead for disk I/O. Question 37. Which sysctl setting influences the TCP receive window scaling? A) net.ipv4.tcp_window_scaling B) net.core.rmem_max C) net.ipv4.tcp_rmem D) All of the above Answer: D

Exam

Explanation: All three affect TCP receive buffer sizing and scaling; tcp_window_scaling enables scaling, while rmem_max and tcp_rmem set limits. Question 38. The “noatime” mount option improves filesystem performance by: A) Disabling file access time updates on each read B) Enabling asynchronous writes C) Turning off journaling D) Using larger block sizes Answer: A Explanation: noatime stops the kernel from updating the atime attribute, reducing write overhead. Question 39. Which command can be used to display the current I/O scheduler for a block device? A) cat /sys/block/sda/queue/scheduler B) iostat - x sda C) blkid sda D) fdisk - l Answer: A Explanation: The scheduler file under /sys/block//queue lists the active scheduler and available options. Question 40. The “deadline” scheduler maintains two queues. What are they? A) Read and write queues B) FIFO and LIFO queues C) Priority and fairness queues

Exam

C) The order of I/O completion callbacks D) The maximum number of real‑time priorities Answer: B Explanation: When set, newly forked tasks are scheduled before the parent, affecting latency. Question 44. Which command can be used to monitor per‑process network socket statistics? A) netstat - p B) ss - p C) ifconfig - a D) ping - c 1 Answer: B Explanation: ss (socket statistics) with - p shows process information for each socket. Question 45. The “pstate” in CPU terminology refers to: A) Power state of the whole system B) Processor performance state (frequency/voltage level) C) Peripheral device state D) Process scheduling state Answer: B Explanation: P‑states are performance states that define CPU frequency and voltage, used for scaling. Question 46. Which Linux kernel feature allows a user‑space program to request a specific CPU core for execution? A) setuid

Exam

B) chroot C) sched_setaffinity D) ptrace Answer: C Explanation: sched_setaffinity sets the CPU affinity mask for a process, binding it to selected cores. Question 47. In the context of RHEL/CentOS performance tuning, the “tuned‑adm” command is used to: A) Install new kernel modules B) Apply a tuned profile C) Manage SELinux policies D) Create LVM snapshots Answer: B Explanation: tuned‑adm activates, lists, or switches tuned profiles. Question 48. Which of the following is NOT a valid perf event type? A) software B) hardware C) tracepoint D) filesystem Answer: D Explanation: Perf supports software, hardware, tracepoint, and cache events, but not a generic “filesystem” event type. Question 49. The “iowait” field in /proc/stat represents:

Exam

Question 52. Which kernel module provides support for the Btrfs filesystem? A) ext4.ko B) xfs.ko C) btrfs.ko D) jfs.ko Answer: C Explanation: btrfs.ko implements the Btrfs filesystem driver. Question 53. The “deadline” I/O scheduler’s “fifo_batch” parameter controls: A) The maximum number of requests merged into one B) Number of requests processed in a single batch from the FIFO queue C) The size of the deadline queue in megabytes D) The time slice allocated to each request Answer: B Explanation: fifo_batch defines how many consecutive requests are taken from the FIFO queue before checking deadlines. Question 54. Which command shows the current kernel version and build information? A) uname - r B) cat /proc/version C) dmesg | grep Linux D) All of the above Answer: D Explanation: All three commands provide kernel version details.

Exam

Question 55. In the context of Linux power management, “C‑state” refers to: A) CPU frequency scaling steps B) CPU idle power‑saving states C) Cache coherence protocols D) Core scheduling classes Answer: B Explanation: C‑states are various idle states (C0‑active, C1‑C6 deeper sleep) that reduce power consumption. Question 56. Which sysctl key controls the maximum number of concurrent TCP connections in the SYN backlog? A) net.ipv4.tcp_max_syn_backlog B) net.core.somaxconn C) net.ipv4.tcp_fin_timeout D) net.ipv4.tcp_tw_reuse Answer: A Explanation: tcp_max_syn_backlog sets the size of the queue for half‑opened connections. Question 57. The “blkio.weight” cgroup parameter influences: A) CPU scheduling priority B) Disk I/O bandwidth allocation among cgroups C) Memory swapping behavior D) Network packet shaping Answer: B