Tag Info

Hot answers tagged

12

Debian's stance is that, beyond certain critical system components which are considered required¹, there is no preferred software. If two programs provide similar functionality, and they're both suitable for Debian², and there's a Debian developer willing to maintain each package, then both programs will end up in Debian. The idea is that it's up to the user ...


10

dpkg -L libhtmlparser-java For the source: apt-get source libhtmlparser-java


8

open("$ORIGIN/../lib/i386/jli/tls/i686/sse2/cmov/libz.so.1", O_RDONLY) = -1 ENOENT (No such file or directory) The executable you're running looks for libraries in an rpath in addition to the normal library search path. The rpath here is $ORIGIN/../lib/i386/jli:$ORIGIN/../jre/lib/i386/jli. Normally $ORIGIN should be replaced by the location of the ...


7

If you're trying to get any chrooted app to show up in X11, you will need a couple of things set up correctly. One is a valid DISPLAY environment variable, second is a proper Xauthority file, and third and most important, access to the socket used by X11/Xorg. X11 can use either a TCP network socket or a Unix Domain socket. A TCP socket will be easier to ...


7

BitcoinPlus is a web-based Bitcoin mining application written in Java. It uses your CPU to perform intensive calculations in an attempt to solve difficult math problems - this is part of the Bitcoin creation and security process. I've not heard of any *nix trojans or virii for Bitcoin generation (the only one I'm aware of is, ironically, MacOSX exclusive) ...


7

Update: Found a site that has a pretty good explanation: LINK From the link: Then we have to do some configuration. Debian has a script to maintain different version of programs like java called update-alternatives. update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.7.0/bin/java 1065 update-alternatives --install /usr/bin/javac javac ...


7

Here's how it's done: # Must install 7 first or else when uninstalling six, it will try to install a bunch of replacement gcj stuff. sudo apt-get install openjdk-7-jdk sudo apt-get remove openjdk-6-jre sudo apt-get remove openjdk-6-jre-lib Afterwards: > java -version java version "1.7.0_03" OpenJDK Runtime Environment (IcedTea7 2.1.1pre) ...


7

which 2 commands? /usr/bin/java is a soft (symbolic) link to /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre/bin/java There is no difference as they are the same file. If you type something like ls -l /usr/bin/java You might get a result such as: lrwxrwxrwx. 1 root root 22 Aug 5 17:01 /usr/bin/java -> /etc/alternatives/java Which would mean ...


7

You didn't specify a shell. So, I will assume bash. The next issue is: did you set it for your user only or system-wide? If you set it as your user, then run: grep JAVA_HOME ~/.bash_profile, ~/.bash_login ~/.profile ~/.bashrc If you set it system-wide, then it may vary with distribution but try: grep JAVA_HOME /etc/profile /etc/bash.bashrc ...


6

You need to use a native method, but you don't need to implement it yourself. Java has a variation on JNI called JNA (Java Native Access), which lets you access shared libraries directly without needing a JNI interface wrapped around them, so you can use that to interface directly with glibc: import com.sun.jna.Library; import com.sun.jna.Native; public ...


6

Linux Mint seems to be an exact match to what you're looking for! It includes allmost everything you need. OpenOffice, codecs, Firefox, jockey for easy installation of drivers (if needed), XChat, Pidgin, VLC, Transmission (BitTorrent client), Java, ... etc. I've been using it for about a year now, and it hasn't let me down since that time. One thing I would ...


6

The . is the current directory. The : is the path separator, used to separate multiple paths in a single option/variable under *nix. This command line therefore adds both . and zookeeper-3.4.5.jar to the Java classpath.


5

If you run java folder/somefile java tries to find a class somefile in the package folder, but your class isn't located in the package folder, it's just located in the path folder. You can adjust the search path for classes using the -cp option (meaning classpath). For example having a class YourClass in the package your.package, this package is located in ...


5

The exact rules followed by the gcc compiler for finding include files are explained at: http://gcc.gnu.org/onlinedocs/cpp/Search-Path.html A quick command-line trick to find out where an include file comes from is the following:1 echo '#include <unistd.h>' | gcc -E -x c - > unistd.preprocessed Then, if you look at the unistd.preprocessed file, ...


5

Try Java Virtual Machine Process Status Tool(jps): [Tue Aug 30@17:02:14][prince@localhost ~]$ jps -l 30207 sun.tools.jps.Jps 29947 org.netbeans.Main


5

