Examen 101 - LPI Chapter 4,5: Managing Files (31 de 50)

Descrição

Se aprueba con 31 preguntas como minimo.
Carlos Alberto Jara Alva
Quiz por Carlos Alberto Jara Alva, atualizado more than 1 year ago
Carlos Alberto Jara Alva
Criado por Carlos Alberto Jara Alva quase 7 anos atrás
151
0

Resumo de Recurso

Questão 1

Questão
You type mkdir one/two/three and receive an error message that reads, in part, No such file or directory. What can you do to overcome this problem? (Select two.)
Responda
  • Add the --parents parameter to the mkdir command.
  • Issue three separate mkdir commands: mkdir one, then mkdir one/two, and then mkdir one/two/three.
  • Type touch /bin/mkdir to be sure the mkdir program file exists.
  • Type rmdir one to clear away the interfering base of the desired new directory tree.
  • Type mktree one/two/three instead of mkdir one/two/three.

Questão 2

Questão
Typing ls -ld wonderjaye reveals a symbolic file mode of drwxr-xr-x. Which of the following are true? (Select two.)
Responda
  • wonderjaye is a symbolic link.
  • wonderjaye is an executable program.
  • wonderjaye is a directory.
  • wonderjaye has its SUID bit set.
  • wonderjaye may be read by all users of the system.

Questão 3

Questão
When should programs be configured SUID root?
Responda
  • At all times. This permission is required for executable programs.
  • Whenever a program should be able to access a device file.
  • Only when they require root privileges to do their job.
  • Never. This permission is a severe security risk
  • Whenever the program file is owned by the root user.

Questão 4

Questão
You see the usrquota and grpquota options in the /etc/fstab entry for a filesystem. What is the consequence of these entries?
Responda
  • Quota support will be available if it’s compiled into the kernel; it will be automatically activated when you mount the filesystem.
  • User quotas will be available, but the grpquota option is invalid and will be ignored.
  • Quota support will be disabled on the filesystem in question.
  • Nothing. These options are malformed and so will have no effect
  • Quota support will be available if it’s compiled into your kernel, but you must activate it with the quotaon command.

Questão 5

Questão
Which of the following commands can be used to summarize the quota information about all filesystems?
Responda
  • repquota
  • repquota -a
  • quotacheck
  • quotacheck –a
  • edquota -a

Questão 6

Questão
Which of the following file-location commands is likely to take the most time to find a file that may be located anywhere on the computer (assuming the operation succeeds)?
Responda
  • The find command.
  • The locate command.
  • The whereis command.
  • The type command.
  • They’re all equal in speed.

Questão 7

Questão
What can the type command do that whereis can’t?
Responda
  • Identify the command as being for x86 or x86-64 CPUs
  • Locate commands based on their intended purpose, not just by name
  • Identify a command as an alias, internal command, or external command
  • Assist in typing a command by finishing typing it for you
  • Identify a command as being a binary or a script

Questão 8

Questão
What can you conclude from the following interaction? $ which man /usr/bin/man
Responda
  • The only file called man on the computer is in /usr/bin.
  • The /usr/bin/man program was installed by system package tools.
  • The /usr/bin/man program will be run by any user who types man.
  • The first instance of the man program, in path search order, is in /usr/bin.
  • The user man owns the /usr/bin/man program file.

Questão 9

