CompTIA Exam Questions

What would happen if you ran rm foo?

You have read/write permission on an ordinary file foo. You have just run In foo bar. What would
happen if you ran rm foo?

A.
foo and bar would both be removed.
Soft link Can create for directory also, can span multiple pratations but available until and
unless Original Files remain.
Syntax for Soft link In-soriginalfile linkfile
b . Hardlink Can separate Physical File, can’t create for directory, can’t span multiple file but
remains the link file if original file removed.
Syntax for Hardlink In originalfile linkfile
In Questions, created the bar hardlink of foo. That means bar is on separate physical file. The file
bar is accessible after removing the foo file also.
QUESTION 10
Which of the following commands will change all CR-LF pairs in an imported text file, userlist.txt, to
Linux standard LF characters and store it as newlist.txt?
tr ‘\r\n'” < userlist.txt > newlisttxt

B.
foo would be removed while bar would remain accessible.
tr -c ‘\n\r'” < newlist.txt > userlist.txt

C.
foo would beremoved, bar would still exist but would be unusable.
tr -d V < userlist.txt > newlisttxt

D.
Both foo and bar would remain accessible.
tr V V userlist.txt newlist.txt

E.
You would be asked whether bar should be removed.
tr-s /AM’ /AJ’ userlist.txt newlist.txt

A.
foo and bar would both be removed.
Soft link Can create for directory also, can span multiple pratations but available until and
unless Original Files remain.
Syntax for Soft link In-soriginalfile linkfile
b . Hardlink Can separate Physical File, can’t create for directory, can’t span multiple file but
remains the link file if original file removed.
Syntax for Hardlink In originalfile linkfile
In Questions, created the bar hardlink of foo. That means bar is on separate physical file. The file
bar is accessible after removing the foo file also.
QUESTION 10
Which of the following commands will change all CR-LF pairs in an imported text file, userlist.txt, to
Linux standard LF characters and store it as newlist.txt?
tr ‘\\r\\n'” < userlist.txt > newlisttxt

A.
foo and bar would both be removed.
Soft link Can create for directory also, can span multiple pratations but available until and
unless Original Files remain.
Syntax for Soft link In-soriginalfile linkfile
b . Hardlink Can separate Physical File, can’t create for directory, can’t span multiple file but
remains the link file if original file removed.
Syntax for Hardlink In originalfile linkfile
In Questions, created the bar hardlink of foo. That means bar is on separate physical file. The file
bar is accessible after removing the foo file also.
QUESTION 10
Which of the following commands will change all CR-LF pairs in an imported text file, userlist.txt, to
Linux standard LF characters and store it as newlist.txt?
tr ‘\\\\r\\\\n'” < userlist.txt > newlisttxt

B.
foo would be removed while bar would remain accessible.
tr -c ‘\\n\\r'” < newlist.txt > userlist.txt

C.
foo would beremoved, bar would still exist but would be unusable.
tr -d V < userlist.txt > newlisttxt

D.
Both foo and bar would remain accessible.
tr V V userlist.txt newlist.txt

E.
You would be asked whether bar should be removed.
tr-s /AM’ /AJ’ userlist.txt newlist.txt

Explanation:
Correct Answer is B. The In command is used to create the link. There are two types of link a. Soft
link b. Hard link.