Skip to content
Menu
e-lo [IT Engineer life]
  • Home
    • Notes
    • Important notes
  • Database
    • T-SQL
    • SQL Server quick
    • SQL server docs
    • MySql quick sheet
    • Postgre
    • InfluxDB
  • Programming
    • MS Azure Powershell
    • MS Azure Command-Line Interface (CLI) doc
    • Python Docs
    • Python Logging
    • Python-cheat-sheet
    • Git-guide
  • Azure
    • MS Windows virtual machines in Azure
    • MS ARM Docs
    • MS ARM Template Docs
    • MS ARM Functions
    • MS Bicep+ARM
    • MS ARM Tutorial
    • MS Deployment scripts (intern/extern)
    • MS Virtual Network
  • Az-nutshell
    • ms-technology-choices-compute-decision-tree
    • ms-data-store-decision-tree
    • ms-data-explorer
    • ms-storage-explorer
    • ms-azure-sql
    • ms-common-data-services
    • ms-azure-mysql-daas
    • ms-sla
    • az paas
    • az glossary-quicksheet
    • az-test-vm-script-quickguide
  • Linux
    • Top CMD’s
    • Useful CMD Linux
    • ss64 Linux
    • Ubuntu
    • 30 things Ubuntu 18.04
    • Bootable Ubuntu USB
    • LinuxFilesystemTreeOverview
  • Sys Admin
    • System Administrator
    • Sys News
    • Packet Sniffers
  • Zen
    • Not thinking about anything is Zen
e-lo [IT Engineer life]

5 min .msi and .zip

Posted on January 10, 2022January 10, 2022 by espenk

https://techoral.com/blog/java/adoptopenjdk-install-windows.html

.msi and .zip
Both versions of have the same functionality, features, plugins, etc.

The main difference is that the Zip file does not get installed in the system as a program,
meaning that the executable files are not in the programs folder.

The application does not appear on the start menu, or as part of the programs menu.
Also the operating system will not associate .java files to open automatically.

The zip file can be extracted to any folder you want, and the contained java.exe program can be run from there.
It can even be executed from an external drive, so that it can also be run on computers where the user has no access to modifying the operating system (in schools, public computers, your parent’s computer, etc).

The zip file allows you to use different versions of the program, whereas the installed version will use only the latest one installed.


The files used on the zip file don’t need to be uninstalled from the system, you can simply delete the containing folder.
To uninstall the .msi file you need to use the OS uninstall tools.

jdk-11 was installed with msi

cmd

C:\Users\jekl>java -version
openjdk version “11.0.13” 2021-10-19
OpenJDK Runtime Environment Temurin-11.0.13+8 (build 11.0.13+8)
OpenJDK 64-Bit Server VM Temurin-11.0.13+8 (build 11.0.13+8, mixed mode)

Now lets swap to the downloaded zip jdk-17

It is unzipped to the same folder as jdk-11 was installed in.

Lets run a jar file and then change the JAVA_HOME from

C:\Users\jekl>echo %JAVA_HOME%
C:\Program Files\Eclipse Adoptium\jdk-11.0.13.8-hotspot

cd c:\giti2021\Kotlins\testbasic
java -jar Main.jar
[]
Hello from VSC
12
WORKER1 28
Utility str
19
0.0667848
espen
silje
object pojo
Customer(name=object pojo, email=email@mil.com)

To

# cmd as admin
setx -m JAVA_HOME “C:\Program Files\Eclipse Adoptium\jdk-17.0.1+12”

Close and open cmd again (as admin if change back), run the same jar file

c:\Users\jekl>echo %JAVA_HOME%
C:\Program Files\Eclipse Adoptium\jdk-17.0.1+12
c:\giti2021\Kotlins\testbasic>java -jar Main.jar
[]
Hello from VSC
12
WORKER1 28
Utility str
85
0.36406016
espen
silje
object pojo
Customer(name=object pojo, email=email@mil.com)

Great, now we have installed jdk-11 but are using jdk-17.

How to set environment variables for Java using command line (codejava.net)

I will revert back to jdk-11.0.13.8-hotspot , the cmd output java -version will not change before we uninstall the installed jdk-11

RSS Azure

  • MLOps Blog Series Part 3: Testing scalability of secure machine learning systems using MLOps June 30, 2022

RSS RabbitMQ

  • RabbitMQ 3.8.15 release

RSS Python

  • PEP 694: Upload 2.0 API for Python Package Repositories June 11, 2022

Tags

5 min (29) Ansible (1) ARM (10) azure (41) cmd (3) Django (4) Docker (1) e-lo (2) Flask (2) Github (9) Grafana (2) Information (7) Information Retrieval (13) JAVA (1) kivy (2) Kotlin (6) linux (15) mobile (2) Natural Language Prossesing (NLP) (2) Net.Core (1) Networking and Security (9) OPC (2) PEP8 (1) Philosophy (3) Python (48) Python Networking and Security (5) Reason (2) RMQ (3) Solr (11) Sql (10) Uncategorized (2) VSC (1) Warframe (2) WMVARE (4) Zabbix (7)

Recent Posts

  • 401 access denied win server (iis), Local Security Policy
  • Callback
  • Share-level permissions IAM Azure AD
  • Packet Sniffers
  • MSA Account

Archives

Meta

  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org

Photo by Markus Spiske from Pexels "Matrix"

©2022 e-lo [IT Engineer life] | Powered by WordPress & Superb Themes