Kythor
  •  Kythor
  • 65.6% (Friendly)
  • YAF Camper Topic Starter
2013-11-07T15:42:43Z
Hi,

I have uploaded all the files for the upgrade to YAF 2.0.
But when I run the upgrade Wizard I always get this:

[HttpException (0x80004005): Request timed out.]


now what???

I guess it runs some sql scripts and that's what's taking so long... Can I execute them manually?

Please, I need urgent help!
Sponsor
squirrel
2013-11-07T21:14:24Z
You can try to adjust the timeout settings in app.config and db.config -
If you can't find it using the forum search, try my signature link -- searches this site using Google: Google is my Friend 
Kythor
  •  Kythor
  • 65.6% (Friendly)
  • YAF Camper Topic Starter
2013-11-08T09:58:44Z
that worked! thanks
BWG
  •  BWG
  • 99.4% (Exalted)
  • YAF Lover
2013-12-04T19:15:08Z
Hi,

I've also been getting timeout errors when trying to upgrade on a SQL 2005 platform. I've adjusted the timeouts but this hasn't solved the problem for me. When I run the upgrade on a different VM running SQL 2008 there isn't a problem! I've raised this in a thread here:

http://forum.yetanotherf...-6-1-to-2.aspx#post61985 

I've run SQL Server profiler and the problem on SQL 2005 seems to occur with this statement:

