Quiz 2
- You have plugged in a Digital Camera to the usb port. What command would you use to list usb devices?
a. lspci
b. usbdevices
c. lsusb
d. cat /proc/usb - The system you are managing has two scsi hard drives. Under what device names would they be listed as?
a. /dev/scsia and /dev/scsib
b. /dev/hda and /dev/hdb
c. /dev/sra and /dev/srb
d. /dev/sda and /dev/sdb - What is the command you would issue to upgrade or install an RPM package?
a. rpm -uh foo.rpm
b. dpkg -u foo.rpm
c. apt-get upgrade foo.rpm
d. rpm -Uh foo.rpm - You need to compile and and instal a program given to you as a tarball foomatic.tar.gz? Which of the following is the most likely sequence of commands to compile and install the program?
a. tar -jxf foomatic.tar.gz ; build ; install
b. unzip foomatic.tar.gz; make; make install
c. tar -zxf foomatic.tar.gz ; make ; make install
d. rpm -ih foomatic.tar.gz - You have just copied some files to your system. The command locate does not find this file. Write down the command you need to issue so that locate will be able to list this file.
____________ - The following commands have been run:
export VAR=foo;
VAR=;
However the VAR variable is still available in your environment. Which command would remove this variable?
a. remove VAR
b. unset VAR
c. rm VAR
d. export VAR=""; - To search a list of installed RPM packages on your system for the package named foo. Which command would you enter?
a. rpm search foo
b. dpkg -l foo
c. rpm -qa | grep foo
d. list-packages | grep foo - You have been given a text file with a list of names. You wish to list the names down in order. Write the the text utility that will do this job. Command only.
__________ - What file system option do you need to add in /etc/fstab to enable user quotas for a mount point?
a. userquota
b. quotausr
c. usrquota
d. quotausrenable - You are editing a file using the vi editor, and wish to save and quit. Which key sequence would you enter?
a. :save!
b. :wq!
c. :write
d :save and quit - An regular IDE hard disk which is installed as Master on IDE channel 1, has one logical partition. What would be the device name of this device?
a. /dev/hdb1
b. /dev/ide5
c. /dev/hda5
d. /dev/hda1 - The directory foo has the following octal permissions 0755. What permissions does this directory have? Select all that apply.
a. Owner can access and write files in the directory.
b. Directory is not writeable by users other than the owner.
c. All users can execute files in this directory.
d. There is a sticky bit set, and users cannot delete other files in this directory. - You wish to update and upgrade your Debian system. What commands you run?
a. apt-get update; apt-get upgrade;
b. rpm -Uvh
c. dpk -u --all-packages
d. system-update - You wish to verify the installation of all RPM packages installed on your system, what command would you use?
a. rpm -V --all
b. rpm -v all
c. rpm --check-sigs
d. rpm verify installation - You need to find all the files modified within the last 30mins in /home, which command would be appropriate.
a. find /home -modified last 30 minutes
b. find /home -cmin -30
c. find /home -amin -30
d. find /home -mmin -30 - Where would you modify the login screen for the GDM window manager?
a. grub.conf
b. gdm.conf
c. xdm.conf
d. gnome-window-manager.conf - /var and /tmp are mounted on different partitions, what would be the result of this command?
ln /tmp/test /var/test
a. Create symbolic link /var/newlink that points to /tmp/test
b. Invalid command
c. Create a hard link /var/test that points to /tmp/test
d. Create a hard link /tmp/test that points to /tmp/test - You wish to switch the device driver for your video card. Which configuration file would you most likely need to edit? Select all that apply.
a. /etc/X11/xorg.conf
b. /etc/X11/XF86Config
c. /etc/X11/video.conf
d. /etc/X11/drivers.cfg - You are trying to display the X programe Xterm on another computer with hostname othercomputer. Which environment variable would you edit?
a. DISPLAY
b. XDISPLAY
c. XORG
d. X11 - You have a job with id 1 suspended in the background. What command would you issue to run and attach it to your interactive terminal?
a. foreground -id 1
b. bg 1
c. resume 1
d. fg 1