Initial Installation: Difference between revisions

From Vision
(Updated instructions from latest install 08/09/2017)
(Added details of Easysoft ODBC-ODBC Bridge Installation)
 
(9 intermediate revisions by the same user not shown)
Line 3: Line 3:


==Installation Procedure==
==Installation Procedure==
Please note: These installation notes are draft and should be used as guidelines at this stage.
Please note: These installation notes are draft and should be used as guidelines - each version of Windows and the applications contained therein are configured differently.
 
{{Note}} For datamining from legacy systems (i.e. 4.14 WMS on AIX using C-ISAM files), additional installation files are required specified in the following [[Easysoft ODBC-ODBC Bridge Installation]] section.


Install MySQL database.
Install MySQL database.


Files used:
Files used:
* mysql-5.1.45-win32.msi
* mysql-enterprise-gpl-5.1.46sp1-win32.msi
* mysql-workbench-gpl-5.2.35.1-win32.msi
* mysql-workbench-community-6.3.3-winx64.msi
* mysql-connector-odbc-5.1.6-win32.msi
* mysql-connector-odbc-5.1.11-win32.msi


{{Note}} the latest MySQL Enterprise binaries should be used - download from MySQL as required.
{{Note}} the latest MySQL Enterprise binaries should be used - download from MySQL as required.
Line 16: Line 18:


MySQL Workbench Installation Notes:
MySQL Workbench Installation Notes:
* {{Note}} Workbench requires a number of Microsoft redistributable files to be installed, that may require the machine to be rebooted. The files are:
* {{Note}} Workbench requires a number of Microsoft redistributable files to be installed, that may require the machine to be rebooted. These may be downloaded on demand as part of the Workbench install. The files are:
** wic_x86_enu.exe
** wic_x86_enu.exe (not required on most machines - try the vcredist first)
** vcredist_x86.exe or vcredist_x64.exe
** vcredist_x86.exe or vcredist_x64.exe (Studio 2013 version)
** dotNetFx40_Client_x86_x64
** dotNetFx45_Full_setup.exe (may not be required on some machines)
* Install the files in this sequence.
* Install the files in this sequence.
* Install workbench to default directory.
* Install workbench to default directory.
Line 26: Line 28:


MySQL Connector Installation Notes:
MySQL Connector Installation Notes:
* {{Note}} Microsoft Windows Server 2008 (and any other 64bit version) require the 64bit versions of the ODBC connectors - the latest file is mysql-connector-odbc-5.1.8-winx64.msi)
* {{Note}} Microsoft Windows Server 2008 (and any other 64bit version) require the 64bit versions of the ODBC connectors - the latest file is mysql-connector-odbc-5.1.11-winx64.msi)
* Complete install to default directory.
* Complete install to default directory.


Line 58: Line 60:
* Re-start the service.
* Re-start the service.
'''This must be done before any tables are created within the database.'''
'''This must be done before any tables are created within the database.'''
MySQL Workbench Configuration:
* Edit/Preferences
* SQL Editor
* Disable Safe Updates




Line 66: Line 73:


Install the Vision package. The latest version can be found in the project driver under ''\_Installers\Installer''.
Install the Vision package. The latest version can be found in the project driver under ''\_Installers\Installer''.
* File used: IN110627Vision.zip
* Latest version: IN180406Vision.zip
* Previous version: IN110627Vision.zip
{{Note}} Install the Vision application files away from the root drive.
{{Note}} Install the Vision application files away from the root drive.