You can list the installed files with rpm -ql packagename You will see somewhere a bin directory with java executable But if the JDK RPM was correctly installed you should already find java in you path. Try javac MyFirstJavaClass.java and if everything compiles java MyFirstClass (If you didn't change anything the current directory . should already ...


5

Try this: find -name "*3.0.6.RELEASE.jar" -exec sh -c 'unzip -l "{}" | grep -q stereotype.Controller' \; -print There's no need for xargs or a for loop here. All can be done with a single find. If you want to also output the content that got grepped, just remove the -q option to grep - but notice that the grep matches will appear before each file name. ...


5

Android uses a single Zygote process that forks to start a new application. This optimization is possible because all Android applications start in the same environment; there is very little to do (mainly set the user and load the application code) to launch an application. This optimization is effective because there is little to do, especially since the ...


5

You forgot the name of the class to run. Normally Java programs are run like this: $ java MainClass $ java -jar foobar.jar You can use -D to set system properties, but you still need the class or JAR to run: $ java -Djsse.enableSNIExtension=false MainClass $ java -Djsse.enableSNIExtension=false -jar foobar.jar As far as I know you can't set system ...


5

In the context of a Unix or linux process, the phrase "the stack" can mean two things. First, "the stack" can mean the last-in, first-out records of the calling sequence of the flow of control. When a process executes, main() gets called first. main() might call printf(). Code generated by the compiler writes the address of the format string, and any other ...


5

On Debian and derivates, you should probably use update-java-alternatives. Anyway, all those tools are system related, not user related. If you want to use a different java, simply put those lines in your ~/.profile: JAVA_HOME=/usr/lib/jvm/java-6-sun JRE_HOME=/usr/lib/jvm/java-6-sun/jre PATH=$JAVA_HOME/bin:"$PATH" export JAVA_HOME JRE_HOME


5

For killing a process that is associated with multiple processes, you need to kill that by using process id associated with that process. To get the process id of that java process run ps -A |grep java output of this command will give the list of java processes running on your system. Note down Process ID (PID) of that process whom you want to kill and ...


5

Until you asked the question I never even heard of this facility in Unix (file capabilities). I found this link which looks to have the solution as to how to make ld.so trust your shared libraries: JDK-7157699 : can not run java after granting posix capabilities excerpt from that post When one is raising the privileges of an executable, the runtime ...


5

locating java Try using this command: $ type java to find out where Oracle Java is installed. Also open JDK is the opensource project's version of Java, you have to download and install Oracle Java from the Java website. It comes as an RPM you can install. http://java.com/en/download/manual.jsp?locale=en Java package If you've used FedoraUtils to ...


5

OpenVZ & Memory The failcnt is going up on privvmpages, so your container is unable to allocate any more virtual memory space from the host: root@server: ~ # cat /proc/user_beancounters Version: 2.5 uid resource held maxheld barrier limit failcnt privvmpages ...


5

Alternatives Alternatives is a tool that will manage the locations of the installed software using links under the control of the alternatives tool. These links are ultimately managed under /etc/alternatives with intermediate links created under a directory in $PATH, typically /usr/bin. Example $ ls -l /usr/bin/java lrwxrwxrwx. 1 root root 22 Feb 24 ...


5

As found at AskUbuntu: Java (IcedTea) doesn't have a PPAPI plugin available, and so it's not usable in Chromium, since Chromium 34 in Trusty has switched to the Aura rendering framework and no longer allows NPAPI plugins. See also https://bugs.launchpad.net/ubuntu/+source/chromium-browser/+bug/1308783. I guess it's a same with Oracle Java plugin. ...


5

I think this would be a very big project, since you would need a JVM implementation written in C with custom parts using the kernel API. The openjdk hotspot is apparently 250K+ LOC in C and C++. Note you cannot use C++ with the linux kernel. Methinks that could work out to a number of person-years to implement. It's very unlikely you could then get it ...


5

If you want to return only the matching text (instead of the whole line), you need the -o flag grep -o 'public .*[a|A]ction.*)' or with extended regular expressions grep -Eo 'public .*[aA]ction.*\)' file Or, extended for any lines beginning with pub(lic), pri(vate) or pro(tected) grep -Eo '^(pub|pri|pro).*[aA]ction.*\)' file


5

The read system call reads some bytes from an open file. The “odd string” is the bytes that are read by the call. This call attempts to read 32 bytes (third parameter), and succeeds (return value), from file descriptor 34. To find out what file your application is reading for, look back in the trace for the system call that opens this file descriptor. This ...



Only top voted, non community-wiki answers of a minimum length are eligible