12

What is the loopback interface and how does it differ from the eth0 interface?

And why do I need to use it when mounting an ISO or running a service on localhost?

1 Answer 1

17

The loopback networking interface is a virtual network device implemented entirely in software. All traffic sent to it "loops back" and just targets services on your local machine.

eth0 tends to be the name of the first hardware network device (on linux, at least), and will send network traffic to remote machines. You might see it as en0, ent0, et0, or various other names depending on which OS you're using at the time. (It could also be a virtual device, but that's another topic)

The loopback option used when mounting an ISO image has nothing to do with the networking interface, it just means that the mount command has to first associate the file with a device node (/dev/loopback or something with a similar name) before mounting it to the target directory. It "loops back" reads (and writes, if supported) to a file on an existing mount, instead of using a device directly.

2
  • 1
    It would nice to add an example of actual example usage of mounting an iso using the loopback interface. I just got to this question by googling "iso loopback interface". Mar 28, 2011 at 21:19
  • 6
    Just to clarify, the "loopback" option to mount (which creates a "loopback device" for a given file, as you can do with "losetup) is not related with networking.
    – jjmontes
    Dec 26, 2012 at 17:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .