Go Back   The macosxhints Forums > OS X Help Requests > UNIX - Newcomers



Reply
 
Thread Tools Rating: Thread Rating: 3 votes, 4.67 average. Display Modes
Old 03-05-2002, 12:35 PM   #21
hschickel
All Star
 
Join Date: Jan 2002
Location: NY, NY
Posts: 776
merv,

Sure - I was playing around with loose end #1 in this article from MacWrite.

Specifically, I added these flat files:

/etc/lookupd/global
LookupOrder CacheAgent FFAgent NIAgent NILAgent

and

/etc/lookupd/hosts
LookupOrder CacheAgent FFAgent NIAgent NILAgent

The file /etc/lookupd/global seemed to cause the problems. I originally tried it this way:

/etc/lookupd/global
LookupOrder CacheAgent NIAgent FFAgent NILAgent

and the system became unbootable. I switched the FFAgent and NIAgent back via single user mode and I was up and running again. But I could no longer su to root. Eliminating /etc/lookupd solved the problem. I ended up niloading this file into netinfo:
Code:
{
"LookupOrder" = ( "CacheAgent", "NIAgent", "YPAgent" );
"name" = ( "lookupd" );
"MaxThreads" = ( "12" );
CHILDREN = (
{
"name" = ( "groups" );
"LookupOrder" = ( "CacheAgent", "NIAgent", "YPAgent" );
},
{
"name" = ( "users" );
"LookupOrder" = ( "CacheAgent", "NIAgent", "YPAgent" );
},
{
"name" = ( "hosts" );
"LookupOrder" = ( "CacheAgent", "NIAgent", "YPAgent", "DNSAgent", "NILAgent" );
},
{
"name" = ( "netgroups" );
"LookupOrder" = ( "CacheAgent", "NIAgent", "YPAgent" );
}
)
}
This worked without any undo effects on other logins. There are no flatfile agents mentioned in this version - although I believe there would be no problems if they were listed after NIAgent.

Hugh
hschickel is offline   Reply With Quote
Old 03-05-2002, 01:00 PM   #22
mervTormel
League Commissioner
 
Join Date: Jan 2002
Posts: 5,536
Lightbulb ding!

thanx, hugh. i had read that article back in december, and decided i wasn't ready for any of that without further knowledge.

tho i loathe ads, and i'm still not ready for weed-whacking in netinfo, this topic and your post has been enlightening.

so, in the hierarchy of netinfo services, flat files override the netinfo db? just another level to specify where to find things? and the lowest level?

i don't want to get too off-track here, but it seems that the best laid plans... perhaps some sort of caveat is in order. is there a big red banner in the 10.1.3 release notes that says, "warning, your squirrely netinfo flat file schemes are now broken!" ? nay.

we shall wait to hear from gowrann that 10.1.3 broke his netinfo service scheme.
mervTormel is offline   Reply With Quote
Old 03-05-2002, 06:54 PM   #23
gowrann
Triple-A Player
 
Join Date: Mar 2002
Location: Sydney, Australia
Posts: 158
Lightbulb

oh.....that MacWrite article.....doh.....!!!

Yes I also did the exercise to a certain extent.... I will remove my /etc/lookupd/global file and see what happens.
gowrann is offline   Reply With Quote
Old 03-06-2002, 02:02 AM   #24
gowrann
Triple-A Player
 
Join Date: Mar 2002
Location: Sydney, Australia
Posts: 158
Thumbs up

voila....problem fixed by removing the "global" file,
thanks for hanging in there Merv, and Hugh for the last minute goal.

Neil
gowrann is offline   Reply With Quote
Old 03-06-2002, 10:52 AM   #25
pmccann
Major Leaguer
 
Join Date: Jan 2002
Location: Adelaide, South Australia
Posts: 470
Congratulations all concerned, from an interested (yet distanced) bystander!

I just read the article of "interest", together with the loose ends below, and must admit that I would be a bit scared about trusting my netinfo database (or flat files) to the author without a lot more accompanying information (especially when one of the loose ends below talks about his troubles with netinfo database corruption!) There's just a little too much laissez faire within the netinfo prescriptions, and a bit of lazy fare within the loose ends: in particular, I think that some of his stuff about ssh is just plain wrong, "outlook express" does not equal "outlook", and the viral problems with Windows versions of outlook were widely known not to affect mac users. Maybe I'm just a bit grumpy because I happen to use some of these things on occasion! Defensive reflex arc...

In any case: maybe other issues of macwrite inspire greater confidence? I'll have to peck around a bit more and see. (I'm obviously not a regular reader, and am being ridiculously unfair in this message. I do quite like his jaunty writing style.)

Best Wishes,
Paul
pmccann is offline   Reply With Quote
Old 03-07-2002, 08:07 AM   #26
stetner
MVP
 
Join Date: Jan 2002
Location: Brisbane, Australia
Posts: 1,108
Just catching up on this one....

The premis of that 'loose end' article was that the lookupd configuration in netinfo quit working at some point (10.1??).

I think that is wrong. I have my config in netinfo, use flat files for my hosts, then netinfo, then DNS and it works fine at 10.1.3 EG:
Code:
% lookupd -d
lookupd version 233.1 (root 2001.11.14 22:52:19 UTC)
Enter command name, "help", or "quit" to exit
> configuration
Array: "Configuration 0" (8 objects)
[
Dictionary: "Global Configuration"
ConfigSource: netinfo://127.0.0.1/local:/locations/lookupd
DomainOrder: .
LookupOrder: CacheAgent NIAgent NILAgent
MaxIdleServers: 16
MaxIdleThreads: 16
MaxThreads: 32
TimeToLive: 43200
Timeout: 30
ValidateCache: YES
ValidationLatency: 15
_config_name: Global Configuration
name: lookupd

Dictionary: "Host Configuration"
LookupOrder: CacheAgent FFAgent NIAgent DNSAgent NILAgent
_config_name: Host Configuration
name: hosts

Dictionary: "Group Configuration"
TimeToLive: 60
ValidateCache: NO
_config_name: Group Configuration

Dictionary: "Network Configuration"
LookupOrder: CacheAgent DNSAgent NIAgent DSAgent
_config_name: Network Configuration

Dictionary: "NIAgent Configuration"
ConnectTimeout: 5
TimeToLive: 14400
Timeout: 30
ValidationLatency: 15
_config_name: NIAgent Configuration
name: NIAgent

Dictionary: "NILAgent Configuration"
TimeToLive: 3600
Timeout: 30
_config_name: NILAgent Configuration
name: NILAgent

Dictionary: "DNSAgent Configuration"
Retries: 2
Timeout: 15
_config_name: DNSAgent Configuration
name: DNSAgent

Dictionary: "CacheAgent Configuration"
TimeToLive: 14400
ValidateCache: YES
_config_name: CacheAgent Configuration
name: CacheAgent

]
And the results:
Code:
% lookupd -d
lookupd version 233.1 (root 2001.11.14 22:52:19 UTC)
Enter command name, "help", or "quit" to exit
> hostWithName: niprod
Dictionary: "FF: host niprod"
_lookup_FF_file: /etc/hosts
_lookup_FF_timestamp: 1015028944
_lookup_info_system: Flat_File
ip_address: 160.7.8.121
name: niprod
+ Category: host
+ Time to live: 0
+ Age: 0 (expires in 0 seconds)
+ Negative: No
+ Cache hits: 0
+ Retain count: 2


> hostWithName: zaqwsx
Dictionary: "NI: host zaqwsx"
_lookup_NI_checksum: 65727
_lookup_NI_index: 0
_lookup_info_system: NI
ip_address: 192.168.0.155
name: zaqwsx
+ Category: host
+ Time to live: 0
+ Age: 0 (expires in 0 seconds)
+ Negative: No
+ Cache hits: 0
+ Retain count: 2


> hostWithName: www.yahoo.com
Dictionary: "DNS: host www.yahoo.akadns.net"
_lookup_DNS_domain: yahoo.akadns.net
_lookup_DNS_server: 127.0.0.1
_lookup_DNS_time_to_live: 1200
_lookup_DNS_timestamp: 1015504978
_lookup_info_system: DNS
ip_address: 216.115.102.79 216.115.102.80 216.115.102.75 \
   216.115.102.76 216.115.102.77 216.115.102.78
name: www.yahoo.akadns.net www.yahoo.com
+ Category: host
+ Time to live: 0
+ Age: 0 (expires in 0 seconds)
+ Negative: No
+ Cache hits: 0
+ Retain count: 2


> hostWithName: www.yahoo.com
Dictionary: "DNS: host www.yahoo.akadns.net"
_lookup_DNS_domain: yahoo.akadns.net
_lookup_DNS_server: 127.0.0.1
_lookup_DNS_time_to_live: 1172
_lookup_DNS_timestamp: 1015505006
_lookup_info_system: DNS
ip_address: 216.115.102.79 216.115.102.80 216.115.102.75 \
   216.115.102.76 216.115.102.77 216.115.102.78
name: www.yahoo.akadns.net www.yahoo.com
+ Category: host
+ Time to live: 0
+ Age: 0 (expires in 0 seconds)
+ Negative: No
+ Cache hits: 0
+ Retain count: 2

>
Where niprod is only in /etc/hosts, zaqwsx is only in netinfo, and www.yahoo.com is only in DNS. The only disappointment is that the CacheAgent does not seem to be used (see the second www.yahoo.com lookup, and it is the same for niprod and zaqwsx as well).

[edit: readability -mt]
__________________
Douglas G. Stetner
UNIX Live Free Or Die

Last edited by mervTormel; 08-11-2002 at 01:24 PM.
stetner is offline   Reply With Quote
Old 03-14-2002, 04:25 AM   #27
gowrann
Triple-A Player
 
Join Date: Mar 2002
Location: Sydney, Australia
Posts: 158
this is the Macwrite disclaimer:


Part 4: Troubleshooting

If you get "permission denied" errors with any of the steps, you probably aren't superuser. Type su</> at the Terminal prompt and press Enter. Give it your admin password when prompted, the same one used when you first installed OS X. If this isn't your Mac, then you are probably out of luck.

If su fails but you are certain you are an administrator, then try sudo prepended to each action command, e.g. sudo niload -v hosts / < hosts. Again, you'll need the same password as above. Earlier I showed how to create the file /etc/lookupd/global, which also inadvertently caused this problem. If it exists, try renaming that file with the command mv global global.dud, followed by a reboot.

http://www.macwrite.com/criticalmass...-revisited.php
gowrann is offline   Reply With Quote
Reply


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



All times are GMT -5. The time now is 10:35 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.
Site design © IDG Consumer & SMB; individuals retain copyright of their postings
but consent to the possible use of their material in other areas of IDG Consumer & SMB.