Home > Networking, Windows Server 2012, Windows Server 2012 R2 > How to enable Ping in Windows Server 2012

How to enable Ping in Windows Server 2012

November 20, 2012 Leave a comment Go to comments


Updated 2013-02-04 – Added link menu and corrected PowerShell command syntax

This is just a quick guide to enabling a server to respond to ping, the default setting in Windows Server 2012 is to not respond. This is how you do it:

The exact same steps apply to Windows Server 2012 R2

-

Click to choose your style…
Server2012_Logo_small Enable Ping using the GUI – Graphical User Interface
powershell_logo_small Enable Ping using PowerShell


-
-
GUI – Graphical User Interface

1. Open Control Panel, then select System and Security by clicking on that header

-

-

2. Select Windows Firewall

-

-

3. Advanced Settings

-

-

4. In ‘Windows Firewall with Advanced security’ click on ‘Inbound rules’

-

-

5. Scroll down to ‘File and Printer sharing (Echo request – ICMPv4-In)

-

-

6. Rightclick on the rule and select ‘Enable rule’

-

-

Make sure that it turns green

Done, close down the ‘Windows Firewall with Advanced Security’ windows and then the Control panel.
Verify functionality by pinging the servers own IP address from a command or PowerShell prompt.

Done!
Back to top

-
-
PowerShell
(This will enable the existing rule exactly as the instruction above does)

Import-Module NetSecurity
Set-NetFirewallRule -DisplayName “File and Printer Sharing (Echo Request – ICMPv4-In)” -enabled True
 
EnablePing

(ABove enables the existing rule, below will create a new rule that allows ICMPv4/Ping and enable it)

Import-Module NetSecurity
New-NetFirewallRule -Name Allow_Ping -DisplayName “Allow Ping”  -Description “Packet Internet Groper ICMPv4″ -Protocol ICMPv4 -IcmpType 8 -Enabled True -Profile Any -Action Allow
 
EnablePing2

(For IPv6 Ping you obviously enable the v6 Inbound Rule…)

Thats all there is to it!
Back to top

-

-

_________________________________________________________

Enjoy!

Regards

Twitter | Technet Profile | LinkedIn

About these ads
  1. bill
    March 11, 2013 at 13:07

    Thanks mate helped a lot….

  2. April 21, 2013 at 13:15

    It looks like the name giving is wrong… for File and Printer sharing

    PS C:\> Set-NetFirewallRule -DisplayName “File and Printer Sharing (Echo Request – ICMPv4-In)” -enabled True
    Set-NetFirewallRule : No MSFT_NetFirewallRule objects found with property ‘DisplayName’ equal to ‘File and Printer Shar
    ing (Echo Request – ICMPv4-In)’. Verify the value of the property and retry.
    At line:1 char:1
    + Set-NetFirewallRule -DisplayName “File and Printer Sharing (Echo Request – ICMPv …
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : ObjectNotFound: (File and Printe…st – ICMPv4-In):String) [Set-NetFirewallRule], CimJob
    Exception
    + FullyQualifiedErrorId : CmdletizationQuery_NotFound_DisplayName,Set-NetFirewallRule

    • April 21, 2013 at 14:39

      Hi.
      Works for me, check the quotes, if you copy them frim here they will become the wrobg ones.
      Regards

  3. glenn929
    June 6, 2013 at 02:40

    it didn’t work because it has -Enabled where it should be just -Enable :)

  4. steve
    June 20, 2013 at 21:48

    Any easy way to do this on Server 2008r2 that doesn’t have the new powershell modules like NetSecurity?

    • June 20, 2013 at 22:03

      Hi.
      Simply add the registry key…
      Dont know of a way to script it.
      Regards // Thomas

  5. Dan
    June 21, 2013 at 16:30

    Nice!! Thx

  6. Odot
    September 18, 2013 at 18:24

    Thank you, quick and easy solution

  7. Navan
    September 27, 2013 at 09:24

    Thanks It helped me

  8. Davo
    January 16, 2014 at 04:09

    Nice, Quick, and Easy! Thanks mucho!

  9. Matt
    April 16, 2014 at 09:33

    Thanks

  1. July 30, 2013 at 15:18
  2. May 25, 2014 at 17:36

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

Join 203 other followers

%d bloggers like this: