DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 31st March 2013
munchiez munchiez is offline
New User
 
Join Date: Nov 2012
Posts: 7
Thanked 0 Times in 0 Posts
Default Manually Configuring an IP Address problem

Hi, I'm trying to configure my wireless interface manually without dhclient. I tried searching around but cant seem to find the right steps. So far i have tried

Code:
sudo ifconfig urtw0 inet [ipaddress] netmask [netmask] up
ifconfig shows my status is active, but nothing works in the browser.
the ip address and netmask i use are the ones last used so they are right. What other steps am i missing?

thanks
munchiez
Reply With Quote
  #2   (View Single Post)  
Old 31st March 2013
denta denta is offline
Fdisk Soldier
 
Join Date: Nov 2009
Posts: 73
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by munchiez View Post
ifconfig shows my status is active, but nothing works in the browser.
the ip address and netmask i use are the ones last used so they are right. What other steps am i missing?
Possibly verifying the routing table looks ok?
Reply With Quote
  #3   (View Single Post)  
Old 31st March 2013
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 3,135
Thanked 182 Times in 149 Posts
Default

You need:
  • A default route:
    Code:
    $ netstat -rn -f inet
    Routing tables
    
    Internet:
    Destination        Gateway            Flags   Refs      Use   Mtu  Prio Iface
    default            192.168.222.10     UGS        8    14022     -     8 re0  
    127/8              127.0.0.1          UGRS       0        0 33152     8 lo0  
    127.0.0.1          127.0.0.1          UH         3     2380 33152     4 lo0  
    192.168.222/24     link#1             UC         2        0     -     4 re0  
    192.168.222.10     00:10:5a:14:52:a5  UHLc       1     1004     -     4 re0  
    192.168.222.20     127.0.0.1          UG         0        0 33152    56 lo0  
    192.168.222.200    link#1             UHLc       1        3     -     4 re0  
    224/4              127.0.0.1          URS        0        0 33152     8 lo0
  • A valid /etc/resolv.conf
    Code:
    search utp.xnet
    nameserver 192.168.222.10
    lookup file bind

In my case the nameserver and default route happens to be the same, because I run a nameserver on my OBSD firewall. Usually these are different.
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump
Reply With Quote
  #4   (View Single Post)  
Old 31st March 2013
munchiez munchiez is offline
New User
 
Join Date: Nov 2012
Posts: 7
Thanked 0 Times in 0 Posts
Default

netstat -rn shows normally with working connection:

Code:
Internet:
Destination        Gateway            Flags   Refs      Use   Mtu  Prio Iface
default            192.168.0.1        UGS        1       33     -    12 urtw0
127/8              127.0.0.1          UGRS       0        0 33196     8 lo0  
127.0.0.1          127.0.0.1          UH         2        2 33196     4 lo0  
192.168.0/24       link#5             UC         1        0     -     4 urtw0
192.168.0.1        c4:3d:c7:18:ba:3b  UHLc       1        0     -     4 urtw0
192.168.0.4        127.0.0.1          UGHS       0        0 33196     8 lo0  
224/4              127.0.0.1          URS        0        0 33196     8 lo0

after i run
Code:
 inet 192.168.0.4 netmask 0xffffff00 broadcast 192.168.0.255
i get:

Code:
Internet:
Destination        Gateway            Flags   Refs      Use   Mtu  Prio Iface
127/8              127.0.0.1          UGRS       0        0 33196     8 lo0  
127.0.0.1          127.0.0.1          UH         2        2 33196     4 lo0  
192.168.0/24       link#7             UC         0        0     -     4 urtw0
192.168.0.4        127.0.0.1          UGHS       0        0 33196     8 lo0  
224/4              127.0.0.1          URS        0        0 33196     8 lo0
Reply With Quote
  #5   (View Single Post)  
Old 31st March 2013
munchiez munchiez is offline
New User
 
Join Date: Nov 2012
Posts: 7
Thanked 0 Times in 0 Posts
Default

resolv.conf is the same on both instances

Code:
nameserver 194.168.4.100
nameserver 194.168.8.100
lookup file bind

i''m trying to add a default gateway , but etc/mygate does not exist

Last edited by munchiez; 31st March 2013 at 10:19 PM.
Reply With Quote
  #6   (View Single Post)  
Old 31st March 2013
munchiez munchiez is offline
New User
 
Join Date: Nov 2012
Posts: 7
Thanked 0 Times in 0 Posts
Default

ok solved just added the route via terminal
Reply With Quote
  #7   (View Single Post)  
Old 31st March 2013
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 3,135
Thanked 182 Times in 149 Posts
Default

First get things working by adding the route manually: # route add default ww.xx.yy.zz

/etc/mygate only needs a single line with the IP address of the default gateway. See mygate(5)
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump
Reply With Quote
  #8   (View Single Post)  
Old 31st March 2013
munchiez munchiez is offline
New User
 
Join Date: Nov 2012
Posts: 7
Thanked 0 Times in 0 Posts
Default

thanks
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Configuring PF for NAT nekoneko OpenBSD Security 7 13th August 2012 04:36 PM
configuring second NIC tomp OpenBSD Installation and Upgrading 19 15th August 2011 07:25 PM
Static IP address problem rex FreeBSD General 2 25th November 2008 08:53 PM
How do I manually load firmware in OpenBSD? Shagbag OpenBSD Packages and Ports 3 18th September 2008 08:37 PM
Need Help Configuring Postfix iainnitro General software and network 6 8th June 2008 04:55 AM


All times are GMT. The time now is 12:32 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick