1827483 Members
2144 Online
109965 Solutions
New Discussion

Re: swlist display error

 
Kenneth_61
Frequent Advisor

swlist display error

I am using UNIX v11.0. swlist display error. It is ok in the past. I had look at the /etc/hosts and /etc/resolv.conf. I am using BIND 9.


# swlist
# Initializing...
# Contacting target "server.mydomain.com"...
ERROR: Could not contact host "server.mydomain.com". Make sure
the hostname is correct.
ERROR: More information may be found in the daemon logfile on this
target (default location is
server.mydomain.com:/var/adm/sw/swagentd.log).

# cat /var/adm/sw/swagentd.log

======= 12/14/04 22:24:07 EAT BEGIN swagentd (pid = 2010).

WARNING: An attempt to get the network host entry for
"server.mydomain.com" failed. This may result in denial of
access to users and agents at this host. Check the spelling
of this name, then your "/etc/hosts" file, or your
"/etc/resolv.conf" file and DNS resolver configuration. The
nslookup program may be helpful in isolating this problem.

======= 12/14/04 22:28:20 EAT END swagentd (pid = 2010).


ref:
# cat /etc/hosts

192.168.1.2 server
127.0.0.1 localhost loopback

# cat /etc/resolv.conf
domain mydomain.com
nameserver 192.168.1.2
nameserver 202.67.143.222
nameserver 202.67.240.10



9 REPLIES 9
Kenneth_61
Frequent Advisor

Re: swlist display error

But, I can ping server and server.mydomain.com also. So, I do not know what is wrong. :-(


# ping server
PING server: 64 byte packets
64 bytes from 192.168.1.2: icmp_seq=0. time=1. ms
64 bytes from 192.168.1.2: icmp_seq=1. time=0. ms
#
# ping server.mydomain.com
PING server.mydomain.com: 64 byte packets
64 bytes from 192.168.1.2: icmp_seq=0. time=1. ms
64 bytes from 192.168.1.2: icmp_seq=1. time=0. ms
Bharat Katkar
Honored Contributor

Re: swlist display error

Hi Kenethh,
If you are sure about the configration files (hosts,resolv.conf etc.) then try restarting the swagentd daemon. Hope fully it should work.

# /sbin/init.d/swagentd stop
# /sbin/init.d/swagentd start

If this doesn't work then check the
"# hostname"
output.
Is it showing the same server name as it is there in /etc/hosts and the one you are able to resolve. If not then use
"# set_parms hostname"
and set it right but this will reboot the server and accordingly u need to plan downtime.

Hope that helps.
Regards,
You need to know a lot to actually know how little you know
Stf
Esteemed Contributor

Re: swlist display error

OK,

Look if you've got a /etc/nsswitch.conf file?

If this is the case modify the hosts'line like this:

hosts: files [NOTFOUND=continue] dns

Stf ;-)
harry d brown jr
Honored Contributor

Re: swlist display error

Like Bharat Katkar asked, do you have "swagentd" running?

Also, Why do you have 192.168.1.2 (server) pretending to be its own name server?

Could you post the following files?

/etc/named.conf
/etc/rndc.conf
/etc/nsswitch.conf
/etc/named.data/* (all zone config files)


live free or die
harry d brown jr
Live Free or Die
Michael Roeder
Frequent Advisor

Re: swlist display error

Hi,

probably, your DNS is not working properly.
The easiest way ist a local entry to nsswitch.conf:
hosts: files dns
Then add to /etc/hosts:
192.168.1.2 server.mydomain.com server

Then the server would be known as server.mydomain.com with the alias "server"
Nguyen Anh Tien
Honored Contributor

Re: swlist display error

I just think swagent has problem. you try to restart this agent by issues two command
# /sbin/init.d/swagentd stop
# /sbin/init.d/swagentd start
and check again.
HP is simple
Kenneth_61
Frequent Advisor

Re: swlist display error

Wah !!! Even though it display the same server server.mydomain.com when run "#hostname" , it solves !! when I run 'set_parms hostname" . Many thanks. :-)
Kenneth_61
Frequent Advisor

Re: swlist display error

Thanks, Bharat Katkar .

Kenneth_61
Frequent Advisor

Re: swlist display error

At the end, I know the solution is to change:

From :
192.168.1.2 server

to:
192.168.1.2 server.mydomain.com server

in /etc/hosts

Many thanks all of you.