ONTAP Discussions

Creating multiple qtrees

Limor

Hello,

I'd like to create multiple qtrees on a cifs volume. I found the article about creating a file that consists of multiple commands for qtree creation, saving it to the root dir on the said volume and then, from the console, running the command 'source <filename>'.

I receive the error "source is not supported". I have Data Ontap 9.7.

Is there another way of doing this?

Help will be much appreciated.

 

Limor

1 ACCEPTED SOLUTION

parisi

PS C:\> help New-NcQtree

NAME
New-NcQtree

SYNOPSIS
Create a new qtree.


SYNTAX
New-NcQtree [-Volume] <String> [[-Qtree] <String>] [-Mode <String>] [-SecurityStyle <String>] [-Oplocks <String>] [-ExportPolicy
<String>] [-VserverContext <String>] [-Controller <NcController[]>] [-InformationAction <ActionPreference>] [-InformationVariable
<String>] [-PipelineVariable <String>] [-ZapiRetryCount <Int32>] [<CommonParameters>]


DESCRIPTION
Create a new qtree.

RELATED LINKS
Get-NcQtree

REMARKS
To see the examples, type: "get-help New-NcQtree -examples".
For more information, type: "get-help New-NcQtree -detailed".
For technical information, type: "get-help New-NcQtree -full".
For online help, type: "get-help New-NcQtree -online"

View solution in original post

5 REPLIES 5

pedro_rocha

I am not sure if source command exists in ontap 9.7

 

if you are doing this only once, just copy and paste the qtree creation commands to an ssh session

 

if this a repetitive task, you could take a look at the ontap powershell tool kit 

Limor

Thank you for answering.

I'll need to create dozens if not hundreds of qtrees.  No copy/paste for me.

I'll check the powershell option you suggested.

Limor

I looked through the powershell toolkit. Couldn't find a command that'll create qtrees.

Can anyone point it out for me please?

Thanks in advance.

parisi

PS C:\> help New-NcQtree

NAME
New-NcQtree

SYNOPSIS
Create a new qtree.


SYNTAX
New-NcQtree [-Volume] <String> [[-Qtree] <String>] [-Mode <String>] [-SecurityStyle <String>] [-Oplocks <String>] [-ExportPolicy
<String>] [-VserverContext <String>] [-Controller <NcController[]>] [-InformationAction <ActionPreference>] [-InformationVariable
<String>] [-PipelineVariable <String>] [-ZapiRetryCount <Int32>] [<CommonParameters>]


DESCRIPTION
Create a new qtree.

RELATED LINKS
Get-NcQtree

REMARKS
To see the examples, type: "get-help New-NcQtree -examples".
For more information, type: "get-help New-NcQtree -detailed".
For technical information, type: "get-help New-NcQtree -full".
For online help, type: "get-help New-NcQtree -online"

View solution in original post

parisi

PowerShell and REST APIs would be the way to go.

 

We also have Ansible playbooks:

 

https://docs.ansible.com/ansible/latest/collections/netapp/ontap/na_ontap_qtree_module.html

 

We don't do source for files anymore, as we don't use flat files in cDOT.

Announcements
NetApp on Discord Image

We're on Discord, are you?

Live Chat, Watch Parties, and More!

Explore Banner

Meet Explore, NetApp’s digital sales platform

Engage digitally throughout the sales process, from product discovery to configuration, and handle all your post-purchase needs.

NetApp Insights to Action
I2A Banner
Public