Exam Linux-Praxis - 1 ( From )

Similar documents
TestOut Linux Pro - English 4.0.x OBJECTIVE MAPPING: CompTIA Linux+ LX0-103

LPIC-1 System Administrator

Comptia LX0-101 Exam Questions & Answers

Linux Interview Questions and Answers

LPI LPI Level Junior Level Linux Certification Part 1 of 2. Download Full Version :

Chapter 6. Linux File System

Welcome to getting started with Ubuntu Server. This System Administrator Manual. guide to be simple to follow, with step by step instructions

Unix System Architecture, File System, and Shell Commands

Open Source Operating Systems: Introduction to Command Line Administration (SCQF level 8)

Chapter 5: User Management. Chapter 5 User Management

Hands-on Keyboard: Cyber Experiments for Strategists and Policy Makers

More on file systems, Booting Todd Kelley CST8177 Todd Kelley 1

More on file systems, Booting Todd Kelley CST8177 Todd Kelley 1

Linux Nuts and Bolts

Linux Command Line Primer. By: Scott Marshall

Course 144 Supplementary Materials. UNIX Fundamentals

Exam Actual. Higher Quality. Better Service! QUESTION & ANSWER

ADVANCED LINUX SYSTEM ADMINISTRATION

Perl and R Scripting for Biologists

Disks, Filesystems 1

RH133. Red Hat Linux System Administration

The table below lists the domains measured by this examination and the extent to which they are represented in the examination.

UNIX System Programming Lecture 3: BASH Programming

Please choose the best answer. More than one answer might be true, but choose the one that is best.

MasterExam CD QUESTIONS Exam 101. Q1: Designing an implementation

client X11 Linux workstation

Linux Essentials Objectives Topics:

QUESTION BANK ON UNIX & SHELL PROGRAMMING-502 (CORE PAPER-2)

Disks, Filesystems, Booting Todd Kelley CST8177 Todd Kelley 1

Presented by Bill Genske Gary Jackson

The landscape. File hierarchy overview. A tree structure of directories The directory tree is standardized. But varies slightly among distributions

CST8207: GNU/Linux Operating Systems I Lab Ten Boot Process and GRUB. Boot Process and GRUB

Chapter-3. Introduction to Unix: Fundamental Commands

The Ultimate Linux/Windows System

Operating Systems Lab 1 (Users, Groups, and Security)

Basic Shell Commands. Bok, Jong Soon

bash startup files Linux/Unix files stty Todd Kelley CST8207 Todd Kelley 1

NETW 110 Lab 5 Creating and Assigning Users and Groups Page 1

Introduction to Linux

D. Delete the /var/lib/slocate/slocate.db file because it buffers all search results.

Stop all processes and then reboot - same as above startx. Log in as superuser from current login exit

Unix File System. Class Meeting 2. * Notes adapted by Joy Mukherjee from previous work by other members of the CS faculty at Virginia Tech

UNIT V. Dr.T.Logeswari. Unix Shell Programming - Forouzan

CompTIA Linux Course Overview. Prerequisites/Audience. Course Outline. Exam Code: XK0-002 Course Length: 5 Days

Linux Reference Card - Command Summary

CSE 390a Lecture 2. Exploring Shell Commands, Streams, Redirection, and Processes

A Brief Introduction to Unix

Prerequisites: General computing knowledge and experience. No prior knowledge with Linux is required. Supported Distributions:

5/20/2007. Touring Essential Programs

SANJAY GHODAWAT POLYTECHNIC

Disks, Filesystems Todd Kelley CST8177 Todd Kelley 1

Accurate study guides, High passing rate! IT TEST BOOK QUESTION & ANSWER. Ittestbook provides update free of charge in one year!

Introduction to Linux

Working with Basic Linux. Daniel Balagué

More Raspian. An editor Configuration files Shell scripts Shell variables System admin

Commands are in black

Answers to Even- Numbered Exercises

Computer Systems and Architecture

CSE 303 Lecture 2. Introduction to bash shell. read Linux Pocket Guide pp , 58-59, 60, 65-70, 71-72, 77-80

Table of contents. Our goal. Notes. Notes. Notes. Summer June 29, Our goal is to see how we can use Unix as a tool for developing programs

Linux System Administration, level 1. Lecture 4: Partitioning and Filesystems Part II: Tools & Methods

Linux Kung-Fu. James Droste UBNetDef Fall 2016

Actual4Test. Actual4test - actual test exam dumps-pass for IT exams

Embedded Linux Systems. Bin Li Assistant Professor Dept. of Electrical, Computer and Biomedical Engineering University of Rhode Island

Some useful UNIX Commands written down by Razor for newbies to get a start in UNIX

System Administration and Networking

Appendix B WORKSHOP. SYS-ED/ Computer Education Techniques, Inc.

Using grub to Boot various Operating Systems

Introduction p. 1 Who Should Read This Book? p. 1 What You Need to Know Before Reading This Book p. 2 How This Book Is Organized p.

RH-202. RedHat. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs)

Useful Unix Commands Cheat Sheet

Exam Questions RH133

Actual4Test. Actual4test - actual test exam dumps-pass for IT exams

Simulados LPI. Simulado Prova 101

Read the relevant material in Sobell! If you want to follow along with the examples that follow, and you do, open a Linux terminal.

Q) Q) What is Linux and why is it so popular? Answer - Linux is an operating system that uses UNIX like Operating system...

OPERATING SYSTEMS LINUX

File permission u owner of file/directory (user) g group of the file/directory o other a all

LPI Number: Passing Score: 800 Time Limit: 120 min File Version: 5. LPI Questions & Answers

LiLo Crash Recovery. 1.0 Preparation Tips. 2.0 Quick Steps to recovery

Embedded System Design

The Linux IPL Procedure

Lecture 02: Linux Command Line

This is Lab Worksheet 13 - not an Assignment. Boot Process and GRUB

User accounts and authorization

INTRODUCTION TO LINUX

RedHat. Rh202. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs)

Operating Systems. Engr. Abdul-Rahman Mahmood MS, PMP, MCP, QMR(ISO9001:2000) alphapeeler.sf.net/pubkeys/pkey.htm

National University of Computer and Emerging Sciences Operating System Lab - 02 Lab Manual

Introduction To Linux. Rob Thomas - ACRC

CST8207: GNU/Linux Operating Systems I Lab Seven Linux User and Group Management. Linux User and Group Management

IMPORTANT: Logging Off LOGGING IN

UNIX Quick Reference

IT 363 Unix Shell Programming

Introduction to remote command line Linux. Research Computing Team University of Birmingham

Mills HPC Tutorial Series. Linux Basics I

Exam Questions LX0-101

System Administration

OPS235. Linux File Systems Partitioning Mounting File Systems

CSE 390a Lecture 2. Exploring Shell Commands, Streams, and Redirection

Transcription:

Exam Linux-Praxis - 1 ( From http://www.linux-praxis.de ) (1)Which of the following commands results in mailing the content of the current directory to Bob? A. mail Bob < ls B. ls > mail Bob C. ls mail Bob D. ls mail Bob E. mail Bob ls (2)How could you describe the following command line? foo & bar & foobar A.The commands foo, bar and foobar are started in the background. B.The command foo is processed. If it results without error, then bar and foobar are processed. C.The command foo is processed. If it results without error, then bar will be processed. If bar results without error, then foobar will be processed. D.The commands foo, bar and foobar are processed one after another. E.The commands foo and bar are started in the background, foobar is started in the foreground (3)Which would be the command to delete the enviroment variable FOO from the current environment in the bash shell? A. delete $FOO B. destroy FOO C. unset FOO D. FOO= E. rm -rf $FOO (4)What would the following command result in? cp $(find. -size -12k) /tmp A. The file with the name stored in the variable "find. -size -12k" will be copied to /tmp B. All files in the current directory which are smaller than 12 KByte will be copied to /tmp C. All files in the current directory and in all included subdirectories which are smaller than 12 KByte will be copied to /tmp. D. All files in the current directory and in all included subdirectories which are smaller than 12 KByte will be copied to /tmp. The directory structure will be copied, too. E. This isn't a valid command 91_LPI_Linux-praxis_1.sxw - 1

(5)How could you get the following information: Which GID has the default group of user foo? A. defgrp foo B. defgrp -n foo C. grep foo /etc/passwd cut -d: -f4 D. getuserinfo -gid foo E. grep foo /etc/group cut -d: -f3 (6)What command is used to count the number of lines, words and characters inside a textfile - just the command, no options? Type the answer. (7)What would the following command result in? cp /home/foo/bar /home/bar/foo /foo A. The files /home/foo/bar, /home/bar/foo, and /foo are copied into the current directory B. The file /home/foo/bar is copied into the directories / home/bar/ foo and /foo C. The files /home/foo/bar and /home/bar/foo are copied together in the file /foo D. The files /home/foo/bar and /home/bar/foo are copied into the directory /foo E. This isn't a valid commandline (8)You've started three jobs in the background. Now you would like to bring a particular one of them into the foreground again. How could you do it? A. Get the list of jobs using the jobs command and then use: fg jobid B. Switch through all background-jobs using the Ctrl-Tab key C. Get the list of jobs using the jobs command and then use: kill -STFG PID_of_job D. Use the command: fg jobname E. Get the list of jobs using the jobs command and then use: jobname (9) What command sends signals to processes (just the command - no options)? Type the answer. 91_LPI_Linux-praxis_1.sxw - 2

(10)A high nice value of a process means? A. the process uses less irqs B. the priority of the process is higher than normal C. the priority of the process is lower than normal D. the process uses no enviroment E. the process allows interprocess communication (11)What means the following construct inside a regular expression? [^A-Z][!A-Z] A. The starting of a line, followed by an uppercase letter, followed by a non uppercase letter. B. Either the starting of a line or an uppercase letter followed by a non uppercase letter. C. A non uppercase letter followed by either an! or an uppercase letter D. A non uppercase letter at the beginning of a word followed by a non uppercase letter. E. An uppercase letter at the beginning of a word followed by a non uppercase letter. (12)What statement concerning the following wildcard is correct? [A-Z]\* A. All files beginning with an uppercase letter followed by one * B. All files beginning with an non numeric letter C. All files beginning with an uppercase letter followed by the backslash D. All files without numbers in their names E. All files beginning with one of the letters A, Z or - (13)What command would you use to show all partitions on all hard drives? A. df B. mtab C. fstab D. fdisk -l E. du (14)While monitoring the integrity of the filesystems, you detect, that there are no more free inodes left on the /home partition although there are many megabytes free space. What could be the reason? A. This is a typical filesystem error on ext2 partitions. B. A user has created lots of very small files. C. The inode table is corrupted. D. There are lots of cross-linked files. E. The report of many megabytes free space is wrong due to an overflow of the 32 Bit Free-Space-Variable. 91_LPI_Linux-praxis_1.sxw - 3

(15)Consider an unmounted partition /dev/hdc7 should be mounted on /usr/local. The following entry in /etc/fstab exists: /dev/hdc7 /usr/local ext2 defaults 1 2 Which command could you use to mount the filesystem? Choose all correct answer. A. mount -l /dev/hdc7 B. mount /dev/hdc7 C. mount /dev/hdc7 /usr/local D. mount /usr/local E. mount -V /usr/local (16)How could you generate a report of the user quota of /home? A. repquota /home B. quotarep /home C. quota --report /home D. edquota /home E. quotaed /home (17)What is the meaning of the following file permission mode of the file foobar? -rwsr-xr-x 1 foo bar 12345 Oct 29 14:51 foobar A. Everybody who executes this file does this under the EUID of root B. Everybody who executes this file does this under the EUID of foo C. Everybody who executes this file does this under the GID of bar D. Everybody who executes this file does this under the EUID 1 E. Everybody who executes this file does this under the GID 1 (18)What command changes the default permission mode for newly created files? (Just the command - no options). Type the answer. (19)How could you change the ownership of the file foobar to user foo? A. chown foo:foobar B. chown foobar foo C. chown foo foobar D. chmod --user foo foobar E. chperm --user foo --file foobar (20)The files foo and bar points to the same content. One of them was created as a hard link to the other. How could you detect which of the two is the original file and which is the link? A. The ls -l command shows a l for the link and a - for the file B. The ls -l command shows a -> from the link to the file C. The "ln --list foo bar" command shows the link and the file D. The ls -l command shows a different filesize for the link and the file. The file shows it's real size but the link shows only the size of it's destination filename. E. There is no way to differ between file and link 91_LPI_Linux-praxis_1.sxw - 4

(21)Which of the following statements concerning the locate command is true? A. locate can find any file in the system which was created before the last call of updatedb B. locate can find only program files inside the searchpath (PATH) C. locate is used to locate manpages inside the MANPATH D. locate can find any file in the system which was created after the last call of updatedb E. locate is used to find the original file of a hard or symbolic link (22)What command would you use to read the kernel bootup messages? (Just the command, no options) Type the answer. (23)What command would cleanly reboot your Linux box? Choose all correct answer. A. shutdown -r now B. init 0 C. telinit 1 D. init 6 E. reboot (24)What is the meaning of the MANPATH variable? A. It describes the path to the man, apropos and whatis command. B. It stores the last visited manpages. C. It stores the directories for the different manual sections. D. It stores a list of all directories which contain manpages. E. It stores the routing path for the Metropolean Area Network. (25)User Paul has forgotten his password. He asks you, the administrator, to help him. What could you do to help him? A. Decrypt his encrypted password in /etc/shadow and tell him his forgotten password. B. Create a new password for him using the command "passwd paul" and tell him his new password. C. Remove the user paul and create a new one with a new password. D. Login as user paul using the command "su paul" and create a new password with passwd E. Remove the entry of his password in /etc/shadow and let him login without password. 91_LPI_Linux-praxis_1.sxw - 5

(26)The group foo should get its own administrator, so that you, as the root user, are not forced to add the new group members. The group administrator is the user bar, who already is member of foo. He should be able to add and remove group members. What command would you use for that purpose? A. chgrpadmin bar foo B. chgrpadmin foo bar C. gpasswd -A bar foo D. gadmin foo bar E. gpasswd -a foo bar (27)Which directory contains a set of template configuration files, to be copied in an newly created user directory? Enter the whole path. Type the answer. (28)How could you describe the following command? tail -f /var/log/messages A. It cuts the last 10 lines of the file /var/log/messages to STDOUT B. It changes the access time for the file /var/log/messages to now C. It changes the modification time for the file /var/log/messages to now D. It writes the contents of the file /var/log/messages in reversed order to STDOUT E. It displays every new line of the file /var/log/messages while this file is growing (29)How can you describe the function of the following commands? foo tee bar foobar A. The command foo redirects its output to the command tee. After that the command bar redirects its output to the command foobar B. The command foo writes its output to the file tee; the command bar writes its output to the file foobar C. The command foo redirects its output to the command tee which writes it into the file bar and sends the same further to the command foobar D. The command foobar gets its input from the command bar which gets its input from the command foo E. This isn't a valid commandline 91_LPI_Linux-praxis_1.sxw - 6

(30)How could you describe the following commandline? foo & bar A. The command foo is started in the background and redirects its output to the command bar. B. The command bar is only processed if the command foo returns no error. C. The command bar is only processed if the command foo returns an error. D. The command bar is processed after the command foo, regardless of errors. E. This isn't a valid commandline. (31)How would you assign the content of the enviroment variable PATH to the environment variable MYPATH in the bash shell? A. MYPATH=PATH B. MYPATH=$PATH C. $MYPATH=PATH D. $MYPATH=$PATH E. let MYPATH=$PATH (32)Which command would change the owner of all files and subdirectories under / home/foo to foobar? Choose every correct answer. A. chmod foobar /home/foo B. chown foobar /home/foo C. chown -r foobar /home/foo D. chown -R foobar /home/foo E. chown --recursive foobar /home/foo (33)How could you get the following information: Which GID has the default group of user foo? A. defgrp foo B. defgrp -n foo C. grep foo /etc/passwd cut -d: -f4 D. getuserinfo -gid foo E. grep foo /etc/group cut -d: -f3 (34)What command is used to display a textfile in reversed order (last line first - first line last) - just the command, no options? (35)What is the result of the following command? cd ~foo A. The current directory is changed to ~foo B. The current directory is changed to the directory foo inside your home directory C. The current directory is changed to the home directory of the user foo D. The current directory is changed to the nearest directory with a name ending with foo E. This isn't a valid command 91_LPI_Linux-praxis_1.sxw - 7

(36)How would you suspend a running foreground-job? A. Ctrl-Z B. Ctrl-C C. Ctrl-X D. Ctrl-S E. Ctrl-D (37) How could you try to stop a hung process which refuses to accept keyboard input? Choose every correct answer. A. Ctrl-C B. Ctrl-S C. kill -9 PID D. kill PID E. ipcsend SIGKILL PID (38)What command starts processes with higher or lower priority? Type the answer. (39)Which of the following tools could be used to search a textfile for a particular searchstring without opening it with an interactive editor? Choose every correct answer. A. vi B. sed C. ed D. grep E. find (40)What set of files would be affected by the following wildcard? foo.*bar Choose every correct answer. A. foo.bar foo.1bar foo.2bar B. foobar foo.2bar foo.34bar C. foo.1bar foo.2bar foo.fbar D. foo.1bar foo.2bar Foo.3.bar E. foobar foo1bar foo2bar (41) /dev/ ist the first logical partition of the master on the second IDE-channel. Type the answer. (42)How could you monitor the amount of free inodes on /dev/hda3? A. inode --free /dev/hda3 B. ls -i /dev/hda3 C. du -i /dev/hda3 D. dm -i /dev/hda3 E. df -i /dev/hda3 91_LPI_Linux-praxis_1.sxw - 8

(43)You have created a new directory named /foo and now you have copied the two files bar and foobar into this new directory. Now you mount a floppy onto /foo using the command: mount /dev/fd0 /foo What happens to the two files foobar and foo if you would use the commands: rm -rf /foo/* and then umount /foo A. They are removed B. They are removed but you can restore them C. It isn't possible to mount a floppy in a non empty directory D. Nothing. They are still there E. The names appear in the directory but the inodes are deleted (44)How could you generate a report of the user quota of /home? A. repquota /home B. quotarep /home C. quota --report /home D. edquota /home E. quotaed /home (45)What command is used to change the permission mode of a file? (Just the command - no options) Type the answer. (46)What would be the default file permission modes for new files if you set umask to 022? A. 755 B. 644 C. 022 D. 220 E. 550 (47)What command is used to change group membership of a file? (Just the command - no options) Type the answer. (48)You create a hard link bar which points to the file foo. If you remove the file foo, what happens? A. The link is automaticly removed as well B. The link exists but any access would lead to an error C. The link exists and it is possible to have access to it's content D. The link is automaticly changed into a regular file with the content of foo. E. The link but not the file was removed. 91_LPI_Linux-praxis_1.sxw - 9

(49)Which directories are forced to be located on the root partition? Choose every correct answer. A. /boot B. /proc C. /usr D. /dev E. /etc (50)How could you check the integrity of a non mounted filesystem /dev/hdb7 even if it has a valid cleanflag? A. chkdsk /dev/hdb7 B. fsck /dev/hdb7 C. hdcheck --force /dev/hdb7 D. fsck -f /dev/hdb7 E. fschk -f /dev/hdb7 (51)You want to activate graphical login on your Linux box so everybody can use a secure X11. What would you do to start this service immediatly? A. Switch to the displaymanager runlevel B. Start the klogin program C. Start the xlogin program D. Start the xdm program E. Enter the number of the displaymanager runlevel in the entry of the default runlevel in /etc/inittab. (52)What kind of information would you find in the manual section 8? A. about games B. about macro packages and conventions C. about system administration commands (usually only for root) D. about file formats and conventions eg /etc/passwd E. library calls (functions within system libraries) (53)Which shell would you use for a POP3 only account on your system? A. /bin/bash B. /bin/rsh C. /bin/psh D. /bin/popsh E. /bin/false (54)The group foo has a password. Who needs to know this password? Choose every correct answer. A. Any user who is member of the group foo B. Any user who is member of the group foo but foo isn't his primary group C. Any user who is member of the group foo and wants to change his primary group to foo D. Any user who is not member of the group foo but wants permission to a file belonging to this group E. Any user who wants permission to a file belonging to this group 91_LPI_Linux-praxis_1.sxw - 10

(55)You get a mail from user bart, in which he tells you, that he can't execute a self written shell-script named foo. This script is placed in the directory /home/bart and the user's current working directory is /home/bart, too. The ls -l command shows the script and the user has execute permission. What would probably be the reason of the problem? A. A user may not execute scripts inside his home-directory B. The PATH-variable doesn't include the. entry C. A normal user may not execute shellscripts anywhere D. The environment variable EXEC is not set E. An error inside the script (56)How could you describe the following commandline? foo && bar A. The command foo is started in the background, the command bar is started in the foreground. B. The command foo and the command bar are started simultaneously. C. The command bar is only processed if the command foo leaves without error. D. The command bar is only processed if the command foo leaves with an error. E. This isn't a valid commandline 91_LPI_Linux-praxis_1.sxw - 11

Exam Linux-Praxis - 1 Answers 1. D. ls mail Bob 2. E. The commands foo and bar are started in the background, foobar is started in the foreground 3. C. unset FOO 4. C. All files in the current directory and in all included subdirectories which are smaller than 12 KByte will be copied to /tmp. 5. C. grep foo /etc/passwd cut -d: -f4 6. wc 7. D. The files /home/foo/bar and /home/bar/foo are copied into the directory /foo 8. A. Get the list of jobs using the jobs command and then use: fg jobid 9. kill 10. C. the priority of the process is lower than normal 11. C. A non uppercase letter followed by either an! or an uppercase letter 12. A. All files beginning with an uppercase letter followed by one * 13. D. fdisk -l 14. B. A user has created lots of very small files. 15. B. mount /dev/hdc7 C. mount /dev/hdc7 /usr/local D. mount /usr/local 16. A. repquota /home 17. B. Everybody who executes this file does this under the EUID of foo (EUID = Effective User ID) 18. umask 19. C. chown foo foobar 20. E. There is no way to differ between file and link 21. A. locate can find any file in the system which was created before the last call of updatedb 22. dmesg 23. A. shutdown -r now D. init 6 E. reboot 24. D. It stores a list of all directories which contain manpages. 25. B. Create a new password for him using the command "passwd paul" and tell him his new password. 26. C. gpasswd -A bar foo 27. /etc/skel 28. E. It displays every new line of the file /var/log/messages while this file is growing 29. C. The command foo redirects its output to the command tee which writes it into the file bar and sends the same further to the command foobar 30. E. This isn't a valid commandline. 31. B. MYPATH=$PATH 32. D. chown -R foobar /home/foo E. chown --recursive foobar /home/foo 33. C. grep foo /etc/passwd cut -d: -f4 34. tac 35. C. The current directory is changed to the home directory of the user foo. 36. A. Ctrl-Z 91_LPI_Linux-praxis_1.sxw - 12

37. A. Ctrl-C C. kill -9 PID D. kill PID 38. nice 39. B. sed D. grep 40. A. foo.bar foo.1bar foo.2bar C. foo.1bar foo.2bar foo.fbar 41. hdc5 42. E. df -i /dev/hda3 43. D. Nothing. They are still there 44. A. repquota /home 45. chmod 46. B. 644 47. chown and chgrp 48. C. The link exists and it is possible to have access to it's content 49. B. /proc D. /dev E. /etc 50. D. fsck -f /dev/hdb7 51. E. Enter the number of the displaymanager runlevel in the entry of the default runlevel in /etc/inittab. 52. C. about system administration commands (usually only for root) 53. E. /bin/false 54. D. Any user who is not member of the group foo but wants permission to a file belonging to this group 55. B. The PATH-variable doesn't include the. entry 56. C. The command bar is only processed if the command foo leaves without error. 91_LPI_Linux-praxis_1.sxw - 13