The transition to NetApp MS Azure AD B2C is complete. If you missed the pre-registration, you will be invited to reigister at next log in.
Please note that access to your NetApp data may take up to 1 hour.
To learn more, read the FAQ and watch the video.
Need assistance? Complete this form and select “Registration Issue” as the Feedback Category.

ONTAP Discussions

How to make set adv, priv, diag with the rest of the command into one line of commnad.


Hi All. I just wanted to find out if they can make the 'set [mode]' command with the rest of the command into one line of command. We are trying to monitor with the automated script so for them it would be a struggle if they have to separate those two lines when running the script. 


Would there be someway they can cheat or work around the way ? 








You should be able to use the ";" to separate multiple commands . As for the set command you can use the -c (confirmation) set to off.


Per example:


cluster::> set diag -c off; cluster ring show


Hope this answer your question.



Correct. And don't worry about doing set admin/adv/diag. Just run them all from set diag.

I would strongly recommend to not run all as set diag. Diag mode has a number of things that are different on some commands and can cause you trouble. You should always go for least privilege needed. 

When  using the CLI, sure. But when scripting them out, it doesn't really matter. You're not going to tab complete yourself into trouble. You'll run the same command you would in admin priv, just at diag level and it won't vary.


Diag commands are only different because you have extra flags you can run. They're not different simply because they're in diag priv.

I agree.


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