Windows : Adding Multiple IP Addresses at Once

In Microsoft Windows Server Environment :
We use netsh with FOR loop for quickly add IP to windows system
FOR /L %variable IN (start,step,end) DO command

So we could easily add every IP address from an entire subnet using this command:

FOR /L %A IN (0,1,255) DO netsh interface ipv4 add address “Local Area Connection” 192.168.1.%A

Leave a Reply

Your email address will not be published. Required fields are marked *