flex.cfg #5

  • //
  • guest/
  • netapp/
  • p4flex/
  • main/
  • demo/
  • flex.cfg
  • View
  • Commits
  • Open Download .zip Download (2 KB)
############################################################
# p4 flex configuration file
#
# This file contains both p4 and NetApp filer configuration
# options.  Please read descriptions for each option.
############################################################

########################################
# Perforce Helix setup 
########################################
[p4]
user: flex
port: localhost:1666
passwd: Password
snap: flexSnap:
clone: flexClone:


########################################
# NetApp Storage Config Info  
########################################
# NetApp vserver admin access usr/pass pair
# admin permissions to access filer 
# IMPORTANT: the vserver admin must have 'ontapi' application access
#            this login access to the vserver and not to the cluster.
#            Check permission access
#            cluster> security login show

[NaServer]
# name of the cluster management interface
server: 10.192.39.10 
server_type: FILER
# default vserver name
vserver: P4FlexServer
# Sets the authentication mechanism to be used for communicating with the # given server.
# default is 'LOGIN'
style: LOGIN
# The default transport type is HTTP. For secure transport, use HTTPS as the transport type.
transport: HTTP
# Sets the port on which the API commands need to be invoked for the given server context
# HTTP -> use port 80, HTTPS -> use port 443
port: 80
# username and password pair for filer access.  see note above about 'ontapi' application access.
admin_user: admin
admin_passwd: netapp123
# file aggregate where new volumes will be created
aggr: aggr1_01

# mount_base: location to mount new volumes created with %> p4 flex volume <options>
mount_base: /ce_projects
# mount_users: root location for mounting flexclones. The p4 flex clone <options>
#              will mount clones at <mount_users>/<username>/<clone_name>
#              This of course is configurable by modifying the variable below
#              and the flex.py subroutine for mounting flexclones.
mount_users: /ce_projects/android1/users

# Change User Description Committed
#6 20103 netapp Latest code - Aug 15, 2016.
Changes made to address :
1. Added in functionality for snapshot delete ('snapshot -V volname -d snapshotsname')
2. Corrected volume delete to not allow for Helix database volume delete, unless all clones are first removed
3. 'p4 flex clones' now produces full table showing Parent Volume, Parent-Snapshot, FlexClone name, Parent volume space consumed, FlexClone volume space consumed, FlexClone acutal (space versus parent volume), and the Clone-path
4. Flex Clones now thinly provisioned to allow for storage space savings
5. Code change to process P4 first when taking snapshots, and then follow with NetApp step versus previous reverse order
#5 19478 netapp Additons:

1.    Added in snapshot deletion capability
2.    Created separate user clone mount directory, which can be different from the base directory
3.    Cleaned up error handling for all p4 flex calls, so errors are handled with understandable output, versus program crashes
4.    Added in ability to specify volume owner when creating a volume with �p4 flex volume �s �u�.
#4 19476 netapp added new files to address these changes:
1.    Added in snapshot deletion capability
2.    Created separate user clone mount directory, which can be different from the base directory
3.    Cleaned up error handling for all p4 flex calls, so errors are handled with understandable output, versus program crashes
4.    Added in ability to specify volume owner when creating a volume with �p4 flex volume �s �u�.
#3 19475 netapp revise list
#2 19474 netapp Uploaded new files for project.
Enhancements include:
1.    Added in snapshot deletion capability
2.    Created separate user clone mount directory, which can be different from the base directory
3.    Cleaned up error handling for all p4 flex calls, so errors are handled with understandable output, versus program crashes
4.    Added in ability to specify volume owner when creating a volume with �p4 flex volume �s �u�.
#1 18997 netapp Rename/move file(s)

Project name change:
moving
//guest/netapp/p4flexclone/main/…
to
//guest/netapp/p4flex/main/…
//guest/netapp/p4flexclone/main/demo/flex.cfg
#6 15418 Paul Allen Updated config for demo
#5 14180 Paul Allen Set file ownership for clone's mounted files.

 + Minor fix to clone delete
#4 13993 Paul Allen Added NetApp commands to Flex.

Example:

4007::ws$ p4 flex volume vol1
Created flex volume vol1

4007::ws$ p4 flex snapshot -V vol1 snapshot1
Created flex snapshot snapshot1

4007::ws$ p4 flex snapshot -V vol1 snapshot2
Created flex snapshot snapshot2

4007::ws$ p4 flex snapshots
snapshot vol1:snapshot1 root /home/pallen/flexclone/demo/ws
snapshot vol1:snapshot2 root /home/pallen/flexclone/demo/ws

4007::ws$ p4 flex clone -V vol1 -P snapshot1 clone_A
Created flex clone client flexClone:clone_A

4007::ws$ p4 flex clone -V vol1 -P snapshot1 clone_B
Created flex clone client flexClone:clone_B

4007::ws$ p4 flex clones
Clone clone_A root /home/pallen/flexclone/demo
Clone clone_B root /home/pallen/flexclone/demo

4007::ws$ p4 clients
Client flexClone:clone_A 2015/06/17 root /home/pallen/flexclone/demo 'Created by pallen. '
Client flexClone:clone_B 2015/06/17 root /home/pallen/flexclone/demo 'Created by pallen. '
Client flexSnap:vol1:snapshot1 2015/06/17 root /home/pallen/flexclone/demo/ws 'Created by flex. '
Client flexSnap:vol1:snapshot2 2015/06/17 root /home/pallen/flexclone/demo/ws 'Created by flex. '
Client pallen-ws 2015/06/10 root /home/pallen/flexclone/demo/ws 'Created by pallen. '

4007::ws$ p4 flex clone -d clone_B
Deleted Flex clone clone_B

4007::ws$ p4 flex clone -d clone_A
Deleted Flex clone clone_A

4007::ws$ p4 flex volume -d vol1
Deleted Flex volume vol1
   deleted client: flexSnap:vol1:snapshot1
   deleted client: flexSnap:vol1:snapshot2

4007::ws$ p4 clients
Client pallen-ws 2015/06/10 root /home/pallen/flexclone/demo/ws 'Created by pallen. '
#3 13868 agnesj Made modifications to config file to reflect the actual filer information
#2 13859 Paul Allen Config details for cloud demo + NaServer test
#1 13796 Paul Allen Moved options to a configuration file.

 - The config file 'flex.cfg' MUST be located in the same dir as the script
 - Provided a sample 'in.txt' file to simulate a broker call (used for debug only)