1 |
Am 13.11.2012 17:27, schrieb Bruce Hill: |
2 |
> On Tue, Nov 13, 2012 at 04:52:25PM +0100, Helmut Jarausch wrote: |
3 |
>>>> |
4 |
>>>>> I'd like to assign fixed IP numbers to computers of a local |
5 |
>>>> map MAC addresses to IP addresses. |
6 |
> |
7 |
[...] |
8 |
> |
9 |
> If you just want to setup a static IP per machine, /etc/conf.d/net: |
10 |
> |
11 |
> config_wlan0="192.168.1.2/24" |
12 |
> routes_wlan0="default via 192.168.1.1" |
13 |
> |
14 |
> Hope this helps. If it's too confusing, might mention where DHCP is handed |
15 |
> out, and some more about your LAN. |
16 |
|
17 |
The following is taken directly from my /etc/conf.d/net with minimal |
18 |
editing. It assigns configs based on SSIDs. If I'm not mistaken (haven't |
19 |
tested it in a long time) this means it will default to DHCP for |
20 |
unspecified nets. Good for quick and dirty setups while traveling: |
21 |
|
22 |
modules_wlan0="wpa_supplicant" |
23 |
|
24 |
config_MySSID="192.168.2.5 netmask 255.255.255.0" |
25 |
routes_MySSID="default via 192.168.2.1" |
26 |
dns_servers_MySSID="192.168.6.1" |
27 |
dns_domain_MySSID="example.net" |
28 |
|
29 |
config_SomeHotelSSID="dhcp" |
30 |
|
31 |
config_HotelWithVPN="dhcp" |
32 |
dhcp_HotelWithVPN="nodns" |
33 |
dns_servers_HotelWithVPN="192.168.6.1" # DNS server via VPN |
34 |
dns_domain_HotelWithVPN="vpn.example.net" |
35 |
|
36 |
Hope this helps, |
37 |
Florian Philipp |