System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

smbclient won't send popup to PC (Connection failed)

 
Rob van Buiten
Regular Advisor

smbclient won't send popup to PC (Connection failed)

I want to send (from an hpux server) a popup to a windows PC.
From server A it works fine with:
echo "Bla Bla Bla" | smbclient -M PC4180
From server B it won't work I wanted.
It only works when I put ip and pcname into:
/etc/opt/samba/lmhosts
And that is what I don't want. We have dns and PCâ s will changed from IP sometimes

debug output from server A see attachment:
give a line "resolve_hosts: Attempting host lookup for name PC4180<0x20>"

but server B give:
"resolve_hosts: not appropriate for name type <0x3>" I miss pc name.

What is going wrong on server B
Is samba config not up to date ?

Regards,
Paul Ettema.
3 REPLIES
TTr
Honored Contributor

Re: smbclient won't send popup to PC (Connection failed)

If you look in the name resolution for PC4180 in your debug, you will see
server A
resolve_lmhosts: Attempting lmhosts lookup for name PC4180<0x20>
startlmhosts: Can't open lmhosts file /etc/opt/samba/lmhosts. Error was No such file or directory
resolve_hosts: Attempting host lookup for name PC4180<0x20>
Connecting to 10.240.32.197 at port 139

Server B
resolve_lmhosts: Attempting lmhosts lookup for name PC4180<0x3>
startlmhosts: Can't open lmhosts file /etc/opt/samba/lmhosts. Error was No such file or directory
resolve_wins: Attempting wins lookup for name PC4180<0x3>
resolve_wins: WINS server resolution selected and no WINS servers listed.
resolve_hosts: not appropriate for name type <0x3>

Server A connects to 10.240.32.197 at port 139 and resolves the PC name. Server B can not connect find your wins server

Check the samba configuration in server B (/etc/opt/samba/smb.conf). You probably don't have the wins server configured or not running the nmdb service.
Rob van Buiten
Regular Advisor

Re: smbclient won't send popup to PC (Connection failed)

TTr,

"wins server" is the problem.
I had also discussed the problem with our windows servers administration department.

The two servers are in a different site
on one site (A) we have a "wins server" and do only that site. Site B don't have and don't get one.

So, I look foor a different solution. I found it in using the "smbclient" command.

I have pcname, do by my self nslookup and give IP at option -I to "smbclient".

So, command is now (and working):

echo "${POPUP_MSG}" | /opt/samba/bin/smbclient -I ${IPinfopc} -M $infopc >/dev/null
Rob van Buiten
Regular Advisor

Re: smbclient won't send popup to PC (Connection failed)

Solution is use option -I