okay sorry for cross posting but want to see if any one can explain the
solution to this problem for me:
I have a .Net ASP.Net app written in C# that use COM+ components to do some
business processing......
When I have the ASP.Net website and the COM+ components installed on the
same machine (i.e everything local) it all works fine, and it can write to
the event log....
But when I moved the COM+ component onto a remote application server I get
the following error when the COM+ service attempts to write to a remote
event log.
A first chance exception of type 'System.InvalidOperationException' occurred
in mscorlib.dll
Additional information: Cannot open log for source {0}. You may not have
write access.
Can anyone tell me how to cofig the event log so that the remote COM+
service can write to this event log.
All servers in my architecture are running windows 2003 server. I know that
the COM+ service is running correctly because several calls i have made to
the component have completed correctly, but when a particular method fails
and attempt to wirte to the remote Event log it fails and the exception is
generated in the ASP.Net application saying the above, this indicates that
it can not write to the event log does it?
Cheers in advance
Ollie
Kevin Spencer - 22 Apr 2004 19:22 GMT
Everybody who cross-posts has a reason for doing so. However, nobody has a
RIGHT reason for doing so.

Signature
HTH,
Kevin Spencer
.Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
> okay sorry for cross posting but want to see if any one can explain the
> solution to this problem for me:
[quoted text clipped - 29 lines]
>
> Ollie
Ollie - 22 Apr 2004 19:44 GMT
how about "Big things are made up of useful things........"
or better still
"Big things are made up from useful help from lots of people........"
> Everybody who cross-posts has a reason for doing so. However, nobody has a
> RIGHT reason for doing so.
[quoted text clipped - 36 lines]
> >
> > Ollie
Kevin Spencer - 22 Apr 2004 21:16 GMT
If you think that p***ing people off is going to be useful to you, go ahead
and call my advice useless. Netiquette exists for a reason, and my advice is
there to help you continue to get answers when you need them. I believe that
teaching a man to fish is much more valuable than giving a man a fish. Go
figure.

Signature
HTH,
Kevin Spencer
.Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
> how about "Big things are made up of useful things........"
> or better still
[quoted text clipped - 45 lines]
> > >
> > > Ollie
Ollie - 22 Apr 2004 21:52 GMT
I wonder if I can report MVP's for the 'wrong' attitude and generally being
useless and therefore not being a 'VALUED PROFESSIONAL'......
because I am now off to search the MVP site for such a link.....
Have A Nice Day...
FYI - Willy Denoyette [MVP] provide a very useful short and precise answer
that helped the problem greatly. I suggest you have a lot to learn about
'HELPING' people, having a pro-active answer is what is required not a
negative unhelpful answer, I guess you get more MVP 'points' by the number
of replies you post not the quality.....
> If you think that p***ing people off is going to be useful to you, go ahead
> and call my advice useless. Netiquette exists for a reason, and my advice is
[quoted text clipped - 60 lines]
> > > >
> > > > Ollie
Ollie - 22 Apr 2004 20:01 GMT
Infact I will tell you why i crossed posted:
1. It's an asp.net app so it seems reason to post here and I don't whether
this is an asp.net issue.....
2. It's an asp.net that contains COM+ components and I don't whether this is
a com+ issue.....
3. It's all written in C# .net and I don't whether this is a C# issue.....
4. And..... what the hell I will ask in the COM+ newsgroup because may be
this is not a .Net managed environment issue but a general rights issue with
windows 2003
Ollie.
PS - why do you have an MVP is it to help other people who are trying to
solve problems when they can't see the wood for the tree's or is it because
you just want geek fame and big yourself up?
Because if you are an example of the current MVP's then god help us......
Have A Nice Day....
> Everybody who cross-posts has a reason for doing so. However, nobody has a
> RIGHT reason for doing so.
[quoted text clipped - 36 lines]
> >
> > Ollie
Willy Denoyette [MVP] - 22 Apr 2004 19:51 GMT
This is a security issue, check if the identity of the COM+ server has the
right privileges to access the remote eventlog.
But you should ask yourself why an application running on lets say serverA
should write to the eventlog of serverB.
Willy.
> okay sorry for cross posting but want to see if any one can explain the
> solution to this problem for me:
[quoted text clipped - 33 lines]
>
> Ollie
Ollie - 22 Apr 2004 20:05 GMT
thanks for the answer Willy,
The reason that it is using a remote event log is because you can't have a
.net config file for a COM+ (as I understand the current status of COM+)
service component and what i did instead was to pass the event log
information from the asp.net and tell the remote COM+ component to write
that event log if an error occurs....
Cheers
Ollie
> This is a security issue, check if the identity of the COM+ server has the
> right privileges to access the remote eventlog.
[quoted text clipped - 40 lines]
> >
> > Ollie
Steve Jansen - 26 Apr 2004 16:55 GMT
Ollie,
Your prior statement is no longer true with COM+ 1.5. I did not see if you
are using Windows XP or Windows 2003.
If you are, check out the blog entry:
http://weblogs.asp.net/florinlazar/archive/2003/12/04/41369.aspx
Basically, you need to set the COM+ Application Root Directory to something
other than %WINDIR%\system32, then add a simple application.manifest file
along with your application.config file. The manifest can be as boilerplate
as :
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
</assembly>
The config file should contain your normal configuration settings.
HTH,
Steve
BTW -- Kevin Spencer's behavior was unprofessional. MVPs contribute to
the developer community, not detract from it. MS should reconsider whether
he is deserving of the title.
> thanks for the answer Willy,
>
[quoted text clipped - 57 lines]
> > >
> > > Ollie
GL - 22 Apr 2004 20:08 GMT
In 2003, there are special permissions for who can write to the eventlog.
This may be part of your problem. Also, the ASP.Net worker process by
default does not have the registry permissions to create a new eventlog
source.
This page may help you, It helped me.
http://support.microsoft.com/default.aspx?scid=kb;en-us;323076
GL
> okay sorry for cross posting but want to see if any one can explain the
> solution to this problem for me:
[quoted text clipped - 29 lines]
>
> Ollie
Ollie - 22 Apr 2004 20:14 GMT
cheers GL.....
I already have the settings to allow the local asp.net app to create and
write to the event log, the remote process can't currently write to a remote
event log
Ollie
> In 2003, there are special permissions for who can write to the eventlog.
> This may be part of your problem. Also, the ASP.Net worker process by
[quoted text clipped - 43 lines]
> >
> > Ollie