AppConKit 3: How do I enable the device log view? - appconkit

Currently, I am developing an App using the AppConKit 3. In the debug perspective of the IDE, there is a view at the bottom called "Device Log". It is supposed to display log messages generated by the mobile device. There are two fields to input an URL and a port and a "Connect" button. I'm not sure which settings to use, the default settings 127.0.0.1 with port 4012 did not work for me - I couldn't see any log messages.

To enable the log view, you have to enable the log server in your app's server part. Switch to the Java perspective, unfold the "WebContent" area and also the "WEB-INF". In there, you should find the ibiz.prop file. In that file, uncomment the two lines
#the port the remote device connects to
devicelogport            = 4000
#the port the remote UI connects to
guilogport                = 4012
When you now restart your app (server), you should be able to connect to the device log server and see log messages.

Related

Seeing scripts in unix box - Information Server

We did some changes in login.wpcs to change the user name provided in UI to lower case as LDAP login was not case sensitive. Now the issue is we are not able to login as 'Admin' and we have not given any of the roles permissions to change the ACG/Roles etc. Also Screen level access is not permitted to any other role. How do I now login into the company and change the login script. I tried to mount the document store '/scripts' folder but it also didn't help. I am not able to see the scripts in the unix box mounted location.
Once login.wpcs script is messed up can't even get to the UI to clean up. Try the following procedure
 
1. From a working MDM CE environment of same version, take a Selective Environment Export which just contains the /scripts/login/Login.wpcs file from docstore. Same can be achieved by running the following script snippet in sandbox
 
var envObjList = new EnvObjectList();
envObjList.setTypeToExport("DOC_STORE");
envObjList.addObjectByNameToExport("/scripts/login/Login.wpcs", null, "CREATE_OR_UPDATE");
var result = exportEnv(envObjList, "export_20120501_234914.zip");
out.println("result: " + result);
 
 
2. Run sh $TOP/bin/importCompanyFromZip.sh  --company_code= --zipfile_path=
 
Now try logging in.

Failed to connect to SQL Database Premium Plan on Bluemix (Error code SQL1776N)

I develop an application using "Ruby on Rails runtime" and "SQL Database Premium Plan" on Bluemix.
When I restart the application, it cannot connect to SQL Database.
The application was operating normally until yesterday.
How can I solve this problem?
Log Messages
2016-04-22T16:19:37.748+0900[App/0]ERRFailed to connect to [IXXXXXXX] due to: uncaught throw :"Connection failed: [IBM][CLI Driver] SQL1776N The command cannot be issued on an HADR database. Reason code = \"1\". SQLCODE=-1776"
2016-04-22T16:19:37.748+0900[App/0]ERRrake aborted!
2016-04-22T16:19:37.749+0900[App/0]ERR/home/vcap/app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.3/lib/active_record/connection_adapters/abstract/connection_pool.rb:263:in `block in connection'
2016-04-22T16:19:37.749+0900[App/0]ERR/home/vcap/app/vendor/bundle/ruby/2.2.0/gems/activerecord-4.2.3/lib/active_record/connection_adapters/abstract/connection_pool.rb:348:in `checkout'
...
This should be a temporary issue, it should start to work again shortly. If the problem persists you could open a support request using one of the following methods:
Use the Support Widget. It is available from the user avatar in the
   upper right corner of the main Bluemix UI.  After opening the support
   widget panel, select Get Help > Get In Touch , select the type of
   assistance you need, and then fill out the support form.
Use the Support Site 'Get Help' form. This form is available on a separate site that is made available for ticket submission when you cannot log into Bluemix and access the Support Widget.  Go to http://ibm.biz/bluemixsupport and fill in the support request form.
Please remember to provide the VCAP_SERVICES environment variable value to the SQL Database team.

sending email using cdo & classic asp on dedicated server (memset) in IIS6?

