cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
avdhesh
Level 5

Getting Error during running "Capability Request.java" Example.

Hi,

I successfully run my server  on my localhost using "8090" port .when i try to run the "CapabilityRequest.java " i got some error .

I attached the error snapshot and also   "CapabilityRequest.java"  file that i am using.

 

0 Kudos
(33) Replies
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Hi @avdhesh ,

What is the server endpoint you are using with your example?  For a local license server running on port 8090 you should be running the CapabilityRequest example with the options:

-server  http://locahost:8090/fne/bin/capability

Best regards,

Jim

 

0 Kudos

Thank you for Reply.
i change the argument from "-server http://locahost:8090/request" to -server "http://locahost:8090/fne/bin/capability" but i got the same error.
0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Hello @avdhesh ,

I tried out your CapabilityRequest.java,  making only one change to the file as my FNE local server is on the default port (7070):

args = new String[]{"-server", "http://localhost:7070/fne/bin/capability"};

I got the expected results as shown below (no features are requested from the server as options.addDesiredFeature is commented out).

Number of features loaded from trusted storage: 0
request url - -http://localhost:7070/fne/bin/capability
Successfully processed response.
Response data
Vendor dictionary:
none
Response status:
none
Machine Type:
PHYSICAL
Confirmation request needed: no
Number of features loaded from capability response: 0
Unable to acquire survey: Requested feature was not found.

I'd recommend creating a support ticket so that someone can work with you directly to help resolve your problem.

Best regards,

0 Kudos

Currently we are in evaluation period so how can i create a support ticket.
0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Please contact your Flexera Sales Representative to ensure you get the proper support for your evaluation.

Thank you,

0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

In the meantime can you provide the output from flexnetlsadmin -status  and flexnetlsadmin -features?  The flexnetlsadmin utility can be found in the /enterprise directory of the license server kit.

0 Kudos

we can't locate the enterprise directory in the license server kit provided to us. Also, can't location flexnetlsdmin file in the provided toolkit.
We are referring to "FNE_JavaXTUserGuide_2019R1.pdf" file for instructions. hope this is right file. please confirm and suggest how to proceed further as we are running out of our evaluation time.
0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Hi @avdhesh ,

In your first post you mentioned you have your server running on your localhost on port 8090.   Are you referring to a FlexNet Embedded local license server or are you using the the test back-office server capserverutil?  With the limited information provided I originally assumed it was a FlexNet Embedded local license server but am now thinking you may be using the test back-office server.    Also it would be helpful if you could provide some identifying information from your evaluation such as a Customer Number or Order Number.

Thanks,

0 Kudos

Hi,

Currently ,we using "FlexNet Publisher 2018 R4(11.16.2)Development Environment Guide" for run the server and "FlexNet Embedded Client 2019 R1 Java XT SDK User Guide "  for java Development.

  
My order number is " SSF-0000557257 (PO# FNL Evaluation)"  and Account ID "MOA-000608327".
i just want to implement and integrate floating license server with our  tool.

please let me know if you required another information.

0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Thanks @avdhesh ,

I believe I now see the issue.  With a FlexNet Embedded Licensing only evaluation  (without the FlexNet Operations back office) you have 3 ways to obtain a license on a client device:

1) Manually generate a license (capability response) using the capresponseutil utility and then load this response on the client device.

2) Install a FlexNet Embedded local license server, load a floating license on the local license server generated with capresponseutil, then point your license requests (capability requests) from your client devices to the local license server.  If the license server is running on your local system then license requests should be directed to http://localhost:7070/fne/bin/capability   (7070 is default local license server port)

3) Use the test back office utility, capserverutil to respond to license requests from the client device.  If you are running the capserverutil on your localhost the license requests from clients should be directed to http://localhost:8080/request (8080 is default port for capserverutil)

If your goal is to quickly test the process of getting a license back from a server to your client device then option 3 is the easiest.  

Run the following from the tools directory:

.\capserverutil.bat -id .\IdentityBackOffice.bin -template .\templates\ -v

*********************************************************
This utility is for testing purposes only.
It is not intended for production environments.
*********************************************************

Info : [11:01:43] Processing template files in .\templates\:
Info : [11:01:43] 1234567890.lic
Info : [11:01:43] survey:1.0:1
Info : [11:01:43] highres:1.0:1
Info : [11:01:43] li1.lic
Info : [11:01:43] f1:1.0:5
Info : [11:01:43] f2:1.0:10
Info : [11:01:43] Listening on port 8080
Info : [11:01:43] capserverutil started. Press ENTER to exit.

If you then run the CapabilityRequest.java example from the SDK out of the box (no modifications) with the options:

-server -server http://localhost:8080/request  

You should see the following output:

Number of features loaded from trusted storage: 0
Successfully processed response.
Response data
Vendor dictionary:
none
Response status:
none
Machine Type:
PHYSICAL
Confirmation request needed: no
Number of features loaded from capability response: 2
Successfully acquired "survey", version 1.0, 1 count.

