CompTIA Linux+ Practice Questions: Shell Configuration

5 free, exam-style CompTIA Linux+ (XK0-006) practice questions covering Shell Configuration. Each question shows the correct answer and a clear explanation. Ready for the real thing? Take the full timed quiz below.

🚀 Take the full CompTIA Linux+ quiz 📘 CompTIA Linux+ study guide

Q1. Which file defines default shell variables?

Explanation: /etc/environment sets system-wide environment variables. Learn more.

Q2. What command lists all environment variables?

Explanation: env prints current environment variables. Learn more.

Q3. What does 'echo $?' display?

Explanation: $? contains exit status of previous command. Learn more.

Q4. Which file defines system-wide aliases?

Explanation: /etc/bashrc contains global bash settings. Learn more.

Q5. Which command shows environment variables?

Explanation: All display environment variables in different formats. Learn more.

More CompTIA Linux+ practice topics