• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1648
  • Last Modified:

"net send" for Solaris (how to send messages to Machines on Solaris Lan)

I need to develop a script that will notify a handfull of users when a directoy listing changes.  This is non public internal Solaris lan.  I was leaning away from setting up sendmail just for these messages.  Is there a Solaris equiv to "net send" in windows.  I can't use wall or write becuse the user name is not unique.  I need to sent to a machine name.  

Thanks,
Chuck
0
ChuckVincent
Asked:
ChuckVincent
  • 4
  • 4
  • 4
  • +2
1 Solution
 
yuzhCommented:
why not simply just send emai (use mailx or mail).

You can also use "write" or rwall, have a look at the following page for more details:
http://rsusu1.rnd.runnet.ru/solaris2.7/Solaris_System_Administration_Guide-stripped/ch01/008-010.html
0
 
jgiordanoCommented:
Us the logger command that is used to send messages to syslog.

Basically you need to do the following:

1) edit the /etc/syslog.conf file; add an entry on for user.notice                              <user or groups>
2) stop and start syslog /etc/init.d/syslog (stop|start)
3) use the logger command - #logger -p user.notice   <MSG>

0
 
ChuckVincentAuthor Commented:
Do you guys read?  the user name or group is out.  The users are not UNIQUE.  There are 15 people loged into 15 different computers twith the same user.  I need to send to machine name/ip OR outside email.

0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
PsiCopCommented:
"rwall" seems to me to be what you want. Is there something about it that doesn't do what you need?
0
 
jgiordanoCommented:
You could set up syslog to send to syslog on a specific host using @host,@host instead of users;

1) edit the /etc/syslog.conf file ON YOUR BOX; add an entry on for user.notice                              @HOST,
0
 
jgiordanoCommented:
Then on the host set up the syslog.conf to foward the messages:

1) edit the /etc/syslog.conf file; add an entry on for user.notice                              <user or groups>
0
 
jgiordanoCommented:
rwall does send to the machine(s) specified and all users logged into those machines you don't specify the users
0
 
ChuckVincentAuthor Commented:

Please help with error below...

develop-harriet (31) ping harriet
harriet is alive
develop-harriet (32) rwall harriet
test
rwall: Can't send to harriet
harriet: RPC: Program not registered
develop-harriet (33) rwall -h harriet
test
rwall: Can't send to harriet
harriet: RPC: Program not registered
develop-harriet (34)
develop-harriet (37) rwall harriet < test.txt
rwall: Can't send to harriet
harriet: RPC: Program not registered
develop-harriet (38) cat test.txt | rwall harriet
rwall: Can't send to harriet
harriet: RPC: Program not registered
0
 
PsiCopCommented:
The host "harriet" may have been hardened and the "rwalld" daemon is not running, or all RPC services may have been turned off. Chect /etc/services
0
 
ChuckVincentAuthor Commented:
There is no rwall in the /etc/services  How do I add it?

-Chuck
0
 
PsiCopCommented:
Hmmm.... you would ask that when I don't have a Solaris machine handy to look at. I was just in a server last night, disabling this stuff. Whoops! OK, I found my notes on system hardening, and I directed you to the wrong file.

Look at /etc/inetd.conf, not /etc/services

About 1/3rd or so into the file, look for "walld"

That line needs to be UNcommented (does not start with a #). If it is commented, you'll need to uncomment it, save the file, and then restart the inetd process (for you, I suspect it will be easier to reboot the box).
0
 
ChuckVincentAuthor Commented:
I found it disabled in inetd.conf.  after enableing it and restarting inetd I can receive messages on harriet BUT ONLY in the console window.  I tried the '-a' like in wall to print messages to all ttys but that is not a valid option.  Without a console window open you miss the messages.

Is there a way to send to all terminals on a remote host?

-Chuck
0
 
ahoffmannCommented:
xmessage
if not installed to be found at http://www.sunfreeware.com/
0
 
PsiCopCommented:
Interesting.
0
 
ahoffmannCommented:
cc: PsiCop
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 4
  • 4
  • 4
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now