Script require to do telnet & run few commands


 
Thread Tools Search this Thread
Top Forums UNIX for Beginners Questions & Answers Script require to do telnet & run few commands
# 1  
Old 07-30-2019
Script require to do telnet & run few commands

I am new in scripting,
I need script(BASH) which do telenet to one of the elements & run few commands , after running it successfully it will check status of files & exit.

Help is greatly appreciated 🙏
# 2  
Old 07-31-2019
Hi. Welcome.

Please post your script, meaning your best attempt, and we will will help you along the way.

All the best,

Neo
# 3  
Old 07-31-2019
Welcome Vinesh_123,

I have a few to questions pose in response first:-
  • Is this homework/assignment? There are specific forums for these.
  • What have you tried so far?
  • What output/errors do you get?
  • What OS and version are you using?
  • What are your preferred tools? (C, shell, perl, awk, etc.)
  • Do you have to use telnet or would ssh be available on the client and server?
  • What logical process have you considered? (to help steer us to follow what you are trying to achieve)
Most importantly, What have you tried so far?

There are probably many ways to achieve most tasks, so giving us an idea of your style and thoughts will help us guide you to an answer most suitable to you so you can adjust it to suit your needs in future.


We're all here to learn and getting the relevant information will help us all.



Kind regards,
Robin
This User Gave Thanks to rbatte1 For This Post:
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Perl telnet to router run commands from file

I have a perl script that is called with a router name command list file and output file. The command file can be very large, up to 3k of commands. At first I dumped the command list file to an array and ran the entire file on the router and captured the output. It worked ok for a command list in... (1 Reply)
Discussion started by: numele
1 Replies

2. Programming

Run ruby test and include require

I want to run a test for the gem mini_magick: https://github.com/minimagick/minimagick I got the directory lib, inside of which i got: - mini_magick.rb - mini_gmagick.rb and inside of the test folder is the test i need to run: - image_test.rb and a helper file called: - test_helper.rb ... (1 Reply)
Discussion started by: tornow
1 Replies

3. Shell Programming and Scripting

Script for telnet and run one command kill it and run another command using while loop

( sleep 3 echo ${LOGIN} sleep 2 echo ${PSWD} sleep 2 while read line do echo "$line" PID=$? sleep 2 kill -9 $PID done < temp sleep 5 echo "exit" ) | telnet ${HOST} while is executing only command and exits. (5 Replies)
Discussion started by: sooda
5 Replies

4. UNIX for Dummies Questions & Answers

No idea how to run it, may require gstreamer pluggins

Hello , i want to work on Gstreamer.i am attaching a file here . please have a look at that and let me know on which system it gets compiled . i guess the file is related to gstreamer code, and when i run the files its giving many errors. i am using red hat linux. is it possible to install... (0 Replies)
Discussion started by: juststarted
0 Replies

5. Solaris

Require some way or shell in which commands doesnot gets logged in history file

Guys, can u tell me some way in which the commands i execute on solaris system doesnot gets logged. It should not appear in history file.. Is there any shell which provide such solution or can I turn off the logging, if yes then how... Help will be appreciated Thanks (2 Replies)
Discussion started by: harpreetrekhi
2 Replies

6. Shell Programming and Scripting

Run a shell script from one host which connext to remote host and run the commands

I want to write a script which would run from one host say A and connect to other remote host B and then run rest of commands in that host. I tried connecting from A host to B with SSH but after connecting to host B it just getting me inside Host B command prompt. Rest of the script is not running... (6 Replies)
Discussion started by: SN2009
6 Replies

7. Shell Programming and Scripting

shell script to run a few commands help!

Hi friends this is first post i am very new to shell scripting so i require your expertise to do the following thank u I need to write a shell script which will run the following commands pg_dump bank > backup(Enter) Wait for bash prompt to appear coz it indicates that the command is... (23 Replies)
Discussion started by: perk_bud
23 Replies

8. Shell Programming and Scripting

telnet & su in shell script

Hi, Any scripting experts out there that can point me to the right direction of writing a script using telnet and su to access a server without any users interaction such as login and entering passwd. Thanks. Thanks in advance vastare (1 Reply)
Discussion started by: vastare
1 Replies

9. UNIX Desktop Questions & Answers

Does it require each x-client sould run in separate process?

Hi Every One, I got a Basic doubts about clients on X-Server environment. 1) First of all what is mend by one client. (as per my understanding one application which is connected to X-server). 2) if i say two clients connected to my X-Server from the same machine, does it mean that two... (0 Replies)
Discussion started by: ps_sureshreddi
0 Replies

10. UNIX for Dummies Questions & Answers

How would I telnet & change user password automatically in a script

I would like to create a script that logs into a list of several servers 50+ and changes my password all at once. Every 60 days we are required to login to each system and change our passwords or else they expire and our login account is deleted. I have an idea on how I could do this but... (4 Replies)
Discussion started by: darthur
4 Replies
Login or Register to Ask a Question