Snippet Name: RSConfig_and_Subscription_Accounts
Tags:
Created Date: 2025-06-16 13:12:47
Last Modified Date: 2025-05-31 10:32:19
Dependencies:
DBA Notes:
Sample Output:
Title: RSConfig and Subscription Accounts
Author: user
in SQL2019 SSRS , I know i can change the service account for the service, can i use rsconfig.exe to change the subscription settigns and then file share account?
Author: ChatGPT
In **SQL Server 2019 Reporting Services (SSRS)**, you can **change the file share account used for subscriptions** using `rsconfig.exe`, but with **important limitations** and distinctions:
---
### ???? What `rsconfig.exe` is for:
`rsconfig.exe` is primarily used to:
- Configure **Report Server database connection** credentials.
- Set or reset the **symmetric key** encryption password.
- Configure the **Unattended Execution Account** (if needed).
---
### ??? What `rsconfig.exe` **cannot** do:
It **does not manage subscription-specific credentials**, including:
- **File share (Windows) credentials** used for File Share Delivery subscriptions.
- **Data source credentials** for reports.
- **Execution account** or **individual user subscription accounts**.
---
### ??? To Change File Share Credentials for Subscriptions:
File Share Delivery subscriptions store the file share **Windows credentials** within the subscription definition. To update them, you have **3 options**:
---
#### 1. **Manually edit each subscription** via Report Manager or SSRS Web Portal:
- Go to the report with a subscription.
- Edit the subscription.
- Update the **Windows credentials** used for file share access.
---
#### 2. **Scripted update using T-SQL**:
You can directly update the subscriptions via the `ReportServer` database. For example:
```sql
-- WARNING: This modifies internal SSRS data. Test thoroughly!
USE ReportServer;
UPDATE Subscriptions
SET
ExtensionSettings = REPLACE(
CAST(ExtensionSettings AS NVARCHAR(MAX)),
'UserName="old_user"',
'UserName="new_user"'
)
-- You can also update Password, FilePath, etc. using XML manipulation
WHERE ExtensionSettings LIKE '%FileShare%';
```
> ?????? `ExtensionSettings` is stored in **XML format**. You'll need to parse or update XML carefully, especially if encrypted.
---
#### 3. **Use the SSRS Web Service (`ReportService2010`) via PowerShell or C#**:
This is the **cleanest way** to manage and update subscription credentials programmatically.
Here???s a PowerShell snippet using the SSRS web service proxy:
```powershell
# Load web service
$ssrs = New-WebServiceProxy -Uri "http://<reportserver>/ReportServer/ReportService2010.asmx?wsdl" -Namespace SSRS -UseDefaultCredential
# Get the subscription
$subs = $ssrs.ListSubscriptions("/MyReport", $null)
# Update ExtensionSettings (including new credentials)
$extSettings = $ssrs.GetSubscriptionProperties($subs&#91;0].SubscriptionID, &#91;ref]$desc)
$extSettings.ParameterValues | ForEach-Object {
if ($_.Name -eq "USERNAME") { $_.Value = "domain\\new_user" }
if ($_.Name -eq "PASSWORD") { $_.Value = "new_password" }
}
$ssrs.SetSubscriptionProperties($subs&#91;0].SubscriptionID, $extSettings)
```
---
### Summary:
| Task | Tool |
|------|------|
| Change service account | Services.msc / `sc.exe` |
| Change ReportServer DB credentials | ??? `rsconfig.exe` |
| Change File Share credentials for subscriptions | ??? Not via `rsconfig.exe`<br>??? Web Portal, T-SQL, or Web Service API |
Would you like a fully working PowerShell or SQL example to update file share credentials in bulk?