Wireless Access

last person joined: yesterday 

Access network design for branch, remote, outdoor, and campus locations with HPE Aruba Networking access points and mobility controllers.
Expand all | Collapse all

Mass folder creation

This thread has been viewed 0 times
  • 1.  Mass folder creation

    Posted Sep 17, 2012 08:15 AM

    Hello,

     

    Anyway to create a mass amount of folders by importing using CSV?

     

    I know we can import devices via CSV but not create folders.

     

    I have 28 controllers which I want in their own AMP Group.

    I also have roughly ~2100 APs that I need to monitor via Airwave but I want them in their own folder for per folder reporting possibilities.

     

    Any way to do this??



  • 2.  RE: Mass folder creation
    Best Answer

    EMPLOYEE
    Posted Sep 17, 2012 10:19 AM

    Yes, there's a create folders from csv script

     

    # cd /root/svn/mercury/scripts

    # ./create_folders_from_csv.pl

     

    ./create_folders_from_csv.pl <csv_data_file>

    Create a folder structure from a csv file. This script will not allow duplicate folder names even though AMP will.
    You must create the high level folders before you create the sub folders. From the example below, you cannot create
    sub_sub_folder_1 before you create sub_folder_1.

     

    CSV FORMAT:

    Top_folder,new_folder

     

    example:
    Top_folder,new_folder
    Top,sub_folder_1
    Top,sub_folder_2
    sub_folder_1,sub_sub_folder_1

     

    --> first row entry of CSV must be Top_folder,new_folder

     

    Here's an example run through:

    [root@amp tmp]# cat csv
    Top_folder,new_folder
    Top,alpha
    Top,beta
    alpha,gamma

    [root@amp tmp]# cd /root/svn/mercury/scripts

    [root@amp scripts]# ./create_folders_from_csv.pl csv
    creating new folder alpha under Top
    creating new folder beta under Top
    creating new folder gamma under alpha

     

    And then verify that your UI reflects the desired folder structure.



  • 3.  RE: Mass folder creation

    Posted Sep 17, 2012 10:31 AM

    Beautiful. Thanks a lot, I didn't know this existed.

     

    Are these scripts usually reserved for TAC? or is there a document that explains how to use these scripts for end-users?

     

    EDIT: It worked, thankl you



  • 4.  RE: Mass folder creation

    EMPLOYEE
    Posted Sep 17, 2012 12:04 PM

    There's a few KBs that recommend using the scripts.  Other than that, they are left for TAC to recommend as needed.  There's no single document since these are all custom scripts that were created as needed.

     

    You can get lucky and try ? or no flags to see if there are usage notes.

    # ./create_folders_from_csv.pl ?

    ./create_folders_from_csv.pl

    -in this case, the latter produces the usage note output I previously provided.

     

    Be aware that some of these scripts will run if there's no flag.  So you may want to try them on a lab setup before trying them in production.  If you do not have a lab setup, it'd be best if you interacted with TAC instead of guessing which script to try, as some of these scripts can cause lost of CLI access or database data.



  • 5.  RE: Mass folder creation

    Posted Sep 17, 2012 12:22 PM

    Thank you very much for your time. This helps greatly



  • 6.  RE: Mass folder creation

    EMPLOYEE
    Posted Jun 16, 2015 06:08 AM

    Awesome.  This saved me a good couple of hours.

     

    :-)



  • 7.  RE: Mass folder creation

    Posted Nov 26, 2013 05:11 AM

    This information is help to cteate mass folder.

    But if i need more sub_folder, how to do it

     

    example:

    HS   --->High School

    HS,RHHS

    HS,AAAA

    JS  ---->Junior High School

    JS

    JS,BBBB

     

     

    like that. Can it do it by "mass folder create way" ?

     

    Kirby