Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
cancel
Showing results for 
Search instead for 
Did you mean: 
craigcmehil
Product and Topic Expert
Product and Topic Expert
1,203
So the other week I published about the OSS project I participated in and this week I've been at QCon London and realized as I showed folks various things about SAP HANA I never really took the time to show the connectivity points here with all of you.



The interesting thing about QCon has been the fact that as soon as the sessions start all and I do mean like seriously all the attendees are in them so the booth and expo areas are relatively quiet. I was able to work, meet cool folks like Twilio and think about some video content which I've not done in ages.

So topic of the day here was connecting to the system...

The big point I found was that it was easy to connect a tool locally to my docker container but the struggle was the fact I am trying to run all my tools in containers and nothing locally, hold over from the problems I had!

So enter "docker-compose" and a quick bit of combining two containers into a single compose file and thus giving them network access to each other.
version: "3"

services:
hana:
image: store/saplabs/hanaexpress:2.00.022.00.20171211.1
ports:
- "39013:39013"
- "39017:39017"
- "39041-39045:39041-39045"
- "1128-1129:1128-1129"
- "59013-59014:59013-59014"
environment:
- LOCAL_HANA_PASSSWORD=${HANA_PASSWORD-blablablaknowyourselfhowblabla}
sysctls:
- net.ipv4.ip_local_port_range=40000 60999
entrypoint:
- sh
- -c
- echo "{\"master_password\":\"$$LOCAL_HANA_PASSSWORD\"}" > /tmp/hana_password.json; cat /tmp/hana_password.json;/run_hana --agree-to-sap-license --passwords-url file:///tmp/hana_password.json
volumes:
- hana-data:/hana/mounts

sqlpad:
build:
context: docker-sqlpad/.
volumes:
- db-data:/opt/data
ports:
- "3000:3000"
depends_on:
- hana

volumes:
hana-data:
db-data:

I've completely deviated from the docker instructions provided about HXE so be sure you have a basic understanding of Docker before screwing around with this.
Again this is different to the standard instructions and based on my being a Mac user so be sure you know the basics or perhaps even a bit more before doing any of this >>> You've been warned, I haz no liability 🙂

 



 

The query I am running is one of my favorites that I use to the test my connections as opposed to the standard.
select * from DUMMY

I use
select TO_VARCHAR(ROUND((FREE_PHYSICAL_MEMORY) /1024/1024/1024, 2)) 
AS FREEMEM
from PUBLIC.M_HOST_RESOURCE_UTILIZATION

Which shows me how much free memory SAP HANA has available to it.
1 Comment