nerdexam
LPI

201-400 · Question #23

If the current directory is /root and the kernel source is located in /usr/src/linux, which of the following commands should be used to apply the patch /tmp/foopatch?

The correct answer is D. cd/usr/src/linux; patch -p1 </tmp/foopatch. See the full explanation below for the reasoning.

Question

If the current directory is /root and the kernel source is located in /usr/src/linux, which of the following commands should be used to apply the patch /tmp/foopatch?

Options

  • Acat /tmp/foopatch | patch -p0
  • Bcd/usr/src/linux; cat/tmp/foopatch | patch -p0
  • Ccd/usr/src/linux; cat/tmp/foopatch | patch
  • Dcd/usr/src/linux; patch -p1 </tmp/foopatch
  • Ecd/usr/src/linux; patch -p1 >/tmp/foopatch

How the community answered

(27 responses)
  • A
    15% (4)
  • C
    4% (1)
  • D
    74% (20)
  • E
    7% (2)

Community Discussion

No community discussion yet for this question.

Full 201-400 Practice