Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

Tomcat Shutdown Script

#Finds the tomcat process id
ps aux | grep tomcat | grep JavaVirtualMachines | awk -F  " " '{print $2}' > tomcatProcessID

#Kills the process id returned from above mentioned command.
kill -9 `cat tomcatProcessID` && tput setaf 3 && echo "Tomcat killed Successfully" ;rm -rf tomcatProcessID

#Not a mandatory command.
#Used to show all the remaining processes with 'tomcat' keyword in it.
#To inform on the console that the tomcat (running ess or indexer) is killed.
ps aux | grep tomcat | grep -v grep | grep -v killtomcat
Comment

PREVIOUS NEXT
Code Example
Shell :: if command has output bash 
Shell :: command not found 
Shell :: You need to have the Android SDK Build-tools installed on your system 
Shell :: check if word at end of string regex bash 
Shell :: linux command to clean up log files in /var/log 
Shell :: install node and npm ubuntu 
Shell :: download composer 
Shell :: webpack install webpack config 
Shell :: git check if there are staged changes 
Shell :: configure static ip address ubuntu server 20.04 
Shell :: generate github access token 
Shell :: install anbox terminal 
Shell :: vscode restart window 
Shell :: Installing Apache Tomcat on MacOS Mojave using Homebrew 
Shell :: gtk4 windows install 
Shell :: run .bin file command linux 
Shell :: install express globally 
Shell :: comprimir directorio linux 
Shell :: view permissions linux 
Shell :: sudo windows 
Shell :: postgres run query from command line 
Shell :: Creating tar.gz 
Shell :: change wallpaper command line linux 
Shell :: git remove submodule keep files 
Shell :: create repository, commit, and push 
Shell :: publish website locally 
Shell :: How do I make a Git commit in the past 
Shell :: uninstall cinnamon 
Shell :: linux create link to folder 
Shell :: powershell import module 
ADD CONTENT
Topic
Content
Source link
Name
4+1 =