LPIC exam 101 trainer

By Pygmalion  
 
These questions are intended to help you train for the LPI exam. Please note that they are not official exam questions. 
 
1. How would you list all files starting with x, y or z?
 
ls ^xyz*
ls [xyz]+
ls [xyz]*
ls ^[xyz].*
 
2. How many devices can be connected to an Ultra Wide SCSI bus (including the host adapter)?
 
32
16
8
4
 
3. 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
tac foo.txt
cat foo.txt | ls -r
 
4. On a Debian system, what command will update all installed packages to the latest available version?
 
apt-cache update
apt-get install
apt-get update
apt-cache install
dpkg -i
dpkg -u
 
5. You have a text file with tab-separated values, but your application needs them space-separated. What command would you use from the Bash shell to achieve this?
 
unexpand
expand
grep
cut
 
6. Which command displays mounted partitions, their mount points and available space?
 
mount
df
du -a
du
fdisk
 
7. Which of the following commands can be used to create an ext2 filesystem? (choose 2)
 
ext2fs
mke2fs
mkfs.e2fs
mkfs.ext2
 
8. You administer a system with quota enabled. The powers that be have asked you to add a new user Sam. Sam should have the same amount of diskspace available as his colleague Mose. What command would you use? (choose the best answer)
 
repquota -a sam -p mose
edquota -p mose sam
quotaon sam -p mose
quotactl -n sam -p mose
 
9. You logged in as user tux1, but now you want to switch users to tux2 with tux2's environment. How would you do this?
 
su tux2
su -e tux2
su -l tux2
su -m tux2
su -f tux2
 
10. When reading man pages, a lot of extra characters are shown on screen. Which of the following commands can help to deal with this problem?
 
col
grep
more
pg
row