NotesWhat is notes.io?

Notes brand slogan

Notes - notes.io

#!/bin/bash
declare -A sites=( [8004]=auth [8003]=directory_backend [9001]=directory_frontend [8303]=health [7801]=highcharts_export_server [8001]=interactions [8200]=intfiletracker_backend [8002]=providers [8317]=refdata_backend [8000]=references [8011]=rti_backend [8100]=scp_backend [9101]=scp_frontend [8100]=scp_jobs [9201]=tracker_frontend ) #Declaring associative array
declare -a not_workingPort=() #Initialising empty array for ports
declare -a not_workingServ=() #Initilaising empty array for service
flag=0
for i in "${!sites[@]}" #Checking array elements Reverse Mapping
do
netcat -z localhost $i
if [ $? -ne 0 ];then
not_workingPort=("${not_workingPort[@]}" "$i") #Putting not working port in the array not_workingPort
not_workingServ=("${not_workingServ[@]}" "${sites[$i]}") #Putting not working service in the array not_workingServ
flag=1
fi
done
if [ $flag -ne 0 ];then

for e in "${not_workingPort[*]}" #Extracing not working service ports
do
for g in "${not_workingServ[*]}" #Extracing not working service name
do
echo -e "The services $g are down"
done
done
exit 2
fi

echo "All ports
auth on 8004
directory_backend on 8003
directory_frontend on 9001
health on 8303
highcharths on 7801
interacions on 8001
intfiletracker_backend on 8200
providers on 8002
refdata_backend on 8317
references on 8000
rti_backend on 8011
scp_backend on 8100
scp_frontend on 9101
scp_jobs on 8100
tracker_frontend on 9201
are working fine"
exit 0
     
 
what is notes.io
 

Notes.io is a web-based application for taking notes. You can take your notes and share with others people. If you like taking long notes, notes.io is designed for you. To date, over 8,000,000,000 notes created and continuing...

With notes.io;

  • * You can take a note from anywhere and any device with internet connection.
  • * You can share the notes in social platforms (YouTube, Facebook, Twitter, instagram etc.).
  • * You can quickly share your contents without website, blog and e-mail.
  • * You don't need to create any Account to share a note. As you wish you can use quick, easy and best shortened notes with sms, websites, e-mail, or messaging services (WhatsApp, iMessage, Telegram, Signal).
  • * Notes.io has fabulous infrastructure design for a short link and allows you to share the note as an easy and understandable link.

Fast: Notes.io is built for speed and performance. You can take a notes quickly and browse your archive.

Easy: Notes.io doesn’t require installation. Just write and share note!

Short: Notes.io’s url just 8 character. You’ll get shorten link of your note when you want to share. (Ex: notes.io/q )

Free: Notes.io works for 12 years and has been free since the day it was started.


You immediately create your first note and start sharing with the ones you wish. If you want to contact us, you can use the following communication channels;


Email: [email protected]

Twitter: http://twitter.com/notesio

Instagram: http://instagram.com/notes.io

Facebook: http://facebook.com/notesio



Regards;
Notes.io Team

     
 
Shortened Note Link
 
 
Looding Image
 
     
 
Long File
 
 

For written notes was greater than 18KB Unable to shorten.

To be smaller than 18KB, please organize your notes, or sign in.