Hi
Ich würde mir gern Java auf debian installieren, weiß aber nicht genau was ich brauche.
Das Debian schaut bei mir so aus:
root@new-host:/home/ich# cat /etc/issue
Debian GNU/Linux 7
\l
root@new-host:/home/ich# uname -a
Linux new-host 3.2.0-4-amd64 #1 SMP Debian 3.2.46-1 x86_64 GNU/Linux
root@new-host:/home/ich# cat /etc/debian_version
7.1
root@new-host:/home/ich# cat /etc/apt/sources.list
deb cdrom:[Debian GNU/Linux 7.1.0 Wheezy - Official amd64 NETINST Binary-1 20130615-23:04]/ wheezy main
#deb cdrom:[Debian GNU/Linux 7.1.0 Wheezy - Official amd64 NETINST Binary-1 20130615-23:04]/ wheezy main
deb Index of /debian wheezy main
deb-src Index of /debian wheezy main
deb http://security.debian.org/ wheezy/updates main
deb-src http://security.debian.org/ wheezy/updates main
wheezy-updates, previously known as ‚volatile‘
deb Index of /debian wheezy-updates main
deb-src Index of /debian wheezy-updates main
root@new-host:/home/ich# uname -m
x86_64
Also ich würde raten, ich brauche jdk-7u25-linux-x64.tar.gz. Stimmt das??
Das open jdk ist doch installiert?!
Ansonsten sudo apt-get install Java
Die sun Installation ist auch irgendwo erklärt. Musste mal googlen findet man schlecht.
Ein Paket “Java” kennt mein synaptic gar nicht.
Mit OpenJDK funzt scheinbar ned alles. Habe ich ein Problem mit dem Aufruf einer Webseite im Internet.
Dann wars openjdk oder jre… Ist doch alles dokumentiert.
mogel
16. August 2013 um 22:21
6
Moin,
[ol]
[li]Download von Java über Oracle Seite
[/li][li]entpacken nach /opt/java
[/li][li]einen Link “current” erstellen auf die gewünschte Version in /opt/java -> ln -s jdk_1.7.irgendwas current
[/li][li]das Script laufen lassen
[/li][/ol]
beim Nächste Java Update einfach wieder nach /opt/java entpacken und auf die gewünschte Version mit ln -s jdk_1.7.irgendwas current
umbiegen
#!/bin/bash
update-alternatives --install "/usr/bin/java" "java" "/opt/java/current/bin/java" 1
update-alternatives --install "/usr/bin/javac" "javac" "/opt/java/current/bin/javac" 1
update-alternatives --install "/usr/bin/javaws" "javaws" "/opt/java/current/bin/javaws" 1
update-alternatives --install "/usr/bin/jar" "jar" "/opt/java/current/bin/jar" 1
update-alternatives --install "/usr/lib/mozilla/plugins/mozilla-javaplugin.so" "mozilla-javaplugin.so" "/opt/java/current/jre/lib/amd64/libnpjp2.so" 1
update-alternatives --set "java" "/opt/java/current/bin/java"
update-alternatives --set "javac" "/opt/java/current/bin/javac"
update-alternatives --set "javaws" "/opt/java/current/bin/javaws"
update-alternatives --set "jar" "/opt/java/current/bin/jar"
update-alternatives --set "mozilla-javaplugin.so" "/opt/java/current/jre/lib/amd64/libnpjp2.so"
wieso die da im Wiki nicht mit Vorteilen von Linux arbeiten weis ich nicht
Stimmt, könnte man mal auf die symlink Version umändern
deetee
17. August 2013 um 01:24
8
Unter Debian/Ubuntu kann man die Sun/Oracle Java Pakete nicht mehr per apt-get installieren, aufgrund von Lizenzänderungen 2011.
Ich habe hier eine detailierte Anleitung wie man vorgehen kann:
Softwareentwicklung mit Java/JEE, Apache Shiro, Apache Maven, Hibernate, Spring Framework, Freemarker, TestNG, DbUnit, Mockito und MySQL.
Unter Schritt 2 Server Side Installationen.
Majora
17. August 2013 um 02:53
9
Unter Ubuntu kannst du auch auf ein externes Repository zugreifen, dass dir einen passenden Installer liefert.
$ sudo add-apt-repository ppa:webupd8team/java
$ sudo apt-get update
$ sudo apt-get install oracle-java7-installer