Learn Setup Windows Server 2012 - aliconnect/aliconnect.sdk GitHub Wiki

Windows Server 2012

SQLServerManager12.msc

specs

Setup-Windows-Server-2012_files/image002.jpg

Setup

  1. File Explorer
  2. Instellen File Explorer onderdrukken bekende extensies uitzetten
  3. Mapoties Extensies voor bekende bestandstype verbergen, uitzetten Setup-Windows-Server-2012_files/image004.jpg

Create Aim folders

D:
├📁aliconnect
│ ├📁bu
│ │ ├📁bak
│ │ └📁zip
│ ├📁cert
│ ├📁node_modules
│ └📁webroot
└📁sql
  └📁bak

Setup basic applications

  1. Setup Google Chrome
  2. Setup Atom
  3. Setup GitHub

Setup Server Hoge Prestaties

  1. [Windows]+[R] Run: powercfg.cpl
  2. Select Hoge prestaties Setup-Windows-Server-2012_files/image006.jpg

Setup Server Firewall

  1. [Windows]+[R] Run: wf.msc
  2. In addition to using SQL Server Configuration Manager to enable TCP/IP connections, you need inbound tcp port and optionally udp port 1434 open at the firewall for SQL Server to accept inbound connections.
  3. Setup binnenkomende berichten voor
  4. MSSQL_TCP; Protocol=TCP; Poort=1433,1434; 1. Bereik=IP adressen van
    • kantoor Klingelbeekseweg 67
    • kantoor Geelkerkenkamp 14a
    • klanten airo
    • mobiel
  5. MSSQL_UDP; Protocol=UDP; Poort=1434; 1. Bereik=Elk IP-adres
  6. WSS; Protocol=TCP; Poort=81,82,444,445; 1. Bereik=Elk IP-adres
  7. Regels voor binnenkomende verbindingen
    Setup-Windows-Server-2012_files/image008.jpg
  8. Acties/Nieuwe regel
  9. Selecteer Poort
    Setup-Windows-Server-2012_files/image010.jpg
  10. Volgende

Setup Server IIS override mode voor handlers

Override mode staat standaard op Deny. Deze mode is nodig zodat de Web.config code werkt voor het blokkeren van executabel files in de shared folder.

  1. [Windows]+[E] Open File Explorer
  2. Locatie: %windir%\System32\inetsrv\config\
  3. Systeem vraagt wellicht of je toegang wilt tot deze map, bevestig dit
  4. Open: applicationHost.config (met Atom of Notepad)
  5. Select Atom
  6. Zoek naar de tekst: handlers
  7. Wijzig
  • Deny naar Allow <section name="handlers" overrideModeDefault="Allow" />
  1. Zoek naar de tekst: GET,
  2. Wijzig overal GET,HEAD,POST in GET,HEAD,POST,PUT,DELETE,PATCH
  3. Sla bestand op [CTRL]+[S]
  4. Sluit Atom [ALT]+[F4]
  5. Restart IIS

Create SSL Certificate pks file

  1. Use \aim\setup\openssl.exe Of download openssl.exe from https://indy.fulgan.com/SSL/
  2. [Windows]+[R] Run: cmd
  3. Change dir to location certificates
  4. cd \aim\certificates\aliconnect_nl
  5. Run openssl.exe
  6. Type command
    openssl pkcs12 -export -out cert.pfx -inkey private.key -in cert.crt -certfile CACert.crt
    openssl pkcs12 -export -out aliconnect_nl.pfx -inkey aliconnect_nl.key -in aliconnect_nl.crt -certfile aliconnect_nl.ca

