Sending windows messenger messages on linux

Hello,

Is there anyway that I could automatically send a message to all of the computers on the network usign the windows messenger service(not M$N Messenger) from my red hat 9.0 server.

I would like to beable to make it so when the server restarts a message is sent.

- Robbert
rrijkseAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

ThisIsMyNameCommented:
cat yourMessage.txt | smbclient -M [host]

where [host] is either a machine name or a user name.

If you have a list of hosts, you could make a simple script to message them all

#! /usr/bin/perl -w
open (IN,"listOfHosts.txt");
while (<IN>){
    chomp;
    system ("cat yourMessage.txt | smbclient -M $_");
}
close IN;

Note that messaging to users (rather than hosts) can be problematic if a user is signed on at more than one computer.
0
rrijkseAuthor Commented:
Thanks, that worked like a charm
0
rrijkseAuthor Commented:
I have one question, how would I make it so that that script runs when the redhat box is restarted?

If you can help me with that, i'll give you 100 points

- Robbert
0
Cloud Class® Course: Microsoft Exchange Server

The MCTS: Microsoft Exchange Server 2010 certification validates your skills in supporting the maintenance and administration of the Exchange servers in an enterprise environment. Learn everything you need to know with this course.

ThisIsMyNameCommented:
you can call the script from /etc/rc.d/rc.local and it will do it's thing on startup... Hope that helps!
0
rrijkseAuthor Commented:
I need the server to send out a message, when the server is going to be down for a restart or shutdown.

I made a message saying: "The server will be down for the next few minutes." and I want that to be send to all of the computers on the network.

- Robbert
0
ThisIsMyNameCommented:
Ah.. ok. I thought you wanted to send out messages after the restart (which seemed a bit odd).

Look at your /etc/rc6.d/ directory.. you'll see entries like this


K05atd
K05keytable
K05saslauthd
K10cups
K10xfs
K15gpm
(etc)

make a symlink (ln -s [original file] [new location]) from your script to a file in this directory. Name it something like Kxxsendmsg. The numbers that you use for "xx" determine when your script will be run. On my system, K07sendmsg would be executed after the system
shuts down saslauthd and before it shuts down cupsd.

The rc6.d directory is used when your system restarts. Add an entry to rc0.d as well if you'd like your system to send out messages when things are halted, too.

Obviously, you want to run your script before things like samba and network are shut down.

Hope that's a bit more helpful :)
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
rrijkseAuthor Commented:
Sorry about the delay, I completely forgot about this question.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux Networking

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.