404.0 error on remote web service, but not local on IIS - iis-6

I have a web service I have written and am trying to publish to a production server. The strange thing is, when I pushed it on the server and set up a virtual folder for the service, it doesn't want to work when accessed from the Internet!
If I open up IIS 6 admin, look at the folder, right click on the .asmx file and select browse; it opens in Internet Explorer fine! If i change the URL to the public URL name, it works ok, but only on the server. If I try to access it from my desktop, I get a 404.0 error! I know the file is there, it works fine on localhost on the server!
I'm pulling my hair out! Any suggestions?

It was a stupid error on my part. When i deployed the web service, i put it in it's own folder on the server. I didn't check permissions on the folder though. When accessing it on localhost, my logged in user had administrative privileges and could see the file. Remotely, as anonymous, it couldn't. Once i matched permissions to what wwwroot had, it worked fine.
List item

Related

Process.start is not working when code is hosted on IIS

I want to open notepad file by process.start when I debug the code locally it is working fine. But when I host my API on IIS it is not working I already give all the permission to my Site on IIS.
I give all the permission to my hosted Website.
Process.Start("C:\\Windows\\notepad.exe");
return Ok("DONE");
There is No error or exception coming.API run correctly.

MAMP PRO: The 'Path' to your remote document root is incorrect. but is not true - all files are there

The problem is incorrect path to remote host, but is not true. I have acces to my server via ftp without problems. All WP files are there and the site is working fine (frontend/backent). I have also access to phpMyAdmin to MySQL datepase binded to this site.
I have notce that paht to the web files is differ depend on FTP or SFTP is. In FTP app is such stright:
/[all wp files]
in editor app (such TextWrangler), after the samy access id/pass, I have got such path:
/home/[accountname]/public_html/[all wp files]
After click on detect button, app changing the path filed on:
- blanc - under FTP connection
or
- public_html - under SFTP
so it mean conection between MAMP and my server is working. Fine. But after this when I trying to Check URLs & credentials or when I trying Import Host... I received:
Error code: -3010 (The 'Path' to your remote document root is incorrect. The 'Path' field on the remote tab is the document root of your remote site that will be accessed via your Public Site URL (e.g.: 'public_html').) - Start auto detect not solved the problem.
or
Error code: -3113 (The 'Path' to your remote document root is incorrect. The 'Path' field on the remote tab is the document root of your remote site that will be accessed via your Public Site URL (e.g.: 'public_html').)
But it is not true! All files are there!
Please help. Should I use some special code under Apache tab (Additional parameters for VirtualHost directive or Directory directive?
Should I know something more from my serverprovider (home.pl) and solved this problem with them (there is no, in my subscription plan, access via cPanel or so, to set up something)?
Should I change something in https.conf file?
I'm not so using server coding so please forgive me but I have no idea where is the problem (but I'm trying to learn) :o)
My environment is:
MacOS X: 10.13.6
MAMP Pro: 5.2.2 (17923)
Thanx for any help or redirection to the answers someware else (I used searching ;o) but without success or I used wrong ask).
Just ran into this and found a solution that worked for me. I just had to switch the Public URL from https to http and it worked.
I had this error too.
Here's what I did to fix it:
Logged into my remote CPanel account
Created an FTP account for user#sitename.com
Defined the user directory in the FTP user settings similar to this /home/[site]/public_html
Ensured that this user had read/write permissions on the remote server (otherwise importing a site in MAMP Pro might fail)
Then, in MAMP Pro (v 6.0.1) created a new host following these steps:
https://documentation.mamp.info/en/MAMP-PRO-Mac/Create-a-new-host/Import/
I found that once the correct FTP permissions were set at the server, MAMP was OK and functioned as planned.
Good luck, hope this works for you too.

Virtual Directory to navigate to http://localhost/MyWebsite instead of http://localhost:8080

I have deployed an ASP.NET MVC 4 application to a new site I have created in IIS 7.5, which I have bound to port 8080. I can reach it by navigating to http://localhost:8080, but I want to reach it via http://localhost/MyWebsite.
I have added a Virtual Directory under my website, which points to "C:\inetput\wwwroot\MyWebsite\". However, when I navigate to http://localhost/MyWebsite, I am presented with a configuration error:
"It is an error to use a section registered as
allowDefinition='MachineToApplication' beyond application level. This
error can be caused by a virtual directory not being configured as an
application in IIS."
Here is what my IIS hierarchy looks like (this is a demo since I have no internet access on the server I am working on).
I have two questions:
Why am I getting this error?
Is this the best way to go about achieving what I want? It seems messy to have the list of files and folders underneath the website and then again underneath the Virtual Directory. If there is better practice then please tell!
Virtual Directories cannot execute scripts, reason why you are getting that error. You need to make your MyWebsite folder an Application. Also, you don't necessarily have to create a separate website for your website, you can use the Default Web Site and create an application MyWebsite in there (it might be less confusing maybe?).

IIS - Resource not found while Directory is browsable

I have a little strange issue on my system. I have hosted a Service, Rest Service (Be Specific) on my system. When I try to access the svc page of the same service it gives me HTTP 404 (The resource cannot be found.) error while I can browse the whole directory and in that directory it shows that the svc file lies with in the folder but when I click on svc file i get the 404 error.
I tried to host the same service on other system and it works fine. I am not sure what causing it not to display on my system.
Any clue would be great help.

403 - forbidden error when add class library to WCF web role on Azure Project

Open VS as admin, I create a solution, add new Cloud Azure Project then pick WCF service web role and then run it, everything is fine, I could access default services through browser nicely, however, when add new blank class library as new DAL project to the solution and run it, I have 403 error says "You do not have permission to view this directory or page using the credentials that you supplied."
what is going wrong?
thanks
P.S (with or without adding EMDX with proper db access to class lib, it came out something)
I tried to answer here https://stackoverflow.com/a/9411719/182371:
As for the Access Denied error:
it could be just an IIS default setting to disable browsing. To resolve that, just navigate to that web site in IIS, find Directory
Browsing icon, and press Enable. You will at least see the files
inside that directory.
Also try not only 127.0.0.1:81, buta specific document inside that folder, like 127.0.0.1:81/Default.aspx
Take into account the fact that there's sometimes some mess with the ports. You see that in the error message it's port 82, but in your
browser it's port 81. So make sure you're using the right port. Or,
even better, in your service definition try to use some non-standard
port for this to avoid remapping.