Jump to content
Changes to the Jaspersoft community edition download ×
  • This documentation is an older version of Jaspersoft for AWS User Guide. View the latest documentation.

    This section describes the processes for creating a JasperReports Server instance or cluster inside a Virtual Private Cloud (VPC).

    note-icon-ns.png.0351874bbc511ceeac94a7e299bb88fa.png

    Your Jaspersoft software is charged separately from the AWS EC2 instance charges. Please make sure you follow these instructions to turn off your EC2 instance server running Jaspersoft after use. If not, you will continue to be charged by the hour for EC2 use. Note that when you stop your EC2 instance server no one will have access to the reports or dashboards you've created until you restart the EC2 instance server. When you stop an EC2 instance server, you will still be charged the small EBS charge. If you don't want to be charged for EBS, make sure you terminate your EC2 instance server. Note that in this case none of your work will be retrievable, unless you're using an auto-scaling cluster.

    Creating a JasperReports Server Instance Inside a VPC

    The JasperReports Server instance will be hosted in your Virtual Private Cloud (VPC).

    To create a new JasperReports Server instance in a VPC:

    1. Select the Jaspersoft product you want in the AWS Marketplace and follow the subscription process to get to the Configure the Software page.
    2. Under Fulfillment Option, select CloudFormation Template from the first drop-down list and Jaspersoft Stack Instance Inside a VPC from the second list.
    3. Select the software version and region, then click Continue to Launch.
    4. Under Choose Action, select Launch CloudFormation and then click Launch. The Create Stack page in the AWS console opens. Under Specify template, the Amazon S3 URL option is already selected and a URL for the template file is filled in. Do not change these options.
    5. Click Next. The Specify stack details page appears.
    6. In the Stack name field, give your CloudFormation stack a unique name.
    7. Choose an InstanceType.
    8. Choose the KeyName of your EC2 KeyPair.
    9. Choose the VpcId from your account.
    10. Choose the SubnetId from the VPC.
    11. Choose whether to create a publicly accessible IP address for the instance using EnablePublicIp. Default is True. Select False to refuse.
    12. In the SecuredIp field, enter the IP address and mask for SSH access.
    13. Click Next. The Configure stack options page appears.
    14. Add any tags you want use to simplify administration of your infrastructure.

    A tag consists of a key/value pair and will flow to resources inside your stack. You can add up to 10 unique keys to each instance, along with an optional value for each key.

    15. Select an IAM role for managing the stack's resources.
    16. Expand the Advanced section and set your notification, rollback, and other options.
    17. Click Next. The Review page appears.
    18. Double check your template, parameter, and option information.
    19. Click the acknowledgment check box, then click Create Stack. You'll see a message telling you your stack has been created. The Services web page, shows your stack's initial status as CREATE_IN_PROGRESS. It generally takes two to four minutes for the status to change to CREATE_COMPLETE.
    20. Select your complete instance and click the Outputs tab. Here you'll find information you'll need when you're ready to log into JasperReports Server:
         The URL for Getting Started with JasperReports Server .
         The name of your instance.
         The login name and password.
         The name of your S3LicenseBucket.

    Creating a JasperReports Server Cluster Inside a VPC

    Jaspersoft provides an auto-scaling cluster using Amazon Relational Database Service (RDS) that ensures that there are enough EC2 instances to handle the workload for your JasperReports Server application. With the cluster, instances are created and removed depending on CPU usage. It also provides a failover mechanism by storing your repository in an external database, so if something happens to an instance it will be replaced and connected to your existing repository. The cluster uses the Amazon Elastic Load Balancer (ELB) to route traffic and only supports PostgreSQL databases. You'll need to create and initialize your PostgreSQL database and make sure that it's in the same cloud as the VPC.

    The CloudFormation template for the cluster creates the following AWS resources:

    An Auto Scaling group that contains the EC2 instances for your JasperReports Server cluster. When creating the stack, you'll define the maximum number of instances in your cluster. The Auto Scaling group defines the thresholds for increasing and decreasing the instances in your cluster. For more information about auto scaling groups, see the AWS documentation:

    https://docs.aws.amazon.com/autoscaling/latest/userguide/AutoScalingGroup.html

    An Amazon ELB that works as a static endpoint (DNS Name - URL) and monitors the clustered JasperReports Server instances. If something happens to one of your instances—the instance fails or JasperReports Server stops responding—it will be replaced with a new one. For more information on ELB, see the AWS documentation:

    https://docs.aws.amazon.com/elasticloadbalancing/latest/classic/elb-internet-facing-load-balancers.html

    note-icon-ns_28x28.png.2ce7eca188f658e91d20d5c09dca9fa1.png

    If you are using a BYOL license, make sure to delete any existing instances after applying your license. Deleting an instance before applying your license may result in the automatic creation of a new instance using an older license. See Applying a Jaspersoft License for AWS BYOL for more information.

    To create a new JasperReports Server cluster in a VPC:

    1. Select the Jaspersoft product you want in the AWS Marketplace and follow the subscription process to get to the Configure the Software page.
    2. Under Fulfillment Option, select CloudFormation Template from the first drop-down list and Jaspersoft Cluster using RDS for metadata from the second list.
    3. Select the software version and region, then click Continue to Launch.
    4. Under Choose Action, select Launch CloudFormation and then click Launch. The Create Stack page in the AWS console opens. Under Specify template, the Amazon S3 URL option is already selected and a URL for the template file is filled in. Do not change these options.
    5. Click Next. The Specify stack details page appears.
    6. In the Stack name field, give your CloudFormation stack a unique name.
    7. Enter the host name of your database connection in DBHost, the database port number in DBPort, and the database name in DBName .
    8. Enter the database user name in the DBUser field and the database password in DBPassword.
    9. Choose an InstanceType.
    10. Choose the KeyName of your EC2 KeyPair.
    11. Choose your VpcId and SubnetId from the drop downs.
    12. EnablePublicIp defaults to true. Unless you change this setting, your initialization instance will be assigned a public IP address and ELB (if enabled) will be configured as "internet-facing". See Amazon's documentation about internet-facing load balancers here:

    http://docs.aws.amazon.com/ElasticLoadBalancing/latest/DeveloperGuide/elb-internet-facing-load-balancers.html

    13. In the SecuredIp field, enter the IP address and mask for SSH access.
    14. Enter the maximum number of instances to create for your cluster in the MaxInstancesCount field. You can have a maximum of 10 instances in your cluster.
    15. Chose your AvailabilityZones from the drop down.
    16. To enable notifications about your instance state, enter a valid email address in the OperatorEMail field. Leave this field blank to disable notification.
    17. Click Next. The Configure stack options page appears.
    18. Add any tags you want to simplify administration of your infrastructure.

    A tag consists of a key/value pair and will flow to resources inside your stack. You can add up to 10 unique tags for each instance.

    19. Expand the Advanced section of the Configure stack options page and set your notification, rollback, and other options.
    20. Click Next. The Review page appears.

    Double-check your template, parameter, and option information.

    21. Click the acknowledgment check box, then click Create.

    You'll see your Stack Name listed in a table. While it's being created the Status column will display CREATE_IN_PROGRESS. After a few minutes the status should change to CREATE_COMPLETE.

    If the status changes to ROLLBACK instead of CREATE_COMPLETE, you may need to accept the Terms of Use. Check the Events tab for more information.

    22. Select your complete instance and click the Outputs tab. Here you'll find information you'll need when you're ready to log into JasperReports Server:
         The URL for Getting Started with JasperReports Server.
         The login name and password.
         The name of your ProvisionInstance.
         The name of your Auto Scaling group.
         The name of your S3LicenseBucket.

    Manually Deploy Your Cluster in VPC

    Manually create a new Repository database in an external PostgreSQL database and initialize it.

    note-icon-ns.png.f75b85d2140eb253219a6e531f192cb4.png

    If a database connection issue occurs, make sure that the instance's public and private IP addresses are accessible to RDS.

    To deploy your cluster manually:

    1. Log into your instance by ssh using the ssh -i EC2_KeyPair ec2-user@instance_name command.

    You can find the instance name on the Outputs tab. See Amazon's documentation for more information on connecting to the instance:

    http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AccessingInstances.html

    2. Change the directory to:

    /usr/share/jrs_dist/jasperreports-server-bin

    3. Run the initialization script:

    sudo -E ./deploy-database-to-external-repo.sh normal if you want to create the sugarcrm and foodmart sample databases or sudo -E ./deploy-database-to-external-repo.sh minimal if you don't want those databases.

    note-icon-ns.png.de053c8e8b0b0619e4da5a339872ab80.png

    You may want to skip the initialization script If your external database already contains a valid JasperReports Server repository that you want of use. The script will create (or recreate) a JasperReports Server repository database (for example from a previous dump or RDS snapshot) with a minimal set of resources or with samples.

    4. If initialization is successful, halt the instance: sudo halt -p

    If initialization is unsuccessful, troubleshoot the database, then run the initialization script (step 3).

    5. Go to the EC2 Console and increase the instance count from 0 to 1 in the Auto Scaling group (name is provided on the Outputs tab of the CloudFormation template).
    6. Use the Getting Started URL from the Outputs tab to access your JasperReports Server appliance.

    Creating a JasperReports Server Instance from the EC2 Console

    If you have a complex network topology or special volume requirements, you might need to create your instance from the EC2 Console.

    Before you can create a JasperReports Server instance from the EC2 console, you need to create a CloudFormation role. If you skip this step, when you get to the Welcome screen, you'll see the following error message:

    We don't recommend this method, because it doesn't provide the auto-connect feature for Amazon RDS and Redshift included with the CloudFormation templates. If you choose this method, be sure to define that option during the setup process.

    Missing Role Error Message

    no-role-error_524x104.png.6cc3f80a2149b72455e5b6ebb331257b.png

    If you launch your instance with a role, JasperReports Server will use that Role to generate temporary AWS security tokens for automatic discovery and management of security between your JasperReports Server instance and RDSRedshift instances.

    If no role is defined in your JasperReports Server Instance, you have 2 options:

    Provide Access and Secret keys in AWS Datasource for Discovery and Automatic Security management.
    Manage security manually. (In this case remember to disable Automatic security management in JasperReports Server Server Settings.)

    To create a JasperReports Server instance from the EC2 console:

    1. Open the AWS Management Console.
    2. Go to Compute > EC2. The EC2 Dashboard page opens.
    3. On the left, select Image > AMIs.
    4. Enter Jaspersoft in the Search text field and press Enter.
    5. Select the AMI you want, and click the Launch button at the top of the page. The Choose an Instance Type page opens.

    note-icon-ns_28x28.png.bb574e3cf5a0686847b924a9f727a33d.png

    Make sure you select the correct AMI for you license type (hourly, annual, or BYOL).

    6. Choose an Instance Type from the list.

    Instance Type list

    instance-type_600x309.png.5ce84988c1f5850643402a94acc463e5.png

    7. Click Next: Configure Instance Details at the bottom of the page, and configure the following details. Hover over the information icon icon-info.png.d529c1dc61b0e7f1029d9749d3439394.png
         Number of instances
         Purchasing option
         Network
         Availability Zone (if using EC2) or Subnet (if using VPC)
         Auto-assign Public IP
         IAM role
         Shutdown behavior
         Enable termination protection
         Monitoring
         Tenancy
    8. Expand the Advanced Details section and configure the following details:
         Kernel ID
         RAM disk ID
         User data
    9. Click Next: Add Storage and review the details. Click items you want to edit. You can add EBS and instance store volumes by clicking the Add New Volume button.
    10. Click Next: Tag Instance and add optional tags. To add more tags click the Create Tag button.

    A tag is a key/value pair that will flow to resources inside your stack. You can add up to 10 unique tags to each instance.

    11. Click Next: Configure Security Group and configure your firewall rules. Choose an existing security group or create a new security group.

    note-icon-ns_28x28.png.b93185251c6d545106ab7d8b9b9c68d1.png

    We set up one AWS DB Security Group (using IP address) per JasperReports Server instance in each RDS region. The security group allows connections from the JasperReports Server instance to the specified AWS database instance.

    12. Click Review and Launch. Review your information and edit if necessary.
    13. Click Launch.
    14. When prompted, select an existing key pair, or create a new key pair, and click Launch Instances.

    You'll see a message telling you that your instance is now launching. Your instances may take a few minutes to launch, depending on the software you are running.

    note-icon-ns_28x28.png.fd90379331ac362337af768629d62964.png

    Hours of use on your new instances will start immediately and continue to accrue until you stop or terminate your instances.

    15. Click Close.

    Logging in to JasperReports Server

    Log into JasperReports Server using the Getting Started URL generated when you created your JasperReports Server instance. You'll find this URL in the Cloud Formation Outputs tab.

    The initial user is superuser and password is your AWS instance ID, located below the Getting Started URL in the Outputs tab or in the EC2 console. You can change the password after your initial login.

     

    To log into JasperReports Server the first time:

    1. Click the GettingStartedURL link in your Outputs tab. The Welcome to Jaspersoft BI page appears.

    Welcome to Jaspersoft BI page

    welcome_600x508.png.d18cdd33efc2f638052bb8673f8ed41f.png

    2. Choose what you want from the following:
         Upload your license to the server
         Explore resources
         Watch an introductory video
         Log in

    Login Screen

    login-screen_600x417.png.4d482dafec6df1cffbecca19460c7999.png

    If you're using BYOL, you'll start with a 72-hour license. This page will display a reminder when your license is set to expire.

    Before you click the Login button on this page:

    1. Enter superuser as your User ID.
    2. Your AWS EC2 instance ID is your initial password.

    You'll find your AWS instance ID on the CloudFormation Outputs tab of your instance or in the EC2 console.

    Finding the default password in the CloudFormation stack

    stack.png.641553e700b271d52528d30e1c5ddf83.png

     

    Finding the default password in the EC2 console.

    EC2-console.png.f48701f371c494dbc3978d10d81a1a86.png

    3. Click Change password and enter a new password.
    4. Log in again. The Home screen appears.

    Home Screen

    home-screen_600x416.png.96582c056c4951a451f94b54debecce9.png

    warning-icon-ns_28x28.png.6a163cc87dd689e911eaeec59ede8e5e.png

    If you use PostgreSQL as your database, not all PostgreSQL-supported functions will work with Redshift. See the Redshift documentation for details about supported functions.


    User Feedback

    Recommended Comments

    There are no comments to display.



    Guest
    This is now closed for further comments

×
×
  • Create New...