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 29th March 2016
WeoNat WeoNat is offline
Port Guard
 
Join Date: Mar 2016
Posts: 10
Default dhclient.conf: line 2: expecting a statement?

i edited /etc/dhclient.conf

Code:
sudo nano /etc/dhclient.conf
there was only a single line stating

Code:
send host name "openbsd";
to which i added right after it:

Code:
supercede domain-name-servers 8.8.8.8, 8.8.4.4;
i saved dhclient.conf and rebooted my machine.

during rebooting, a kernel message reads:

Code:
pf enabled
starting network
/etc/dhclient.conf     line 2: expecting a statement
supercede
^
what happened please?
Reply With Quote
  #2   (View Single Post)  
Old 29th March 2016
e1-531g e1-531g is offline
ISO Quartermaster
 
Join Date: Mar 2014
Posts: 628
Default

You have: supercede
It should be: supersede
Reply With Quote
  #3   (View Single Post)  
Old 29th March 2016
WeoNat WeoNat is offline
Port Guard
 
Join Date: Mar 2016
Posts: 10
Default

Quote:
Originally Posted by e1-531g View Post
You have: supercede
It should be: supersede
oh my...my...

thanks a lot

i hope what i am about to tell you guys is on topic.

you see, while waiting for a reply to my original post, i changed the word supercede to prepend as in

Code:
prepend domain-name-servers 8.8.8.8, 8.8.4.4;
in /etc/dhclient.conf, saved the file and rebooted my machine.

upon reboot, i tried to ping google.com and was told there was no route to host.

what happened?
Reply With Quote
  #4   (View Single Post)  
Old 29th March 2016
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,977
Default

Inspect your /etc/resolv.conf file. Per the resolv.conf(5) man page, you may have a maximum of 3 nameservers defined. I'll guess you now have more than 3, which is a configuration error.

Last edited by jggimi; 29th March 2016 at 01:48 PM. Reason: typos. I always have them. Plan on it.
Reply With Quote
  #5   (View Single Post)  
Old 29th March 2016
WeoNat WeoNat is offline
Port Guard
 
Join Date: Mar 2016
Posts: 10
Default

Quote:
Originally Posted by jggimi View Post
Inspect your /etc/resolv.conf file. Per the resolv.conf(5) man page, you may have a maximum of 3 nameservers defined. I'll guess you now have more than 3, which is a configuration error.
sorry jggimi but i know how to count.....or do i??

8.8.8.8 is first nameserver
8.8.4.4 is second nameserver

so where are the third and fourth?
Reply With Quote
  #6   (View Single Post)  
Old 29th March 2016
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,977
Default

Because your directive was to prepend two Google nameservers in front of ISP-provided nameservers, I assumed the problem was too many. I was wrong. It was a guess on my part, because we can only see what you post.

Looking again at the error message you reported -- "no route to host" -- I'll make another guess -- your IP configuration may not have been successfully provisioned. Perhaps dhclient(8) complained about your configuration file, if it did not complete the TCP/IP configuration properly. That complaint should be recorded in a file in /var/log; most likely /var/log/daemon or possibly /var/log/messages. You can also start (or rerun) dhclient(8) manually. The command # dhclient -d <your nic> will not only restart dhclient, it will post those complaints right on your console, if any. The -d option says, "do not daemonize, keep this running on my console or in my terminal window."

If dhclient has no complaints, look at your current network configuration. That would be the output of an "ifconfig" command, which will show us the configuration of all NICs, real and pseudo, and the output of "route -n show -inet", that will show your routing table.

I'll put away the crystal ball and take off the magic hat, if you provide information that can help narrow down the problem.
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
OpenBSD New OpenBSD dhclient(8) J65nko News 1 7th May 2013 09:41 PM
dhclient configuration ? wlm2 OpenBSD General 5 25th August 2011 02:34 PM
dhclient at startup bsdnewbie999 OpenBSD General 3 31st March 2009 03:55 AM
dhclient.conf: multiple fixed-address statements xiphias FreeBSD General 14 19th June 2008 06:42 AM


All times are GMT. The time now is 01:38 AM.


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