if exists (select top 1 1 from [dbo].[yaf_Message] where UserDisplayName IS NULL)
exec('[dbo].[yaf_forum_initdisplayname]


I'm finding this a difficult problem to resolve, so any help or suggestions would be gratefully received.

BWG
tha_watcha
2013-12-06T12:21:11Z
Originally Posted by: BWG 

Hi,

I've also been getting timeout errors when trying to upgrade on a SQL 2005 platform. I've adjusted the timeouts but this hasn't solved the problem for me. When I run the upgrade on a different VM running SQL 2008 there isn't a problem! I've raised this in a thread here:

http://forum.yetanotherf...-6-1-to-2.aspx#post61985 

I've run SQL Server profiler and the problem on SQL 2005 seems to occur with this statement:

if exists (select top 1 1 from [dbo].[yaf_Message] where UserDisplayName IS NULL)
exec('[dbo].[yaf_forum_initdisplayname]


I'm finding this a difficult problem to resolve, so any help or suggestions would be gratefully received.

BWG



Try to remove the execution of that script in the install/tables.sql delete the lines

if exists (select top 1 1 from [{databaseOwner}].[{objectQualifier}Message] where UserDisplayName IS NULL)
exec('[{databaseOwner}].[{objectQualifier}forum_initdisplayname]')
GO


Then the upgrade should run within seconds

That sql script can take some time if you have a large db with lots of topics. It injects all missing display name values in the database

UserPostedImage
BWG
  •  BWG
  • 99.4% (Exalted)
  • YAF Lover
2013-12-06T23:38:27Z
Originally Posted by: tha_watcha 

Originally Posted by: BWG 

Hi,

I've also been getting timeout errors when trying to upgrade on a SQL 2005 platform. I've adjusted the timeouts but this hasn't solved the problem for me. When I run the upgrade on a different VM running SQL 2008 there isn't a problem! I've raised this in a thread here:

http://forum.yetanotherf...-6-1-to-2.aspx#post61985 

I've run SQL Server profiler and the problem on SQL 2005 seems to occur with this statement:

if exists (select top 1 1 from [dbo].[yaf_Message] where UserDisplayName IS NULL)
exec('[dbo].[yaf_forum_initdisplayname]


I'm finding this a difficult problem to resolve, so any help or suggestions would be gratefully received.

BWG



Try to remove the execution of that script in the install/tables.sql delete the lines

if exists (select top 1 1 from [{databaseOwner}].[{objectQualifier}Message] where UserDisplayName IS NULL)
exec('[{databaseOwner}].[{objectQualifier}forum_initdisplayname]')
GO


Then the upgrade should run within seconds

That sql script can take some time if you have a large db with lots of topics. It injects all missing display name values in the database



Thanks, as you said the upgrade runs in seconds.

Will removing that script cause any problems when using the upgraded forum?

bbobb
  •  bbobb
  • 100% (Exalted)
  • YAF Developer
2013-12-07T01:54:00Z
Originally Posted by: BWG 


Will removing that script cause any problems when using the upgraded forum?


Yes, you can loose display names in some cases. Moreover if should be here, because it can be run only once, run it by hand.
The sp creating script is just above the problem script in tables.sql.
It's a strange problem. Try to use begin | end block. I suspect that it can be related to your specific database settings.



BWG
  •  BWG
  • 99.4% (Exalted)
  • YAF Lover
2013-12-07T08:59:33Z
Originally Posted by: bbobb 

Originally Posted by: BWG 


Will removing that script cause any problems when using the upgraded forum?


Yes, you can loose display names in some cases. Moreover if should be here, because it can be run only once, run it by hand.
The sp creating script is just above the problem script in tables.sql.
It's a strange problem. Try to use begin | end block. I suspect that it can be related to your specific database settings.




My SQL isn't very good, so sorry if I have got this wrong.

I added the Begin | End block like this:

if exists (select top 1 1 from [{databaseOwner}].[{objectQualifier}Message] where UserDisplayName IS NULL)
Begin
exec('[{databaseOwner}].[{objectQualifier}forum_initdisplayname]')
End
GO

The script still times out, the message is:


Exception Details: System.Exception: FILE:
mssql/tables.sql

ERROR:
Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding.

STATEMENT:
if exists (select top 1 1 from [dbo].[yaf_Message] where UserDisplayName IS NULL)
Begin
exec('[dbo].[yaf_forum_initdisplayname]')
End



tha_watcha
2013-12-07T10:16:49Z
What you can try is increase the sql timeout or set it to unlimited in the app.config

<add key="YAF.SqlCommandTimeout" value="0" />

0 means unlimited.
UserPostedImage
BWG
  •  BWG
  • 99.4% (Exalted)
  • YAF Lover
2013-12-07T13:59:37Z
Originally Posted by: tha_watcha 

What you can try is increase the sql timeout or set it to unlimited in the app.config

<add key="YAF.SqlCommandTimeout" value="0" />

0 means unlimited.



When I try this SQL uses 99% CPU and just hangs, so the upgrade never finishes.




tha_watcha
2013-12-07T16:28:46Z
Originally Posted by: BWG 

Originally Posted by: tha_watcha 

What you can try is increase the sql timeout or set it to unlimited in the app.config

<add key="YAF.SqlCommandTimeout" value="0" />

0 means unlimited.



When I try this SQL uses 99% CPU and just hangs, so the upgrade never finishes.






Did you actually have the display name feature enabled (which is disabled by default)? Because when display name feature is disabled yaf works correctly, and you don't have to run the procedure.


UserPostedImage
tha_watcha
2013-12-07T16:55:17Z
@Bbobb Can you split the procedure in to multiple procedures to fix this problem?
UserPostedImage
bbobb
  •  bbobb
  • 100% (Exalted)
  • YAF Developer
2013-12-07T21:15:26Z
It doesn't need splitting it should be rewrited to update with correlated quieries.
In the most cases it can be cured by setting connection time to a large value and some patience,
but if a forum is very large, slow cursors create a problem.

sp init_styles has a pattern, I don't have time this year. Or we will wait until I have it.

BWG
  •  BWG
  • 99.4% (Exalted)
  • YAF Lover
2013-12-08T16:23:35Z
Originally Posted by: tha_watcha 

Originally Posted by: BWG 

Originally Posted by: tha_watcha 

What you can try is increase the sql timeout or set it to unlimited in the app.config

<add key="YAF.SqlCommandTimeout" value="0" />

0 means unlimited.



When I try this SQL uses 99% CPU and just hangs, so the upgrade never finishes.






Did you actually have the display name feature enabled (which is disabled by default)? Because when display name feature is disabled yaf works correctly, and you don't have to run the procedure.



I'm not using the display name feature, so I commented out the part of the SQL script which was causing the problem and ran the upgrade successfully. Thanks

About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button

Project Twitter Updates

Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved