File share in SODA facilitates the user to create file share, set access permission for that file share and user can also create snapshot. SODA provides both CLI and Dashboard to operate or play with file share feature. Goals of file share in SODA are
Follow the wiki link to install SODA https://github.com/sodafoundation/api/wiki/SODA-Projects-Cluster-Installation-through-Ansible
Make sure backend nfs is enable to use file share feature
If nfs
is chosen as storage backend, modify group_vars/osdsdock.yml
, native nfs driver dependent on lvm:
enabled_backends: nfs
Firstly configure SODA CLI tool:
sudo cp /opt/opensds-hotpot-linux-amd64/bin/osdsctl /usr/local/bin/
export OPENSDS_ENDPOINT=http://{your_real_host_ip}:50040
export OPENSDS_AUTH_STRATEGY=keystone
export OS_AUTH_URL=http://{your_real_host_ip}/identity
export OS_USERNAME=admin
export OS_PASSWORD=opensds@123
export OS_TENANT_NAME=admin
export OS_PROJECT_NAME=admin
export OS_USER_DOMAIN_ID=default
osdsctl pool list # Check if the pool resource is available
Create a file share profile
osdsctl profile create '{"name":"Prf_fileshare", "description":"default policy for fileshare", "storageType":"file"}'
Create a file share
osdsctl fileshare create <size(int)> -n <fileshare_name> -p <profile_id>
List all file shares
osdsctl fileshare list
Delete the file share
osdsctl fileshare delete <fileshare id>
Set access for file share
osdsctl fileshare acl create <fileshare_id> -a <client_ip> -c <list_of_access_capabilities> -t "ip"
client ip is here ip of file share client, which system/user wants to access the file share mounted on server list of access capablities are read, write, execute, append etc.. For now only read and write capabilities are supported
Create snapshot of file share
osdsctl fileshare snapshot create <fileshare_id> -n <snapshot_name> -d "description of file share snapshot"
SODA UI dashboard is available at http://{your_host_ip}:8088
, please login the dashboard using the default admin credentials: admin/opensds@123
. Create tenant
, user
, and profiles
as admin.
Logout of the dashboard as admin and login the dashboard again as a non-admin user to manage storage resource
Post login into the SODA UI, File share can be created from: Resource -> File share -> Create
a) Click on File Share name b) Under Snapshot menu, click on ‘Create’ Also the quick option a) Click on file share resource menu, and on file share name b) Under fileshare name menu in same row you can find Create Snapshot link to create snapshot