Questão
Which one of the following commands copies files with the .txt extension from /dir into /dir2, while preserving file attributes such as dates?
Responda
  • mv --copy /dir1/*.txt /dir2
  • mv /dir1/*.txt /dir2
  • cp -k /dir1/*.txt /dir2
  • cp -p /dir1/*.txt /dir2
  • cp -p /dir2 < /dir/*.txt

Questão 10

Questão
Which one of the following file globs matches "Linux" and "linux", but not "linux.com" and not "TurboLinux"?
Responda
  • [L/linux]
  • ?inux
  • \L\linux
  • [Ll]inux
  • [Ll]inux?

Questão 11

Questão
Which one of the following outcomes results from the following command? #chmod g+s /home/software
Responda
  • The SUID bit will be set for /home/software
  • The SGID bit will be set for /home/software, preventing access by those not a member of the software group.
  • The SGID bit will be set for /home/software, in order to keep group membership of the directory consistent for all files created.
  • The sticky bit will be set for /home/software
  • The sticky bit will be applied to all files in /home/software.

Questão 12

Questão
Which one of the following commands versosely extracts files from a tar archive on a magnetic tape device?
Responda
  • tar cvf /dev/st0
  • tar cvf /dev/ttyS0
  • tar xvf /dev/st0
  • tar xvf /dev/ttyS0
  • tar rvf /dev/st0

Questão 13

Questão
Which command can be used to quickly tell you if an executable command is in any directory defined in your $PATH environment variable?
Responda
  • find
  • locate
  • which
  • who
  • what

Questão 14

Questão
Which directory, according to he Filesystem Hierarchy Standard, is designed to hold essential system binaries?
Responda
  • /sbin
  • /bin
  • /usr/bin
  • /opt/bin
  • /usr/local/bin

Questão 15

Questão
According to the Filesystem Hierarchy Standard, what directory (or directories) must hold the system kernel? (Select two)
Responda
  • /boot
  • /
  • /opt
  • /sbin
  • /kernel

Questão 16

Questão
What command(s) can be used to copy data to and from raw devices, bypassing the filesystem? (Select two)
Responda
  • cp
  • tar
  • dd
  • mv
  • sed

Questão 17

Questão
A user accidentally created the subdirectory \dir in his home directory. Which of the following commands will remove that directory?
Responda
  • rmdir '~/\dir'
  • rmdir "~/\dir"
  • rmdir ~/'dir'
  • rmdir ~/\dir
  • rmdir ~/\\dir

Questão 18

Questão
Which of the following commands can be used to locate programs and their corresponding man pages and configuration files?
Responda
  • dirname
  • which
  • basename
  • query
  • whereis

Questão 19

Questão
In compliance with the FHS, in which of the directories are man pages found?
Responda
  • /usr/share/man
  • /opt/man
  • /usr/doc/
  • /var/pkg/man
  • /var/man

Questão 20

Questão
Which of the following commands displays the contents of a gzip compressed tar archive?
Responda
  • gzip archive.tgz | tar xvf -
  • tar ztf archive.tgz
  • gzip -d archive.tgz | tar tvf -
  • tar cf archive.tgz

Questão 21

Questão
Which of the following commands will send output from the program myapp to both standard output (stdout) and the file file1.log?
Responda
  • cat < myapp | cat > file1.log
  • myapp 0>&1 | cat > file1.log
  • myapp | cat > file1.log
  • myapp | tee file1.log
  • tee myapp file1.log

Questão 22

Questão
Which of the following commands will change the quota for a specific user?
Responda
  • edquota
  • repquota
  • quota -e
  • quota

Questão 23

Questão
Which of the following file permissions belong to a symbolic link?
Responda
  • -rwxrwxrwx
  • +rwxrwxrwx
  • lrwxrwxrwx
  • srwxrwxrwx

Questão 24

Questão
What is the output of the following command? #echo "Hello World" | tr -d aieou
Responda
  • Hello World
  • eoo
  • Hll Wrld
  • eoo Hll Wrld

Questão 25

Questão
In a nested directory structure, which find command line option would be used to restrict the command to searching down a particular number of subdirectories?
Responda
  • -dirmax
  • -maxdepth
  • -maxlevels
  • -n
  • -s

Questão 26

Questão
Which of the following commands will NOT update the modify timestamp on the file /tmp/myfile.txt?
Responda
  • file /tmp/myfile.txt
  • echo "Hello" >/tmp/myfile.txt
  • sed -ie "s/1/2/" /tmp/myfile.txt
  • echo -n "Hello" >>/tmp/myfile.txt
  • touch /tmp/myfile.txt

Questão 27

Questão
What does the ? symbol within regular expressions represent?
Responda
  • Match the preceding qualifier one or more times
  • Match the preceding qualifier zero or more times.
  • Match the preceding qualifier zero or one times.
  • Match a literal ? character.

Questão 28

Questão
Which of the following commands prints all files and directories within the /tmp directory or its subdirectories which are also owned by the user root? (Choose TWO correct answers.)
Responda
  • find /tmp -uid root -print
  • find -path /tmp -uid root
  • find /tmp -user root -print
  • find /tmp -user root
  • find -path /tmp -user root print

Questão 29

Questão
Which of the following commands changes the ownership of file.txt to the user dan and the group staff?
Responda
  • chown dan/staff file.txt
  • chown dan:staff file.txt
  • chown -u dan -g staff file.txt
  • chown dan -g staff file.txt

Questão 30

Questão
Which of the following commands makes /bin/foo executable by everyone but writable only by its owner?
Responda
  • chmod u=rwx,go=rx /bin/foo
  • chmod o+rwx,a+rx /bin/foo
  • chmod 577 /bin/foo
  • chmod 775 /bin/foo

Questão 31

Questão
Which of the following commands can be used to display the inode number of a given file?
Responda
  • inode
  • ls
  • ln
  • cp

Questão 32

Questão
Which of the following commands are common Linux commands for file management? (Choose three correct answers.)
Responda
  • copy
  • mv
  • move
  • cp
  • mkdir

Questão 33

Questão
Which of the following commands can be used to create a new file that is 100kB in size?
Responda
  • dd
  • file
  • mkfile
  • touch

Questão 34

Questão
In compliance with the FHS, in which of the following directories are documentation files found?
Responda
  • /usr/share/documentation
  • /usr/local/share/documentation
  • /var/share/doc
  • /usr/share/doc
  • /etc/share/doc

Questão 35

Questão
Which chown command will change the ownership to dave and the group to staff on a file named data.txt?
Responda
  • chown dave/staff data.txt
  • chown –u dave –g staff data.txt
  • chown --user dave --group staff data.txt
  • chown dave:staff data.txt

Questão 36

Questão
Which of the following is the GRUB 2 boot loader configuration file?
Responda
  • /dev/grub
  • The MBR
  • /boot/grub/grub.conf
  • /boot/grub/grub.cfg
  • /boot/grub/menu.lst

Questão 37

Questão
What program do you use to start or stop services when using the systemd initialization process?
Responda
  • journalctl
  • systemctl
  • init
  • service
  • systemd

Questão 38

Questão
What is an advantage of vi over graphical text editors?
Responda
  • vi is X based, so it is easier to use than other graphical text editors.
  • vi encodes text in EBCDIC, which is more flexible than Emacs’s ASCII.
  • vi’s mode-based operations permit it to handle non-English languages.
  • vi includes a built-in web browser and email client; Emacs doesn’t.
  • vi is smaller, so it can fit on compact emergency USB flash drive systems and embedded devices.

Questão 39

Questão
How do you exit vi’s insert mode to type command-mode commands?
Responda
  • Press the ~ key.
  • Press the Esc key.
  • Press Ctrl+X followed by Ctrl+C.
  • Press the F10 key.
  • Press the Shift+Insert key combination.

Questão 40

Questão
What line in /etc/inittab would indicate that your default runlevel is 5?
Responda
  • ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
  • id:5:initdefault:
  • si:5:sysinit:/etc/init.d/rcS
  • l5:5:wait:/etc/init.d/rc 5
  • 1:2345:respawn:/sbin/getty 38400 tty1

Semelhante

Geometria Plana
Bruno Fernandes3682
10 DICAS SOBRE TECNOLOGIA EDUCATIVA
Cristinamba
Blocos econômicos
Ighor Ferreira
Phrasal Verbs - Inglês #1
Eduardo .
Simulado Inglês
Marina Faria
Física: Mecânica - Cinemática
GoConqr suporte .
A Matemática
linmoniz
Contabilidade Geral
Leonardo Lisboa
Palavras novas pro TOEFL
Jéssica Westphal
Questionário 1 - Introdução à Informática
Ederval Pablo Ferreira
FLUXOGRAMA PARA ATENDIMENTO E ACOMPANHAMENTO ACIDENTE COM EXPOSICAO A MATERIAL BIOLÓGICO (AEMB)
Hyago Connor