Forum Discussion
Hyder_141209
May 13, 2015Altostratus
Cannot retrieve proper partition list using iApp
Hi there!
I am trying to develop an iApp in order to retrieve the existing partition list and if a partition does not exist intending to create a new one. Unfortunately, using the following commands ...
- May 13, 2015
"iapp::get_items -norecursive auth partition" should return partition names. It returns answers based on your user role, however, so if you are not logged in as "admin," you will not see all partitions.
Fred_Slater_856
May 13, 2015Historic F5 Account
"iapp::get_items -norecursive auth partition" should return partition names. It returns answers based on your user role, however, so if you are not logged in as "admin," you will not see all partitions.
- Hyder_141209May 14, 2015AltostratusThat's awesome. Thanks very much Fred. Best regards Hyder
- Hyder_141209May 19, 2015AltostratusBy the way, Fred, if would like to retrieve the current partition, which command should I use? Cheers.
- Fred_Slater_856May 19, 2015Historic F5 Accountpwd
- Hyder_141209May 20, 2015AltostratusThanks Fred. Sorry my question was not clear. I am looking for getting the current partition to be shown in the iApp presentation window. Something like iapp::get_items -norecursive auth partition current-partition. Cheers.
- Fred_Slater_856May 20, 2015Historic F5 AccountThis code will display it in the form of a dropdown menu. Of course, the partition is already displayed by the main UI in the upper right-hand corner of the frame. choice my_partition tcl { return [tmsh::pwd] }
- Hyder_141209May 20, 2015AltostratusYou are absolutely brilliant Fred. Thanks very much.
- Hyder_141209May 21, 2015AltostratusHello Fred, one last question is about creating the partition in the iApp implementation part. While running this command seems not working [iapp::conf create auth partition TEST] . However, while running from tmsh I can create it using the command of 'tmsh create auth partition TEST'. Appreciate if you could advise if anything is missing on this. Cheers.
- Fred_Slater_856May 21, 2015Historic F5 AccountI just tested, and [iapp::conf create auto partition TEST] works fine for me. Are you logged in with admin privilege when you run the iapp?
- Hyder_141209May 21, 2015Altostratusyes Fred, I can create using the tmsh command line no problem. Just cannot create from iApp. I am using my local virtual F5. Suppose I am creating the partition TEST11 and can see this output in the /shared/tmp/scriptd.out 'create auth partition TEST11', however in a later part of the presentation, after creating the partition, I would like to create a logging profile which is supposed to contain a pool and monitor for that pool. And I am getting this error message in the GUI "01070734:3: Configuration error: Can't associate (/TEST11/test_user5.app/test_user5_icmp) with folder (/TEST11/test_user5.app) folder does not exist" Additionally, /var/log/audit it stops here: May 21 14:52:53 f5 notice mcpd[7508]: 01070417:5: AUDIT - client tmsh, tmsh-pid-17618, user admin - transaction 843856-56 - object 0 - create_if { app_instance_value { app_instance_value_instance "/Common/test_user5.app/test_user5" app_instance_value_name "asm_partition__partition_name" app_instance_value_value "TEST11" app_instance_value_encrypted 0 } } [Status=Command OK] This iApp is to create a new partition as well as to create a new virtual server, pool and monitor for it. Is there any limitation for it to have partition and other configuration in the same iApp? I tried to use the perl script to call the iControl externally as well, seems its failing to create the partition as well as well. Cheers. Best regards Hyder
- Fred_Slater_856May 21, 2015Historic F5 AccountHyder- My example [iapp::conf create auto partition TEST] was run inside an iapp, and it works. It appears that you expect to use an iapp, initially running in /Common, to create a partition /TEST11, then move itself (the iapp instance) into that partition before creating other configuration objects. That is new territory for me, but it seems dubious. I could not comment further without doing some lab work.
Recent Discussions
Related Content
Â
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects