Forum Discussion

Algebraic_Mirror's avatar
Algebraic_Mirror
Icon for Cirrostratus rankCirrostratus
Oct 18, 2017

iRulesLX Workspace Mapping Lost - Where is iRulesLX placed in the config?

I just ran into an odd problem with iRulesLX. I was working in a workspace, and had created a new TCL iRule in the workspace. It had a syntax error, but I didn't find that out until I went to create a plugin for my workspace. When I tried to create the plugin, it threw an error about the syntax.

 

So I went back to my workspace to correct the TCL iRule, and it gave me an error message and was unable to load it. To try to resolve that, I used SSH to connect to the BigIP, then I navigated to /var/ilx/... , found the rules directory in my workspace, and deleted it (it was the only rule I had, so I figured if I deleted the rules directory it was no big loss, as I could just click "add rule" on the workspace and recreate).

 

However, things went from bad to worse. After deleting the rules folder, my entire workspace would not show up in the GUI. It was like I didn't have any workspace... there was nothing in the list! Yet when I went out to /var/ilx/... in the command line, it was there still and so where all the files. It was like the GUI/config had somehow lost its connection to that workspace and was no longer aware of it.

 

So I basically have a couple questions: 1. How could that happen when I never deleted the whole workspace, just the rules folder underneath? 2. How do I get the config to recognize that that workspace exists? Is there some mapping in the config files somewhere that I need to restore to tell the F5, "Hey, there's an ilx workspace at /var/ilx/..., please remap!"

 

Any suggestions would be much appreciated!

 

Note: I did try restarting the sdmd process, but that didn't help, probably because my issue is not with plugins or node instances (I didn't have any yet), just with the workspace.

 

3 Replies

  • Found the answer. In the filesystem, underneath your workspace, you will have a couple subdirectories: "extensions" and "rules". These are required for the GUI to be able to load your workspace. Delete either of them, and the workspace will disappear without warning or explanation. Recreate them, and it will return. They can be empty, such as the case where you have no iRules or extensions in your workspace, but they must exist, and if they don't the GUI appears unable to successfully parse/display your workspace, despite the fact that a workspace folder of that name still exists in the filesystem (albeit without a "rules" subdirectory).

     

    When I ran into that issue where a syntax error was causing me to be unable to edit or delete my iRule via the GUI, I was forced turn to the command line. So I went there and deleted the rules folder. Since I only had one rule in the folder, and I wanted it gone, I didn't think deleting the whole "rules" folder was a problem (I naively assumed it had been created when I created my rule, and that if I was getting rid of the last rule, the folder should go away). But, that was not the case: it had been created when I created the workspace, and it had to exist even if empty. Recreating it brought the workspace back.

     

    One other part of the answer: the GUI does not store mappings to iRulesLX stuff in configuration files. For example, there is no entry in the bigip.conf file for any of these workspaces. The GUI just reads the filesystem and shows the workspaces and plugins accordingly. Here are the locations for both:

     

    1. /var/sdm/plugin_store/plugins/
    2. /var/ilx/workspaces/

    Hopefully if someone else runs into this it will help them.