SSIS package deploy to remote SQL Server 2012 - visual-studio-2010

I have created SSIS packages on
VS 2010 shell
and I am able to successfully deploy my packages to SSISDB/Folder/Projects/PackageName (local server)
But I am having trouble to deploy the same to remote SQL Server 2012.
How can I do that?
And where is my File system/ MS SQL Server package deployment in VS 2010 Shell?
I tried this:
FTP the Package (ispac) to remote database server and run it from there.
when i try that, I get the bellow error
Warning: Failed to decrypt an encrypted XML node. Verify that the project was created by the same user. Project load will attempt to continue without the encrypted information.
Warning: Failed to decrypt sensitive data in project with a user key. You may not be the user who encrypted this project, or you are not using the same machine that was used to save the project. If the sensitive data is a parameter value, the value may be required to run the package on the Integration Services server.

So ... there's a lot to unpack in your question.
In SQL Server 2012, Microsoft introduced a new default deployment model, the Project Deployment Model. Instead of deploying individual .DTSX package files you "build" a project deployment file (your .ISPAC) and deploy that in toto to the server.
So that's why you don't see File system/package deployment model. You can if you want change a project's deployment model to Package Deployment Model. Just right-click on the Project and select "Convert to Package Deployment Model" and you can then proceed to deploy your packages individually to the File System or MSDB Store as before.
(I don't recommend this by the way, the project deployment is pretty sweet.)
So one question is what error do you see when you go through the Deploy process of VS2010 for your SSIS Project and choose the remote server as your target for deployment?
For your encryption issue, read this link about Access and Security Controls in SSIS Packages, and pay particular attention to the section at the bottom entitled "Protection Level Setting Based on Package Life Cycle" which has some best practices for modifying package encryption levels when migrating packages from a development environment to a production environment.

Related

How do I deploy an SSRS solution?

This is an extremely vague question because I don't know enough to know what I don't know. Here's my situation:
I have downloaded SSDT and connected to a data source (A SQL Server DB instance). I've created a report. I can preview the report in VS. I can publish the report from the VS build menu and it gets published to my local reports server that seems to have been installed by default at http://localhost/reports. I can use a browser to go to that url and see the report I created.
Now, the problem is that this is all only in my local development environment. I installed SSDT through Visual Studio and it auto-created my reports server. Is there a way to install a reports server without installing visual studio and publish the reports from a report solution using an MSI created by a packager like WiX? I'm having a hard time finding information about how to do this.
The report server is typically installed when you install SQL Server. If you want to publish reports so that others can use them do the following:
Go to your VS solution and right-click on the project then select properties.
Set the TargetReportFolder (this will be created if it does not
exist). This will usually reflect the name of the group of reports
you are working on (e.g. 'HR Reports')
Set the TargetServerURL to the report server on your SQL Server box for example http://mySQLServerBox/reportserver/
Set the TargetServerVersion to match your SQL Server installation version (SQL Server 2016 etc)
Now you can simply right-click a report rdl in VS and choose deploy, you can also do the same at the folder level to deploy all the reports in one go.
To access the reports, go to the web portal which will usually be http://MySQLServerBox/reports
I hope this is what you are looking for..

Sitecore Cannot open database "marktwoSitecore_Web" requested by the login. The login failed. Login failed for user 'blah''

I am currently trying to set-up a Sitecore project on my PC. When I go to view the project on my browser I get the following error:
Sitecore Cannot open database "marktwoSitecore_Web" requested by the login. The login failed. Login failed for user 'blah''.
These are the steps that I have carried out so far:
1) Firstly there are three types of sitecore installations to do:
- Complete
- Database only
- Client only
I have gone with the Client only installation.
2) The Sitecore "Client-only" installation instance was made inside the inetpub/ wwwroot folder.
3) I then made a visual studio project
4) I made a folder called "Libraries", which is located in the root of my visual studio project solution. I copied over all the relevant Sitecore.dll's from the wwwroot project to my visual-studio project into the Libraries folder. I also replaced the Default web.config file in my Visual studio project with Sitecore's version of Web.config. And then I added Sitecore references to my Visual Studio project.
6) With all of the initial configuration done; I set-up a publish profile so that I could publish my C# code to inetpub/wwwroot project. I did step four so that my publish would not overwrite sitecore dlls.
5) I changed the Connection strings in App_Config/ConnectionStrings.config to point to the Web, core and master sitecore databases. That were created during the Sitecore installation.
Those were the steps I did prior to getting the error about invalid login credentials. I am not sure why I am getting this error; since I went into Microsoft SQL server Management Studio and I gave the user "blah" admin rights to all of the datbases: Master, web and core.
Any support and guidance would be greatly appreciated; as I am unsure of how to address this problem
This error is happening because the web database referenced in your Website/App_Config/ConnectionStrings.config is either not there or the permissions are not set properly on that database. The easiest way to troubleshoot is to load SQL Server Management Studio specifying the host, username and password that are in your connection strings and see if it connects. It sounds like you are probably logging in with your Windows user when you are making the changes listed above.
You could try making the blah user a "db_owner" to see if that helps or your local instance may not be in "mixed authentication mode" which allows for named users and windows users. You can change that in the settings, but you need to restart the service for it to take effect.

How to save a SQL Server Maintenance Plan within a Visual Studio Database Project

Having created a SQL Server maintenance plan in a SQL Server 2008 R2 instance, how can I import the definitions into a Visual Studio 2013 SSDT database project?
I don't mind using pre- and post-deployment scripts if that helps but I want it to be in a database project and to be able to build the project in VS and then to be able to deploy either a new instance of the plan, or to be able to synchronize an existing plan instance with the definitions in the database project. Also, drop and re-create is entirely acceptable.
Does anyone else already know how to do that ?
First of all maintenance plans are not supported by SSDT.
You can export it manually as an xml template file and then try to write some sql/batch post deploy scripts to deploy it.
You can find general instruction here (read comments also): https://robertbigec.wordpress.com/2013/10/03/automating-deployment-of-sql-server-maintenance-plans/
One note: The exported xml template contains some specific values such as server name or path to backup/log file locations. You might want to write custom script to get these values from target machine and replace it in the xml file.

Visual Studio 2012 Publish from command line

I'm struggling to publish a project from the command line. Here are the steps I've taken:
Created a brand new ASP.NET MVC 3 (internet) project in
Visual Studio 2012
Added a publish File System profile using the publish wizard and specified the destination directory.
Clicking publish successfully deployed the app to the location specified.
Added a second publish profile but this time a Web Deploy
profile. Specified the server, the site name, a username and
password for an account that I use to remote desktop to the
server. Clicked Validate Connection. It displays a small "tick"
image to denote success.
Clicking publish Successfully deploys the app to the remote server.
So in summary, when I use the publish wizard from within Visual Studio I can successfully deploy to the local file system or a remote server using Web Deploy.
Then I switch to the command line
msbuild MyMVCProject.csproj /p:DeployOnBuild=true /p:PublishProfile=PublishToFileSystem.pubxml /p:VisualStudioVersion=11.0
Deploys successfully to the local file system.
However
msbuild MyMVCProject.csproj /p:DeployOnBuild=true /p:PublishProfile=BuildServer.pubxml /p:VisualStudioVersion=11.0 /p:AllowUntrustedCertificate=true
Returns the following error:
msdeploy error ERROR_USER_UNAUTHORIZED: Web deployment task failed. (Connected to the remote computer ("10.0.1.6") using the Web Management Service, but could not authorize. Make sure that you are using the correct user name and password, that the site you are connecting to exists, and that the credentials represent a user who has permissions to access the site. Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_USER_UNAUTHORIZED.)
The page it mentioned in the error message didn't really help me.
Can anyone help, why can I deploy without an issue from the Visual Studio publishing wizard and not from the command line?
The solution turned out to be very simple. I simply needed to add /p:Password=<insert password here> as a parameter on the command line. I supplied the password in the publish wizard, but for security purposes this isn't stored in the .pubxml file.
Actually I discovered this from a 'supplement' book by SAYED IBRAHIM HASHIMI. The book is titled Supplement to Inside the Microsoft Build Engine.

Publishing a SQL Server Database project

I've created a SQL Server database project that correctly deploys a database on my machine. However, I need this project to create databases on QA's machine. They do not know how to create a database from a script.
Is there a way a database project in Visual Studio 2010 can be published so all a non-technical user has to do is click an executable and the database will automatically install?
What you are looking for is this MSDN article: Deploying a Database by Using the Database Publishing Wizard.

Resources