New 'unhandled exception' roadblock in upgrading to 4.7
I know the fine folks at Umbraco just _love_ getting those "Object reference not set to an instance of an object" errors because I see them tackling quite a few of them here in the forum, and they're all pretty different from one another. This one occurs after logging into the admin page, apparently successfully because I still get the Content pane and everything's still in the database. The stack trace that appears in the workspace, though, appears to my (amateur) eye to be referring to contents of ASP.NET and not Umbraco proper, so perhaps there's something about my ASP.NET configuration I need to tweak or fix. At any rate, here is the stack trace in full:
[NullReferenceException: Object reference not set to an instance of an object.]
umbraco.presentation.masterpages.umbracoPage.Page_Load(Object sender, EventArgs e) +9
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
System.Web.UI.Control.OnLoad(EventArgs e) +91
System.Web.UI.Control.LoadRecursive() +74
System.Web.UI.Control.LoadRecursive() +146
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2207
I'm not panicking, and am frankly more interested in learning from what may have been a mistake on my part so I can share the lessons with the other users here. If it's too esoteric a problem, I can start over with a fresh installation using the Web Platform Installer if necessary. My thanks for your help in advance.
Thank you, Jan. With this particular installation, I started out with 4.0.4.1. For safety's sake, I upgraded it first to 4.5.1 and then immediately to 4.7, thinking that I would avoid a situation like I discovered in testing where skipping over a version or two could skip over a file or two inadvertently.
Yes, the .NET 4.0 framework is installed. In IIS 7.0, I've changed the application pool over to ASP.NET 4.0 (not Classic), recycled the application pool, and restarted the IIS server. (Several times.)
Yes, but you inspired me to triple-check them. For those of you following at home, the essential Umbraco folders inside the wwwroot folder each need to have permissions enabled for the NETWORK SERVICE user, specifically set to Full Control. I did discover that the umbraco_client folder did not have such a permission set, though I hadn't seen where it needed it before. Anyway, I did create a NETWORK SERVICE permission for umbraco_client, then restarted IIS. No change, same unhandled exception message in the admin window.
Hope there's enough resolution here for you to make this out. Also double-checked with IIS 7.0, and yes, Managed Pipeline Mode for the ASP.NET 4.0 application pool is set to Integrated.
From my checklist, here's the steps I took beginning just after running the Umbraco installation page for 4.5.1 that updates the database:
Stopped the IIS server.
Backed up the existing web.config file.
Unpacked the 4.7.0 binaries to a separate folder.
Moved the contents of the changed folders App_Browsers, App_Data, bin, config, install, umbraco, umbraco_client, and macroScripts (which is empty anyway) and the file default.aspx to their appropriate locations under wwwroot.
Edited the web.config file to include new sections that were added in version 4.6.1 and highlighted in the web.config file included with the 4.7.0 binaries.
Ensured that the admin password in web.config was temporarily set to Clear in order to enable me to update the database and enter the backoffice. (Once everything is working, I can set it back to Hashed and change the password in SQL Server Management Studio.)
Ensured that Full control permissions were granted to the NETWORK SERVICE user for all the folders under wwwroot.
Restarted the IIS server and recycled the ASP.NET 4.0 application pool.
Triggered the 4.7.0 installation page which updates the database.
Entered my temporary admin password to enter the backoffice.
And that's where we are at the moment. Although my plan is to update all my XSLT to the new schema and to Razor, I did try setting UseLegacyXMLSchema in umbracoSettings.config to True, but that has changed nothing.
Could there have been something in the config files from the config folder that I should have taken account of? If so, I do have the working config files from 4.0.5.1 and can make restorations.
Problem solved! You were certainly pointing me on the right track by having me look over my checklist. I decided to install Total Commander on my server and examine each folder from wwwroot and from the binaries download package side-by-side. As it turned out, for some reason unbeknownst to me at present, the contents of the umbraco\masterpages folder were never updated. (Remember the reference to masterpages in the stack trace? That should have been my first clue.) Once I updated that, restarted IIS7 and logged in again, the exception disappeared.
Thank you very much, Jan, as always for all your help.
Great to hear you managed to solve the problem. It's usually related to one self forgetting about something during the process when the backoffice is acting up - and it's always a bit frustrating.
But you're ready to rock now, which is great! Have a good time, right :-)
New 'unhandled exception' roadblock in upgrading to 4.7
I know the fine folks at Umbraco just _love_ getting those "Object reference not set to an instance of an object" errors because I see them tackling quite a few of them here in the forum, and they're all pretty different from one another. This one occurs after logging into the admin page, apparently successfully because I still get the Content pane and everything's still in the database. The stack trace that appears in the workspace, though, appears to my (amateur) eye to be referring to contents of ASP.NET and not Umbraco proper, so perhaps there's something about my ASP.NET configuration I need to tweak or fix. At any rate, here is the stack trace in full:
I'm not panicking, and am frankly more interested in learning from what may have been a mistake on my part so I can share the lessons with the other users here. If it's too esoteric a problem, I can start over with a fresh installation using the Web Platform Installer if necessary. My thanks for your help in advance.
Yours,
Scott Fulton
Hi Scott
What version of Umbraco did you upgrade from? And do you have the .NET 4 framework installed?
/Jan
Thank you, Jan. With this particular installation, I started out with 4.0.4.1. For safety's sake, I upgraded it first to 4.5.1 and then immediately to 4.7, thinking that I would avoid a situation like I discovered in testing where skipping over a version or two could skip over a file or two inadvertently.
Yes, the .NET 4.0 framework is installed. In IIS 7.0, I've changed the application pool over to ASP.NET 4.0 (not Classic), recycled the application pool, and restarted the IIS server. (Several times.)
SF3
Hmmm
Have you double checked that something has not gone wrong with the permissions somehow?
/Jan
Yes, but you inspired me to triple-check them. For those of you following at home, the essential Umbraco folders inside the wwwroot folder each need to have permissions enabled for the NETWORK SERVICE user, specifically set to Full Control. I did discover that the umbraco_client folder did not have such a permission set, though I hadn't seen where it needed it before. Anyway, I did create a NETWORK SERVICE permission for umbraco_client, then restarted IIS. No change, same unhandled exception message in the admin window.
SF3
Hi Scott
Hmmm...ok then...
Could you perhaps post a screendump of what your backoffice looks like?
I suppose the app pool is using integrated mode as well?
/Jan
Here's what I'm looking at, at the moment:
Hope there's enough resolution here for you to make this out. Also double-checked with IIS 7.0, and yes, Managed Pipeline Mode for the ASP.NET 4.0 application pool is set to Integrated.
SF3
Hi Scott
when you made the upgrade from 4.5.1 to 4.7 what steps did you take then?
/Jan
From my checklist, here's the steps I took beginning just after running the Umbraco installation page for 4.5.1 that updates the database:
And that's where we are at the moment. Although my plan is to update all my XSLT to the new schema and to Razor, I did try setting UseLegacyXMLSchema in umbracoSettings.config to True, but that has changed nothing.
Could there have been something in the config files from the config folder that I should have taken account of? If so, I do have the working config files from 4.0.5.1 and can make restorations.
SF3
Problem solved! You were certainly pointing me on the right track by having me look over my checklist. I decided to install Total Commander on my server and examine each folder from wwwroot and from the binaries download package side-by-side. As it turned out, for some reason unbeknownst to me at present, the contents of the umbraco\masterpages folder were never updated. (Remember the reference to masterpages in the stack trace? That should have been my first clue.) Once I updated that, restarted IIS7 and logged in again, the exception disappeared.
Thank you very much, Jan, as always for all your help.
SF3
Hi Scott
Great to hear you managed to solve the problem. It's usually related to one self forgetting about something during the process when the backoffice is acting up - and it's always a bit frustrating.
But you're ready to rock now, which is great! Have a good time, right :-)
/Jan
hi scott
[NullReferenceException: Object reference not set to an instance of an object.]
umbraco.presentation.masterpages.umbracoPage.Page_Load(Object sender, EventArgs e) +9
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +51
System.Web.UI.Control.OnLoad(EventArgs e) +92
System.Web.UI.Control.LoadRecursive() +54
System.Web.UI.Control.LoadRecursive() +145
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +772
help me with this error
thanks
tanya
is working on a reply...