ERROR ON INSTALL2.2.4.5

Post here for help with installing or upgrading mojoPortal pre-compiled release packages. When posting in this forum, please provide all relevant details. You may also want to review the installation or upgrading documentation.

If you have questions about using the source code or working with mojoPortal in Visual Studio, please post in the Developer forum.

Post here for help with installation of mojoPortal pre-compiled release packages

When posting in this forum, please try to provide as many relevant details as possible. Particularly the following:

  • What operating system were you running when the bug appeared?
  • What database platform is your site using?
  • What version of mojoPortal are you running?
  • What version of .NET do you use?
  • What steps are necessary to reproduce the issue? Compare expected results vs actual results.

You may also want to review the installation or upgrading documentation.

If you have questions about using the source code or working with mojoPortal in Visual Studio, please post in the Developer forum.

This thread is closed to new posts. You must sign in to post in the forums.
1/7/2008 7:10:48 PM
Gravatar
Total Posts 2

ERROR ON INSTALL2.2.4.5

When I run 2.2.4.5,mojoPortal Setup give these error info:

Probing system...
File system permissions ok.
MSSQL database connection ok.
database permissions are sufficient to alter schema.
database initial schema already exists.
database core schema needs upgrade.
0 site(s) found.
Running script mojoportal-core - 2.2.4.1 - 00:00:01.1470000
Running script mojoportal-core - 2.2.4.2 - 00:00:01.2420000
Running script mojoportal-core - 2.2.4.3 - 00:00:01.3462000
Running script mojoportal-core - 2.2.4.4 - 00:00:01.3618000
Running script mojoportal-core - 2.2.4.5 - 00:00:01.3930000
System.Data.SqlClient.SqlException: 在被引用表 'dbo.mp_Sites' 中没有与外键 'FK_mp_TaskQueue_mp_Sites' 中的引用列列表匹配的主键或候选键。无法创建约束。请参阅前面的错误消息。 在 System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) 在 System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) 在 System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) 在 System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) 在 System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async) 在 System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe) 在 System.Data.SqlClient.SqlCommand.ExecuteNonQuery() 在 mojoPortal.Data.SqlHelper.ExecuteNonQuery(SqlTransaction transaction, CommandType commandType, String commandText, SqlParameter[] commandParameters) 位置 D:\GoogleSrc\mojoportal\mojoPortal.Data.MSSQL\SQLHelper.cs:行号 448 在 mojoPortal.Data.DBPortal.DatabaseHelperRunScript(String script, String overrideConnectionInfo) 位置 D:\GoogleSrc\mojoportal\mojoPortal.Data.MSSQL\dbPortal.cs:行号 516 在 mojoPortal.Data.DBPortal.DatabaseHelperRunScript(FileInfo scriptFile, String overrideConnectionInfo) 位置 D:\GoogleSrc\mojoportal\mojoPortal.Data.MSSQL\dbPortal.cs:行号 452 在 mojoPortal.Business.DatabaseHelper.RunScript(Guid applicationId, FileInfo scriptFile, String overrideConnectionInfo) 位置 D:\GoogleSrc\mojoportal\mojoPortal.Business\DatabaseHelper.cs:行号 312 - 00:00:01.6270000
Note: This page shows some information that is helpful during setup and upgrades but for security it would be best not to show any information when the system is up to date. You can disable setup and suppress all information on this page by setting DisableSetup=true in Web.config. When you need to upgrade, you can set this back to false. If you are logged in as Administrator setup will run and you will be able to see this page even if it is disabled in Web.config so you can easily leave it disabled and just login before upgrading. But if you are not logged in you will need to enable setup in Web.config.
 

Who can help me?thanks!

 

1/8/2008 6:41:12 AM
Gravatar
Total Posts 18439

Re: ERROR ON INSTALL2.2.4.5

Hi,

Thanks for letting me know. I'm looking into this right now and will post again very soon when it is fixed.

Joe