Line 103: Line 111:
* Stop the default web site (as it will be using port 80)
* Stop the default web site (as it will be using port 80)
* Create a new web site named CALIDUS Vision, pointing to the virtual directory where you installed the Vision application. Ensure you enable the ability to execute scripts). Accept the standard Application Pool if this is the first install. If multiple installs on this machine, consider using the same pool for both.
* Create a new web site named CALIDUS Vision, pointing to the virtual directory where you installed the Vision application. Ensure you enable the ability to execute scripts). Accept the standard Application Pool if this is the first install. If multiple installs on this machine, consider using the same pool for both.
* Set the Idle Timeout on the Application Pool to your required value, in minutes, through Advanced Settings.
* Set the port for the application. Note: If there are other sites or web servers on the machine, you may need to change this or them away from the standard port 80. That includes the Default Web Site for IIS - change it 8080 if there are no other web servers on the machine (for example Apache, which defaults to port 8080) or 8081.
* Set the port for the application. Note: If there are other sites or web servers on the machine, you may need to change this or them away from the standard port 80. That includes the Default Web Site for IIS - change it 8080 if there are no other web servers on the machine (for example Apache, which defaults to port 8080) or 8081.
* Change the properties of the new Website ('''Advanced Settings''').Change the connection timeout to 300 seconds.
* Change the properties of the new Website ('''Advanced Settings'''). Change the connection timeout to your required timeout in seconds.
* Ensure that Daily '''Logging''' is enabled - use the Advanced tab or '''Select Fields''' button to ensure that all elements are being reported. The information contained in these logs will be used for bandwidth and system efficiency.
* Ensure that Daily '''Logging''' is enabled - use the Advanced tab or '''Select Fields''' button to ensure that all elements are being reported. The information contained in these logs will be used for bandwidth and system efficiency.
* For IIS 6.0 or greater, ensure that Parent Paths are enabled, by enabling the flag 'Enable Parent Paths' from the web site's properties/Home Directory/Configuration/Options screen ('''ASP''' option).
* For IIS 6.0 or greater, ensure that Parent Paths are enabled, by enabling the flag 'Enable Parent Paths' from the web site's properties/Home Directory/Configuration/Options screen ('''ASP''' option).
Line 116: Line 125:
* Windows Explorer to ..\MySQL Datafiles, right-click, Properties, Security, Edit, Add, "IUSR", OK. {{Note}} If not found, use Advanced, Name Starts With IUSR, Find Now, double-click on the user.
* Windows Explorer to ..\MySQL Datafiles, right-click, Properties, Security, Edit, Add, "IUSR", OK. {{Note}} If not found, use Advanced, Name Starts With IUSR, Find Now, double-click on the user.
* Click IUSR added, click Full Control, Apply, OK, OK.
* Click IUSR added, click Full Control, Apply, OK, OK.
{{Warning}} On IIS 6.1, this may not work. In this case, when you attempt to connect to the system through the browser, you receive an error 401.3 (Authentication error). In this case:
* Check the application Pool, Advanced settings. In '''Identity''', should be set to "ApplicationPoolIdentity".
* On Vision Site, Authentication, select ''Anonymous Authentication'', click ''Edit...'', select 'Application pool identity', then '''OK'''.
This should allow the system to run.
{{Note}} If you want to see the proper errors on the system when it stops, then you need to set the following setting:
* On Vision Site, ASP, select ''Debugging Properties'', '''Send Errors to Browser...''', set to ''True'' then '''Apply'''.


Load the database structure through the MySQL Workbench.
Load the database structure through the MySQL Workbench.
Line 127: Line 146:
These files can also be loaded through the following command:
These files can also be loaded through the following command:
<pre>>mysql.exe --host=127.0.0.1 --user=root --password={password} --default-character-set=utf8 --comments <{SQL file}</pre>
<pre>>mysql.exe --host=127.0.0.1 --user=root --password={password} --default-character-set=utf8 --comments <{SQL file}</pre>
{{Note}} If you have any updates or patches to install, do this now.




Line 159: Line 181:
If the system is running on a 64bit version of Windows (natively 7/2008+), the ODBC drivers may not be found, as evidenced by an error when running these scripts. Also, they will not be visible in ''Administrative Tools/Data Sources (ODBC)/System DSN''. If they are visible when executing ''c:\windows\syswow64\odbcad32.exe'', then the items must be scheduled differently. Set them up as follows:
If the system is running on a 64bit version of Windows (natively 7/2008+), the ODBC drivers may not be found, as evidenced by an error when running these scripts. Also, they will not be visible in ''Administrative Tools/Data Sources (ODBC)/System DSN''. If they are visible when executing ''c:\windows\syswow64\odbcad32.exe'', then the items must be scheduled differently. Set them up as follows:
* "c:\windows\syswow64\wscript.exe" "{name of script}"
* "c:\windows\syswow64\wscript.exe" "{name of script}"
In certain version of Windows, this will request that the script name be added as a parameter instead of in the program to be run - this also works.
In certain version of Windows, this will request that the script name be added as a parameter instead of in the program to be run - this also works.
{{Note}} Windows 2012: Also specify the ''Start In'' folder, but DO NOT enclose in quotes.





Latest revision as of 12:29, 20 June 2018

System Requirements

The system should be installed on a Windows Server (2000/2003/2008) with at least 4Gb free disk space and at least 0.5Gb free memory.

Installation Procedure

Please note: These installation notes are draft and should be used as guidelines - each version of Windows and the applications contained therein are configured differently.

Note Note: For datamining from legacy systems (i.e. 4.14 WMS on AIX using C-ISAM files), additional installation files are required specified in the following Easysoft ODBC-ODBC Bridge Installation section.

Install MySQL database.

Files used:

  • mysql-enterprise-gpl-5.1.46sp1-win32.msi
  • mysql-workbench-community-6.3.3-winx64.msi
  • mysql-connector-odbc-5.1.11-win32.msi

Note Note: the latest MySQL Enterprise binaries should be used - download from MySQL as required.


MySQL Workbench Installation Notes:

  • Note Note: Workbench requires a number of Microsoft redistributable files to be installed, that may require the machine to be rebooted. These may be downloaded on demand as part of the Workbench install. The files are:
    • wic_x86_enu.exe (not required on most machines - try the vcredist first)
    • vcredist_x86.exe or vcredist_x64.exe (Studio 2013 version)
    • dotNetFx45_Full_setup.exe (may not be required on some machines)
  • Install the files in this sequence.
  • Install workbench to default directory.
  • Complete install


MySQL Connector Installation Notes:

  • Note Note: Microsoft Windows Server 2008 (and any other 64bit version) require the 64bit versions of the ODBC connectors - the latest file is mysql-connector-odbc-5.1.11-winx64.msi)
  • Complete install to default directory.


MySQL Server Installation notes:

  • Install MySQL server accepting defaults.
  • Ensure that the database and bin areas are installed away from the root drive if possible.


MySQL Server Configuration Notes:

  • Detailed Configuration
  • Server machine
  • Transactional Database Only (InnoDB)
  • Ensure that the database area is installed away from the root drive if possible.
  • Manual Setting of concurrent connections, 50.
  • Enable TCP/IP networking. Note Note: Default port is 3306, which is fine, unless there are other databases installed on the server. If so, it is recommended to set the port to 5306.
  • Add firewall exception. Enable strict mode.
  • Best support for multilingualism
  • Install as a Windows service. Include Bin directory in PATH.
  • Set root password and enable root access from remote servers.
  • Warning Warning: No anonymous access.
  • Warning Warning: NOTE THE ROOT PASSWORD.
  • Execute.


Note Note: In order to help with the preservation and allocation of space to tables, it is recommended that each table is set within it's own data file. In order to do this:

  • Stop the MySQL service.
  • Edit the my.ini file created in {Program Files}\MySQL\MySQL Server 5.1
  • Add the text innodb_file_per_table to the end of the file.
  • Save the my.ini file.
  • Re-start the service.

This must be done before any tables are created within the database.

MySQL Workbench Configuration:

  • Edit/Preferences
  • SQL Editor
  • Disable Safe Updates


Install Microsoft Internet Information Services (IIS) at this stage, if not already installed, from the Add/Remove Windows Components control panel screen (Note Note: IIS can also be installed as part of the Vision installation package).

Note Note: If this is not already installed, this may require the Windows Installation disks.


Install the Vision package. The latest version can be found in the project driver under \_Installers\Installer.

  • Latest version: IN180406Vision.zip
  • Previous version: IN110627Vision.zip

Note Note: Install the Vision application files away from the root drive.


Change the settings in Global.asa (used in Connection.asp and Productivity.asp) to the port number you chose for database connections when installing MySQL. Settings available:

' Connectivity settings - change if the DB server changes or this is a test/dev implementation with a different schema
Application("connServer") = "localhost"
Application("connPort") = 5306
Application("connDB") = "Productivity1"
	
' App settings - these are the defaults for the cookies created and the style setup - change at least appDefStyle for each site
Application("appDefStyle") = "OBS2"
Application("appMenu") = "N"
Application("appFrame") = "800"
Application("appFont") = "m"
Application("appTimeout") = "60"
Application("appTitle") = "CALIDUS Vision"
Application("appPinned") = "Y"
Application("appRedirect") = "N"

' Availability setting - change to "N" if you want to administer the site or install a patch
Application("appAvail") = "Y"
' A notify message that will appear in the footer if set
Application("appNotify") = ""


Add Roles to Server

Start Server Manager:

  • Ensure that Web Service Extensions are enabled for Active Server Pages (From Server Manager/Roles/Add Role).


Configure IIS:

Settings used:

  • Stop the default web site (as it will be using port 80)
  • Create a new web site named CALIDUS Vision, pointing to the virtual directory where you installed the Vision application. Ensure you enable the ability to execute scripts). Accept the standard Application Pool if this is the first install. If multiple installs on this machine, consider using the same pool for both.
  • Set the Idle Timeout on the Application Pool to your required value, in minutes, through Advanced Settings.
  • Set the port for the application. Note: If there are other sites or web servers on the machine, you may need to change this or them away from the standard port 80. That includes the Default Web Site for IIS - change it 8080 if there are no other web servers on the machine (for example Apache, which defaults to port 8080) or 8081.
  • Change the properties of the new Website (Advanced Settings). Change the connection timeout to your required timeout in seconds.
  • Ensure that Daily Logging is enabled - use the Advanced tab or Select Fields button to ensure that all elements are being reported. The information contained in these logs will be used for bandwidth and system efficiency.
  • For IIS 6.0 or greater, ensure that Parent Paths are enabled, by enabling the flag 'Enable Parent Paths' from the web site's properties/Home Directory/Configuration/Options screen (ASP option).
  • Change the Default Document to Productivity.asp
  • Warning Warning: If necessary, ensure that the pages expire immediately, to force reload. (HTTP Response Headers/Set Common Headers). This should happen automatically with server-derived pages, but may be required for some systems. Note Note: Enabling this results in much larger bandwidth requirements, as every page (and item on the page) is resent to the browser at all times. Either leave this disabled or enable it at the web-site level, then enable content expiration of 1 day on the folders Files, Releases, Charts and jQuery. This will ensure that the bulk of the traffic is only resent per day. (Expand the Site on the left, click the folders specified above, use HTTP Response Headers as directed previously).
  • Enable 32bit apps from the Application Pool assigned to this website, from Application Pools above Sites, select the application pool created for the site).

Stop and start the Website created.

Note Note: Set the permissions on the database so that the default IIS user (IUSR) for the machine has access to the folders:

  • Windows Explorer to ..\MySQL Datafiles, right-click, Properties, Security, Edit, Add, "IUSR", OK. Note Note: If not found, use Advanced, Name Starts With IUSR, Find Now, double-click on the user.
  • Click IUSR added, click Full Control, Apply, OK, OK.

Warning Warning: On IIS 6.1, this may not work. In this case, when you attempt to connect to the system through the browser, you receive an error 401.3 (Authentication error). In this case:

  • Check the application Pool, Advanced settings. In Identity, should be set to "ApplicationPoolIdentity".
  • On Vision Site, Authentication, select Anonymous Authentication, click Edit..., select 'Application pool identity', then OK.

This should allow the system to run.


Note Note: If you want to see the proper errors on the system when it stops, then you need to set the following setting:

  • On Vision Site, ASP, select Debugging Properties, Send Errors to Browser..., set to True then Apply.


Load the database structure through the MySQL Workbench.

File used:

  • {Vision}/Database/CreateDB.sql

or

  • {Vision}/Database/CreateDB-Struct.sql
  • {Vision}/Database/CreateDB-Data.sql

These files can also be loaded through the following command:

>mysql.exe --host=127.0.0.1 --user=root --password={password} --default-character-set=utf8 --comments <{SQL file}


Note Note: If you have any updates or patches to install, do this now.


Create any users with localhost permissions through the MySQL Workbench.

Create user permissions in the database using MySQL Workbench.

Alternatively, run the following procedure through the MySQL Browser or Workbench:

CALL InitialiseInstall(<site>, <systems>, <Comp>, <WH>);

Parameters:

  • <site> - The site code used as a base, for example, CHE, BHS, COV, etc.
  • <systems> - The systems to be set up, comma-delimited. They can be WMS, WMS414, WCS, CTMS.
  • <Comp> - The Company Code
  • <WH> - The Warehouse ID

This procedure will create all data-mining parameters required, as well as a default user, based on the site.


Check that the system is working using a web browser.


Set up the Scheduled tasks as follows (through Administrative Tools/Task Scheduler on Windows 7/2008+ or Control Panel/Scheduled Tasks on other versions of Windows):

  • Vision Mining - Daily, from 00:10, for 23 hours 50 minutes. The interval could be anything from 5-15 minutes. It is not recommended that it be any more frequent than every 5 minutes.
  • Vision Cleardown - Daily, once at 00:00.

The two scheduled items above may be tested be right-clicking and selecting Run from the pop-up list of actions.

Note that these tasks require ODBC drivers to access the various systems, as follows:

  • WCS - Microsoft Access
  • WMS/TMS - Oracle

These must be installed. Note that the various versions of Windows may have these installed already. If installed separately, the ODBC driver may have a different name to the one in the script and therefore may need changing in the various scripts. See Administrative Tools/Data Sources (ODBC)/System DSN/Add for the naming of the ODBC drivers.

If the system is running on a 64bit version of Windows (natively 7/2008+), the ODBC drivers may not be found, as evidenced by an error when running these scripts. Also, they will not be visible in Administrative Tools/Data Sources (ODBC)/System DSN. If they are visible when executing c:\windows\syswow64\odbcad32.exe, then the items must be scheduled differently. Set them up as follows:

  • "c:\windows\syswow64\wscript.exe" "{name of script}"

In certain version of Windows, this will request that the script name be added as a parameter instead of in the program to be run - this also works.

Note Note: Windows 2012: Also specify the Start In folder, but DO NOT enclose in quotes.


Upgrading to a new server

If the server being installed is a copy of an older server, follow these instructions after you have installed the system above:

On the old server:

  • Back up the Vision folder and all sub-folders and place in a safe folder
  • backup the entire database:
mysqldump --host=127.0.0.1 --port=5306 --user=root --password={} --result-file=VisionDBBackup_YYYYMMDD.sql Productivity1
  • Copy all the users, passwords and grants with this code:
$ mysql -uroot -N -p -s > myfile
Enter password:
select Distinct CONCAT('show grants for , user, @, host, ;') as query from mysql.user;
quit
$ mysql -uroot -N -p -s -r < myfile > grantfile
Enter password:
  • Add a semicolon to the end of every line in grantfile.
  • Copy the grantfile and the Vision and database backup files to the new server.

On the new server:

  • Copy the Vision backup over the new installation of Vision.
  • Create the database from the backup:
mysql --host=127.0.0.1 --port=5306 --user=root --password={} --comments Productivity1 <VisionDBBackup_YYYYMMDD.sql 
  • Create all users, password and grants:
$ mysql -uroot -p < ./grantfile