LPIC exam 101 trainer
These questions are intended to help you train for the LPI exam. Please note that they are not official exam questions.
You're processing a file 'allmostempty.txt' with lots of empty lines. You want to get rid of these empty lines as they are totally useless for your purpose. Which command would be your best choice?
grep -v '^$' < allmostempty.txt
sed 's/^$//' < allmostempty.txt
grep '.+' < allmostempty.txt
sed -e '.+' < allmostempty.txt
Which of the following can be used to alter the priority of a running process?
How would you install GRUB (Legacy) on the MBR of the first hard drive in a system?
You are formatting a single hard disk for a Linux install. What is the maximum number of primary partitions you can create?
After you connect your usb cd writer, nothing happens. What should you check?
See if /proc/bus/usb is mounted
List loaded kernel modules
All of the above
What option will cause the tail command to display new lines as the file grows?
You want to list file foo.txt line by line, but in reverse order. What command would you use?
ls -r foo.txt | cat
cat -r foo.txt
cat foo.txt | ls -r
In which directory must definition files be placed to add additional repositories to yum?
Your system is becoming a bit unreponsive due to a program with PID 9519. You don't want to kill it. What other option do you have?
nice +10 -p 9519
nice -10 -p 9519
renice +10 -p 9519
renice -10 -p 9519
In GRUB's configuration file you find the line 'root (hd1,4)'. What is the corresponding device name on a Linux system?