--
Hi,I tried to write a user-level client program performing basic write/read operation with Alluxio.After I run the following codes in my client program in order to setup Alluxio configuration:ClientContext.getConf().set(Constants.MASTER_HOSTNAME,*master host name*);ClientContext.getConf().set(Constants.MASTER_RPC_PORT, Integer.toString(*master port*);But this only works when the client program and the master are on the same machine. The client will not be able to find master when they are on different machines.After debugging, I found that ClientContext.getMasterAddress() doesn't return the real master address, but the default address(which is set when the ClientContext class was firstly loaded into JVM, before I can set the master address by the above code)According to the java doc of ClientContext, it is said that when I change the master hostname/port configuration, I should call init() again.Therefore, I changed the code to the following:ClientContext.getConf().set(Constants.MASTER_HOSTNAME,*master host name*);ClientContext.getConf().set(Constants.MASTER_RPC_PORT, Integer.toString(*master port*);ClientContext.init();However, this time I got the following error when making "createFile" rpc from FileSystemMasterClient to FileSystemMasterClientServiceHandler:Exception in thread "main" java.io.IOException: Frame size (1213486160) larger than max length (16384000)!at alluxio.AbstractClient.checkVersion(AbstractClient.java:109)at alluxio.AbstractClient.connect(AbstractClient.java:172)at alluxio.AbstractClient.retryRPC(AbstractClient.java:320)at alluxio.client.file.FileSystemMasterClient.createFile(FileSystemMasterClient.java:111)at alluxio.client.file.BaseFileSystem.createFile(BaseFileSystem.java:91)at alluxioOperation.AlluxioBasicIO.getFileOutStream(AlluxioBasicIO.java:69)at alluxioOperation.AlluxioBasicIO.writeFile(AlluxioBasicIO.java:53)at alluxioOperation.AlluxioBasicIO.main(AlluxioBasicIO.java:132)My questions are:1) What should I do after I set the master hostname/port so that ClientContext.getMasterAddress() returns the correct value?2) Is it correct to manually call ClientContext.init() after I set the master hostname/port? If so, why did I get this error message?I am running Alluxio on two virtualBox machinesMany thanks,Nelson
You received this message because you are subscribed to the Google Groups "Alluxio Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to alluxio-user...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Hi Gene,Thanks for the excellent answer!!I found that I used the wrong port(19999) for data transmission.Every thing looks great now.Best,Nelson