1833555 Members
3087 Online
110061 Solutions
New Discussion

Re: swlist give error

 
Ahmed ABDOU_1
Advisor

swlist give error

hi

We have hp-ux 11.00, when we run swlist command to check the product in the system it give the following error.

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

When checking the swagentd.log there is nothing showing error as the output from swagentd.log file below:

======= 02/03/01 08:31:39 WAT BEGIN swagentd (pid = 5200).

* Stopping swagentd program, process ID 921.

======= 02/03/01 08:31:39 WAT END swagentd (pid = 5200).


======= 02/03/01 08:31:39 WAT END swagentd (pid = 921).


======= 02/03/01 08:37:44 WAT BEGIN swagentd (pid = 313).

* Started remove agent on "/" for root@cmfbckup, pid=325,
02/03/01 08:37:46 WAT
* Agent pid=325 completed. 02/03/01 08:37:56 WAT

======= 02/03/01 08:38:46 WAT BEGIN swagentd (pid = 924).

* Restarting swagentd program, process ID 313.

======= 02/03/01 08:38:46 WAT END swagentd (pid = 313).

* Started remove agent on "/" for root@cmfbckup, pid=25865,
02/20/01 13:35:07 WAT
* Started remove agent on "/" for root@cmfbckup, pid=25967,
02/20/01 13:38:51 WAT
* Agent pid=25865 completed. 02/20/01 13:38:51 WAT
? Agent pid=25967 completed. 02/20/01 13:39:09 WAT


Can you please help in this?

Regards,

7 REPLIES 7
Santosh Nair_1
Honored Contributor

Re: swlist give error

First try to rule out any name resolution problems...change the host lookup order in /etc/nsswitch.conf to:

hosts: files dns

then restart swagentd:

kill the running swagentd.
run /sbin/rc2.d/S870swagentd start

then try the swlist command again.

More than likely this is a name resolution problem.

-Santosh
Life is what's happening while you're busy making other plans
Christopher McCray_1
Honored Contributor

Re: swlist give error

make sure your hostname is entered in the /etc/hosts file. If you're using dns, make sure that your hostname is resolvable with nslookup:

# nslookup hostname
# nslookup ip_address

Also, make sure your default gateway is defined and you are connecting to it, because swlist, swinstall, etc. is looking for these things to be defined. Also, the /var/adm/syslog/syslog.log may provide you with additional information.

Hope this helps
Chris
It wasn't me!!!!
Carlos Fernandez Riera
Honored Contributor

Re: swlist give error

Sanjay_6
Honored Contributor

Re: swlist give error

Hi,

Make sure your system name is defined in the /etc/hosts file and also your hosts resolution is working okay. check for /etc/nsswitch.conf file. If you are using DNS and /etc/hosts for name resolution, have this entry in /etc/nsswitch.conf file

hosts DNS [NOTFOUND=continue] files

Also check to see that your resolver is configured correctly (/etc/resolv.conf)

Have a look at the threads below for more info.

http://docs.hp.com/cgi-bin/fsearch/framedisplay?top=/hpux/onlinedocs/B2355-90685/B2355-90685_top.html&con=/hpux/onlinedocs/B2355-90685/00/00/26-con.html&toc=/hpux/onlinedocs/B2355-90685/00/00/26-toc.html&searchterms=resolver%20&queryid=20010918-114659

http://docs.hp.com/cgi-bin/fsearch/framedisplay?top=/hpux/onlinedocs/B2355-90685/B2355-90685_top.html&con=/hpux/onlinedocs/B2355-90685/00/00/8-con.html&toc=/hpux/onlinedocs/B2355-90685/00/00/8-toc.html&searchterms=nsswitch.conf&queryid=20010918-114832

Hope this helps.

thanks
Varghese Mathew
Trusted Contributor

Re: swlist give error

Hi,

Could you try restarting the swagentd daemon by this way :
#/usr/sbin/swagentd -k (for killing the daemon)

restart in this way
#/usr/sbin/swagentd

Hope this helps..
Cheers !!!
Mathew

Cheers !!!
Tim D Fulford
Honored Contributor

Re: swlist give error

Mathew & any one else with this problem

I followed this (& other threads on the subject) & found that
# /usr/sbin/swagentd -k; /usr/sbin/swagentd worked for me. Matthew get 10 points ,but I'm not the author!!!

Briefly the below was checked first, all worked fine
nslookup host
nslookup ip_addd
uname -n; hostname
check /var/adm/sw/products & INDEX exists
(to rebuild INDEEX see http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x527b06295e00d6118ff40090279cd0f9,00.html

/sbin/init.d/swagentd stop; /sbin/init.d/swagentd start --- failed to resolve problem

I hope this helps others with this problem..

We also noticed "swagentd -r" was running.

Regards

-
James R. Ferguson
Acclaimed Contributor

Re: swlist give error

Hi:

Verify that your server's hostname is reflected correctly in '/etc/hosts' *and* in '/etc/rc.config.d/netconf'.

Then, restart the 'swagentd' daemon:

# swagentd -r

Regards!

...JRF...