I gave my father-in-law a linksys router we weren’t using any more. Unfortunately, since I (still, unfortunately) use my Linux box for my dhcp server, this meant that it didn’t Just Work because once he hooked it up, his computer couldn’t dhcp an address from the router.
To get around that, I needed to be able to tell him to set a static IP address so he could connect to the linksys box (at http://192.168.1.1) and enable the DHCP server. I didn’t want to tell him to click through a bunch of UI and set values by hand – I wanted something he could copy-paste and have it (hopefully) Just Work.
I vaguely knew of netsh and it seems to be able to do what I need. Here’s what I just emailed him to try (worked on my Vista box) to set the interface for a static IP. The "store=active" is key since the default is to make it persistent.
netsh interface ip set address "Local Area Connection" static 192.168.1.3 255.255.255.0 192.168.1.1 store=active