SAP Business One Deployment Guide

This deployment guide shows you how to deploy and connect to a Google Compute Engine VM running SAP Business One.

For more information about planning your deployment, see the SAP Business One planning guide.

Deploying SAP Business One on GCP

This solution uses a GCP install script to set up SAP Business One on GCP. The solution uses the following software:

  • SAP HANA 1.0 SP12
  • SAP Business One 9.2 PL08

Setting up your Google account

A Google account is required to work with GCP.

  1. Sign up for a Google account if you don't already have one.
  2. Log in to the Google Cloud Platform Console, and create a new project.
  3. Enable your billing account.
  4. Configure SSH keys so that you are able to use them to SSH into your Compute Engine instances. Use the gcloud command-line tool to create a new SSH key, or, if you already have an existing SSH key, use the tool to format your existing SSH keys.
  5. Use the gcloud command-line tool or GCP Console to add the SSH keys to your project metadata. This allows you to access any Compute Engine instance created within this project, except for instances that explicitly disable project-wide SSH keys.

Creating a network

When you create a project, a default network is created for your project. However, for security purposes, you should create a new network and specify firewall rules to control who has access.

To set up networking:

  1. Go to Cloud Shell.

    Go to Cloud Shell

  2. To create a new network in the custom subnetworks mode, run:

    gcloud compute networks create [YOUR_NETWORK_NAME] --subnet-mode custom

    where [YOUR_NETWORK_NAME] is the name of the new network. The network name can contain only lowercase characters, digits, and the dash character (-).

    Make sure to specify the custom flag instead of using an automatic subnetwork. An automatic subnetwork always has the same assigned IP address range, which can cause issues if you have multiple subnetworks and want to use VPN.

  3. Create a subnetwork, and specify the region and IP range:

    gcloud compute networks subnets create [YOUR_SUBNETWORK_NAME]
            --network [YOUR_NETWORK_NAME] --region [YOUR_REGION] --range [YOUR_RANGE]

    where:

    • [YOUR_SUBNETWORK_NAME] is the new subnetwork.
    • [YOUR_NETWORK_NAME] is the name of the network you created in the previous step.
    • [REGION] is the region where you want the subnetwork.
    • [YOUR_RANGE] is the IP address range, specified in CIDR format, such as 10.1.0.0/24. If you plan to add more than one subnetwork, assign non-overlapping CIDR IP ranges for each subnetwork in the network. Note that each subnetwork and its internal IP ranges are mapped to a single region.
  4. Optionally, repeat the previous step and add additional subnetworks.

Setting up a NAT gateway

If you intend to create one or more VMs that will not have public IP addresses, you must create a NAT gateway so that your VMs can access the Internet to download Google's monitoring agent.

If you intend to assign an external public IP address to your VM, you can skip this step.

To create a NAT gateway:

  1. Create a VM to act as the NAT gateway in the subnet you just created:

    gcloud compute instances create [YOUR_VM_NAME] --can-ip-forward \
            --zone [YOUR_ZONE]  --image-family [YOUR_IMAGE_FAMILY] \
            --image-project [YOUR_IMAGE_PROJECT] \
            --machine-type=[YOUR_MACHINE_TYPE] --subnet [YOUR_SUBNETWORK_NAME] \
            --metadata startup-script="sysctl -w net.ipv4.ip_forward=1; iptables \
            -t nat -A POSTROUTING -o eth0 -j MASQUERADE" --tags [YOUR_VM_TAG]

    where:

    • [YOUR_VM_NAME] is the name of the VM you are creating that want to use for the NAT gateway.
    • [YOUR_ZONE] is the zone where you want the VM.
    • [YOUR_IMAGE_FAMILY] and [YOUR_IMAGE_PROJECT] specify the image you want to use for the NAT gateway.
    • [YOUR_MACHINE_TYPE] is any supported machine type. If you expect high network traffic, choose a machine type with that has at least eight virtual CPUs.
    • [YOUR_SUBNETWORK_NAME] is the name of the subnetwork where you want the VM.
    • [YOUR_VM_TAG] is a tag that is applied to the VM you are creating. If you use this VM as a bastion host, this tag is used to apply the related firewall rule only to this VM.
  2. Create a route that is tagged so that traffic passes through the NAT VM instead of the default Internet gateway:

    gcloud compute routes create [YOUR_ROUTE_NAME] \
            --network [YOUR_NETWORK_NAME] --destination-range 0.0.0.0/0 \
            --next-hop-instance [YOUR_VM_NAME] --next-hop-instance-zone \
            [YOUR_ZONE] --tags [YOUR_TAG_NAME] --priority 800

    where:

    • [YOUR_ROUTE_NAME] is the name of the route you are creating.
    • [YOUR_NETWORK_NAME] is the network you created.
    • [YOUR_VM_NAME] is the VM you are using for your NAT gateway.
    • [YOUR_ZONE] is the zone where the VM is located.
    • [YOUR_TAG_NAME] is the tag on the route that directs traffic through the NAT VM.
  3. If you also want to use the NAT gateway VM as a bastion host, run the following command. This command creates a firewall rule that allows inbound SSH access to this instance from the Internet:

    gcloud compute firewall-rules create allow-ssh --network [YOUR_NETWORK_NAME] --allow tcp:22 --source-ranges 0.0.0.0/0 --target-tags "[YOUR_VM_TAG]"

    where:

    • [YOUR_NETWORK_NAME] is the network you created.
    • [YOUR_VM_TAG] is the tag you specified when you created the NAT gateway VM. This tag is used so this firewall rule applies only to the VM that hosts the NAT gateway, and not to all VMs in the network.

Downloading SAP software

Download the SAP HANA and SAP Business One binaries.

  1. Access the SAP installation page.

    If your SAP Support Portal account does not allow access to the software and you believe that you should have access to the software, contact the SAP Global Support Customer Interaction Center.

  2. Download all applicable parts of the following software to your local machine:

    • SAP HANA Platf.Ed.1.0 SPS12
    • SAP Business One 9.2 PL08
  3. Use the GCP Console to create a Cloud Storage bucket for storing the SAP HANA installation files. Note that the bucket name must be unique across GCP. During bucket creation, choose Regional in the Default storage class section, then choose us-west1 in the Regional location section.

  4. Configure bucket permissions. By default, as owner of the bucket, you have read-write access to the bucket. If you want, you can allow other members in your group or individual users to access your bucket, as shown here:

    Bucket Permissions

  5. In the GCP Console, in the Cloud Storage bucket page, choose Upload Files to upload the software to your bucket from your local machine:

    Upload Files

  6. Note the name of the bucket that you uploaded the binaries to. You will need to use it when installing the SAP software.

Setting up configuration files

Next, set up the two configuration files that are used by the install script.

  1. Create a text file named install.cfg and add the following lines:

    [General]
    components=server,client,afl
    
    [Server]
    # SAP HANA System ID
    sid=[SID]
    
    # Instance Number
    number=00
    
    # SAP Host Agent User (sapadm) Password
    sapadm_password=[SAPADM_PASSWORD]
    
    # System Administrator Password
    password=[SYSTEM_ADMIN_PASSWORD]
    
    # Database User (SYSTEM) Password
    system_user_password=[SYSTEM_PASSWORD]
    
    Restart system after machine reboot? ( Default: n )
    autostart=y
    
  2. Create a text file named b1.cfg and add the following lines:

    SITE_USER_ID=B1SiteUser
    SITE_USER_PASSWORD=[SITE_USER_PASSWORD]
    SLD_CERTIFICATE_PASSWORD=[SLD_CERTIFICATE_PASSWORD]
    B1S_TECHUSER_PASSWORD=[B1S_TECHUSER_PASSWORD]
    
  3. Upload these two files into the root of the Cloud Storage bucket you created in the previous steps.

  4. Delete these two files from your local machine as a security precaution, because they contain password information.

Creating a VM for SAP HANA and SAP Business One

The following instructions create an SAP-certified n1-highmem-32 instance with all of the required disk configuration, and then install SAP HANA on the instance. Please refer to the pricing section to understand the costs.

  1. Navigate to Cloud Shell.

    OPEN THE CLOUD SHELL

  2. Set the following environment variables. Replace [YOUR_BUCKET] with your bucket name, [NETWORK] with your network name, and [SUBNETWORK] with your subnetwork name.

    export INSTANCE_NAME="sapb1server"
    export INSTANCE_TYPE="n1-highmem-32"
    export ZONE="us-west1-b"
    export LINUX_VERSION="SLES 12 SP1"
    export NETWORK_NAME="[NETWORK]"
    export SUBNET="[SUBNETWORK]"
    export MEDIA_BUCKET="[YOUR_BUCKET]"
    export INSTALL_B1="YES"
    
  3. Create the instance:

    curl https://storage.googleapis.com/saphana/deployinit | bash
    

    The above command specifies an installation script that initiates after VM creation completes. The script downloads the SAP HANA and SAP Business One software from your bucket, and installs the software using the values specified in the configuration files. The script takes approximately 40 minutes to complete.

    Copy the internal and external IP addresses that appear when the script begins. You will need to use one of these addresses to connect to SAP Business One in the next step.

Verifying the SAP Business One installation

  1. After approximately 40 minutes has passed, navigate to your SAP Business One site address. You can use a VPN to connect to the internal IP, or you can open ports on your instance to use the external IP. Access the following URL using the applicable IP address.

    https://[IP]:40000/ControlCenter/
    

    You should see the following screen:

    SAP Business One home

  2. Login using the following credentials:

    1. Username: B1SiteUser, which is the value defined in SITE_USER_ID in b1.cfg.
    2. Password: The value defined in SITE_USER_PASSWORD in b1.cfg.
  3. Ensure that the login works and takes you to the SAP Business One landing page. SAP Business One landing page

Support

GCP customers with Gold or Platinum Support can request assistance with SAP provisioning and configuration questions on Compute Engine. You can find additional information about support options at the GCP Support page. Customers can also contact SAP support for SAP-related issues. SAP does the initial evaluation of the support ticket and transfers the ticket to the Google queue if SAP considers it an infrastructure issue.

What's next

Was this page helpful? Let us know how we did:

Send feedback about...