Skip to main content

Posts

Showing posts with the label DHCP

Windows release DHCP IP Address and get a new one

 Working remotely is quite a norm in today's pandemic world.  IT / System Admin working remotely may find it difficult or a good opportunity to work at the comfort at their own homes. Difficult in a way, when something goes wrong on a server or any device and you need a physical hand even just to force power off and turn it back on may seem an impossible task. DHCP is an amazing technology that lets machines auto configured themselves with an IP Address without human intervention. But not everything seems to work smoothly at times, and if you have multiple networks in a single manage switch. Changing one network from another makes life easier using a manage switch. However, the machine, server or computer may not change easily; you either need to reboot the machine or just simply release and renew the DHCP to set or get the desired IP Address from a new network profile. In Windows DHCP network, ipconfig /release will release the IP and the machine will be automat...

Get network interfaces description in Windows

Netsh is a command line tool that is very useful provided of course you know exactly on how to use it. Below is an example on how to display the GUID and the description of the network interface card.    netsh trace show interfaces Sample output: Ethernet adapter Ethernet:     Description:      Intel(R) I350 Gigabit Network Connection     Interface GUID:   {1C8DC74A-0BCD-48FF-F3B7-26B1FF4D5650}     Interface Index: 12     Interface Luid:   0x8000008000000 Tunnel adapter isatap.{BCF65C9D-CB58-49F7-8BA1-88DBF2A6FBCE}:     Description:      Microsoft ISATAP Adapter #3     Interface GUID:   {F8BB0A84-D5A4-CA93-BA100-27EF2898CC82}     Interface Index: 19     Interface Luid:   0x12000005000000 The GUID (globally unique identifier) is used to identify objects in Wi...

Show interface IP Address in Windows 10

Commands below work in Windows 10, I think it will also work in Windows 2012. Displaying or show IP Address in Windows is quite straight forward using ipconfig /all command. The command has the /all parameter so it will display the IP Address of all the interfaces on the machine. Display IP Address of a specific interface in Windows via command line using “netsh” tool. To display the interface IP Address you need to get the interface name. Typing the command below will show all the interface name and its state whether its connected or disconnected.      netsh interface show interface Sample output: Admin State    State          Type             Interface Name ------------------------------------------------------------------------- Enabled        Connected      ...

JunOS DHCP set MAC or static binding

How to set a static binding in JunOS? How to set a reservation of MAC address in DHCP? How to configure DHCP manual bindings? Different ways of asking on how to do but only one  specific goal, to assign an IP Address to a specific MAC or hardware. In JunOS SRX firewalls type this command: set system services dhcp static-binding 01:02:03:09:0A:0B fixed-address 192.168.1.1 IP Address of 192.168.1.1 will be assigned to a device with this MAC or hardware identifier of 01:02:03:09:0A:0B . See reference below for more details: http://www.juniper.net/documentation/en_US/junos12.1/topics/example/security-device-dhcp-server-configuring.html To do a reservation of MAC Address on Windows see below: Using Windows GUI see this link: https://technet.microsoft.com/en-us/library/dd759190.aspx The GUI instruction may change from version of the operating system but the logic on how to do it stays the same, you need to know the MAC address which will serve as an identifier s...

PowerShell get DHCP enabled NIC

How to get NICs with DHCP enabled? A one liner code to get DHCP network interfaces card and its IP Address settings.   Get-WmiObject win32_networkadapterconfiguration | where {$_.DHCPEnabled -eq “True”} To save a few more bytes used this code: gwmi win32_networkadapterconfiguration | ? {$_.DHCPEnabled -eq “True”} A quick and easy way to get DHCP enabled NICs with the help of PowerShell. Sample output: DHCPEnabled       : True IPAddress         : {192.168.11.50} DefaultIPGateway : {192.168.11.254} DNSDomain         : CiscoFW_01 ServiceName       : e1cexpress Description       : Intel(R) 82579LM Gigabit Network Connection Index             : 7 DHCPEnabled       : True IPAddress      ...

PowerShell Get files and files size

A PowerShell script that will lists or monitor files by specific date and also check the size of the file on a particular folder. It can be used to monitor newly added files and also monitor the file size. Or enter a specific date and lists the files. If a shared folder suddenly runs out of space, it's good to check which file or files are the culprit. ========================== $xfile = Get-ChildItem  -Path "D:\From XW Drive" -File | #Get the full path, file name and the creation time of the file Select-Object FullName, CreationTime | Where-Object {       #convert the creation time to string to compare dates       $xfile = $_.CreationTime.Date.Month.ToString()  + "/" + ($_.CreationTime).Date.day.ToString() + "/" +  ($_.CreationTime).Date.Year.ToString()               $xCompareDate=  "1/25/2010"     #conditional ...

Export Task Scheduler Jobs in Windows

How to export Task Scheduler jobs in Windows? Windows has provided a graphical interface to export Task scheduler job. But the graphical interface allows exporting one selected job only. It does not allow exporting more than one. Which basically means importing of task scheduler jobs, can be done one by one only. See image below on how to export a task in Windows. Where to find Task Scheduler jobs? Tasks scheduler jobs can be found on c:\windows\system32\tasks folder.   To open a particular tasks just type notepad plus the filename. The command prompt should be open at an elevated mode. It will open the job and in XML format. See image below: If you have quite a few tasks running on a server or different servers which runs different tasks job. It's gonna be fun to do it manually and I guess Microsoft expect Windows System Administrator to have some fun once in a while.   It has to be done manually al...