Firstly I am new to setting up a server so appologies for being dumb.
I have a website which is hosted on a provider called memset its a 2008r2 box using ms sql 2012. My domain was bought from my 1and1.co.uk account and the dns is pointing to my site - all working fine - site works! However in using cdo to send mail in a classic asp page I am struggling to understand how - what i should do.
I did create some email accounts on 1and1... but am unsure if this is correct or if i should do something different? I have set the site up to use iis7, and installed iis6 / smtp server on 2008r2.
How should i configure iis6? should i send it via my new server i am creating - or forward the emails to 1and1 - and if so how do i do this? is this to do with smart host at all ??
So confused.
I am a web / dba developer by trade - not a server manager.
Running Classic ASP on IIS 7.x Checklist:
(1) Do not name site folders with .com, .net, etc at the end.
(2) Create NEW user account:
- [app pool user identity] is user: app_pool_blahblahblah, pw: xxxxxx
(3) In Server Manager, right click "Web Server (IIS)" and choose "Add Role Services". Add IIS 6 Management Compatibility.
(4) In Server Manager under features add SMTP server.
Install IIS6 Resource Kit so you can
Use Metabase Explorer.
Grant the [app pool user identity] user read access to the /Local Machine/SmtpSvc/ and /Local Machine/SmtpSvc/1/ nodes in the IIS Metabas
(5) In Application Pool, advanced settings:
- set .Net Framework version to "v2.0" <-- fixed issue with default asp doc not working!
- set "Enable 32-bit applications" to TRUE.
- set managed pipeline mode to "Classic". <-- this may not be necessary.
- under Process Model, change Identity to "[app pool user identity]" account we created.
- be sure "load user profile" is set to FALSE.
- be sure "maximum worker processes" is "1".
(6) Mail: In IIS 6 Management Console:
http://intellitect.com/configuring-windows-smtp-server-on-windows-2008-for-relay/
- Under SMTP Virtual Server Properties:
-- "Access" Tab --> Relay: add IPs of this box, including 127.0.0.1
-- "Delivery" Tab --> Advanced: for "fully qualified domain name" put name of box
-- "Delivery" Tab --> Advanced: for "smart host" put "dedrelay.secureserver.net"
-- "Delivery" Tab --> Outbound connections: Make sure limits are set to 100.
-- "Security" Tab --> add "[app pool user identity]" and IIS_IUSRS
(7) In IIS 7.5 under web site:
- Under ASP:
-- ONLY IF PROBLEM: set enable buffering to "false"
-- under limits change max req entity and buffering limit to 1024000000
-- set script language to "vbscript"
-- set "send errors to browser" to true
- Authentication --> edit "Anonymous Authentication" and set to app pool identity.
- ONLY IF PROBLEM: under error pages: under 404 set to "/home.asp" and "execute URL"
- ONLY IF PROBLEM: edit c:\windows\system32\inetsrv\config\applicationHost.config: change to "Allow"
- under Management (at bottom) go into "Configuration Editor".
-- In the dropdown go to System.web --> http runtime and change maxRequestLength to 1024000000
-- In the dropdown go to System.webserver/security/requestFiltering --> chg allowDoubleEscaping=true
(8)
Set "Modify" Permissions for [app pool user identity] for the following folders:
- your web site
- windows\temp
- inetpub\temp
- inetpub\mailroot
- ONLY IF PROBLEM: windows\serviceprofiles\networkservice\AppData\Local\Temp?
AND Set Permissions in registry:
- ONLY IF PROBLEM: HKLM\SOFTWARE\Wow6432Node\Microsoft\Jet\4.0\Engines?
FOR THESE USER ACCOUNTS:
- IIS_IUSRS
- [app pool user identity]
- NETWORK SERVICE
(9) Install and Use Process Monitor to find permissions issues - filter
(10) Make sure SSL v2 is not being used:
Click Start, click Run, type regedit, and then click OK.
In Registry Editor, locate the following registry key/folder:
HKey_Local_Machine\System\CurrentControlSet\Control\SecurityProviders
\SCHANNEL\Protocols\SSL 2.0
Right-click on the SSL 2.0 folder and select New and then click Key. Name the new folder Server.
Inside the Server folder, click the Edit menu, select New, and click DWORD (32-bit) Value.
Enter Enabled as the name and hit Enter.
Ensure that it shows 0x00000000 (0) under the Data column (it should by default). If it doesn't, right-click and select Modify and enter 0 as the Value data.
Restart the computer.
Verify that no SSL 2.0 ciphers are available at ServerSniff.net or the Public SSL Server Database
(11) SSL issue where Safari tells client that it needs a certificate.
- Go into IIS settings for the SSL-protected site.
- Click on "SSL Settings"
- Choose "ignore".
If you need to send emails, I found that using the Mandrill Email API worked for me (mandrill.com). I am using Classic ASP and was having issues on my web host to do with exceeding the monthly limit for emails sent using their mail servers.
I had to learn a bit about how to use JSON and Classic ASP but it was worth the time.
If you need any example code for how to do it, let me know, would be happy to help.
At least if you do that it'll save you a lot of server config and setup work.

