Hello,
We have to configure servers with a range of IPs which is in itself a subject for another script assistance request -but- we have run into quite a few IP ranges with routing problems lately.
I've been trying to figure out the best way to test a range of IPs, I mean, manually it's not much fun typing "telnet ip 22" then "quit" a few dozen times for each setup. (I log into another linux box and try to telnet to SSH on each IP on the new server, this makes sure the IP is at least functioning and reachable).
I'm open to suggestions for a better method, of course.
A bash script I can upload to my work box and then just input a start and stop IP for the range w/ a result would be great.
Actually making a SSH connection on each IP and transferring a file or running MTR or some other diagnostic over each connection would probably be more "flash" in terms of something I can copy and paste into the customer's deployment report.
I'm just starting off with writing my own bash scripts and could really use the help on this.
Thanks for the replies, tcping looks really interesting but as I said, I'm just getting started w/ writing shell scripts and wouldn't know where to start. (I have an e-book but not much time, unfortunately). I do have a background in programming using a couple of languages that are dead now so I'm hoping some of the base concepts will still translate.
You might be looking for something really simple like this:
(more of a learning experience that useful, but easy to understand)
save the above in a file named pingall.sh
then chmod +x pingall.sh this sets the permissions allowing you to eXecute the scipt
then ./pingall.sh
You might find my version of the documentation of chmod helpful
real-world-systems com/docs/chmod.1.html
also
real-world-systems com/docs/ping.1.html
A more complicated and much faster version:
Please let us know how you do.
I'm new to utilities like socat and netcat and I'm not clear if they will do what I need.
I have a "compileDeployStartWebServer.sh" script and a "StartBrowser.sh" script that are started by emacs/elisp at the same time in two different processes.
I'm using Cygwin bash on Windows 10.
My... (3 Replies)
I'm working on a new exercise that calls for a script that will take in two arguments on the command line (representing the range of line numbers) and will subsequently print those lines from a a specified file. Command line would look like this: ./lines_script.bash 5 15 <file.txt. The script would... (8 Replies)
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
1. The problem statement, all variables and given/known data:
I have written a script for a dice game that: (1) tells user that each of the 2 die are 6 sided (Spots=6); (2)... (3 Replies)
Hi,
I have data in the following form:
AB001 10
AB002 9
AB003 9
etc
AB200 5
What I need to do is sum up the second value according to groups of the first, i.e. AB001 to AB030 the total being X, AB031 to AB050 the total being Y etc (there are 5 AB ranges of different sizes). I'm sure... (3 Replies)
Basically it's for a work assignment.
Have to make a menu with the following choices
***************menu*********************
1) Show Current Directory
2) Dispaly Current Time and Date
3) Copy
4) Change Password
5) write directory to file
6) Edit File Directory
7) Make backup from... (1 Reply)
How do i tell my bash shell script to test the output of the command i'm using?? I want this script to look for lines not equal to 1 then let me know..
$ cat blah ; echo ---- ; cat blah.sh
1 fe
1 fi
1 fo
0 fum
1 blahda
1 blah
0 blahh
1 bla
1 bl
1 blahhh
----
#!/bin/bash
while... (1 Reply)
I want to test if my host can connect to any of the following 10 hosts (192.168.1.0 to 192.168.1.9)
I didnt know which command i should use, so i chose ping. (i wonder if i should use tracepath or sth else)
my code is the following:
#!/bin/bash
clear
firstPart="192.168.1"
maxNum="9"
... (2 Replies)
Is there a basic IP range script or a site that has basic script written?
I am making a script that is looking for a device on my network threw HTTP://. I and using a for loop with wget to download the page and using grep to search the code for the serial number.
My range is 172.16.x.x/16 I... (3 Replies)
I need to execute a script from dev server which is located on Test server.I can use ftp to connect to dev server and from there how can i execute a command on test server.
Thanks (5 Replies)
Hi,
I'm a complete novice at Unix and need to create a script that does the following...
checks to see if an application server is running.
If the app is running then print 'Available'
Else print 'Unavaliable'
exit from scriopt
I have no idea where to start. I'd be very grateful... (0 Replies)