Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 10-23-2003, 01:01 AM   #1
LQ Newbie
Registered: May 2003
Posts: 2

Rep: Reputation: 0
Problem in the Unix Script

Hi All,

Here is my requirement. I want to write out some commands in the particular port (Say, SMTP port). Using script I want to do this. Is there any way that I can do it using Unix script. Or I have to go for some other language like Perl. Thanks in Advance
EMail ->
Old 10-23-2003, 05:11 AM   #2
Senior Member
Registered: Sep 2003
Location: Sweden
Distribution: Debian
Posts: 3,032

Rep: Reputation: 58
Do you want to write to a remote port? telnet or netcat will help you do that. netcat is good for scripting, and it can also be set up to listen to a port for incoming connections if that's what you want.

Old 10-27-2003, 03:26 AM   #3
LQ Newbie
Registered: May 2003
Posts: 2

Original Poster
Rep: Reputation: 0
Im working in Solaris 5.6. netcat is not available in this.

Ill explain you the scenario. My Java program is listening in a particular port. I want to write some commands/ just sentences in that port. In java its very easy, ill open the TCP or UDP connection and do this. Here I want it to do with the Unix Script. Can you please help me in this aspect. Thanks
Old 10-27-2003, 01:25 PM   #4
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 66
You could just use "telnet" and perhaps "expect" if you want interactivity.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
unix shell script cxy0481 Programming 9 11-20-2005 08:15 AM
telnet windows m/c from unix shell script ann124 Programming 1 11-10-2004 01:26 PM
passing java parameters to a unix script nephilim Programming 25 10-22-2003 10:51 AM
scripting the unix command script lmcthbe Linux - General 7 05-28-2003 02:49 PM
How to schedule unix script periodically from unix os level??? gopi_20us Programming 2 03-11-2002 06:45 AM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 07:18 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration