Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Suppose I have following entry in hosts.cfg file:

1.2.3.4 test # foo machine

I start script that every second call ping test and cat \\test\share\machine-name.txt

Script output: IP: 1.2.3.4; machine name: foo

Then I change hosts.cfg to following:

1.2.3.5 test # bar machine

Now script output is following: IP: 1.2.3.5; machine name: foo # bar is expected!

Problem: \\test\share\machine-name.txt still points to old location

I've found only one solution how to resolve this problem: restart LanmanWorkstation service. But the problem with LanmanWorkstation service is that it takes too much time to restart and sometimes it completely hangs on stop operation.

Question: how to clear/reset Windows SMB cache? Something like ipconfig /flushdns

Thanks

share|improve this question

1 Answer 1

is it possible that they're being stored in the NetBios Resolver Cache?

To check try:

nbtstat -c

if that turns out to be the problem, the following will restart it.

nbtstat -R
share|improve this answer
    
Unfortunately it is not NetBios Resolver Cache issue –  Roman Nov 3 '11 at 16:38

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.