Monodroid GenyMotion access internet through code

I have struggling for the past week to try to get this to work. I have downloaded this fantastic tool which is the genymotion emulator for android. But I can't access the internet from my line of code.
using( WebClient wbclient = new WebClient() )
{
try
{
String URI = "http://www.timeapi.org/utc/now"; // test purpose only
Stream s = wbclient.OpenRead( URI );
using( StreamReader r = new StreamReader( s ) )
{
string str = r.ReadToEnd();
}
}catch(Exception ex)
{
// handle...
}
}
This is a simple service that returns the time. If I enter this address in the browser of the guest device genymotion ( android 4.2.2 - API 17 ), the browser works perfectly and the time is returned. But the above code throws an exception "Connection time out". Why within my guest device the above url can be retrieved from the browser and properly display the time and throw an exception when access in code via WebClient object? Thanks
It's not your code: you have discovered that genymotion is not on the internet - this flaw is by official design. this happens because genymotion (a wrapper for VirtualBox) dis-disconnects the correct adapters (that you may or may not have set in VirtualBox) and uses it's own (faulty) "Host Only Adapter" networking setting instead, and then HIDES that it does this.
To fix this highly unfair "bug" (feature?) you have to go into VirtualBox, find the GenyMotion machine by name and then power it off, right click to "Settings" networking and then click under "adapter 2" (tab) and tick "enable network adapter" then click "attached to:>Bridged Adapter" assuming your pc that you are running it all on runs under DHCP it will set up a IP for the Android VM that GenyMotion proclaims as it's own (which it is not)

Connecting to Openfire server using XMPP in iOS

I have installed openfire into my mac. In opnefire server information my Server Name is "john-imac.local.lan" and Host Name is "john-imac.local.lan"
I have created two users user123,user234 in there. In my iphone project i have xmpp framework running fine when i use gmail credentials. To connect to openfire i made these changes
[xmppStream setHostName:#"john-imac.local.lan"];
xmppStream.myJID = [XMPPJID jidWithString:#"user123#john-imac.local.lan"];
(void)xmppStreamDidConnect:(XMPPStream *)sender
{
NSLog(#"XMPP DID CONNECT");
[xmppStream authenticateWithPassword:#"user001" error:NULL];
}
I guess these are changes that i need to make in my project to get connected to Openfire. But when i run the application i get this XMPP DID NOT AUTHENTICATE
<failure xmlns="urn:ietf:params:xml:ns:xmpp-sasl"><not-authorized></not-authorized></failure>
What is that i am missing.
I do not think it is a problem in the code. I think it is just a miss configuration in your Openfire sever. First make sure your users and passwords were created correctly in your Openfire. Second check the "Server Name" property if it was set correctly. Go to you admin panel -> Server Information -> Server Name. If this property is not set to "john-imac.local.lan" then your server will fail in authorizing your users. To set it up pressed on the Edit properties button and change the name of your sever.
I hope this helps you solving the problem you are having!
go to Server -》Server Manager -》 System Properties
In the page bottom, there is a form, in “Property name” put “xmpp.fqdn” and in “Property value” put your domain name
Restart openfire