Jump to content
Welcome to our new Citrix community!

How do I use partitions in CPX using cli_script.sh?


Jim Tsetsos

Recommended Posts

 

When I try switch partition command using cli_script.sh I get an assertion failure, does anyone have a simple example how I can add an admin user to partition "pp2" (as an example), I think from an example like that I'll be able to workout the rest...  (Also maybe include an example of adding a lb web server to partition pp2 as well) 

 

root@71a0dc9d10ff:/var/netscaler/bins# ./cli_script.sh "show partition"
exec: show partition
1)    Name: pp1
        Partition ID: 1
        Max BW : 10240 Kbps
        Max Conn :1024 Max Mem: 10 MB
2)    Name: pp2
        Partition ID: 2
        Max BW : 10240 Kbps
        Max Conn :1024 Max Mem: 10 MB
Done
root@71a0dc9d10ff:/var/netscaler/bins# ./cli_script.sh "switch ns partition pp2"
specialcmds.c:133: Assertion failed in _switchpartition(): psh && pcpe && preq
exec: switch ns partition pp2
Done
root@71a0dc9d10ff:/var/netscaler/bins# ./cli_script.sh "switch partition pp2"
specialcmds.c:133: Assertion failed in _switchpartition(): psh && pcpe && preq
exec: switch partition pp2
Done
root@71a0dc9d10ff:/var/netscaler/bins# 
 

Link to comment
Share on other sites

10 hours ago, Jim Tsetsos said:

 

hah? is there a support document anywhere? it'll save me time from going deeper into this and even recommending this product in the future

Can you  please elaborate the the need  for usage of partition in cpx deployment environment ? 

Link to comment
Share on other sites

5 hours ago, Kiran Torne said:

Can you  please elaborate the the need  for usage of partition in cpx deployment environment ? 

 

Am I missing something?

 

Seems like all the bits are already implemented but CLI does'nt seem to yet support them

 

Mainly be able to partition the administration in a single container rather than spinning up multiple containers

 

Other cases that specificly are addressed by partitioning such as in the following:

 

Admin Partitioning
https://docs.citrix.com/en-us/netscaler/12/admin-partition.html

 

Supported NetScaler configurations

https://docs.citrix.com/en-us/netscaler/12/admin-partition/admin-partition-config-types.html

 

Configure admin partitions

https://docs.citrix.com/en-us/netscaler/12/admin-partition/admin-partition-access-and-configure.html

 

VLAN configuration for admin partitions

https://docs.citrix.com/en-us/netscaler/12/admin-partition/vlan-configuration-for-admin-partitions.html

 

VXLAN support for admin partitions

https://docs.citrix.com/en-us/netscaler/12/admin-partition/vxlan-support-for-admin-partitions.html

 

SNMP support for admin partitions

https://docs.citrix.com/en-us/netscaler/12/admin-partition/snmp-support-for-admin-partitions.html

 

Audit log support for admin partitions

https://docs.citrix.com/en-us/netscaler/12/admin-partition/auditlog-support-for-admin-partitions.html

Link to comment
Share on other sites

  • 3 weeks later...

If I save the configuration after having created partitions, I can see the ns.conf file in /cpx/nsconfig directory. It's a text file. If I edit the file I can see where I have created partitions, eg.
 

root@47bbb0c5ba46:/cpx/nsconfig# more ns.conf 
#NS13.0 Build 36.29
# Last modified by `save config`, Sat Sep 26 00:00:19 2020
set ns config -IPAddress 172.17.0.2 -netmask 255.255.0.0
enable ns feature LB SSL
enable ns mode L3 USNIP PMTUD
set system user nsroot 284b567d173382ab2da38c3d9e55b8c6b55f0db8435de431495bb25bc86e927701619763e1fa7a9dd7d3a3e6fd12327c4485899d352136cca91918bd810bff2b6bc89da08 -encrypted -hashmethod SHA51
2
add ns partition partition1 -partitionid 1
add ns partition partition2 -partitionid 2
add ns partition partition3 -partitionid 3
set rsskeytype -rsstype ASYMMETRIC
set lacp -sysPriority 32768 -mac 36:ff:8e:e2:90:b1
set ns hostName 47bbb0c5ba46
set interface 0/1 -haHeartbeat OFF -throughput 0 -bandwidthHigh 0 -bandwidthNormal 0 -ifnum 0/1
set interface 0/2 -throughput 0 -bandwidthHigh 0 -bandwidthNormal 0 -ifnum 0/2
add ns ip6 fe80::34ff:8eff:fee2:90b1/64 -scope link-local -type NSIP -vlan 1 -vServer DISABLED -mgmtAccess ENABLED -dynamicRouting ENABLED
add ns ip 192.0.0.1 255.255.255.0 -vServer DISABLED -telnet DISABLED -ftp DISABLED -gui DISABLED -ssh DISABLED -snmp DISABLED
set nd6RAvariables -vlan 1
add snmp community labaccess ALL
...
..
.


So I'm left wondering, if I edit this file manually to configure each partition (partition1, partition2 & partition3) what would the format be, eg, adding specific users to specific partitions, specific service settings to specific partitions, lb, etc.. 

What does a typical ns.conf file look like where partitions are in use?

 

Kind Regards

Jim

Link to comment
Share on other sites

On 9/26/2020 at 5:46 AM, Jim Tsetsos said:

If I save the configuration after having created partitions, I can see the ns.conf file in /cpx/nsconfig directory. It's a text file. If I edit the file I can see where I have created partitions, eg.
 


root@47bbb0c5ba46:/cpx/nsconfig# more ns.conf 
#NS13.0 Build 36.29
# Last modified by `save config`, Sat Sep 26 00:00:19 2020
set ns config -IPAddress 172.17.0.2 -netmask 255.255.0.0
enable ns feature LB SSL
enable ns mode L3 USNIP PMTUD
set system user nsroot 284b567d173382ab2da38c3d9e55b8c6b55f0db8435de431495bb25bc86e927701619763e1fa7a9dd7d3a3e6fd12327c4485899d352136cca91918bd810bff2b6bc89da08 -encrypted -hashmethod SHA51
2
add ns partition partition1 -partitionid 1
add ns partition partition2 -partitionid 2
add ns partition partition3 -partitionid 3
set rsskeytype -rsstype ASYMMETRIC
set lacp -sysPriority 32768 -mac 36:ff:8e:e2:90:b1
set ns hostName 47bbb0c5ba46
set interface 0/1 -haHeartbeat OFF -throughput 0 -bandwidthHigh 0 -bandwidthNormal 0 -ifnum 0/1
set interface 0/2 -throughput 0 -bandwidthHigh 0 -bandwidthNormal 0 -ifnum 0/2
add ns ip6 fe80::34ff:8eff:fee2:90b1/64 -scope link-local -type NSIP -vlan 1 -vServer DISABLED -mgmtAccess ENABLED -dynamicRouting ENABLED
add ns ip 192.0.0.1 255.255.255.0 -vServer DISABLED -telnet DISABLED -ftp DISABLED -gui DISABLED -ssh DISABLED -snmp DISABLED
set nd6RAvariables -vlan 1
add snmp community labaccess ALL
...
..
.


So I'm left wondering, if I edit this file manually to configure each partition (partition1, partition2 & partition3) what would the format be, eg, adding specific users to specific partitions, specific service settings to specific partitions, lb, etc.. 

What does a typical ns.conf file look like where partitions are in use?

 

Kind Regards

Jim

Partition is not supported in CPX and add partition command itself is blocked in latest build.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...