Install Jmeter under Linux

Source: Internet
Author: User
Tags gz file save file scp command

Installing Jmeter under Linux requires that you install the JDK above version 1.6 first. So I'll show you how to install the JDK and configure the environment variables.This article describes the. tar.gz version of the JDK installation.
1. Install JDK (. tar.gz format) under Linux
1.1. First to the official website: http://www.oracle.com/technetwork/java/javase/downloads/index.html Download the JDK, with the command: uname-a View the Linux system version (32/64 bit), select the JDK you want to download.

1.2.Select the location where you want to install Java, such as the/usr/directory, create a new folder Java (mkdir Java)move file jdk-8u74-linux-x64.gz to/usr/java
You can use the SCP command to copy the JDK compressed package downloaded under Windows to Linux (provided that you have software that can use Linux commands under Windows, Xshell can create a local shell).

1.3. Unzip the JDK, for example:tar-zxvf jdk-8u74-linux-x64.gz (It is strange here that the. tar.gz file format, which is displayed when downloading on the official web site, has become. gz. The web says. gz format files cannot be decompressed with the tar command, but after the actual operation, Gunzip and Gzip cannot decompress the file or use the tar command. )after decompression, the JDK is installed, the following to configure the Java environment variables
1.4. Configure environment variables to configure environment variables in three ways: (1). Modify the/etc/profile file (global All users) If your Linux machine is recommended only as a development machine, because all of the user's shells have the right to use these environment variables, this can pose a security issue for the system.
    • execute the command at the shell Terminal: Vi/etc/profile
    • At the end of the profile file, add:
java_home=/usr/java/jdk1.8.0_74 path= $JAVA _home/bin: $PATH classpath=.: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar export Java_home, PATH, CLASSPATH
    • Save File
    • To log in again or enter a command: Source/etc/profile
• Annotations
A. You want to change /usr/java/jdk1.8.0_74 to your JDK installation directory B. Use the colon ":" to separate the paths under Linux C. $PATH/$CLASSPATH/$JAVA _home is the value used to refer to the original environment variable when setting environment variables, be careful not to overwrite the original value, which is a a common error.   D. Current directory in Classpath "." It is a common mistake to throw away the current directory.   E. Export is exporting these three variables as global variables.   F. The case must be strictly differentiated.  

     (2). Modify the. bash_profile file (These environment variables are used by a user right) This method is more secure, it can control the use of these environment variable permissions to the user level, if you need to give a user permissions to use these environment variables, you only need to modify their personal user home directory of the. bash_profile file on it.
    • Open the. bash_profile file in the user directory with a text editor:  vi  /home/a user/.bash_profile
export java_home=/usr/java/jdk1.8.0_74 export path= $JAVA _home/bin: $PATH export classpath=.: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar
    • Log back in or enter a command:source/home/a user/.bash_profile

  (3). Set variables directly under the shell (for temporary use)do not support the use of this method, because the shell, your settings are invalid, so this method is only temporary use, and later to use the time to reset, more trouble.  
simply execute the following command at the Shell Terminal:
export java_home=/usr/java/jdk1.8.0_74 export path= $JAVA _home/bin: $PATH export classpath=.: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar

1.5. Test if the JDK has successfully entered the command:java-version    if the output resembles the following error:-bash:/disk2/java/jdk1.8.0_74/bin/java:/lib/ld-linux.so.2:bad ELF interpreter:no such file or directorydescription of the JDK version installation error because 32-bit programs are installed on 64-bit systems
1.6. Uninstalling the JDK
    • Locate the _uninst subdirectory of the JDK installation directory
    • Executes the command at the shell Terminal ./uninstall.sh You can uninstall the JDK.

download the JDK directly from the Linux terminal: wget: Solve the problem of Linux terminal command download JDK (This section is transferred from: http://kingstar.blog.51cto.com/8797655/1750513)

Recently in the server with Linux, in the download of the JDK Oracle official website found, and then use wget + to download, 2 seconds later, the file downloaded, but the file size, only more than 800 K, obviously there are errors, and later found that the information is not available to obtain the URL. Finally figured out a way, no matter what to do, give it a try.

1. Open the page for the JDK resource you want to download http://www.oracle.com/technetwork/cn/java/javase/downloads/jdk7-downloads-1880260.html


2. Press F12 to open the browser debugging interface, to view the network request that piece, this test for Chrome, other browsers should also be similar.


3. Click on the address where you want to download the resource, then go to the download, and note that:


Click to see the URL


All right. To download


4. Change the downloaded file to jdk-7u79-linux-x64.tar.gz.


2. Install JMeter under Linux
2.1Download JMeterOfficial website Download latest version: HTTP://JMETER.APACHE.ORG/DOWNLOAD_JMETER.CGI, currently the latest version is Apache jmeter 2.13 Download binary package, using JMeter dependent JDK, recommended installation JDK More than 1.6 versions.
2.2 Decompression JMetertar-zxvf apache-jmeter-2.13.tgz In this case, the JMeter running environment under Linux is configured.

Install Jmeter under Linux

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.