pavement

Network Configuration (manual)

From FreeBSDwiki
(Difference between revisions)
Jump to: navigation, search
(changing your network with ifconfig)
 
Line 5: Line 5:
 
         options=8<VLAN_MTU>
 
         options=8<VLAN_MTU>
 
         inet6 fe80::290:96ff:fe18:bb9e%dc0 prefixlen 64 scopeid 0x1
 
         inet6 fe80::290:96ff:fe18:bb9e%dc0 prefixlen 64 scopeid 0x1
         inet 192.168.1.101 netmask 0xfffffff00 broadcast 192.168.0.255
+
         inet 192.168.1.101 netmask 0xfffffff00 broadcast 192.168.1.255
 
         ether 00:90:96:18:bb9e
 
         ether 00:90:96:18:bb9e
 
         media: Ethernet autoselect (100baseTX <full-duplex>)
 
         media: Ethernet autoselect (100baseTX <full-duplex>)
Line 20: Line 20:
 
         options=8<VLAN_MTU>
 
         options=8<VLAN_MTU>
 
         inet6 fe80::290:96ff:fe18:bb9e%dc0 prefixlen 64 scopeid 0x1
 
         inet6 fe80::290:96ff:fe18:bb9e%dc0 prefixlen 64 scopeid 0x1
         inet 192.168.1.101 netmask 0xfffffff00 broadcast 192.168.0.255
+
         inet 192.168.0.101 netmask 0xfffffff00 broadcast 192.168.0.255
 
         ether 00:90:96:18:bb9e
 
         ether 00:90:96:18:bb9e
 
         media: Ethernet autoselect (100baseTX <full-duplex>)
 
         media: Ethernet autoselect (100baseTX <full-duplex>)

Revision as of 21:11, 22 November 2005

The quick and dirty way, when you're in a hurry and want to test settings:

# ifconfig dc0
dc0: flags=108843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        options=8<VLAN_MTU>
        inet6 fe80::290:96ff:fe18:bb9e%dc0 prefixlen 64 scopeid 0x1
        inet 192.168.1.101 netmask 0xfffffff00 broadcast 192.168.1.255
        ether 00:90:96:18:bb9e
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active

frmo here you can see my inet address is 192.168.1.101; my network requires that I'm on the 192.168.0.0/24 network. So I change my dc0 settings:

# ifconfig dc0 down
# ifconfig dc0 192.168.0.101 netmask 255.255.255.0 broadcast 192.168.0.255 up

and my settings change:

# ifconfig dc0
  dc0: flags=108843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        options=8<VLAN_MTU>
        inet6 fe80::290:96ff:fe18:bb9e%dc0 prefixlen 64 scopeid 0x1
        inet 192.168.0.101 netmask 0xfffffff00 broadcast 192.168.0.255
        ether 00:90:96:18:bb9e
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active

Since I brought my interface down, made the changes and specified that the state be UP when I changed it, I should be able to ping stuff on the 192.168.0.0/24 network (assuming that my switch/hub/router connection is right etc.) with no problems.

Personal tools