It would be useful if you could clarify which version of Tableau Server you're referring to.
Have you had a previous instance when it worked fine, and if so what version was that and how did you manage it.
Providing this information will help others help you.
I have the same issue.
I am using 2018.2
I don't want to put the password in the batch file, it's not secure. How do I run the backup without using a password?
You can't. A password is required.
Tableau Services Manager command line version 20182.18.0627.2230.
Tableau Server version 20182.18.0627.2230.
What does the account need access to? Surely I'm not going to be forced to ignore security rules to back up your software? Can I add an account to Tableau which can just do the backups?
Version 2018.2.x is really different so we can't really say why it does what it does. It would be best to contact Tableau support about this. Then you can come back and let us know if why and if there is another solution.
I had a same issue but tableau support did not help me modified my script. i was able to figured it out. I have attached Backup, Cleanup and Archive-logs text files. Save those 3 files as .cmd and replace the username and password.
I would recommend that you use the following orders to schedule your scripts.
1. Backup script
2. Cleanup script
3. Archive-logs script.
Get the current file location for backups:
tsm configuration get -k basefilepath.backuprestore
Change the file location for backups:
tsm configuration set -k basefilepath.backuprestore -v "/new/directory/path"
Get the current file location for ziplogs:
tsm configuration get -k basefilepath.log_archive
Change the file location for ziplogs:
tsm configuration set -k basefilepath.log_archive -v "/new/directory/path"
After you change a default file location you need to do the following:
1. Apply pending changes:
tsm pending-changes apply
2. Stop Tableau Server:
3. Restart the TSM Controller (as tableau system account):
sudo su -l tableau -c "systemctl --user restart tabadmincontroller_0.service"
4. Wait several minutes for the controller to restart. You can confirm the controller has restarted with this command:
tsm status -v
When you can run that command and the Tableau Server Administration Controller is listed as 'running' the controller has restarted.
5. Start Tableau Server:
Hope this helps.
Support don't respond to emails or tickets.
The speed at which they respond depends upon the priority assigned and also depends on the support contract (something like basic or premium). You can submit support tickets through your customer portal. If Tableau Support hasn't responded in a day or two from your initial request then you need to let your sales representative know.
2 of 2 people found this helpful
I don't get on with PowerShell. Why do I have a GUI? If I wanted to do everything on a command line why would I use Windows? Anyway, not liking it doesn't fix things.
The answer is in the link Toby Erkson gave, on Lisa Guillet's page. Support also pointed me at it so I gave in and read it properly.
I used the first bit of PowerShell to create cred.sec so I don't have to leave the password in plain text, then created a script like this:
$FilePath = "c:\batch\cred.sec"
$Username = "Domain\Admin"
$encryptedCred = Get-Content $FilePath | ConvertTo-SecureString
$cred = New-Object System.management.Automation.PsCredential($Username, $encryptedCred)
$Pass = $cred.GetNetworkCredential().Password
tsm maintenance cleanup -u "$Username" -p "$Pass"
tsm maintenance backup -f backup.tableau -d -u "$Username" -p "$Pass"
tsm settings export -f "C:\ProgramData\Tableau\Tableau Server\data\tabsvc\files\backups\settings.json" -u "$Username" -p "$Pass"
The batch file at the end copies the backup files to another location and I have a scheduled task "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -ExecutionPolicy Bypass c:\batch\script.ps1". Now all I have to do is update cred.sec when I change the password.
Thanks for sharing your solution. I'm sure it'll help others when they come to upgrade/migrate.
Thanks for explaining what you did, this will help me when I eventually move to 2018.2.x.