Dynadot Aftermarket: discover domain gems worth investing in. Visit our aftermarket.

Write Linux (RHE) shell script from the given pseudo code

SpaceshipSpaceship
SpaceshipSpaceship
Spacemail by SpaceshipSpacemail by Spaceship
Watch

ohcnetwork

New Member
Impact
0
I need to write a Linux (RHE) shell script from the given pseudo code as follows.
Code:
[If statement 1 - Check to see if 10 minutes or longer has passes since the server started/rebooted.]
	[If statement 2 - Check to see if string returned from "curl localhost --max-time 10" contains the string "curl: (28) Operation timed out with 0 out of -1 bytes received"]
		// Restart Apache
	[If statement 2 End]
	[If statement 3 - Check to see if memory used is over xxx MB (because it appears that, when memory used is over xxx MB, Apache/Tomcat/Entire Server locks up/hangs)]
		// Restart server (not just Apache, but the entire server)
	[If statement 3 End]
[If statement 1 End]
Q. How do I write this (using Linux shell script)?

I'd appreciate any help. If you cannot help writing some specific part of the pseudo code, please help me on parts that you can help me ...
 
0
Close
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
AIVikingsAIVikings

We're social

Escrow.com
Spaceship
Domain Recover
CryptoExchange.com

NamePros updates

New: watch any domain
You can now watch domains on NamePros. We check each one and notify you when something changes. Search for a domain and press Watch on...
AIVikings
Catchy
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back