In the capserverutil window you will see the following:

Info : [11:03:01] Received capability request from localhost
Info : [11:03:02] Client: 1234567890/STRING
Info : [11:03:02] Found matching device template for 1234567890
Info : [11:03:02] that includes features:
Info : [11:03:02] survey:1.0:1
Info : [11:03:02] highres:1.0:1
Info : [11:07:12] Received capability request from localhost
Info : [11:07:12] Client: 1234567890/STRING
Info : [11:07:12] Found matching device template for 1234567890
Info : [11:07:12] that includes features:
Info : [11:07:12] survey:1.0:1
Info : [11:07:12] highres:1.0:1

If your goal is to test out the local license server functionality as well then you will need to download the FlexNet Embedded license server from the Flexera Product and License Center and follow the process outlined in step 2 above.

Best regards,

 

Thank you so much for your Reply.


Please tell me how i install a FlexNet Embedded local license server on windows  as mention in point 2.

0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Hi @avdhesh ,

You will need to download the FNE Server from FlexNet Embedded Licenses & Tools in the Flexera Product & License Center.   The FNE Documentation section also has a License Server Producer Guide and Administration Guide.  

A reference video is available here:  

Installation, Configuration and Activation of a FlexNet Embedded License Server:  https://youtu.be/iwkf3uqkNkQ

Since you are not evaluating the FlexNet Operations Back Office system you will need to manually generate a license (capability response) using the capresponseutil utility which you can load onto your server once it is up and running.  Refer to your SDK User Guide for details on how to use capresponseutil.

Best regards,

0 Kudos

Thank you for your reply.

We have successfully started the server and install  and also run the service but we got a problem with activating the server. here are the steps i followed after starting the service:

1:   capresponseutil.bat -id IdentityBackOffice.bin -host A44CC838C333/Ethernet demo.lic demo.bin 

2:copy demo.bin to ./enterprise

3: activating server using "flexnetlsadmin -activate -load demo.bin" command then we  got an Error:

ERROR: { "key" : "Capability response host ID does not match. Expected A44CC838C333/Ethernet, got STRING:A44CC838C333/Ethernet", "message" : "Capability response host ID does not match. Expected A44CC838C333/Ethernet, got STRING:A44CC838C333/Ethernet"}

 

please suggest if we are going wrong.

Thanks.

0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Hi @avdhesh ,

Great, looks like you are very close.  First please make sure your demo.lic license is specified correctly for a served license.  There are many options depending on the type of license you want to generate however here's an example of a license with a permanent and expiring feature:

SERVER this_host A44CC838C333
INCREMENT f1 demo 1.0 permanent 5 START=11-oct-2019
INCREMENT f2 demo 1.0 10-oct-2020 10 START=11-oct-2019

Next generate the capability response for the served license using the following options:

capresponseutil.bat -id IdentityBackOffice.bin -host A44CC838C333 -idtype ethernet -lifetime 0 demo.lic demo.bin

Copy demo.bin to the /enterprise directory and activate the server with flexnetlsadmin -activate -load demo.bin

Thanks,

0 Kudos

Thank you so much for helping me out.
We successfully activate the server but when i run the 'CapabilityRequest.java' using 'args = new String[]{"-server", "http://localhost:7070/fne/bin/capability"};' argument then i got this Error:

Number of features loaded from trusted storage: 0
request url : http://localhost:7070/fne/bin/capability
Licensing exception: Request has invalid content.
Server report: {
Capability requests are only expected from clients, not servers (type=public, code=BAD_REQUEST(51))
}
Error report=[1,7E3,4,0[7000001C,7100002F,250137]]

0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Hi @avdhesh,

Are you sure you are using the IdentityClient.java?  A couple things to try:

1)  Run the CapabilityRequest example with the options -generate caprequest.bin to generate a capability request file.   Copy to the Java SDK /tools folder and then run printbin on the caprequest.bin file to see the contents and then post here.

2) Eliminate the java application and try to send a capability request directly to your server using  the caprequestutil utility in the /tools folder.  Use the following syntax, substituting "F1" with a feature that exists on your server:

  ./caprequestutil.bat -id .\IdentityClient.bin -host TESTCLIENT http://localhost:7070/request -feature F1 1.0 1

Thanks,

0 Kudos

Thank you so much for helping me .
0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

So do you now have the CapabilityRequest.java sample working?

0 Kudos

yeah, CapabilityRequest.java Sample now working after regenerate the IdentityClient.java and can you please tell me the same process in linux machine. 

0 Kudos
jberthold
Revenera Moderator Revenera Moderator
Revenera Moderator

Hi @avdhesh ,

Excellent, glad to hear you are now up and running with the local license server and are able to run the Capability Request java example.    The process is the same for Linux, there are instructions in the Guides on how to install a server on a linux system and there is a Capability Request example in the linux SDK.

 

Best regards,

 

0 Kudos