Some time early in my Blogger experience, I mentioned learning of a new way to process several NDS user objects in different containers. Up to then, my use of UImport had been limited to users in the same container. For example, I can change the password for x users as long as they are in the same container. If they are not, I would have to run UImport against each of the containers. With the new technique, which I shall call The UBang Technique, the context isn't stored in the UImport control file, but is instead specified in the data file, in the form of
!Name Context = blah.bleah.whatever
Two hundred users in two hundred different contexts? No problem, just put !Name Context two hundred times. FYI, the exclamation mark is also known as "bang". Just like backslash ( \ ) is called "whack", these short names make tech talks shorter.
Even though I was excited to learn of the technique from my then-colleague Monika, the opportunity never came up for me to try it out. It didn't help that work had been hectic so there was no time to try new things. At long last, the need arose and I grabbed the chance. On our network we had many desktop deployment accounts. One can have a regular account and then also has a deployment account to carry out desktop deployment for the UmpteenDesk project. Recently, the project came to an end but desktops with the UmpteenDesk image still need to be deployed. The deployment accounts should be terminated with the project, but for some reason they need to be given an expiration date instead. I had 400 of such accounts to work on and they are scattered all over the network, not in a single container. It's true that many were bunched together, say, 20 in a NW container, another 15 in a SE container, but they are still scattered. The UBang Technique comes to the rescue! A colleague of mine helped extracting the necessary info via BindView and further manipulation in Excel and I got myself a .csv file of all the accounts each with its own context, unique or not. Feed the .csv file to my KiXtart script and I got myself a UImport data file with the various contexts properly setup. By some chance, it happened that my own PC couldn't see the network properly so at first the script failed. Running the same script on a colleague's PC worked, so I rebooted and tried again with all 400 accounts. It took almost no time at all. Ah, the Joy of Scripting.
No comments:
Post a Comment