Linux uses PSSH to deploy Tomcat in bulk

Source: Internet
Author: User
Tags pscp

SSH-KEYGEN-T RSA

Ssh-copy-id-i ~/.ssh/id_rsa.pub 192.168.3.2

TAR-XVF pssh-2.3.1.tar.gz

CD pssh-2.3.1

Python setup.py Install

Create all server list TXT file allhosts vim allhosts>>192.168.3.1-15

Create a Java directory

Pssh-i-H allhosts "Mkdir/usr/local/java"

Copy JDK files to all servers

Pscp-h allhosts Jdk-7u45-linux-x64.tar.gz/usr/local/java

Unzip the JDK directory

Pssh-i-H allhosts "Tar-zxvf/usr/local/java/jdk-7u45-linux-x64.tar.gz-c/usr/local/java"

environment variable in effect

Pssh-i-h/root/allhosts "Source/etc/profile"

See if Java is in effect

Pssh-i-h/root/allhosts "Java-version"


Copy the Tomcat installation package

Pscp-h allhosts Apache-tomcat-7.0.77.tar.gz/usr/local/java

Unzip Tomcat

Pssh-i-H allhosts "Tar-zxvf/usr/local/java/apache-tomcat-7.0.77.tar.gz-c/usr/local/java/"

Start the Tomcat service

Pssh-i-H allhosts "/usr/local/java/apache-tomcat-7.0.77/bin/startup.sh"

To see if the service is started

Pssh-i-H allhosts "Netstat-antup | grep 80 "


Linux uses PSSH to deploy Tomcat in bulk

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.