Forum Discussion

Ørjan's avatar
Ørjan
Icon for Nimbostratus rankNimbostratus
Jun 18, 2018

Set partition context in bash

When running the command "show ltm clientssl-proxy cached-certs virtual clientssl-profile " in tmsh I have to do "cd /" first so it finds the correct VS and profile.

 

This VS and client-SSL profile is part of our forward proxy setup for general Internet traffic so this list is quite large. I wanted to save this output to a file to work on it in bash with other tools then just grep, but when I run "tmsh show ltm clientssl-proxy cached-certs virtual clientssl-profile " from bash it can't find the Virtual Server

 

01020036:3: The requested Virtual Server (/Common/) was not found. Is it possible to run this in the correct context so I can write the output to a file?

 

1 Reply

  • You can use

    "tmsh -c"
    to execute tmsh with multiple arguments. So in your case you can CD to the partition first: For example:

    tmsh -c "cd /some_partition; show ltm clientssl-proxy cached-certs virtual clientssl-profile"