Search Web......

Debugging Java on Unix/Linux: My Favorite Unix commands

A collection of really powerful unix/linux commands for a Java Developer to empower while debugging on Unix flavor operating systems like Linux(Ubuntu, RedHat,Fedora), Solaris etc.
Debug Java on Linux, Debugging Java Linux, Debug Java Linux command, Debug Java Linux commands, Debug Java unix, Debug Java Sun Solaris, Powerful Linux commands for java developers, Simple Debug commands for Java on Linux, how to Debug Java process on Linux platform. Java on Linux commands, Java on unix commands,
debug Java,Java for unix,jstack analysis, pstack analysis, lsof analysis java, jmap analysis, Java process analysis unix,strace analysis java unix, ps analysis Java unix, Analyzing java process on unix, jstak for JVM threads analysis, strace JVM analysis,lsof JVM analysis, strace JMV debug on unix, truss linux, linux process management, linux cpu utilization, top command linux, linux monitoring tools, monitor linux server, linux monitors, linux monitoring software,ubuntu truss, top grep, top command

Linux operting system is very powerful and if we know the correct tools to debug its much easier then any other operating system. Here are few good commands to be used while debugging things on Linux/Unix environment.
[Continue reading]

Linux: Resetting a user's password

Question: How do I reset a user’s password under any Linux distribution from command prompt?

Answer: To reset a user’s password, use passwd command. You have to change it to a different password.
Login as the root user
Open terminal or shell prompt
Type the following command:
# passwd username
For example, reset a tom’s password, enter:
# passwd john
Type a password [...]

Unix/Linux Display Variable

Unix Linux set display variable, setting display variable, what is display variable, export display variable, set env display variable value,how to set display variable,Command to set display variable, set command DISPLAY variable, remote display on unix, display unix screen on windows

Using Linux, and especially configuring Linux, normally require some insight, and we strongly suggest (to inexperienced Linux users) to get some help from a system administrator.

In short, you must open up a shell (csh, bash, etc), so that it is possible to issue commands on Linux. Then you must enter the commands to set the environment variable, as explained in the setup-instructions.

You must make sure that the command for setting the DISPLAY variable is called before starting the application server.

There are many discussions/guides on the Internet regarding this issue. Here is an extract from one:

1. What is DISPLAY variable?

The magic word is DISPLAY. In the X window system, a display consists (simplified) of a keyboard, a mouse and a screen. A display is managed by a server program, known as an X server. The server serves displaying capabilities to other programs that connect to it.

A display is indicated with a name, for instance:

* DISPLAY=localhost:4

The display consists of a hostname (e.g., localhost), a colon (:), and a sequence number (e.g. 0 and 4). The hostname of the display is the name of the computer where the X server runs. An omitted hostname means the local host. The sequence number is usually 0. It can vary if there are multiple displays connected to one computer.

If you ever come across a display indication with an extra .n attached to it, that's the screen number. A display can actually have multiple screens. Usually there's only one screen though, with number n=0.

Other forms of DISPLAY exist, but this will do for our purposes.

2. Telling the Client

The client program (for instance, your graphics application) knows which display to connect to by inspecting the DISPLAY environment variable. This setting can be overridden, though, by giving the client the command line argument -display hostname:0 when it's started. Some examples may clarify things.

Our computer is known to the outside as, and we're in domain If we're running a normal X server, the display is known as We want to run the drawing program xfig on a remote computer, called my.remote.machine, and display its output here on

If you have csh running on the remote computer:

remote% setenv DISPLAY
remote% xfig &

Or alternatively:

remote% xfig -display &

If you have sh running on the remote computer:

remote$ export DISPLAY
remote$ xfig &


remote$ xfig &


remote$ xfig -display &

It seems that some versions of telnet automatically transport the DISPLAY variable to the remote host. If you have one of those, you are lucky, and it's automatic. If not, most versions of telnet do transport the TERM environment variable; with some judicious hacking it is possible to piggyback the DISPLAY variable on to the TERM