On Fri, May 12, 2006 at 04:21:09PM +0100, Barnaby Scott wrote: > >The fact that the operating system knows what the machine is called, > >does not necessarily mean that the name is in the DNS. You can put an > >entry in your /etc/hosts file (take a look at the file for the format), > >which will allow sendmail and other daemons to start. > > OK, I looked in /etc/hosts and only 127.0.0.1 localhost appears there. > How do I put another entry in here though, when I don't know in advance > the IP address that will be allocated to this machine by the DHCP server > (provided by my router)? The odd thing is that the system knows exactly > what IP address has been assigned, because I can see that transaction > taking place during the boot sequence long before the point where it > stalls.
You can possibly configure your router to give you the same IP address each time you make a DHCP lease request, by setting up `static' leases. You could also manually configure an IP address, and add that address to the list of IPs excluded from your router's dynamic address pool. How to do so will depend on your router. You can then, with either of these approaches, put an entry in /etc/hosts and it should work. > > You should also > >check that your hostname is in the DNS. You might find something like > >DynDNS or ZoneEdit useful if your machine is on a dynamically assigned > >domestic range, such as you'd get from NTL or Telewest. > > Do I really want it in the DNS? I'm not sure exactly what this means in > the context of my little network, but if it means people outside my > network being able to look for my computer by name, I certainly don't > want that. In case it is important, I should say that during > installation I was asked to configure my NIC and that was where I put a > hostname, but I *didn't* enter a domain name. Should I have put > something here - if so, what? Not necessarily, but as KDK has said, not having a name in DNS (or in /etc/hosts) can cause some daemons to wait while their DNS lookup timeout limit expires. And, as KDK said, it's often sendmail that seems to wait. And wait... ;-) You can certainly manage without public DNS records, but if you need to run sendmail, you should certainly make a new entry in /etc/hosts. > > > > >As for the DNS server, you need to tell FreeBSD where to go to resolve > >names to IP addresses. You do this by putting the IP addresses of your > >ISP's name servers in your /etc/resolv.conf (yes, there really is no 'e' > >on the end of resolv). The format is 'nameserver IP.add.re.ss', without > >the quotes (man 5 resolv.conf will give you more detail). > > /etc/resolv.conf appears to contain one entry: > 'nameserver 192.168.1.1' > which is the address of my router. I have never put in the ISP's > namesevers before, and yet DNS resolution seems to happen OK! > (Presumably when I update or install stuff, the system accesses the > relevant FTP servers by name rather than IP address?) Ah, OK. Then your dhclient is correctly requesting and getting its resolver address. If it is indeed sendmail that causes the delay, then you may want to disable it. Someone has already suggested booting with verbose logging turned on (an option at the boot menu), which should give you more idea of what's causing the delay. Let us know what's going on if you can't figure it out. > > You should > >also check in /etc/nsswitch.conf to make sure that you have an entry > >that looks like this: > > > >hosts: files dns > > Yes it does, but with my particular setup, should I actually change this? No, leave it as it is. You still want to check /etc/hosts before going to the DNS. > > > > >This tells your local resolver library to consult /etc/hosts before it > >goes to the DNS. > > > >If I am teaching Grandma how to suck eggs, I apologise - I got the > >impression from the tone of your post, though, that you are quite new > >to all this UNIX stuff! > > Don't worry - this particular Grandma wouldn't know an egg if she > swallowed one, and she hasn't sucked anything in years! Heheh! Interesting imagery. Thanks... Need soap... > I am very > grateful for all the help I can get. I am hampered by not only being a > Unix virgin, but my only network experience is with a small peer to peer > network of Windows machines (plus only what I have read). I feel rather > like someone who trying to teach himself to fly an advanced fighter jet > with nothing but the technical manual. So far I am still trying to > operate the ladder to get in the cockpit! I'm determined to get there > though. IMHO, you picked a fine OS for your UNIX initiation, in part because of its technical excellence, and in part because of the wonderful support you get from the community. If you are resourceful, and can demonstrate an ability to try and fix things yourself, you will find most people round here very helpful. Welcome aboard! Dan -- Daniel Bye PGP Key: http://www.slightlystrange.org/pgpkey-dan.asc PGP Key fingerprint: D349 B109 0EB8 2554 4D75 B79A 8B17 F97C 1622 166A _ ASCII ribbon campaign ( ) - against HTML, vCards and X - proprietary attachments in e-mail / \
Description: PGP signature