aoza wrote: Again this issue happens only when my vm disk is stored in external hdd. If I keep it on same laptop, it works fine.
There can be no "Again", because you did not mention the "work/no-work depending on the drive used" issue in your first post. You only said the guest was on an external drive, no mention of another test on an internal drive.
To get good help, in addition to Bill's advice to relate details more than "didn't work", please tell the whole story. Further:
Already tried that
Already tried what? There were two suggestions for network settings.
The location of the guest's disk on the host drives, internal or external, has nothing to do with whether ping goes through on NAT or not. Two entirely different situations. Unless you usage of the term "VM disk" or "image" is different that what we use those terms for.
A guest consists, at the least, of a .vbox xml file and a virtual disk file. It is possible, though not recommended, for the .vbox file to be on one host disk and the virtual disk file to be on another disk. If you have your .vbox file on your host and are bouncing your virtual disk file between the internal drive and external drive, that's one scenario. How moving the virtual disk between internal and external drives changes ping behavior is beyond me. If, though, you have a .vbox file and virtual disk on an internal drive, and a different .vbox file and virtual disk on the external drive, then you are really running two different guests, and each guest can have very different settings that can make both-ways-ping work on one guest and not on the other.
Start the guest under the condition where both-ways-ping works. Run a few pings both ways. Then shut down the guest and post a zipped log marked as "ping working" here.
Start the guest again under the condition where both-ways-ping does not work. Attempt to run a few pings both ways. Then shut down the guest and post a zipped log marked as "ping failing" here.