exam questions

Exam XK0-005 All Questions

View all questions & answers for the XK0-005 exam

Exam XK0-005 topic 1 question 126 discussion

Actual exam question from CompTIA's XK0-005
Question #: 126
Topic #: 1
[All XK0-005 Questions]

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
  • B. nc -v 127.0.0.1 3306
  • C. renice -15 $( pidof mysql )
  • D. lsblk
  • E. killall -15
  • F. vmstat -a 1 4
Show Suggested Answer Hide Answer
Suggested Answer: AF 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
TheRealManish
Highly Voted 1 year, 1 month ago
Selected Answer: AF
A: i like A because it will tell us if we need to add more swap space. B: this is netcat command so not relevant C: we might need to renice, in the event that a child process was killed, but we dont know if it was the child process or not. but regargles, -15 is not a very nice number. D: listing storage doesnt help really E: invalid syntax F: not sure how this info will help. By process of elimination I am going with A to check if we can add some swap.. and F to get an overall fee for how the system is doing.. this question is ridiculus
upvoted 5 times
Nvoid
1 year, 1 month ago
Good effort, keep it up buddy!
upvoted 1 times
Nvoid
1 year, 1 month ago
no idea if we're really correct, but just gonna keep trying.
upvoted 1 times
...
...
...
dsmitd33
Most Recent 4 weeks ago
Selected Answer: AF
is vmstat -a 1 4 even a valid command?
upvoted 1 times
...
Alizadeh
4 months, 4 weeks ago
Selected Answer: AF
The correct answers are A. free -h and F. vmstat -a 1 4
upvoted 1 times
...
angellorv
9 months, 1 week ago
Answer C is correct: as the administrator you are trying to prevent a database crash caused by OOM Killer. Questions with OOM caused by MySQL consider "renice" - reprioritizing MySQL as the leading answer.
upvoted 1 times
...
linux_admin
11 months ago
Selected Answer: AF
To troubleshoot an out-of-memory issue with the mysqld process, the systems administrator should check the server's memory usage. Therefore, the correct option is A, free -h, and F, vmstat -a 1 4.
upvoted 1 times
linux_admin
11 months ago
Option B (nc -v 127.0.0.1 3306) is used to check if the MySQL server is running and accepting connections. It will not help troubleshoot an out-of-memory issue. Option C (renice -15 $( pidof mysql )) is used to change the priority of a running process. It will not help troubleshoot an out-of-memory issue. Option D (lsblk) is used to list information about all available block devices, including their mount points. It will not help troubleshoot an out-of-memory issue. Option E (killall -15) is used to send a signal to all processes with a particular name. It will not help troubleshoot an out-of-memory issue.
upvoted 2 times
...
...
KnifeClown1
11 months, 1 week ago
Selected Answer: AF
A. free -h F. vmstat -a 1 4
upvoted 2 times
...
Nvoid
1 year, 1 month ago
Selected Answer: AF
We can eliminate B/C/D because they have nothing to do with it, which leaves us to `troubleshoot with A/E/F` We eliminate E because that is killing processes, not troubleshooting. We're left with A & F. A: Troubleshoot memory = yes B: open netcat on port 3306 = no C: renice -15 = no D: show block devices = no E: kill all processes in -15 = no F: Troubleshoot memory = yes
upvoted 2 times
...
Veteran903
1 year, 1 month ago
Well, analyzing this one again.... I'll go with EF just because the other answers dont match and like you guys said an stopped process cant be renice, also option A offers just info about system memory and swap memory so i think the vmstat is a way better option...
upvoted 1 times
...
Veteran903
1 year, 1 month ago
Hello guys, the right answers are C and F, A free -h only provides info about system memory and swap space while vmstat reports virtual memory statistics, the reason why you have to pick C is because you are not killing the process itself but "sacrificing the child", doing this you will about killing or stopping the process, CompTIA wording is brutal!!! lol
upvoted 2 times
...
MissAllen
1 year, 2 months ago
I would say AC are the correct answers. We don't know the current nice value of the mysqld process, plus since it stopped how can you renice it? Renice is for running processes. Renice also affect CPU access, not memory. Vmstat would be a better choice.
upvoted 1 times
TheRealManish
1 year, 1 month ago
wait, you say AC is correct, but you can't renice a stopped process. how is C correct then? thanks
upvoted 1 times
Alizadeh
4 months, 4 weeks ago
You are correct, you cannot renice a stopped process. The renice command only works on running processes. In this case, the mysqld process is stopped, so the renice -15 $( pidof mysql ) command will not have any effect. However, the administrator may still want to run the command to see if it helps to resolve the issue.
upvoted 1 times
...
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago