Главная страница

Open Source Software


Скачать 1.28 Mb.
НазваниеOpen Source Software
Дата26.05.2022
Размер1.28 Mb.
Формат файлаdocx
Имя файлаFinal_OS 2.docx
ТипДокументы
#551026
страница15 из 39
1   ...   11   12   13   14   15   16   17   18   ...   39


  • cat file1 > file2 > file3 | file4

  • cat file1 file2 file3 > file4

  • cp file1 file2 file3 > file4

  • cat file1 > file2 > file3 > file4


180) Which of the following commands can be used to view the last 15 lines of a file (Select all answers that apply)?

  • tail -15 some_file

  • tail=15 some_file

  • tail +15 some_file

  • tail -n15 some_file


181) Which of the following commands will replace all instances of the word "dog" with "pig" in the file named some_file and send the output to stdout (Select all answers that apply)?

  • sed -e s:dog:pig:g some_file

  • sed -e s/dog/pig/g some_file

  • cat some_file | sed -e s/dog/pig/g

  • sed -e s/dog/pig/ some_file


182) Which commands can be used to print the lines that contain the numbers 0–5 in a file (Select all answers that apply)?

  • grep [0-5] filename

  • grep {0-5} filename

  • grep [0,1,2,3,4,5] filename

  • grep [-e0 -e1 -e2 -e3 -e4 -e5] filename


183) Which command is used to extract columns from a file to work on them later?

  • cut

  • tee

  • tr

  • wc


184) Which of the following special environment variables is the command name?

  • $#

  • $1 $2, etc.

  • $0

  • $@


185) Functions must always be defined before they are used. True or False?

  • True

  • False

186) Which of the following commands are equivalent (Select all answers that apply)?

  • [[ -f file.c ]] && cat file.c

  • if [[ -f file.c ]] ; then cat file.c ; fi

  • if [ -f file.c ] ; then cat file.c ; fi

  • if test -f file.c ; then cat file.c ; fi

187) Which commands will list all files under the current directory ending in "

" (Select all answers that apply)? Note: Output lists may differ in format.

  • find . -name "*" -exec ls -l {} ';

  • ls -l $(find . -name "*")

  • find . -name "*" -ls

  • find . -name "*" | xargs ls -l

188) Functions (subprograms) are useful in bash scripts because (Select all answers that apply):

  • They make things easier to read and comprehend

  • They eliminate the need to retype the same set of commands more than once

  • It is better not to have to call another script to get things done


189) How would you get the value of a variable named VAR into a script?

  • ask VAR

  • accept VAR

  • input VAR

  • read VAR


190) Select the correct statement:

  • A bash function can be placed anywhere in a script, before or after it is used

  • A bash function must be placed before it is used in a script


191) The type of file is determined by examining its extension rather than content. True or False?

  • True

  • False


192) How many characters do you get at the beginning in the description of a file?

  • 3

  • 9

  • 10

  • 12


193) "666" permission means:

  • read-write permission for all users

  • write-execute permission for all users

  • read-execute permission for all users

  • read-write-execute permission for all users


194) Which statement is correct?

  • In Linux, file types are rarely determined by extension letters

  • In Linux, file types are never determined by extension letters

  • In Linux, file types are always determined by extension letters


195) If the first character in the long file listing is a "-", the listed object is a:


  • Symbolic (Soft) Link

  • Block Device Node

  • Unix Domain Socket

  • Directory

  • Normal File

  • Named Pipe (FIFO)

  • Character Device Node


196) If the first character in the long file listing is an "s", the listed object is a:

  • Block Device Node

  • Character Device Node

  • setuid file

  • Named Pipe (FIFO)

  • Unix Domain Socket

  • Symbolic (Soft) Link


197)Which of the following commands are equivalent (Select all answers that apply):

  • chown 664 file

  • chown donald.ducks file

  • chown donald file ; chgrp ducks file

  • chown donald:ducks file

198) Which command will give all users the right to look at a file, but give only the owner the right to change it or execute it:

  • chmod 644 some_file

  • chmod 764 some_file

  • chmod 744 some_file

  • chmod 467 some_file


199) Which of the following is true about journaling filesystems?

  • A transaction must be completed without error, otherwise the filesystem is changed

  • Operations are grouped into transactions

  • They recover quickly from system crashes and ungraceful shutdowns but become corrupted


200) Which of the following commands can be used to see what filesystems your system currently understands?

  • cat /proc/filesystems

  • cat /filesystems

  • /proc/filesystems

  • cat /sys/filesystems


201) Which of the following statements are true for Logical Volume Management (Select all answers that apply):

  • LVM makes it easy to change the size of the logical partitions and filesystems

  • There can be some changes in performance with LVM

  • LVM supports various graphical interfaces

  • Using LVM breaks up one virtual partition into multiple chunks


202) What command would create a new logical volume named mylv of size 256 GB in volume group VG ?

  • lvextend -L+16G /dev/VG/myv

  • lvcreate -L 256 mylv VG

  • lvcreate -L 256G -n mylv VG


203) Which of the following are journaling filesystems (Select all answers that apply):

  • ext4

  • squashfs

  • XFS

  • btrfs

  • vfat

  • VFS


204) For a filesystem to be mounted at boot:

  • It must be mentioned in the mounting scripts in /etc/init.d

  • It must be listed in /etc/fstab

  • It must be listed in /proc/filesystems

  • It must be listed in /etc/mounts



205) When mounting a filesystem, it may be specified by any of the following methods (Select all answers that apply):

  • Kernel configuration option

  • Label

  • UUID

  • Alias mentioned in .bashrc

  • Device node


206) LVM stands for:

  • Little Virtual Murders

  • Logical Volume Management

  • Large Volatile Memory

  • Last Memory Vanished


207) Loopback filesystems (Select all answers that apply):

  • Have slower performance than just having a native filesystem

  • Are never used in production systems

  • Can be useful for testing filesystem features


208) Which of the following statements are correct about gcc (Select all answers that apply):

  • It compiles programs written in a number of languages

  • Its name stands for GNU Compiler Collection

  • There are only some operating systems that offer versions of gcc.


209) gdb can properly debug multi-threaded programs. True or False?

  • True

  • False


210) GCC stands for:

  • Geneva Computation Corporation

  • Great Computer Compiler

  • GNU Compiler Collection

  • GNU Compiler for C


211) A good choice of compiler options for day-to-day use would be:

  • gcc -M -H -O3 -E program.c

  • gcc -O2 -Wall -pedantic program.c

  • gcc -Wall -I /tmp/include -L /tmp/lib program.c

  • gcc -O0 -Wall -ansi program.c


212) Why might you choose to link your program statically, rather than use a shared library version?


  • The static program will not use new versions of shared libraries as they become available, and thus may avoid breakage and bugs

  • The static program will load and execute more quickly

  • The static program need not have an open source license, while the shared library version cannot be closed source

  • The static program will use less memory

213) To find the shared libraries used by /usr/bin/cp you can do (Select all answers that apply):

  • ldd /usr/bin/cp

  • find -libso /usr/bin/cp

  • gcc -ldd /usr/bin/cp

  • ldd $(which cp)


214) Which statements are true (Select all answers that apply):

  • Use of shared libraries can cause bugs because the application may conflict with the new library version

  • Use of shared libraries enables applications to stay up to date with new library features without being recompiled

  • Use of shared libraries saves memory

  • Applications can load faster when using shared libraries


215) The concept of Write Once, Run Anywhere works better on the client side than on the server side. True or False?

  • True

  • False


216) Which of the following is true for Eclipse?

  • It has been used primarily for Java projects, but it also supports a number of other languages

  • It has been an open source project since 2010

  • Eclipse Public License is fully compatible with the GPL license

  • It can be traced back to 2001


217) Which of the following statements are true (Select all answers that apply)?

  • Porting Java programs to Linux requires specialized expert input

  • Java programs developed on other systems can be expected to run without modification on Linux

  • The biggest problem in porting Java code to Linux is often fear

  • There are a number of choices which can be used for the Java implementation on Linux machines, and one can switch between them

  • Java programs need to have some changes to the source before they can run reliably on Linux systems


218) Which utility can be used to select the default Java Implementation on a Linux system?

  • setpref

  • which

  • choose

  • alternatives


219) Which commands will show you information about which version of Java you are running (Select all answers that apply):

  • java -version

  • select --show java

  • version --full java

  • $ readlink -f $(which java)

220) Which of the following are Integrated Development Environments that can be used for Java on Linux (Select all answers that apply)?

  • Eclipse

  • emacs

  • DDD

  • gdb

  • NetBeans


221) If you are experienced in using Eclipse on another operating system, when moving to Linux:

  • The interface and functioning should be almost the same and have little or no learning curve required

  • You will have to start over, as the interface and functioning are rather different


222) Which of the following are packaging system benefits for developers (Select all answers that apply)?

  • Integrity of the installation can be verified in a uniform and rapid fashion

  • Repeatable builds

  • Generation of dependency data, such as what other packages are needed by a given package, and/or what other packages may need a given package

  • Simple installation and removal methods


223) You have to be a superuser to build a binary RPM package on CentOS and openSUSE. True or False?

  • True

  • False


224) Use of a package management system (Select all true statements):

  • Simplifies upgrade and update of individual software packages, as well as the system

  • Is rapidly going obsolete, as disk space becomes larger and cheaper

  • Makes removing software difficult

  • Makes updating slow, as one always has to recompile from source


225) Which of the following distributions use the RPM package management system (Select all answers that apply)?

  • Ubuntu

  • SUSE

  • Red Hat

  • Fedora

  • CentOS

  • Gentoo

  • Debian


226) Which of the following distributions use the APT (dpkg) package management system (Select all answers that apply)?

  • Debian

  • Ubuntu

  • Linux Mint

  • CentOS

  • Gentoo

  • Red Hat

  • SUSE


227) With RPM, all information to configure, compile and install is contained in:

  • The build file

  • The rpm manifest

  • The spec file

  • The yum file


228) Which of the following statements are true (Select all answers that apply)?

  • The source package contains one file in Debian-based systems

  • The source package contains one file in RPM-based systems

  • The source package contains multiple files in RPM-based systems

  • The source package contains multiple files in Debian-based systems



1) Which of the following are some of the major milestones in the history of open source software?

  • The Free Software Foundation

  • The Release of Microsoft Windows

  • The creation of the Linux operating system

  • The birth of Ubuntu

2) What are the three general governance models used in open source projects? Select all answers that apply.

  • Company-led

  • Benevolent dictatorship

  • Private-collective

  • Governing board

3) What are the main types of Open Source Software (OSS) licenses? Select all answers that apply.

  • Free of charge

  • Permissive

  • Proprietary

  • Educational use

  • Restrictive

4) Linux began:

  • In 1998 when IBM made a major investment

  • When UNIX was first born about 1969

  • When SCO ported Xenis to the Intel 8036 processor in 1983

  • In 1991 with an Internet post by a student in Finland

5) Which method best describes the way Android is developed?

  • Company-Led

  • Benevolent Dictatorship

  • Governing Board

6) Which method best describes the way FreeBSD is developed?

  • Benevolent Dictatorship

  • Governing Board

  • Company-Led

7) Which method best describes the way Linux kernel is developed?

  • Benevolent Dictatorship

  • Company-Led

  • Governing Board

8) What are some of the advantages of open source software development? Select all answers that apply.

  • Stronger and more secure code

  • Developers have the means to build better software

  • Potentially faster bug repairs

  • Reduced costs


9) From a business perspective, use of OSS (Select all answers that apply):

  • Lengthens time to make, but is worth it because of improved product

  • Enables use of ingredients from other sources and speeds development

  • Makes marketing more difficult because it is hard to differentiate product

  • Makes marketing easier as some ingredients are already well-known and trusted

10) OSS is (Select all answers that apply):

  • Insecure because no one is in charge of security

  • Causes security problems because developers come from different organizations and companies and do not understand each other's code

  • Can be more secure because many developers can easily see the code, look for problems, and mitigate problems when they are discovered

  • Secure or insecure depending on the quality and priorities of the project maintainers, but at least users can judge this by open discussion and code inspection

11) For school systems at any level, use of OSS (Select all answers that apply):

  • May cause problems with vendor lock-in

  • Can lower costs by letting low-cost or free software be used

  • Should be avoided, as students become confused by choices

  • Can lower costs by letting older hardware be used

12) School systems can benefit from using OSS because (Select all answers that apply):
1   ...   11   12   13   14   15   16   17   18   ...   39


написать администратору сайта