Access Debug IIS Server From Virtual Machine (VS Express 2013 for Web) - visual-studio-2013

I'm developing a web site with Visual Studio 2013 Express for Web on Windows 7, and I need to ensure compatibility with IE8, so I installed Windows Virtual Machine/XP Mode, and set up network bridging to that the VM uses the same network adapter as the main machine.
Ideally, I would like to be able to connect IE8 running in the VM to the debug IIS server started by Visual Studio on the W7 machine, since having to deploy the site to the actual server every time I want to test a minor fix to the formatting would be a hassle.
The VM network bridging seems to be successful, since I can access domain-only web sites and ping the W7 machine from the VM, but pointing a browser to the site address and substituting the W7 IP for "localhost" comes back with a connection problem, I suspect because IIS is refusing the connection.
Is there a way to configure the IIS process that Visual Studio uses for debugging so that I can connect to it from a virtual machine?

Related

Cannot connect to MSVSMon running on Windows 7 x64

I have a test machine that runs Windows 7 Enterprise x64. I setup MSVSMon (tried both 64 and 32 bit versions) on it and made sure that the Firewall settings would not block the remote debugger. Now I'm trying to connect to this from my dev box running Windows 2008 R2 and Visual Studio 2010. However when I try to connect to the remote debugger, it shows me the following error message:
"Unable to connect to the Microsoft Visual Studio Remote Debugging Monitor named "xxxxx". THere is no server by the specified name running on the remote computer.
Some obvious things:
- I have verified that the name I'm using is correct (picked it up from teh MSMSMon.exe options dialog)
- The dev box does have access to the remote machine, I can check that by connecting to it's file shares.
- The same instance of visual studio is able to connect just fine to another similar test machine, but one running a 32 bit Windows 7 Enterprise.
Any ideas?
Vin
Make sure if you are debugging from VS2010,its the debugger for 2010 and not 2008, and/or vice versa
I would check your firewall is not blocking the connection. Just because you can connect to the fileshare doesn't mean it's allowing the DCOM connection to the Remote Debugger.
See http://msdn.microsoft.com/en-us/library/bt727f1t(v=VS.100).aspx
I generally run MSVSMon on the remote machine from a share on my dev machine where I have several versions of Visual Studio installed. I get "There is no server by the specified name running on the remote computer" error when I run the wrong version of MSVSMon. For example if the VS2008 version of MSVMon is running on the remote machine and I am trying to attach to the process from VS2010.
Default location of MSVMon for VS2008 :
C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\Remote Debugger
Default location of MSVMon for VS2010 :
C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\Remote Debugger
I've found alot of ppl bump into this scenario. Tried to cup the solution in my blog post:
http://livshitz.wordpress.com/2013/02/26/remote-debugging-visual-studio-unable-to-connect-to-the-microsoft-visual-studio-remote-debugging-monitor/#more-144
Here is the snippet of the solution:
Make sure firewall is not blocking your request
Make sure the installed version of Visual Studio Remote Debugging Monitor is supported by the running Visual Sutdio
Create local user on remote target, with the exact user name and password as the debugging user (that runs VS process)
If dns resolving is unavailable (source and target on different domains) open this file
"c:\Windows\system32\drivers\etc\hosts"
and add a new line at the bottom:
"xxx.xxx.xxx.xxx TargetHostName" (without quotes)
This will map the target host name with an IP.

Accessing ASP.NET local server from virtual machine

