exam questions

Exam LX0-103 All Questions

View all questions & answers for the LX0-103 exam

Exam LX0-103 topic 4 question 1 discussion

Actual exam question from CompTIA's LX0-103
Question #: 1
Topic #: 4
[All LX0-103 Questions]

After successfully creating a hard link called bar to the ordinary file foo, foo is deleted from the filesystem. Which of the following describes the resulting situation?

  • A. foo and bar would both be removed.
  • B. foo would be removed while bar would remain accessible.
  • C. foo would be removed. bar would still exist but would be unusable.
  • D. Both foo and bar would remain accessible.
  • E. The user is prompted whether bar should be removed, too.
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
linux_admin
2 years, 2 months ago
If a hard link bar is created for an ordinary file foo, and then foo is deleted from the filesystem, the data and metadata associated with the file will remain on the filesystem, and the hard link bar will still be valid. When a hard link is created, it simply creates another name (i.e., another directory entry) for the same file on the filesystem. Both the original file and the hard link(s) reference the same data blocks and inode, which contain the file's content and metadata. Deleting the original file foo does not actually remove the data or inode from the filesystem; it simply removes one of the directory entries that points to it. As long as at least one hard link to the file remains on the filesystem (in this case, the hard link bar), the file's data and metadata will continue to exist.
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago