Showing posts with label NIC. Show all posts
Showing posts with label NIC. Show all posts

Friday, March 5, 2021

Powershell for toggling your network status

 If for whatever reason which you need to turn your network on and off oftenly in Windows, this PowerShell script may be able help you.


if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)) {
    Start-Process PowerShell -Verb RunAs "-NoProfile -ExecutionPolicy Bypass -Command `"cd '$pwd'; & '$PSCommandPath';`"";
    exit;
}
$nic = "Ethernet 2"
$adapter = Get-NetAdapter -Name $nic
if ($adapter.status -eq "Up") {
    Disable-NetAdapter -name $nic -Confirm:$False
}
else {
    Enable-NetAdapter -name $nic
}
# Read-Host -Prompt "Press any key to continue"


Wednesday, April 16, 2014

N54L and Windows 8.1

I spent whole last night wrestling with Windows 8.1 and my micro server.  it hangs at the restart after the installation.  The first thing came to my mind was the RAID setup I had, so I reinstalled my server with custom RAID driver again.  Unfortunately, the same thing happened.


Cut the long story short, at the end I found out it is actually the BIOS and the Broadcom NIC caused my problem!  As soon as I updated my bios to the latest version 2013.10.01, everything just works!


http://h20566.www2.hp.com/portal/site/hpsc/template.PAGE/public/psi/swdDetails/?sp4ts.oid=5336618&spf_p.tpst=swdMain&spf_p.prp_swdMain=wsrp-navigationalState%3Didx%253D%257CswItem%253DMTX_57720d956df94dfcbaa0e28256%257CswEnvOID%253D4168%257CitemLocale%253D%257CswLang%253D%257Cmode%253D%257Caction%253DdriverDocument&javax.portlet.begCacheTok=com.vignette.cachetoken&javax.portlet.endCacheTok=com.vignette.cachetoken