Don't know if maybe this question belongs on serverfault, but I'll try here first.
I'm running Visual Studio 2010 on my machine, and I want to test my ASP.NET page in IE6. IE6 is running on a virtual machine using Windows XP Mode.
The problem is that I can't access localhost from the virtual machine. I've also tried accessing it via my ip: 123.12.12.123:12121, but that doesn't work either. Is there something I can setup in Visual Studio? Or is the problem most likely with the virtual pc?
The "Cassini" web server provided as part of Visual Studio doesn't support requests from any machine other than the one it's running on. A virtual machine running on that machine is considered to be a different machine for these purposes.
You have twothree options:
Deploy your software to IIS running on your development machine (or a.n.other machine).
Download WebMatrix, to get hold of a copy of IISExpress, as it's somewhat easier to setup debugging against as opposed to "real" IIS.
Have a look at UltiDev Cassini, it's another implementation of the Visual Studio web server. I've never used it so can't comment on quality.
The problem is that the (test) web server that's included won't accept connections from outside. Your virtual machine has its own IP address and is seen as a different machine, just the same as any other physical computer.

step into web service on another LAN server

I'm debugging a vb.net windows program which I've upgraded to a VS 2010 solution, targeting Framework 2. I need to step into a webservice's code. The web service is framework 3.5, also vb.net, running on a windows 2003 server on our LAN. I've seen a ton of crap on the Net about it, mostly other people who couldn't get it working either.
The error I get in VS2010 is the exact same one I got before upgrading the project from VS 2005:
Unable to automatically step into the server. Connecting to the server
machine [servername] failed. The Microsoft Visual Studio
Remote Debugging Monitor (MSVSMON.EXE) does not appear to be
running on the remote computer. Please see Help for assistance.
So I did what Help said to do and ran the VS 2008 remote debugging wizard on the host server. I have verified that the remote debugger is running as a service on that machine. And it still fails.
Little help? THANKS
Just in case anyone comes here looking for this answer, here it is. No goofy 'Attach to Process', no weird bad instructions
from websites going off on a million stupid tangents. This answer has been FALKENIZED.
When on the same LAN and on the same domain, remote debugging from Visual Studio 2010 works when you do the following steps.
on web service host machine, share the web application folder where the web service lives; give yourself 755 permissions.
oops, give yourself wrxr permissions.
on local development machine, map a network drive to the [web service host machine][web app] folder you just shared.
copy the Visual Studio 2010 remote debugger folder (containing msvsmon.exe + support files) to web service host machine.
Make sure you get the correct platform for your host server, e.g. x86, x64, etc. Remote debugger is found here:
C:\Program Files\Visual Studio 2010\Common7\IDE\Remote Debugger[platform]
on web service host machine, drag a shortcut from the newly-copied debugger to the desktop, then start the remote debugger
on local development machine, step thru code. when reaching a call to the web service, you'll be prompted to navigate
to the location of requested web service code file, which will then be available in your mapped path. Do it.
Finally after 1000000 headaches, you may start debugging your web service. CONGRATULATIONS

Connecting to a Web Service running on Visual Studio Development Server from another machine

I have a web service running on machine A on Visual Studio's build-in Development Server.
For testing purposes, I'd like to test the service by connecting to it from machine B, which is in the same subnet.
Is this possible? Or is VSDS restricted to localhost calls only?
-pom-
Visual Studio's Web Development server doesn't support remote connections. You might need to install IIS for this purpose or some proxy server like Squid.

Visual Studio Environment Best Practices?

I have a VM on my Win 7 machine running Server 2008. My website can't run properly unless it's running on the server due to COM+, other website integration and environment variables. Currently, I have VS2008 installed on the Windows Server 2008 and I develop there (which is dumb, I know) instead on in my Win 7 workstation. I hate this setup.
My question is, how can I developer on my workstation and then EASILY push and test th websites on the VM Server?
Access files across the network so the actual changes are made on the VM Server?
Make changes locally and publish to VM Server?
Can I set up VS2008 so that if I when I Run the application in VS2008 it pushes everything over and opens a web browser that points to the VMServer's IIS Website?
Of course, the VM is a server on your network. Exactly like any other server on your network, virtual or otherwise.
For debugging you can setup VS2008 to remote debug but I think you'd have to publish the site, start it and then hook up the debugging but I'm happy to learn that there's an easier way... anyone?

Resources