Upgrade - Determine version

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/24/2007 7:34:52 AM
Gravatar
Total Posts 41

Re: Upgrade - Determine version

Hi!

I'm planning on upgrading my site to the latest version. I'm not really sure which version is installed. Is there a way to determine the version?

Can I keep my old Web.config file or do I manually copy my settings over to the new file?

Best regards
Emil

1/24/2007 8:47:31 AM
Gravatar
Total Posts 18439

Re: Upgrade - Determine version

Hi Emil,

In the future I plan to implement something to assist with db upgrades, but for now the best thing to do is look at each of the upgrade scripts and see what they are doing. Usually they are adding new columns or new tables, if you already have the column or table then you don't need to run that specific script, if not then you do need to run it.

You always need to get the latest version of Web.Config and add your custom settings. For settings like connection strings and other tings in the appsettings section, you can place your customizations in user.config and you won't need to change user.config when you upgrade.

Be sure and back up your site and your db before upgrading.

Hope it helps,

Joe
2/2/2007 8:27:30 AM
Gravatar
Total Posts 41

Re: Upgrade - Determine version

Hi!

How should I format my user.config? Could you post an example?

Emil

2/2/2007 9:03:00 AM
Gravatar
Total Posts 18439

Re: Upgrade - Determine version

Hi Emil,

Heres an example:

<?xml version="1.0" encoding="utf-8"?>
<appSettings>

<add key="MSSQLConnectionString" value="server=(local);UID=mydbuser;PWD=mydbpassword;database=mydbname" />
<add key="SMTPServer" value="smtp.mail.yahoo.com" />
<add key="SMTPRequiresAuthentication" value="true" />
<add key="SMTPPort" value="587" />
<add key="SMTPUser" value="mysusername" />
<add key="SMTPPassword" value="mypassword" />
<add key="SSLIsAvailable" value="true" />

</appSettings>

By storing these setting in user.config I don't lose them when I upgrade and replace Web.config with the new one.
It only works for things in the appSettings section of Web.config, but settings in user.config will take priority over Web.config

However, since it only works for appSettings, I still always have to modify the system.net mailSettings section at the bottom of Web.config whenever I upgrade.

Another thing to be aware of, ASP.NET doesn't detect changes you make to user.config, it only watches the Web.config file and if it changes it will restart the app and reload the settings. So when you make a change to user.config you also must open Web.config and type a space or something to modify the file so that the new settings get loaded from user.config.

This also helps when working from svn

Hope it helps,

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