I am running kafka10 on a remote server and the JMX is enabled on port 9999.
JMX URL :- service:jmx:rmi:///jndi/rmi://kafka_host:9999/jmxrmi
When i try to connect to the JMX from my local network, it works fine and getting response within few secs.
But when i try to connect from my test servers, we get connection refused.
The ACL is opened from this host to the kafka host on port 9999.
Application code,
TopicJMXMetrics jmxMetrics = new TopicJMXMetrics();
JMXServiceURL serviceURL = new JMXServiceURL(jmxUrl);
JMXConnector connector = JMXConnectorFactory.connect(serviceURL, null);
MBeanServerConnection connection = connector.getMBeanServerConnection();
Is there any other setting required from Kafka or on the Application Side? Or, any other port to be opened
Thanks
Related
I've implemented a Xamarin app that successfully peers to another instance of itself running on another device using WiFiP2PManager, OnPeersAvailable and OnConnectionInfoAvailable (etc.).
My challenge now is I'd like the group owner to specify the PORT the client(s) will use to connect.
SERVER
var serverSocket = new ServerSocket(port); <<< PASS THIS PORT NUMBER TO THE CLIENT.
client = serverSocket.Accept();
CLIENT
client = new Socket();
InetSocketAddress socketAddress = new InetSocketAddress(address, port); <<< PORT PASSED FROM THE SERVER
client.Connect(socketAddress);
Is there any way I can pass additional information to the peer that it can use for connection, such as the port number?
Thanks
-John
I am trying to configure persistent sessions through a remote server with redis.
under sails.config.session I am configuring the following code to connect to my Server
module.exports.session = {
adapter: '#sailshq/connect-redis',
url:"redis://:pass#157.xxx.xxx.xxx:6379/0",
prefix: 'sess:',
secret: "secretSailsSessionDataHere",
cookie: {
maxAge: 1 * 60 * 60 * 1000
},
}
When I lift Sails with:
sails lift --redis or sails lift
The connection defaults to my localhost redis server. If I shutdown my local server it says connection refused from 127.0.0.1 when my server address is xxx.xxx.xxx It also spits out the following error
Redis connection manager failed unexpectedly. Details: Error: Error emitted from Redis client.
Error details:ReplyError: ERR invalid DB index
Any suggestions on how I can configure module.exports.sessions to use the remote server?
I have set up a radiud server on centos 6.8 and I have a switch that I want to call this radius server for authentication. The switch ip address is 10.2.1.4 which is there in the clients config file. Here is the part of my client conf file
client switch {
ipaddr = 10.2.1.4
secret = testing123
nastype = other
}
Below is the error that I am getting
... adding new socket proxy address * port 55146
Listening on authentication address * port 1812
Listening on accounting address * port 1813
Listening on command file /var/run/radiusd/radiusd.sock
Listening on authentication address 127.0.0.1 port 18120 as server inner-
tunnel
Listening on proxy address * port 1814
Ready to process requests.
Ignoring request to authentication address * port 1812 from unknown client
10.2.1.4 port 1037
Ready to process requests.
Can anyone please help me here?
Here is my smack code to connect ejabberd server
XMPPTCPConnectionConfiguration.Builder builder = XMPPTCPConnectionConfiguration.builder();
builder.setUsernameAndPassword("admin#manish-lenovo-g510", "admin");
builder.setServiceName("manish-lenovo-g510");
builder.setHost("192.168.1.2");
builder.setPort(5280);
XMPPTCPConnectionConfiguration build = builder.build();
AbstractXMPPConnection conn1 = new XMPPTCPConnection(build);
conn1.connect();
I am getting this error:
Exception in thread "main" org.jivesoftware.smack.SmackException$NoResponseException: No response received within reply timeout. Timeout was 5000ms (~5s). Used filter: No filter used or filter was 'null'.
at org.jivesoftware.smack.SmackException$NoResponseException.newWith(SmackException.java:106)
at org.jivesoftware.smack.SmackException$NoResponseException.newWith(SmackException.java:85)
at org.jivesoftware.smack.SynchronizationPoint.checkForResponse(SynchronizationPoint.java:253)
at org.jivesoftware.smack.SynchronizationPoint.checkIfSuccessOrWait(SynchronizationPoint.java:146)
at org.jivesoftware.smack.SynchronizationPoint.checkIfSuccessOrWaitOrThrow(SynchronizationPoint.java:125)
at org.jivesoftware.smack.tcp.XMPPTCPConnection.connectInternal(XMPPTCPConnection.java:837)
at org.jivesoftware.smack.AbstractXMPPConnection.connect(AbstractXMPPConnection.java:365)
if i open admin interface of ejabberd its opening so Why this code is not working. One more thing how to find the service name as i guess that might be the issue as i dont know the service name, i have given it randomly.
I think port should be the standard XMPP port which is 5222. 5280 is the port for web admin, which speaks HTTP, not XMPP.
Here is the scenario:
I have multiple application servers running locally for now (should be running in different host) --> each is listening on different port (at localhost).
I have a single client application running on Tomcat.
When startup Tomcat, login with different user's details with connect to different (above) servers remotely.
My problem is:
First, I startup Tomcat and logged in as userA, it then connected successfully to serverA(localhost:1000).
Then I logged out.
Logged in again as userB, it did NOT connect to serverB(localhost:1001) as expected; instead, it gave exception
"javax.net.ssl.SSLHandshakeException: Received fatal alert: certificate_unknown"
However, if I restart Tomcat, and login as userB first, it then connects successfully to serverB.
Does anyone know what the problem is?
I really appreciate any suggestion :)
Code for client Tomcat:
SetupClientKeystore();
SetupServerKeystore();
SSLContext context = SetupSSLContext();
SSLSocketFactory socketFactory = sslContext.getSocketFactory();
SSLSocket socket = (SSLSocket) socketFactory.createSocket(hostname, portNo);
GZIPOutputStream gZipOut = new GZIPOutputStream(socket.getOutputStream()); // no trust certificate found throws here
Code for serverA and B:
setupClientKeyStore();
setupServerKeystore();
setupSSLContext();
server = new ServerSocket(portNo);
SSLServerSocketFactory socketFactory = sslContext.getServerSocketFactory();
serverSocket = (SSLServerSocket) socketFactory.createServerSocket(portNo);
serverSocket.setNeedClientAuth(true);
while ( true )
{
Socket client = serverSocket.accept();
inStream = client.getInputStream();
BufferedInputStream bufferedIn = new BufferedInputStream(inStream); //unknown_certificate throws here
//do something here.....
}
"javax.net.ssl.SSLHandshakeException: Received fatal alert:
certificate_unknown"
This usually indicates that the server's certificate is not trusted.
Could it be that when you log-in as userA you load the trusted certificate of serverA and connect, and then when you try to connect to serverB you try to authenticate serverB using the certificate of ServerA (loaded when you logged in as userA)?
As a result the SSL handshake fails.
So when you restart and login as userB the appropriate certificate (i.e. of ServerB) is loaded and the connection is succesfull?
You have no code in your post but if you do it as I say, this explains the exception.