Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

If I share a file which is i.e. located at C:\share\somefile.txt to the network what happens when I call it on my computer this way \\MYCOMPUTER-PC\share\somefile.txt. Does the communication flow over the network or does the OS recognize the file I want access is locally stored and goes through the file system without using the network?

In short:

There is a file: C:\share\somefile.txt shared to the network.

Does the OS make a difference between this call C:\share\somefile.txt and this \\MYCOMPUTER-PC\share\somefile.txt when it's executed on the same computer it got shared from to the network?

share|improve this question

1 Answer 1

It's going through the OS network stack, but that doesn't mean it's actually going over the wire to your router and back. To check, you need to:

$ nbtstat -a MYCOMPUTER-PC

That should indicate what the IP address your computer has. Then, check the routing table with:

$ route print

To determine what interface that IP address is going over. If it's the localhost 127.0.0.1 interface, the OS will route it itself, otherwise, I believe it is going to the router and back.

share|improve this answer
    
The packets will not be send over the wire. If Windows sees that the destination address is the address of one of Windows' own NICs, then Windows will just move the packet around inside memory but not send it over the wire (why should it do so?). –  Werner Henze Aug 7 '13 at 11:34
    
That was my question. Why shouldn't it do so? Maybe because of bad implementation or other reasons which I don't know. But do you have any prove for your statement? –  arminb Aug 7 '13 at 20:16

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.