Setup Server SSL Certificate

  1. [Windows]+[R] Run: mmc Setup-Windows-Server-2012_files/image012.jpg
  2. Bestand, Module toevoegen/verwijderen [CTRL]+[M]
  3. Certificaten
    Setup-Windows-Server-2012_files/image014.jpg
  4. Toevoegen
    Setup-Windows-Server-2012_files/image016.jpg
  5. Volgende
    Setup-Windows-Server-2012_files/image018.jpg
  6. Voltooien
    Setup-Windows-Server-2012_files/image020.jpg
  7. OK
  8. Consolebasis, Certificaten, Persoonlijk, Certificaten
    Setup-Windows-Server-2012_files/image022.jpg
  9. Importeren
    Setup-Windows-Server-2012_files/image024.png
    Setup-Windows-Server-2012_files/image026.jpg
  10. Volgende
    Setup-Windows-Server-2012_files/image028.jpg
  11. Bladeren
    Select rechts onder file format “Personal Information Exchange (*.pfx, *.p12)”
    Setup-Windows-Server-2012_files/image030.jpg
  12. Wachtwoord {wachtwoordlijst aliconnect_nl.pfx}
    Setup-Windows-Server-2012_files/image032.jpg
  13. Volgende
    Setup-Windows-Server-2012_files/image034.jpg
  14. Volgende
    Setup-Windows-Server-2012_files/image036.jpg
  15. Voltooien
    Setup-Windows-Server-2012_files/image038.jpg
  16. OK
    Setup-Windows-Server-2012_files/image040.jpg
  17. [Alt]+[F4] Afsluiten
    Setup-Windows-Server-2012_files/image042.jpg
  18. Ja
    Setup-Windows-Server-2012_files/image044.jpg
  19. Opslaan

Setup IIS Mime Type

  1. Setup-Windows-Server-2012_files/image046.jpg
  2. Setup-Windows-Server-2012_files/image047.png

Setup IIS Default document

How To

How to add a default document for an application or site

  1. Open Internet Information Services (IIS) Manager :
  2. If you are using Windows Server 2012 or Windows Server 2012 R2:
  3. On the taskbar, click Server Manager, click Tools, and then click Internet Information Services (IIS) Manager
  4. If you are using Windows 8 or Windows 8.1:
  5. Hold down the [Windows] key, press the letter X, and then click Control Panel
  6. Click Administrative Tools and then double-click Internet Information Services (IIS) Manager
  7. If you are using Windows Server 2008 or Windows Server 2008 R2:
  8. On the taskbar, Start point to Administrative Tools, and then click Internet Information Services (IIS) Manager
  9. If you are using Windows Vista or Windows 7:
  10. On the taskbar, Start point to Administrative Tools, and then click Control Panel
  11. Double-click< Administrative Tools, and then double-click Internet Information Services (IIS) Manager.
  12. In the Connections pane, expand the server name, expand Sites, and then navigate to the Web site or application where you want to configure default documents.
  13. In the Home pane, double-click Default Document. Setup-Windows-Server-2012_files/image048.png
  14. In the Actions pane, click
  15. In the Add Default Document dialog box, type the name of the default document that you want to add in the Name box, and then click OK. Setup-Windows-Server-2012_files/image049.png
  16. If necessary, in the Actions pane, select a default document in the list, and then clickMove Upor Move Down to define the order in which IIS should search through the default document list.
  17. In the Default Document alert box, click Yes to decline configuration inheritance from a parent configuration level, or click No or Cancel to cancel the change in default document order. Setup-Windows-Server-2012_files/image050.png
  18. If necessary, click Remove in the Actions pane to remove any file names that you do not want to use as default documents. Index.php before index.html Setup-Windows-Server-2012_files/image051.png

Setup IIS URL Rewrite 2.0

Gebruik versie 2.0 (niet 2.1)

  1. [Windows}+[E]
  2. Locatie: \aim\setup\
  3. Internet
  4. https://www.iis.net/downloads/microsoft/url-rewrite
  5. Google IIS url rewrite 2.0 or use url https://www.microsoft.com/en-us/download/details.aspx?id=47337
  6. Run: rewrite_amd64.msi
  7. Complete Setup
  1. Voer in aliconnect.nl en check server
    Setup-Windows-Server-2012_files/image069.jpg

Setup Server SMTP Service - Programmas en onderdelen

  1. Windows-onderdelen in- of uitschakelen
  2. Volgende
    Setup-Windows-Server-2012_files/image071.jpg

Setup-Windows-Server-2012_files/image073.jpg

  1. Kies onderdelen en selecteer SNMP Server
    Setup-Windows-Server-2012_files/image075.jpg
  2. Volgende
    Setup-Windows-Server-2012_files/image077.jpg
  3. Run services.msc as administrator
  4. Navigate to the properties of the SNMP service.
    Setup-Windows-Server-2012_files/image079.jpg
  5. Select Automatic as startup type. The service always runs, even after turning your computer off and on again.
  6. For monitoring purposes, select all of the services on the Agent tab to have all SNMP values available. Let op, eerst service afsluiten, anders zie je de tabs niet
  7. Setup-Windows-Server-2012_files/image080.png
  8. Setup-Windows-Server-2012_files/image081.png
  9. SNMP-pakketten van een willekeurige host accepteren
    Setup-Windows-Server-2012_files/image082.png

Setup-Windows-Server-2012_files/image083.png Setup-Windows-Server-2012_files/image085.jpg Setup-Windows-Server-2012_files/image086.png Setup-Windows-Server-2012_files/image087.png

  1. Adjust the security parameters like the community string and the IP/host filter list to your security compliance. For example, add the community namepublicwith READ ONLY rights and accept SNMP packets from at least the address of your monitoring server.
  2. That's it! You have successfully configured SNMP on your Windows machine.

Setup Server FTP User

  1. [Windows]+[R] Run: compmgmt.msc
  2. Folder Systeemwerkset\Lokale gebruikers en groepen\Gebruikers
  3. Right click list: Nieuw gebruiker…
  4. Gebruikersnaam: Aim
  5. Volledige naam: Aim
  6. Beschrijving: Aim Gebruiker
  7. Wachtwoord: {zie wachtwoordlijst}
  8. Vink uit: Gebruiker moet wachtwoord bij volgende aanmelding wijzigen
  9. Vink aan Wachtwoord verloopt nooit.
    Setup-Windows-Server-2012_files/image089.jpg
  10. Klik Maken
    Setup-Windows-Server-2012_files/image091.jpg

Setup IIS FTP Site

  1. [Windows]+[R] Run: inetmgr.exe
  2. Select folder sites
  3. Right Click on list panel
  4. FTP-site toevoegen
    Setup-Windows-Server-2012_files/image093.jpg
  • FTP-sitenaam: aim
  • Fysiek pad: D:\aim
  1. Volgende
    Setup-Windows-Server-2012_files/image095.jpg
  • IP-adres: IP address of server
  • SSL: Geen SSL
  1. Volgend
    Setup-Windows-Server-2012_files/image097.jpg
  2. Voltooien

Setup IIS Web Platform

  1. Setup: WebPlatformInstaller_x64_en-US.msi
    Setup-Windows-Server-2012_files/image099.jpg

Setup IIS PHP 7.2

Setup-Windows-Server-2012_files/image101.jpg

Setup PHP ini file

  1. Open notepad als administrator
  2. Ga naar c:\Program Files\PHP\{version}
[WebPIChanges]
error_log=C:\Windows\temp\PHP72x64_errors.log
upload_tmp_dir=D:\php\temp
session.save_path=D:\php\session
  1. maak mappen aan op d:\php
  2. Open php.ini
  3. Wijzig volgende settings
  4. upload_max_filesize = 20M Voeg volgende parametsr toe
  5. memory_limit = -1
  6. post_max_size = 20M Setup-Windows-Server-2012_files/image103.jpg

Setup IIS PHP 7.3.1

  1. [Windows]+[R] Run: inetmgr.exe
  2. Selecteer server
  3. Midden panel, groep Beheer (bovenaan)
  4. Run Web Platform Installer
  5. Search PHP 7.3.1

PHP.INI

; Add SameSite
attribute to cookie to help mitigate Cross-Site Request Forgery (CSRF/XSRF)
; Current
valid values are &quot;Lax&quot; or &quot;Strict&quot;
  1. Select PHP 7.3.1 (x64) Setup-Windows-Server-2012_files/image105.jpg
  2. Install
  3. I Accept
  4. Search PHP v7.3
  5. Select Microsoft Drivers 5.6 (x64) for PHP v7.3 for SL server in IIS Setup-Windows-Server-2012_files/image107.jpg
  6. Install
  7. I Accept Setup-Windows-Server-2012_files/image109.jpg

Setup-Windows-Server-2012_files/image111.jpg

  1. Machine opnieuw opstarten
  2. [Windows]+[R] Run: inetmgr.exe
  3. Run Web Platform Installer Setup-Windows-Server-2012_files/image113.jpg
  4. Finish

Setup IIS PHP 5.6.31

  1. [Windows]+[R] Run: inetmgr.exe
  2. Run Web Platform Installer
  3. Search PHP 5.6.31
  4. Select PHP 5.6.31
  5. Install
  6. I Accept

Setup MSSQL Server 2012

  1. Download MSSQL 2012 Setup files
  2. Maak gebruiker aim
  3. Maak databases en restore databases
  4. Koppel gebruik aim als eigenaar aan database

Setup SQL Server Configuration Manager

Setup MSSQL zodat er een remote verbinding gemaakt kan worden vanuit applicaties.

  1. [Windows]+[R] Run: SQLServerManager11.msc
  2. Locate: SQL Server Network Configuration / Protocols for SQLEXPRESS
  3. Zet Named Pipes op Enabled
  4. Zet TCP/IP op Enabled
    Setup-Windows-Server-2012_files/image115.jpg
  5. Properties TCP/IP
  6. Set Port=1433
    Setup-Windows-Server-2012_files/image117.jpg
  7. SQL Server Services
    Setup-Windows-Server-2012_files/image119.jpg
  8. Open SQL Server Browser
    Setup-Windows-Server-2012_files/image121.jpg
  9. Set Start mode op automatic
  10. Start SQL Server Browser
    Setup-Windows-Server-2012_files/image123.jpg

Make SQL server named instance the default instance

  1. Ga naar SQL Server Configuratie Manager
    Setup-Windows-Server-2012_files/image125.jpg
  2. TCP Dynamic Ports veranderen in 1433
  3. TCP Port veranderen in 1433
    Setup-Windows-Server-2012_files/image127.jpg

Setup NodeJS

  1. Browser Chrome URL https://nodejs.org/en/
  2. Download versie 10.15.3 LTS
  3. Setup NodeJS

Pas config aan

Command prompt config set prefix c:\aim\www\aim\v1\api\node

Setup wss

  1. Cmd
Cd \aim\wss
Npm init
Voer gegevens in
Npm install mssql
Npm install ws

Setup mqtt mosca

Cd \aim\wss
Npm init
Voer gegevens in
Npm install mssql
Npm install mosca –save
Npm audit fix
  1. http://www.hivemq.com/demos/websocket-client/
  2. Host:aliconnect.nl, Port:1884

Setup node SNMP Service

  1. Npm install snmp-native

Setup node Modbus Service

  1. Npm install jsmodbus
  2. Npm install mssql
  3. Npm install websocket

Start Aim WSS

  1. [Windows]+[E] Explorer
  2. Locatie: \aim\wss\
  3. Run: https.bat Setup-Windows-Server-2012_files/image129.jpg

Controleer

Web Socket Server SSL Certificaat

  1. Start browser op PC
  2. URL https://www.digicert.com/help/
  3. Voer in wss.aliconnect.nl:444 en check server
    Setup-Windows-Server-2012_files/image131.jpg

Controleer Website

  1. Open browser
  2. URL https://aliconnect.nl/aim/v1/

Setup taakplanner

  1. Setup-Windows-Server-2012_files/image133.jpg
  2. Setup-Windows-Server-2012_files/image135.jpg
  3. Setup-Windows-Server-2012_files/image137.jpg
  4. Setup-Windows-Server-2012_files/image139.jpg
  5. Setup-Windows-Server-2012_files/image141.jpg
  6. Setup-Windows-Server-2012_files/image143.jpg
  7. Setup-Windows-Server-2012_files/image145.jpg
⚠️ **GitHub.com Fallback** ⚠️