On Sun, Jan 17, 2010 at 6:19 PM, Tarandeep Singh <[email protected]>wrote:
> On Sun, Jan 17, 2010 at 1:57 PM, Vladimir Klimontovich < > [email protected]> wrote: > > > Maybe, hadoop running MR jobs using different user? For example, if you > > followed installation instructions > > from official site or used rpm/deb packages hadoop using "hadoop" user to > > run jobs. And you probably using different user > > for running your test program. > > > > > Thanks Vladimir.. > I am not running hadoop as the "hadoop" user. Both my test program and > hadoop are run using same user. > From the exception, it is clear the DISPLAY variable is set properly, but > java is not able to connect to the X server (not sure either some > permission > issues or what) > My guess is you're either missing the XAUTHORITY variable, or it's pointed at a file that the user executing the task can't read. (as a side note, this seems like a really bad idea - why are your hadoop tasks trying to talk to an X11 server in the first place?) -Todd > > > > > On Jan 18, 2010, at 12:41 AM, Tarandeep Singh wrote: > > > > > Hi, > > > > > > I am running a MR job that requires usage of some java.awt.* classes, > > that > > > can't be run in headless mode. > > > > > > Right now, I am running Hadoop in a single node cluster (my laptop) > which > > > has X11 server running. I have set up my ssh server and client to do > X11 > > > forwarding. > > > > > > I ran the following java program to ensure that X11 forwarding is > > working- > > > > > > public class Test > > > throws Exception > > > { > > > public static void main( String[] args) > > > { > > > Process p = runtime.getRuntime( ).exec( "/usr/bin/xterm"); > > > p.waitFor( ); > > > } > > > } > > > > > > I ran it as- > > > ssh localhost "java Test" > > > and it worked confirming that X11 forwarding is working over SSH. > > > > > > However, when I run a Map Reduce program that uses java.awt.* classes > > > (trying to create an object that extends Frame), I keep getting this > > error- > > > > > > java.lang.InternalError- Can't connect to X11 window server using > > > 'localhost:10.0' as the value of the DISPLAY variable > > > > > > I printed the value of DISPLAY variable- > > > > > > echo $DISPLAY > > > :0.0 > > > ssh localhost > > > echo $DISPLAY > > > localhost:10.0 > > > > > > I understand this is more of a SSH and X11 related issue, but X11 > > forwarding > > > is working over SSH in my standalone programs, but not in MR program. > > That's > > > why I am posting the problem here. > > > > > > Any help is greatly appreciated. > > > > > > Thanks, > > > Tarandeep > > > > --- > > Vladimir Klimontovich, > > skype: klimontovich > > GoogleTalk/Jabber: [email protected] > > Cell phone: +7926 890 2349 > > > > >
