1

When I copy Windows binaries like ping or netstat to a different location on the machine I can't get any output.

Example:

>C:\Windows\System32\ping.exe 127.0.0.1

Pinging 127.0.0.1 with 32 bytes of data:
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128

Ping statistics for 127.0.0.1:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 0ms, Maximum = 0ms, Average = 0ms

>copy C:\Windows\System32\ping.exe n_ping.exe
        1 file(s) copied.

>n_ping.exe 127.0.0.1

>n_ping.exe 127.0.0.1 > test.out

>type test.out

>move n_ping.exe ping.exe

>.\ping.exe 127.0.0.1

>

Issue:

No output from n_ping command, but I see ICMP traffic in Wireshark.


Is there a way to get output from binaries like ping and netstat running outside of Windows folder?

4d4c
  • 111
  • 5
  • 1
    Possibly related: [Why is DNS apparently involved in issuing “dir” on Windows 10?](https://superuser.com/q/1524172/194694) – gronostaj Jun 16 '20 at 12:16
  • From help "You should only ask practical, answerable questions based on actual problems that you face." What is your actual problem? Why are you copying and renaming these files? – DavidPostill Jun 16 '20 at 17:17
  • @gronostaj, thanks. it worked. Needed to create the "en-US" folder in the same folder from where I'm running the binary – 4d4c Jun 17 '20 at 22:54

1 Answers1

0

Solved by creating en-US folder with mui files in the same folder where binary is executed (thanks to @gronostaj - Why is DNS apparently involved in issuing "dir" on Windows 10?)

>mkdir en-US

>copy %windir%\System32\en-US\ping.exe.mui .\en-US\
        1 file(s) copied.

>.\ping.exe 127.0.0.1

Pinging 127.0.0.1 with 32 bytes of data:
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128

Ping statistics for 127.0.0.1:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 0ms, Maximum = 0ms, Average = 0ms
4d4c
  • 111
  • 5