Solved

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

Posted on 2004-08-05
16
1,631 Views
Last Modified: 2013-12-21
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
Comment
Question by:ChuckVincent
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
  • 4
  • +2
16 Comments
 
LVL 38

Expert Comment

by:yuzh
ID: 11732760
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
 
LVL 11

Expert Comment

by:jgiordano
ID: 11737872
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
 

Author Comment

by:ChuckVincent
ID: 11738131
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
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 34

Expert Comment

by:PsiCop
ID: 11738264
"rwall" seems to me to be what you want. Is there something about it that doesn't do what you need?
0
 
LVL 11

Expert Comment

by:jgiordano
ID: 11738325
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
 
LVL 11

Expert Comment

by:jgiordano
ID: 11738339
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
 
LVL 11

Expert Comment

by:jgiordano
ID: 11738408
rwall does send to the machine(s) specified and all users logged into those machines you don't specify the users
0
 

Author Comment

by:ChuckVincent
ID: 11761976

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
 
LVL 34

Expert Comment

by:PsiCop
ID: 11762160
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
 

Author Comment

by:ChuckVincent
ID: 11762264
There is no rwall in the /etc/services  How do I add it?

-Chuck
0
 
LVL 34

Accepted Solution

by:
PsiCop earned 100 total points
ID: 11762381
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
 

Author Comment

by:ChuckVincent
ID: 11762466
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
 
LVL 51

Expert Comment

by:ahoffmann
ID: 11771677
xmessage
if not installed to be found at http://www.sunfreeware.com/
0
 
LVL 34

Expert Comment

by:PsiCop
ID: 12133398
Interesting.
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 12153671
cc: PsiCop
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

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.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

My previous tech tip, Installing the Solaris OS From the Flash Archive On a Tape (http://www.experts-exchange.com/articles/OS/Unix/Solaris/Installing-the-Solaris-OS-From-the-Flash-Archive-on-a-Tape.html), discussed installing the Solaris Operating S…
Installing FreeBSD… FreeBSD is a darling of an operating system. The stability and usability make it a clear choice for servers and desktops (for the cunning). Savvy?  The Ports collection makes available every popular FOSS application and packag…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question