Gorgo.Live.ToString()

Mariusz, Gorzoch tech Blog

Archive for March 2014

530 User cannot log in, home directory inaccessible

leave a comment »

I’ve was setting up today standard FTP (the one with comes with the installation) server on Windows 2012 R2 and after setting up the users and ensuring that we keep them isolated :

image

we started to get error message as stated in the title of this post.

Home directory of my FTP was = “c:\ftp”

Name of the user “MyUser”

Based on the documentation above setting should try to establish home directory for the user under : “c\ftp\MyUser”. Unfortunately apparently there was something wrong here.

I’ve dig for a while and finally started “ProcessMonitor”. What he show’s me that actually FTP service is looking for home directory under location “c:\ftp\LocalUser\MyUser”. After moving my user folder under “LocalUser” I was able to login without any problems.

Written by Mariusz Gorzoch

27 March 2014 at 15:28

Posted in Bez kategorii

HRESULT E_FAIL has been returned from a call to a COM component–continued

with one comment

It did happened again. Today I got again error “Error HRESULT E_FAIL has been returned from a call to a COM component”. This time I’ve decided to use FileMon (http://technet.microsoft.com/en-us/sysinternals/bb896645) and see if he is not pointing to something with my app doesn’t have access to. What pop-up from that tool is that the app was trying to access that folder :

C:\ProgramData\Microsoft Team Foundation\4.0\Cache

and it end-up with “Access denied”.

I’ve added account used to run app pool to above folder with full permission. Restarted app pool/app and when it went up my error disappeared.

So it, looks that this was permission problem.

Written by Mariusz Gorzoch

21 March 2014 at 10:36

Posted in Bez kategorii

HRESULT E_FAIL has been returned from a call to a COM component

leave a comment »

I have a site hosting application with retrieve some data from TFS 2012 thru TFS API. It was working fine till someone restart. From that point I’ve started to get bellow error:

Error HRESULT E_FAIL has been returned from a call to a COM component.
  Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Runtime.InteropServices.COMException: Error HRESULT E_FAIL has been returned from a call to a COM component.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. 

Stack Trace:

[COMException (0x80004005): Error HRESULT E_FAIL has been returned from a call to a COM component.]
   Microsoft.TeamFoundation.WorkItemTracking.Client.DataStore.DataStoreNative.UpdateMetadata(IntPtr handle, Object rowset, String dbstamp, UInt32& changes) +0
   Microsoft.TeamFoundation.WorkItemTracking.Client.DataStore.Datastore.UpdateMetadata(Object rowset, String dbstamp) +57
   Microsoft.TeamFoundation.WorkItemTracking.Client.WorkItemStore.EndBackendCall(BackendCallData data) +275
   Microsoft.TeamFoundation.WorkItemTracking.Client.WorkItemStore.RefreshCacheInternal(BackendCallData& data) +204
   Microsoft.TeamFoundation.WorkItemTracking.Client.WorkI
temStore.InitializeInternal() +565

I’m still looking for the solution, but what seems to work is:

– add user hosting web site to local admin on the machine

– add user hosting web site to project admins from with you retrieve data

– open team web access (TWA) on user hosting web site on your local machine

– open team web access (TWA) on user hosting web site on the server hosting the solution

This makes web site to work again. Some of above steps are for sure not necessary, but I need above problem to occur again to eliminate some of them. I’ll keep updating that post till I find what exactly is needed to fix above.

Once the web site is back again, then you can undo all above steps and the site will keep working even if you restart IIS.

Written by Mariusz Gorzoch

20 March 2014 at 13:04

Posted in TFS2012

Tagged with

Error HRESULT E_FAIL has been returned from a call to a COM component

leave a comment »

Recently I’ve develop MVC app to expose our TFS to our external customers thru really simplify interface (=Team web access is great, but let’s honest for no IT user it is to far complicated). After testing period on my box and ensuring that all security setup is ok (=we don’t want to show to our customers projects with do not concern them) I’ve deployed that app to one of our DMZ servers. Initially I’ve used one of standard TFS account to host it (the account used to host TFS web services). At that point everything was working fine, but of course that was temporary solution as on the end I preferred to use dedicated account. Unfortunately as soon I get such a account and grant proper access I’ve started to get error as below:

Error HRESULT E_FAIL has been returned from a call to a COM component.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 
Exception Details: System.Runtime.InteropServices.COMException: Error HRESULT E_FAIL has been returned from a call to a COM component.
Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Resolution:

Just take your account and log with it on the server. That as I found is needed in order to create some temporary folder required by TFS API. Once I’ve did that and restarted IIS app pool hosting my app everything started to work correctly.

Written by Mariusz Gorzoch

3 March 2014 at 09:00

Posted in TFS

Tagged with