1/8/2008 6:52:51 AM
Gravatar
Total Posts 18439

Re: ERROR ON INSTALL2.2.4.5

Hi,

It was an error in the upgrade script that I created yesterday.

If you right click the top level folder and do SVN Update it will be fixed.

Thanks,

Joe

1/8/2008 6:39:24 PM
Gravatar
Total Posts 2

Re: ERROR ON INSTALL2.2.4.5

Thanks joe.

I just SVN out and find it works very well.

thanks

2/9/2008 2:10:45 PM
ulu
Gravatar
Total Posts 22

Error installing the latest version

Hi,

I've just got the code from SVN, and I'm trying to install.

It fails to install the 2.2.4.1 upgrade script. It says, Invalid column name 'OpenIDURI'. Invalid column name 'WindowsLiveID'. The problem is, apparently, with the mp_Users_Update procedure -- it tries to use non-existing columns of the mp_Users table.

I noticed that the setup runs the 2.2.3.4 script and then immediately the 2.2.4.1 upgrade script. When I look at the scriptFiles variable in the RunScripts method of the Setup/Default page, I see that the files are not ordered: it shows 2.2.2.1, 2.2.3.0, 2.2.4.1 etc. Meaning that the files are run in a wrong order. Looks like we need some way to order them.

2/9/2008 4:07:47 PM
bob
Gravatar
Total Posts 126
YAF developer

Re: ERROR ON INSTALL2.2.4.5

Look for info in mp_schemascripthistory table. Your error message is there.

2/17/2008 10:09:03 AM
Gravatar
Total Posts 18439

Re: ERROR ON INSTALL2.2.4.5

Hi Ulu,

The way the setup works is this:

If the mp_Sites table does not exist it starts with the script:

/Setup/applications/mojoportal-core/SchemaInstallScripts/mssql/2.2.3.4.config

There will always be only 1 script in this folder which is for initial install on an empty db

after that it will run all scripts in correct order from the folder

/Setup/applications/mojoportal-core/SchemaUpgradeScripts/mssql

starting with the next higher script from the one it ran from the SchemaInstallScripts/mssql folder

there are no missing scripts in this folder though some of the script files are empty in which case it will not run the script but will increment the version in mp_SchemaVersion and will still log running the script in mp_SchemaScriptHistory

I would make sure on your machine that there are no extra script files in the SchemaInstallScripts/mssql folder and no missing or extra scripts in the SchemaUpgradeScripts/mssql folder

If the scripts are there I can think of no reason it would run them in incorrect order. It works correctly in my testing. Perhaps you somehow did not get all the files.

Hope it helps,

Joe

2/17/2008 11:34:42 AM
ulu
Gravatar
Total Posts 22

Re: ERROR ON INSTALL2.2.4.5

Hi Joe,

I'm using the code from the trunk, so I'm able to debug it. The script files are from the trunk as well.

There's this line:

FileInfo[] scriptFiles = directoryInfo.GetFiles("*.config");

Placing a breakpoint on the next line reveals that the scriptFiles variable contains all the necessary files indeed. But they are listed in a random order. Obviously they are sorted alphabetically in your tests; indeed, one could expect that they are sorted, but the docs doesn't say that.

ulu

2/17/2008 12:47:58 PM
Gravatar
Total Posts 18439

Re: ERROR ON INSTALL2.2.4.5

Hi Ulu,

Can you add this right after the GetFiles(...

Array.Sort(scriptFiles);

and let me know if it solves the problem. I see you are right that the sort is not gauranteed to be right using .GetFiles

Thanks,

Joe

4/1/2008 2:33:30 PM
ulu
Gravatar
Total Posts 22

Re: ERROR ON INSTALL2.2.4.5

Hi,

Sorry I'm answering too late, have lost the email alert.

Anyway, a while ago I checked out the new version, and noticed you had added sorting. After that, it worked perfectly.

Thanks

ulu

You must sign in to post in the forums. This thread is closed to new posts.