{"id":646,"date":"2024-03-20T11:58:36","date_gmt":"2024-03-20T10:58:36","guid":{"rendered":"https:\/\/www.shakral.de\/blog\/?p=646"},"modified":"2024-03-20T12:15:12","modified_gmt":"2024-03-20T11:15:12","slug":"windows-dhcp-infos-per-powershell-auslesen","status":"publish","type":"post","link":"https:\/\/www.shakral.de\/blog\/2024\/03\/20\/windows-dhcp-infos-per-powershell-auslesen\/","title":{"rendered":"Windows DHCP Infos per Powershell auslesen"},"content":{"rendered":"<p>Bei der Aufteilung von einem bestehenden Netz in verschiedene VLANs (ja, es gibt noch Situationen, in denen alles in einem einzelnen flachen Netz zuhause ist), kann ein DHCP Server wertvolle Infos liefern und will auch mit m\u00f6glichst wenig Kilometern an der Maus umgezogen werden.<\/p>\n\n\n\n<p>Seih es, um Reservierungen in einen neuen Scope umzuziehen, eine MAC-Adresse einem Host zuzuordnen oder eine dynamische VLAN-Zuordnung an einer unabh\u00e4ngigen dritten stelle zu \u00fcberpr\u00fcfen.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Powershell<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">Scopes anzeigen<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: powershell; title: ; notranslate\" title=\"\">\n Get-DhcpServerv4Scope -Computername &lt;&quot;Computername&quot;&gt;\n<\/pre><\/div>\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"787\" height=\"330\" src=\"https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-150007.jpg\" alt=\"\" class=\"wp-image-647\" srcset=\"https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-150007.jpg 787w, https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-150007-300x126.jpg 300w, https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-150007-768x322.jpg 768w\" sizes=\"auto, (max-width: 787px) 100vw, 787px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">MAC-Adresse suchen<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nGet-DhcpServerv4Scope -Computername &amp;lt;&quot;SRV-DHCP-01&quot;&gt; | Get-DhcpServerv4Lease -Computername &amp;lt;&quot;Computername&quot;&gt; -EA SilentlyContinue -ClientId &amp;lt;&quot;aa-bb-cc-dd-ee-ff&quot;&gt;\n<\/pre><\/div>\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"901\" height=\"217\" src=\"https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-151246.jpg\" alt=\"\" class=\"wp-image-649\" srcset=\"https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-151246.jpg 901w, https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-151246-300x72.jpg 300w, https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-151246-768x185.jpg 768w\" sizes=\"auto, (max-width: 901px) 100vw, 901px\" \/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">IP-Adresse suchen<\/h3>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nGet-DhcpServerv4Reservation -ComputerName &amp;lt;&quot;Computername&quot;&gt; -EA SilentlyContinue -IPAddress &amp;lt;&quot;10.08.15.xy&quot;&gt;\n<\/pre><\/div>\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"951\" height=\"147\" src=\"https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-152722.jpg\" alt=\"\" class=\"wp-image-650\" srcset=\"https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-152722.jpg 951w, https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-152722-300x46.jpg 300w, https:\/\/www.shakral.de\/blog\/wp-content\/uploads\/2023\/12\/Screenshot-2023-12-18-152722-768x119.jpg 768w\" sizes=\"auto, (max-width: 951px) 100vw, 951px\" \/><\/figure>","protected":false},"excerpt":{"rendered":"<p>Bei der Aufteilung von einem bestehenden Netz in verschiedene VLANs (ja, es gibt noch Situationen, in denen alles in einem einzelnen flachen Netz zuhause ist), kann ein DHCP Server wertvolle Infos liefern und will&#46;&#46;&#46;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[98,112,21,113],"tags":[],"class_list":["post-646","post","type-post","status-publish","format-standard","hentry","category-netzwerk","category-powershell","category-server","category-vlan-einfuehrung"],"_links":{"self":[{"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/posts\/646","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/comments?post=646"}],"version-history":[{"count":4,"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/posts\/646\/revisions"}],"predecessor-version":[{"id":657,"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/posts\/646\/revisions\/657"}],"wp:attachment":[{"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/media?parent=646"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/categories?post=646"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.shakral.de\/blog\/wp-json\/wp\/v2\/tags?post=646"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}