ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 126 - XK0-005 discussion

Report
Export

A systems administrator is notified that the mysqld process stopped unexpectedly. The systems administrator issues the following command:

sudo grep -i -r ‘out of memory' /var/log

The output of the command shows the following:

kernel: Out of memory: Kill process 9112 (mysqld) score 511 or sacrifice child.

Which of the following commands should the systems administrator execute NEXT to troubleshoot this issue? (Select two).

A.
free -h
Answers
A.
free -h
B.
nc -v 127.0.0.1 3306
Answers
B.
nc -v 127.0.0.1 3306
C.
renice -15 $( pidof mysql )
Answers
C.
renice -15 $( pidof mysql )
D.
lsblk
Answers
D.
lsblk
E.
killall -15
Answers
E.
killall -15
F.
vmstat -a 1 4
Answers
F.
vmstat -a 1 4
Suggested answer: A, F

Explanation:

The free -h command can be used to check the amount of free and used memory in the system in a human-readable format. This can help to troubleshoot the issue of mysqld being killed due to out of memory. The vmstat -a 1 4 command can be used to monitor the system's virtual memory statistics, such as swap usage, paging activity, and memory faults, every one second for four times. This can help to identify any memory pressure or performance issues that may cause out of memory errors.

The nc -v 127.0.0.1 3306 command would attempt to connect to the MySQL server on port 3306 and display any diagnostic messages, but this would not help to troubleshoot the memory issue. The renice -15 $( pidof mysql ) command would change the priority of the mysql process to -15, but this would not prevent it from being killed due to out of memory. The lsblk command would display information about block devices, not memory usage. The killall -15 command would send a SIGTERM signal to all processes with a matching name, but this would not help to troubleshoot the memory issue. Reference: [CompTIA Linux+ (XK0-005) Certification Study Guide], Chapter 15: Managing Memory and Process Execution, pages 468-469.

asked 02/10/2024
Kurt Onal
30 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first