Skip to content

Aws storage gateway test

wordpress meta

title: 'AWS Storage Gateway Test'
date: '2019-01-18T09:32:01-06:00'
status: publish
permalink: /aws-storage-gateway-test
author: admin
excerpt: ''
type: post
id: 1313
category:
    - AWS
    - nfs
tag: []
post_format: []

I recently wanted to take a quick look at the File Gateway. It is described as "Store files as objects in Amazon S3, with a local cache for low-latency access to your most recently used data." I tried it on Virtualbox using the Vmware ESXi Image they offer.

Steps:

  • Download VMware ESXi Image.
  • With Virtualbox Import OVA AWS-Appliance-2018-12-11-1544560738.ova
  • Adjust memory 16 -> 10. Try not to do this if possible but in my case I was short on memory on the host.
  • Change to bridged networking instead of NAT.
  • Add a SAS controller and thick provisioned a disk. I did type VDI and 8GB for my test.
  • Use the SAS disk attached to the Virtualbox VM as cache in the AWS Storage Gateway console.
  • Share files as NFS (SMB you will need MS-AD)

Some useful CLI commands

``` $ aws storagegateway list-gateways { "Gateways": [ { "GatewayId": "sgw-<...>", "GatewayARN": "arn:aws:storagegateway:us-east-1:<...>:gateway/sgw-<...>", "GatewayType": "FILE_S3", "GatewayOperationalState": "ACTIVE", "GatewayName": "iq-st01" } ] } $ aws storagegateway list-file-shares { "FileShareInfoList": [ { "FileShareType": "NFS", "FileShareARN": "arn:aws:storagegateway:us-east-1:<...>:share/share-<...>", "FileShareId": "share-<...>", "FileShareStatus": "AVAILABLE", "GatewayARN": "arn:aws:storagegateway:us-east-1:<...>:gateway/sgw-<...>" } ] } $ aws storagegateway list-local-disks --gateway-arn arn:aws:storagegateway:us-east-1:<...>:gateway/sgw-<...> { "GatewayARN": "arn:aws:storagegateway:us-east-1:<...>:gateway/sgw-<...>", "Disks": [ { "DiskId": "pci-0000:00:16.0-sas-0x00060504030201a0-lun-0", "DiskPath": "/dev/sda", "DiskNode": "SCSI (0:0)", "DiskStatus": "present", "DiskSizeInBytes": 8589934592, "DiskAllocationType": "CACHE STORAGE" } ] }
</div>**Mount test**

<div class="wp-block-syntaxhighlighter-code ">```

# mount -t nfs -o nolock,hard 192.168.1.25:/st01.iqonda.com  /mnt/st01
# nfsstat -m
/mnt/st01 from 192.168.1.25:/st01.iqonda.com
 Flags: rw,relatime,vers=4.2,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,clientaddr=10.0.2.15,local_lock=none,addr=192.168.1.25