migrate IIS websites from Server 2008r2 to 2012r2

I'm using MS Web Deploy 3.5 on my Windows Server 2008 r2 box running iis 7.0  to create a package of an existing website using the following command in a batch file:

C:\Progra~1\IIS\Micros~1\msdeploy.exe -verb:sync -enableLink:AppPoolExtension -source:apphostconfig="mywebsite.com.au" -dest:package=c:\mywebsite.com.au.zip 

Open in new window


and after copying that to a location on my Windows Server 2012 r2 box running iis 8.5, I use the following command to import it:

C:\Progra~1\IIS\Micros~1\msdeploy.exe -verb:sync -enableLink:AppPoolExtension -source:package=c:\Shared\mywebsite.com.au.zip -dest:apphostconfig="mywebsite.com.au" > msdeploysync-mywebsite.com.au.log

Open in new window


It shows no error and all of the files now appear in the correct location in c:\inetpub, but nothing appears in IIS's website or application pool list...

Can someone please help determine what is going wrong here?

Thanks
LVL 8
ReeceICT ConsultantAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Dan McFaddenSystems EngineerCommented:
Can you post some info from the generated log?  There may be some helpful info inside?

Dan
Dan McFaddenSystems EngineerCommented:
I would try the import command as follows:

C:\Progra~1\IIS\Micros~1\msdeploy.exe -verb:sync -enableLink:AppPoolExtension -source:package=c:\Shared\mywebsite.com.au.zip -dest:auto > msdeploysync-mywebsite.com.au.log

Open in new window


The "-dest:auto" will take the information that is in the source package and deploy the application with the same parameters as on the original server.

Also, make sure to run from a command prompt using the "Run as Administrator" option.

Dan

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
ReeceICT ConsultantAuthor Commented:
This is from the log for this particular website.  (it's an all but empty site and i've changed the url)

Info: Adding MSDeploy.appHostConfig (MSDeploy.appHostConfig).
Info: Adding appHostConfig (mywebsite.com.au).
Info: Updating site (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']).
Info: Adding child bindings (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/bindings/binding).
Info: Adding child bindings (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/bindings/binding).
Info: Updating limits (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/limits).
Info: Updating logFile (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/logFile).
Info: Deleting customFields (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/logFile/customFields).
Info: Updating applicationDefaults (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/applicationDefaults).
Info: Deleting provider (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/ftpServer/security/customAuthorization/provider).
Info: Deleting customAuthorization (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/ftpServer/security/customAuthorization).
Info: Adding child site (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/application[@path='/']).
Info: Adding child application (MSDeploy.appHostConfig/appHostConfig[@path='mywebsite.com.au']/site[@name='mywebsite.com.au']/application[@path='/']/virtualDirectory[@path='/']).
Info: Adding directory (C:\inetpub\mywebsite.com.au).
Info: Adding directory (C:\inetpub\mywebsite.com.au\aspnet_client).
Info: Adding directory (C:\inetpub\mywebsite.com.au\aspnet_client\system_web).
Info: Adding directory (C:\inetpub\mywebsite.com.au\aspnet_client\system_web\4_0_30319).
Info: Adding file (C:\inetpub\mywebsite.com.au\index.html).
Info: Adding file (C:\inetpub\mywebsite.com.au\web.config).

Open in new window

Has Powershell sent you back into the Stone Age?

If managing Active Directory using Windows Powershell® is making you feel like you stepped back in time, you are not alone.  For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why.

Dan McFaddenSystems EngineerCommented:
Is this from your original command line run or from after trying the command in my post?

Dan
ReeceICT ConsultantAuthor Commented:
my original.
it's weird right - everything looks like it worked
Dan McFaddenSystems EngineerCommented:
OK, well at least its working.  Sometimes a second pair of eyes is needed, if only to look and ask a question.

Dan
ReeceICT ConsultantAuthor Commented:
Your suggestion of using "-dest:auto" worked.
All sites appeared in IIS.  
The only issue I had after this was a reference to default document in the web.config files for many of the sites.  After removing those entries, all sites started working fine.

Thanks
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft IIS Web Server

From novice to tech pro — start learning today.