dbus.exceptions.DBusException: org.freedesktop.DBus.Error.LimitsExceeded - linux

Using D-bus am trying to automatically connect raspberry pi with mobile through Bluetooth, it works fine for 265 times but again when I try I get an error
I created a file /etc/dbus-1/session-local.conf and added
<!DOCTYPE busconfig PUBLIC "-//freedesktop//DTD D-Bus Bus Configuration 1.0//EN"
"http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
<busconfig>
<limit name="max_replies_per_connection">1200</limit>
</busconfig>
But still am getting the same error
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.LimitsExceeded: The maximum number of active connections for UID 1000 has been reached
devise doesnt exist
Can anyone let me know if there is anyway to change d-bus limits
Please help me out am new to it

Related

Android Things Rasperry PI GPS and Bluetooth Error

I am getting an error once I load my app in Android Things on Rasperry PI, it shows a message about "Bluetooth has stopped".
This happens just after registering the GPS Driver. it does not affect the functionality and it is only at the first time.
It has already some permissions in the xml
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="com.google.android.things.permission.MANAGE_GNSS_DRIVERS" />
<uses-permission android:name="com.google.android.things.permission.USE_PERIPHERAL_IO" />
Looks like it requires to switch the port to GPS or unregister Bluetooth first... By the way I am not using bluetooth feature in the app. any idea?
thanks
if (context.checkSelfPermission(Manifest.permission.ACCESS_FINE_LOCATION)
!= PackageManager.PERMISSION_GRANTED) {
Log.e(TAG, "No permission");
return;
}
try {
// Register the GPS driver
mGpsDriver = new NmeaGpsDriver(context, "UART0", UART_BAUD, ACCURACY);
mGpsDriver.register();
This is a known limitation of the Raspberry Pi, as per the pinout documentation:
The Raspberry Pi has pins that are multiplexed between various board functions. Some board functions cannot be used simultaneously (for example, enabling Bluetooth and using the UART0 port for peripheral I/O).
So there may be a process running in the background which is still using Bluetooth and causing the driver to crash.

Javascript fast load does not work in Liferay on WebLogic

I have deployed Liferay 6.2 GA4 portal on WebLogic server 10.3.6.0. If the javascript.fast.load property is enabled, the packed javascript version is not got (downloaded) from /combo url. In web browser console the following errors are displayed:
GET https://www.mywebsite.cz/liferay-portal/combo/?browserId=other&minifierType=&languageId=en_US&b=6203&t=1448975784000&/liferay-portal/html/js/aui/color-base/color-base-min.js&/liferay-portal/html/js/aui/event-touch/event-touch-min.js&/liferay-portal/html/js/liferay/dockbar.js 404 (Not Found)
Uncaught TypeError: Cannot read property 'init' of undefined
Due to this for example dockbar doesn't work. From source code it looks like ComboServlet can't get servlet resources found in /combo url parameters. If javascript.fast.load is disabled, portal seems to work.
Weblogic.xml:
<weblogic-web-app
xmlns="http://xmlns.oracle.com/weblogic/weblogic-web-app"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd http://xmlns.oracle.com/weblogic/weblogic-web-app http://xmlns.oracle.com/weblogic/weblogic-web-app/1.2/weblogic-web-app.xsd"
>
<jsp-descriptor>
<keepgenerated>true</keepgenerated>
<page-check-seconds>60</page-check-seconds>
</jsp-descriptor>
<session-descriptor>
<persistent-store-type>replicated_if_clustered</persistent-store-type>
</session-descriptor>
<container-descriptor>
<prefer-application-packages>
<package-name>antlr.*</package-name>
<package-name>com.ctc.wstx.*</package-name>
<package-name>org.antlr.*</package-name>
<package-name>org.apache.commons.lang.*</package-name>
<package-name>org.mozilla.*</package-name>
<package-name>org.xmlpull.*</package-name>
</prefer-application-packages>
<optimistic-serialization>true</optimistic-serialization>
<show-archived-real-path-enabled>true</show-archived-real-path-enabled>
</container-descriptor>
<context-root>/liferay-portal</context-root>
<library-ref>
<library-name>ext-portal-dependencies</library-name>
<specification-version>1.0</specification-version>
<implementation-version>1.0</implementation-version>
<exact-match>false</exact-match>
</library-ref>
</weblogic-web-app>
Does anybody know what could be the problem? Some WebLogic or Liferay settings? Thanks for any idea or help.
I've had a comparable problem long ago on tomcat when there were problems with the temporary file path - e.g. it growing too long. This might happen in a deeply nested filesystem, or when the total path length is limited.
One of the path-length-limiting factors that I'm aware of is an encrypted home folder on Linux. Also, if the temporary filesystem runs full, the compressed file won't be written and consequently can't be served to the browser.
Check something along those lines, and please report back.
After several days of solving the problem I found the main cause of this problem was this:
Because the customer didn't want to have portal dependencies (portal-service.jar, portlet-api.jar, ...) as domain libraries, I deployed it as Java EE Shared Libraries. Obviously it works differently than I expected. So after persuasion of customer, I put liferay dependencies to domain lib folder and suddenly everything started to work.

dotnetnuke cant open my page

Am trying to learn how to use dotnetnuke so am kinda new to it. I installed it correctly and i set up a user in server management studio. So when i try to open my page localhost\mypage i get these errors:
HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid.
Detailed Error Information:
Module IIS Web Core
Notification Unknown
Handler Not yet determined
Error Code 0x8007000d
Config Error Configuration section not allowed in a <location> tag
Config File \\?\C:\inetpub\wwwroot\ANTONISDB\web.config
Requested URL http://`localhost`:80/dotnetnuke
Physical Path
Logon Method Not yet determined
Logon User Not yet determined
Config Source:
210: </system.web>
211: <runtime>
212: <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
Anyone knows whats wrong with this?
Check to make sure the Application Pool for the virtual directory/application is configured to USE ASP.NET 4.0, DNN won't run with .NET 3.5 anymore (starting with Version 7)

Disable use of a proxy in IBM Social Business ToolKit

I am running into a Access-Control-Allow-Origin error when I am trying to build an OpenSocial Gadget with IBM Social Business ToolKit for IBM Connections.
I have 3 servers participating in this gadget:
CONNECTIONS: The IBM Connections 4.0 Server that will be hosting the gadget
IBMSBT: A server hosting the Social Business Toolkit scripts and app
JESSE_API: My application server hosting the API that the gadget will be using
The gadget xml is loaded from JESSE_API by CONNECTIONS. The view for the gadget loads scripts and makes calls to JESSE_API. I would like to use the Social Business Toolkit for accessing parts of Connections so the gadget view is also loading those components from IBMSBT.
I am currently just prototyping this - I was able to make this work just using the Connections 4.0 API but would rather use the SBT libraries.
For getting started I just dropped in the "Get My Communities - Main Window" snippet into my gadget's view and included the following scripts:
<script type="text/javascript">
var djConfig = {
parseOnLoad: true
};
</script>
<script src="//IBMSBT/sbt.dojo180/dojo/dojo.js"></script>
<script src="//IBMSBT/sbt.sample.web/library?ver=1.8.0"></script>
Reloading the gadget gives the following error in the console:
XMLHttpRequest cannot load http://IBMSBT/sbt.sample.web/service/proxy/connections/http/CONNECTIONS/communities/service/atom/communities/my?ps=5
Since my gadget was running on the CONNECTIONS server I should not need the proxy. I did not see an immediate way to disable the proxy for this endpoint so I just set a breakpoint in Endpoint.js before line 160 where the following code is executed:
if(this.proxy) {
args.url = this.proxy.rewriteUrl(args.url,this.proxyPath);
}
When the breakpoint hits, I set this.proxy = null which causes the proxy to not be used and the community information to return correctly.
My question is should I be doing this differently or should a way be added to bypass the use of a proxy given the structure I am currently using?
The SDK Proxy does not need to be used in this environment. We've made some changes in this area recently as part of the work to support OAuth. What you need to do is configure the SDK library initialization so it knows it's running in a Gadget context.
Take a look at the acme.social.sample.webapp:
In faces-config.xml you will see an environment for use with OpenSocial
<!-- OpenSocial Environment -->
<managed-bean>
<managed-bean-name>openSocial</managed-bean-name>
<managed-bean-class>com.ibm.sbt.jslibrary.SBTEnvironment</managed-bean-class>
<managed-bean-scope>application</managed-bean-scope>
<managed-property>
<property-name>endpoints</property-name>
<value>acmeAirOS:acmeAir</value>
</managed-property>
</managed-bean>
The endpoint definition used a gadget endpoint (further down in the faces-config.xml)
<managed-bean>
<managed-bean-name>acmeAirOS</managed-bean-name>
<managed-bean-class>com.ibm.sbt.services.endpoints.GadgetOAuthEndpoint</managed-bean-class>
<managed-bean-scope>session</managed-bean-scope>
<managed-property>
<property-name>url</property-name>
<value>%{acme.url}</value>
</managed-property>
</managed-bean>
In the gadget xml (or imported html) when loading the library pass a parameter to indicate that the OpenSocial environment should be used
<script type="text/javascript" src="../../library?ver=1.8.0&context=gadget&env=openSocial"></script>
Based on the information from Mark Wallace, I looked a bit closer at what the /library/ endpoint was doing.
I was not able to make it quite work exactly with that code but the following works nicely:
<script data-dojo-config="parseOnLoad:true"
src="//IBMSBT/sbt.dojo180/dojo/dojo.js.uncompressed.js"></script>
<script>
if(typeof _sbt=='undefined' || window._sbt_bridge_compat){
_sbt=0;
dojo.registerModulePath('sbt','http://IBMSBT/sbt/js/sdk/sbt');
dojo.registerModulePath('sbt/_bridge','http://IBMSBT/sbt/js/sdk/_bridges/dojo-amd');
dojo.registerModulePath('sbt/dojo','http://IBMSBT/sbt/js/sdk/dojo');
define('sbt/config',['sbt/Proxy','sbt/_bridge/Transport','sbt/authenticator/Basic','sbt/Endpoint'],function(Proxy,Transport,Basic,Endpoint){
window.sbt = {};
sbt.Properties={
"sbtUrl":"http:\/\/IBMSBT\/sbt\/js\/sdk"
};
sbt.Endpoints={
'connections':new Endpoint({
"baseUrl":"http:\/\/connectionsww.demos.ibm.com",
"transport":new Transport({}),
"authType":"basic",
"authenticator":new Basic({}),
"proxyPath":"connections"})
};
return sbt;
});
}
</script>
The contents of the script tag was basically the output from the /library/ endpoint. The sbt.Endpoints.connections definition originally included a defined proxy attribute which I removed.

How to get jetty to send jsessionid-cookies with the secure-flag when using a secure channel

I am using Tomcat in my production environment and jetty in my testing environment (via jetty-maven-plugin).
Tomcat sets the secure-flag on a jsessionid-cookie, when it is sendig it over a secure channel (https), which looks like a good idea to me, becaus it prevents the session from being exposed, when the user klicks on a http://-link. But Jetty does not so!
I would like to force Jetty to behave like Tomcat and always set the secure-flag on jsessionid-cookies send over a secure channel, because otherwise, my testing environment behaves considerably diffrent then my production environment. But I cannot find any configuration option to achive this.
I am also wondering, if this is a security-bug in Jetty. Because not marking a jsessionid-cookie send over a secure channel as secure reveals the secure session if the user switches back to an unsecure channel.
I am adding the following just to show the complete example that worked for me.
Put the following in WEB-INF/jetty-web.xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure.dtd">
<Configure class="org.eclipse.jetty.webapp.WebAppContext">
<Get name="sessionHandler">
<Get name="sessionManager">
<Set name="secureCookies" type="boolean">true</Set>
</Get>
</Get>
</Configure>
The configuration changes needed to set the secureCookies property can be added to the jetty-web.xml file:
<Get name="sessionHandler">
<Get name="sessionManager">
<Set name="secureCookies">true</Set>
</Get>
</Get>

Resources