10 Replies Latest reply on Apr 17, 2015 7:11 AM by Toby Erkson

    tabcmd --site  or -t

    Mark ODonnell

      I am finishing a script which requires tabcmd to use specific sites and I am a bit confused on what --site (-t) requires.

      Is it the sites.id which is numerical (1,3,5,etc)?

      Is it the sites.name which can contain spaces (my site)?

      Is it the sites.url_namespace (my_site, or mysite)?

      Is it something else?

      The documentation is vague in what tabcmd is expecting when using --site (-t).

       

      Thanks in advance.

        • 1. Re: tabcmd --site  or -t
          Mark Fraser

          Hi Mark

           

          I'm a Server newbie myself...

          As far as I know it relates to any additional 'sites' you create on Tableau Server.

          The default on Server is to have a single default site, any additional sites you add yourself.

           

          The -t simply says its not the default (if its default you don't need it) and then use the name you gave the site when you created it. It should also be in the URL of the link.

           

          I assume you have seen these, but if not, they will help.

          Sites

          Work with Sites

           

          Any questions/ problems please write back

           

          Cheers

          Mark

          • 2. Re: tabcmd --site  or -t
            Mark Fraser

            Additional...

             

            Work with Sites

            The URL used for Default does not specify a site.

            For example, the URL for a view named Profits on a site named Sales is

            http://localhost/#/site/sales/views/profits.

             

            The URL for this same view on the Default site would be

            http://localhost/#/views/profits.

             

            tabcmd Global Options

            • 3. Re: tabcmd --site  or -t
              Mark Fraser

              forgot to mention...

              if your site name has spaces, enclose them in quotes i.e. "my example site"

               

              http://localhost/#/site/"my example site"/views/profits.

               

              This applies to all filepaths, not just site.

              • 4. Re: tabcmd --site  or -t
                Mark ODonnell

                Thanks for your help Mark Fraser.   After some more trial and error I figured it out.  It as a bit confusing when site id in the DB is always a number, but the documentation refers to it as a name.

                 

                I am doing a query to the DB and grabbing groups and site information.

                The sites.url_namespace contains the  SITEID required for tabcmd.

                 

                I just finished the groups script and it is working well now.   It gets any group created by the method of AD sync and stores the group name and url_namespace.  It then loads them into an array and for each group tabcmd performs a syncgroup.  This I can schedule to run as often as needed to keep all AD groups in sync.

                • 5. Re: tabcmd --site  or -t
                  Mark Fraser

                  Great news!

                  I'm not sure if my posts helped, but glad you have it working now.

                   

                  If your able, could you share your batch script?

                  It would be useful for myself, but also others in the future.

                   

                  Cheers

                  Mark

                  • 6. Re: tabcmd --site  or -t
                    Mark ODonnell

                    I sure will.    It's a Powershell script.

                    I chose Powershell for the server administration because it's quite easy to use and understand.  It plays very well with Windows, AD, DB connections, Exchange, SharePoint, etc, etc.

                    In the future I can take most of what I have already done in Powershell and convert it to real application using Visual Studio with very little effort.

                     

                    When I get the script clean and fully "noted" I will post it to GitHub where my other scripts are.

                    • 7. Re: tabcmd --site  or -t
                      Toby Erkson

                      One thing I recommend is using is "--timeout":

                      tabcmd syncgroup "ITFinanceUsers" --license interactor --no-complete --timeout 1800 >> %sLogPath%\%sLogName% 2>&1 
                      

                       

                      I have a batch script that updates most of our AD-named Groups and for some reason the process will time-out some where along the way (it's not consistent) even though I've placed it at the login command.  When it times-out you will be prompted for a Password:    So taking a note from The specified item was not found. I put a --timeout command on every single "syncgroup" line and that solved the problem.

                       

                      It would appear that the --timeout command is current-line specific and not encompassing as I would expect, even when used at the login command.

                      • 8. Re: tabcmd --site  or -t
                        Mark ODonnell

                        Thanks for the heads up, I've only run into the timeout issue so far when deleting users, but the timeout has become a "optional" parameter in my scripts when required.

                        • 9. Re: tabcmd --site  or -t
                          Mark ODonnell

                          Toby or anyone else. Can some one clarify if when running "tabcmd syncgroup"  with --license  does it change the license level for all users in the group or do those who are already in the group retain their existing license level.

                           

                          I would test this myself, but I don't have access to make changes to AD groups.

                          Thanks.

                          • 10. Re: tabcmd --site  or -t
                            Toby Erkson

                            Mark, I really don't know, good question!

                             

                            What you could try is importing an AD group and use the --license command.  Change the license level for everyone in the imported group and also delete a couple of the users.  Perform the sync again but use a difference --license value.  See if the people [re-]added have the new license level and see what the licensing is for the ones that already exist.  This would be a valid test without the need to fiddle with AD stuff.  Let us know your results.