IIS 6.0 W3C Log Folder - iis

In IIS 6.0 Manager when setting the logging properties for a web site I have selected W3C Extended Log File Format. I have selected a log file directory but would also like to be able to change the name of log folder which is auto-generated(i.e. W3SVCXXXXXXXX\exyymmdd.log).
Is it possible to change the name of the W3SVC folder? If so how?
Update:
After further research I discovered that the folder name will be W3SVC#. The # refers to the instance of that site and is also known as the identifier. The Default Web Site will always be 1 and every other site will have a random number assigned to it.
If this is true then there would be no way to choose the name of this folder. Can anyone confirm this?

The randomly generated number is also the website identifier which can be customized.

Related

Issue related to layout of custom webpart

According to requirement of application, I have developed a custom web part in Kentico 9. This web part is using with same functionality at various places but we have to use with different layout structure.
As per my understanding, we can create custom layouts for a single web part from "Layout Tab" in web part configuration. As I used same things with various Kentio built in web part like Logon form, Logon-Mini form, etc.
But while trying to create new layout for my custom web part, I am getting web part loading error and when I checked into event log it is showing following error:
The file
'/CMSVirtualFiles/WebPartLayouts/=vg=87a868ce-926c-4cb3-a441-b4f1d4310afc/TDNForgottenPassword/ForgottenPassword.ascx.cs'
does not exist.
Here, internally system looking for ".CS" file under "CMSVirtualFiles" folder, which has actually under the "CMSWebParts" directory in which I have created my user control.
Is there any specific configuration required in custom web part to implement multiple layout of it? Please help me and guide me, what am I missing or doing wrong?
Check your webpart code file property in the ascx file. You need to specifically declare the full relative path to the .cs file and not just the filename. For example:
Correct
CodeFile="~/CMSWebParts/Community/GroupRegistration.ascx.cs"
Incorrect
CodeFile="GroupRegistration.ascx.cs"
Please make sure you don't have the store virtual files in the file system setting enabled.

IIS 8.5 is not serving JS, CSS, and Image files (static content)

The problem
We're running IIS on Windows 8.1 with Update. We're at the Orchard CMS first time setup screen, and IIS is giving 401s for all static content. We have read the following to no avail:
IIS 7.5 no images css js showing
IIS 7.5 no images css js showing
The official Orchard deployment documentation
Based on those, this is what I have tried that doesn't work.
Turn on the IIS feature to Serve Static Content.
Give IIS_IUSRS permission to Read, write & execute.
Give the site's application pool permission to Read, write & execute.
What does work though is the nuclear option: to give Everyone the Read permission (unless we want to proceed with the Orchard setup; then we need to give Everyone even more permissions.) That leads me to believe that I must give permission to some principle with less scope than Everyone but more scope than both IIS_IUSRS and the application pool combined.
Who/what is that principle?
Pictures to show the problem
We receive a 401 on ..\Themes\SafeMode\Styles\site.css
The task manager confirms that the site is running as the orchard user.
The security properties of the ..\Themes\SafeMode\Styles\ directory gives Read permission to orchard.
Why does it only work when we give Read permission to Everyone?
I had a similar problem. Under authentication, I right clicked "Anonymous Authentication" and clicked "Edit". That shows a dialog giving you the ability to set the identity of the anonymous user. I set it to "Application pool identity" and that fixed the problem for me.
.
This may not be the most secure configuration though, but I'm on a dev server so I don't care.
Try turn on the Static Content and Directory Browsing features under Internet Information Services->World Wide Web Services->Common HTTP Features node.
In my case I had to set Read permission for IUSR user for the web site folder.
So, what I had to do to fix this problem was the following:
(and please understand, that this is not ASP or PHP script related, the server wouldn't even show basic simple .html files, yet would serve out PHP results all day long!)
Two fold…
Had to set the application pool for each site, under advanced settings, to use LocalSystem for it’s process
Under site, advanced settings, security, add the IUSR account to have read & list contents access, for the site… :-)
See any problems with doing that?
'cuz it's working....
Updating windows feature for WWW services/Common Http Features/static content by selecting Static Content checkbox fixed my IIS not service static content issue.
Open IIS -> go to advanced settings of selected website and open Physical Path Credentials -> Select specific user and enter your local user credentials. Open below screenshot for further visualising the things:
IIS Settings

HTTP 403 Forbidden : This website requires you to log in

Using asp .net MVC 4.0 , razor , VS2010 , IIS5.2 , windows Server 2003
I have built an application which i want to publish in IIS. what i did is listed below:
Cleaned then built the solution.
right click on project file and clicked PUBLISH.
publish method : File System
Target Location : C:\Inetpub\wwwroot\testing
then publish.
Then i went to IIS and got my site in Default web sites. happy :). Then i did:
right clicked on testing(my app) and open properties.
In the tabdirectory everything goes fine.
in asp.nettab, i set asp .net version 4.0.30319
here is a little confusion, I set home/index as my default content page in documentstab
then I right click testing and clicked browse. And it shows :
Most likely causes:
This website requires you to log in.
This error(HTTP 403 Forbidden) means that this program was able to connect to
the website, but it does not have permission to view the webpage.
a short summury what i got as error message. This is my fist mvc application and first hosting. What is my fault here? what should i do now?
I had the similar issue. Please try the following:
A. Suggestion below from Microsoft Technet helped me:
The solution is to ensure that the Authenticated Users or \Users group (which usually contains DOMAIN\Users group) has Read & Execute, List Folder Contents and Read permissions on the /BIN folder below C:\inetpub\wwwroot\wss\VirtualDirectories{Sitename80}. Follow the steps listed below to grant the required permissions:
Open Windows Explorer and navigate to the /bin directory of
your web application
Right-click on the folder and click on Properties
Go to Security tab and click on Edit
Click on Add and add the local server group Authenticated
Users or < SERVER NAME >\Users (this usually contains
DOMAIN\Users group).
Select the Read & Execute, List Folder Contents and Read
permissions (if you are planning to add Everyone to the /bin folder,
grant Read permissions only)
Click OK to apply the new settings
NOTE: you may need to to it after every Publish, as permissions somehow may get reset.
B. In VS - set the default page for your website, or try navigating to specific page as opposed to simply opening the website with only the site name.
I know it sounds dumb, but that also was the problem for me
after publishing your webiste to IIS, navigate to http://myServer/mySite/somePage instead of http://myServer/MySite

Different My Site Themes on different SSP's

We are running MOSS 2007, with 4 different SSPs.
I want to change the theme that is applied to the mysites created on one of the SSPs. I plan to do this using feature stapling but how can I deploy this feature to just this specific mysite url as it only differs by port number.
Cheers
Isn't the feature Site / WebApplication scoped? That way you target only the web application / site-collection the feature is activated in...
Check out this link:
SharePoint+Features+-+Scope+of+Deployment
The web application deployment target is used as the destination for the following application scope resources which may appear in your solution manifest. These are physical changes to files within your web application (IIS web site).
ApplicationResourceFiles - Ex: MyFiles\My.resx. See the comment at the bottom of the solution manifest schema for some more detail.
Assemblies (if the DeploymentTarget is set to WebApplication) -> Ex: [web]\80\bin\MyAssembly.dll
CodeAccessSecurity - Changes to section in [web]\web.config to point to a new custom policy file in [12]\config
DWPFiles - .webpart and .dwp files for custom web parts
SafeControls - Additional entries in section in [web]\web.config.

"URL Rewriting"/Routing with .net 3.0 and IIS 6.0

I wonder what the best approach is for a situation where I want to have the user type in
http://myserver/something/20
and get redirected (301 or 302) to
http://someotherserver/applications/something/modules/default.aspx?id=20
For .net 3.5 and IIS 7 I found some solutions, but unfortunately I am stuck with .net 3.0 and IIS 6.0 on Windows 2003, and I do not want to install anything on the server if possible. I can change the settings for the Virtual Directory though, and if I have to for the entire site.
HTTPModules and web.config are ASP.net only If I am not completely mistaken, hence that will not help as /20 is not sent to ASP.net per Default?
Can anyone give me some tips where I can set up something like that?
The only way I have seen to do it without putting the 301 redirects directly into IIS Manager is to use Wildcard mapping
Link
Map the .* extension to the same DLL as .aspx in the virtual directory's file mappings in Application Configuration. Then in the web.config's httpHandlers section, map the URL to the type.
You might enlist the assistance of ASP.
Create a 404.asp file in your something folder with the content:-
<%
Dim id : id = CLng(Mid(Request.QueryString, InStrRev(Request.QueryString, "/")+1))
Response.Redirect "http://someotherserver/applications/something/modules/default.aspx? id=" & id
%>
In Custom errors of the something folder in IIS manager tweak to URL and /something/404.asp
Note the querystring value passed to the 404 customer error page looks like:-
404;http://myserver:80/something/20
Edit: D'oh or you could use a 404.ashx custom error page and then use more familiar .NET code.
In IIS, right click on the Virtual Directory, select Properties.
Under the Directory tab, click the Configuration... button.
Under the Mappings tab, under the Wildcard application maps (order of implementation): click the Insert... button.
Browse and select C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll, leave Verify that the file exists unchecked.
Move Up aspnet_isapi.dll to the top of the list.
Click Ok, Ok, and try it. Try recycling the application pool if you don't see it work.
We had a situation where the .Net Routing was working on our development PCs but not on the test and production server with IIS 6 and Windows 2003. This fixed our problem.

Resources