Running 4D Server as a Service on Windows



Similar documents
STATISTICA VERSION 9 STATISTICA ENTERPRISE INSTALLATION INSTRUCTIONS FOR USE WITH TERMINAL SERVER

Changing Your Cameleon Server IP

ACTIVE DIRECTORY DEPLOYMENT

Web based training for field technicians can be arranged by calling These Documents are required for a successful install:

Common SofTest Troubleshooting Techniques

Installation Instruction STATISTICA Enterprise Small Business

STATISTICA VERSION 10 STATISTICA ENTERPRISE SERVER INSTALLATION INSTRUCTIONS

STATISTICA VERSION 12 STATISTICA ENTERPRISE SMALL BUSINESS INSTALLATION INSTRUCTIONS

XMap 7 Administration Guide. Last updated on 12/13/2009

Known Issues and Work Around

Virtual Office Remote Installation Guide

educ Office Remove & create new Outlook profile

Nexio Connectus with Nexio G-Scribe

How To Install Database Oasis On A Computer Or Computer (For Free)

The ECU Wireless system uses a captive portal authentication system. There are three steps to configure your computer for wireless access:

How To Upgrade Your Microsoft SQL Server for Accounting CS Version

XConsole GUI setup communication manual September 2010.

Deploying BitDefender Client Security and BitDefender Windows Server Solutions

XF Extracellular Flux Analyzer. Installation and Troubleshooting Guide

Installation Instruction STATISTICA Enterprise Server

InventoryControl for use with QuoteWerks Quick Start Guide

Abila MIP. Installation User's Guide

Password Manager Windows Desktop Client

Important Notes for WinConnect Server VS Software Installation:

1. Installation Overview

Remote Desktop Access

ILTA HANDS ON Securing Windows 7

User Manual. Onsight Management Suite Version 5.1. Another Innovation by Librestream

for Networks Installation Guide for the application on the server July 2014 (GUIDE 2) Lucid Rapid Version 6.05-N and later

TECHNICAL DOCUMENTATION SPECOPS DEPLOY / APP 4.7 DOCUMENTATION

How To Configure CU*BASE Encryption

Guide to deploy MyUSBOnly via Windows Logon Script Revision 1.1. Menu

Installation Overview

Installing OneStop Reporting Products

Abila MIP. Installation Guide

Administration Guide. . All right reserved. For more information about Specops Gpupdate and other Specops products, visit

How To Create An Easybelle History Database On A Microsoft Powerbook (Windows)

Pearl Echo Installation Checklist

Using Group Policies to Install AutoCAD. CMMU 5405 Nate Bartley 9/22/2005

ilaw Installation Procedure

LifeCyclePlus Version 1

VirtualXP Users Guide

enicq 5 System Administrator s Guide

Universal Management Service 2015

Installation Instructions Release Version 15.0 January 30 th, 2011

Test Note Phone Manager Deployment Windows Group Policy Sever 2003 and XP SPII Clients

Table of Contents. CHAPTER 1 About This Guide CHAPTER 2 Introduction CHAPTER 3 Database Backup and Restoration... 15

System Area Management Software Tool Tip: Integrating into NetIQ AppManager

Historical Reporting Client (HRC) User Login Fails

PROJECTIONS SUITE. Database Setup Utility (and Prerequisites) Installation and General Instructions. v0.9 draft prepared by David Weinstein

Deploying BitDefender Client Security and BitDefender Windows Server Solutions

Nobeltec TZ: Microsoft SQL Server problems

Installing Windows Server Update Services (WSUS) on Windows Server 2012 R2 Essentials

Welcome to the QuickStart Guide

Portions of this product were created using LEADTOOLS LEAD Technologies, Inc. ALL RIGHTS RESERVED.

OneStop Reporting 3.7 Installation Guide. Updated:

Networking Best Practices Guide. Version 6.5

Portions of this product were created using LEADTOOLS LEAD Technologies, Inc. ALL RIGHTS RESERVED.

Virtual CD v10. Network Management Server Manual. H+H Software GmbH

All Tech Notes and KBCD documents and software are provided "as is" without warranty of any kind. See the Terms of Use for more information.

Shellfire L2TP-IPSec Setup Windows XP

Intelligent Power Protector User manual extension for Microsoft Virtual architectures: Hyper-V 6.0 Manager Hyper-V Server (R1&R2)

for Networks Installation Guide for the application on the server August 2014 (GUIDE 2) Lucid Exact Version 1.7-N and later

Snow Inventory. Installing and Evaluating

StrikeRisk v6.0 IEC/EN Risk Management Software Getting Started

Dell UPS Local Node Manager USER'S GUIDE EXTENSION FOR MICROSOFT VIRTUAL ARCHITECTURES Dellups.com

Server & Workstation Installation of Client Profiles for Windows

Mapping ITS s File Server Folder to Mosaic Windows to Publish a Website

Magaya Software Installation Guide

Troubleshooting Guide

Installing and Configuring WhatsUp Gold

WhatsUp Gold v16.0 Database Migration and Management Guide Learn how to migrate a WhatsUp Gold database from Microsoft SQL Server 2005 Express

Aventail Connect Client with Smart Tunneling

Install SQL Server 2014 Express Edition

VERITAS Backup Exec 9.1 for Windows Servers Quick Installation Guide

Xactimate v.27 Network Installation

NextGen Setup Guide First-time Workstation Setup & Logging In

Bosch ReadykeyPRO Unlimited Installation Guide, product version 6.5. This guide is item number DOC , revision 2.029, May 2012.

Thin Client Manager. Table of Contents. 1-10ZiG Manager. 2 - Thin Client Management. 3 - Remote client configurations. 1 of 16

Insight Video Net. LLC. CMS 2.0. Quick Installation Guide

Installation Guide. . All right reserved. For more information about Specops Inventory and other Specops products, visit

Microsoft Office 365 with MailDefender

ZENworks Adaptive Agent Reference

Tool Tip. SyAM Management Utilities and Non-Admin Domain Users

Event Based Interface

Installation Assistance Windows/Microsoft Updates Updating from Spectra or Upgrading from Spectra 6.x...

Database Administration Guide

SystemTools Software Inc. White Paper Series Hyena Installation Requirements

Network Install Guide

Print Audit 4 Network Install Guide

OPC and DCOM: 5 things you need to know Author: Randy Kondor, B.Sc. in Computer Engineering

MicrosoftDynam ics GP TenantServices Installation and Adm inistration Guide

STATISTICA VERSION 11 CONCURRENT NETWORK LICENSE WITH BORROWING INSTALLATION INSTRUCTIONS

TSM for Windows Installation Instructions: Download the latest TSM Client Using the following link:

Out n About! for Outlook Electronic In/Out Status Board. Administrators Guide. Version 3.x

CloudPortal Services Manager Version 11.0 CU1 Deployment Guide

Linko Software Express Edition Typical Installation Guide

Issue Tracking Anywhere Installation Guide

Quick Start Guide 0514US

Transcription:

Running 4D Server as a Service on Windows By Timothy Aaron Penner, Technical Services Team Member, 4D Inc. Technical Note 10-02 1

Table of Contents Table of Contents... 2 Abstract... 3 Introduction... 3 Why run 4D Server as a Service... 3 What is a Service... 3 Why Use 4D as a Service... 3 Registering 4D Server as a Service... 4 Caveats for specific Operating Systems... 6 Windows XP... 7 Windows Server 2003... 7 Windows Vista and Windows 7... 7 Windows Server 2008... 7 Maintenance of the Service... 8 Using the Services Control Panel... 8 Starting the Service... 8 Stopping the Service... 9 Using the Command Line... 11 Starting the Service... 11 Stopping the Service... 11 Unregistering the Database as a Service... 12 Intermediate Updates... 14 Intermediate Upgrades of the 4D Server Software... 15 Intermediate Structure Updates... 15 General Troubleshooting... 15 Why are the 4D menu items concerning Services unavailable?... 15 Why am I unable to interact with the service?... 18 Conclusion... 18 2

Abstract This Technical Note covers many areas surrounding the use of 4D Server as a Service including installation of the service, intermediate upgrades to the 4D software, intermediate updates to the database structure, removal of the service, and some general troubleshooting. Introduction This Technical Note describes the general concepts surrounding running 4D Server as a Service. Tips for maintaining the service including starting and stopping the server from either the Service control panel or the Command Prompt are discussed. Handling of intermediate updates including structure updates and 4D software updates are also discussed. This information should allow the 4D developer the necessary knowledge for deploying their 4D Server applications as a Service on Microsoft Windows operating systems. Why run 4D Server as a Service You may be asking yourself, what is a Service? But more importantly, you may be asking yourself, why should I run 4D as a service? Let s start by first looking at what a Service is. What is a Service On Microsoft Windows operating systems, a Windows service is a long-running executable that performs specific functions and which is designed not to require user intervention. Windows services can be configured to start when the operating system is booted and run in the background as long as Windows is running, or they can be started manually when required. They are similar in concept to a Unix daemon. Source: http://en.wikipedia.org/wiki/windows_service Why Use 4D as a Service The main benefit of using 4D as a Service is a greater integration with the operating system such as: Automatically start when the operating boots up Automatically stop when the operating system shuts down In addition to automatically starting and stopping, services can also be configured to perform specific actions in the event of a failure such as: 3

Restarting the Service Run a program or script Reboot the computer Take no action Registering 4D Server as a Service Most of this is generic and can be applied to all Windows Operating Systems. A few things may differ from OS to OS, such as icons, colors, shortcut names, etc. The main aspect that is specific to Windows 7 and Vista is that the application must be explicitly launched "as an administrator" as described in step 1. 1. Launch 4D Server v11 SQL Release 5 (or higher) as an administrator by right-clicking on the icon and choosing the option to "Run as administrator". * NOTE: If you do not launch the application as an administrator the 4D menu options dealing with services will be unavailable. 2. Open the database that you would like to run as a service. 3. From the File drop down menu, then choose "Register Current Database as Service". 4

* NOTE: At this time, a service should now exist on the machine. But beware: 4D is not yet running as a service. 4. Quit 4D Server. 5. Launch Computer Management. This is most easily accomplished by right-clicking on the "Computer" icon on the desktop and choosing the option to "Manage". 6. Navigate to the Services section under "Computer Management" / "Services and Applications" / "Services" using the Hierarchical menu in left hand column. 7. Find the service for the 4D Server. It is usually named something like "4D Server: DBName" where DBName is the name of your database. In our example we used the DBName of my_test_server. 8. Double-click on the service listing, or right-click and choose properties, to get into the service properties. 5

9. From this screen you will want to choose the startup options such as "Automatic" if you want the service to start automatically, or Manual if you do not want t he database to start automatically. 10. Make a note of the service name listed. This can be used later to start or stop the service from the command line. In the example here, the service name is "4DS my_test_server" 11. After setting the startup options you can click OK to save the properties of the service. 12. At this point you may want to Start the service by right-clicking on it and choosing the option "Start Service" In the examples above we used a database named "my_test_server". Caveats for specific Operating Systems Here is some specific information you should keep in mind when registering a 4D Server database as a service on the different Windows operating systems that are supported. 6

Windows XP The process of registering a 4D Server database as a Service on Windows XP is pretty straight-forward. At the time of this writing there were no known caveats for this operating system. Windows Server 2003 It is important to note that Microsoft has been moving in the direction that Services will no longer be able to interact with the desktop. When Vista was first released, Services were able to interact with the desktop; Microsoft later changed this via a Service Pack update which prevented services from interacting with the desktop. It is not unlikely that Microsoft may make further changes to the way Services work on this operating system. At the time this document was published however, Windows Server 2003 still allowed the service to interact with the desktop. Windows Vista and Windows 7 When registering a 4D Server database as a Service on a machine running Windows Vista or Windows 7 it is very important that you remember to first launch the database as an Administrator; even if you are already logged in to the machine as an administrator. The easiest way to accomplish this is by right-clicking on the icon and choosing the option to "Run as administrator": If you do not launch the application as an administrator the 4D menu options dealing with services will be unavailable. Windows Server 2008 At the time this document was published, Windows Server 2008 did not require the 4D Server application to be launched explicitly as an administrator as it is in Windows 7 and Vista. However, it is unclear whether or not Microsoft will make a change to the operating system that will affect this behavior. 7

Maintenance of the Service This section covers general maintenance, such as starting and stopping of the service. Using the Services Control Panel Many aspects of the service can be controlled / configured from the services menu of the operating system. Starting the Service Starting the service must be completed before any clients can login to the server. The following instructions explain how to start the service using the Computer Management application: 1. Launch Computer Management. This is most easily accomplished by right-clicking on the "Computer" icon on the desktop and choosing the option to "Manage". 2. Navigate to the Services section under "Computer Management" / "Services and Applications" / "Services" using the Hierarchical menu in left hand column. 8

3. Find the service for the 4D Server, it is usually named something like "4D Server: DBName" where DBName is the name of your database. In our example we used the DBName of my_test_server 4. Right-click on the service and choose Start Stopping the Service Stopping the service is an important task that must be completed when performing certain other tasks such as updating the structure, upgrading the 4D Server software, running the Maintenance and Security Center, etc. When the service is stopped the database is not 9

running and the 4D Clients are unable to login. The following instructions explain how to stop the service using the Computer Management application: 1. Launch Computer Management. This is most easily accomplished by right-clicking on the "Computer" icon on the desktop and choosing the option to "Manage". 2. Navigate to the Services section under "Computer Management" / "Services and Applications" / "Services" using the Hierarchical menu in left hand column. 3. Find the service for the 4D Server, it is usually named something like "4D Server: DBName" where DBName is the name of your database. In our example we used the DBName of my_test_server 10

4. Right-click on the service and choose Stop. Using the Command Line The command line can also be used to control the running state of the service. NOTE: On certain Operating Systems such as Windows Vista and Windows 7 you will need to launch the command prompt (cmd.exe) as an administrator otherwise you may get an access denied error message when trying to start or stop the service. Starting the Service Starting the service can be accomplished with the following command: NET START 4DS my_test_server You will need to know the name of the service, which is obtained in step #10 of the Registering 4D Server as a Service section above. In the example above, the service name is 4DS my_test_server and the database name is my_test_server. Stopping the Service Stopping the service can be accomplished with the following command: NET STOP 4DS my_test_server 11

You will need to know the name of the service, which is obtained in step #10 of the Registering 4D Server as a Service section above. In the example above, the service name is 4DS my_test_server and the database name is my_test_server. Unregistering the Database as a Service When a 4D Server database is running as a Service, the menu options concerning services are not available. So before unregistering a database as a Service you must first stop the service (shutdown the database). The easiest way to accomplish this is to issue the NET STOP command from a command prompt. For example, if your database name is my_test_server you could issue the following command from a command prompt: NET STOP 4DS my_test_server NOTE: You must have the command prompt opened with full admin rights in order to perform the above command; otherwise the operating system may prompt you with an access denied error. You can also stop the service using the Services control panel which is located inside of the Computer Management application using the following instructions: 1. Launch Computer Management. This is most easily accomplished by right-clicking on the "Computer" icon on the desktop and choosing the option to "Manage". 2. Navigate to the Services section under "Computer Management" / "Services and Applications" / "Services" using the Hierarchical menu in left hand column. 12

3. Find the service for the 4D Server, it is usually named something like "4D Server: DBName" where DBName is the name of your database. In our example we used the DBName of my_test_server. 4. Right-click on the service and choose Stop. 5. Launch 4D Server v11 SQL Release 5 (or higher) as an administrator by right-clicking on the icon and choosing the option to "Run as administrator". 13

* NOTE: If you do not launch the application as an administrator the 4D menu options dealing with services will be unavailable. 6. Open any database. 7. From the File drop down menu, first choose "Unregister all Server Services" in order to remove all 4D services that exist on this machine. 8. At this point the Service is no longer registered on the machine. 9. Quit 4D. Intermediate Updates This section of the Technical Note covers intermediate updates to both the 4D Software as well as the 4D structure. 14

Intermediate Upgrades of the 4D Server Software When a new version of the 4D Server software comes out you will most likely want to upgrade your deployments. To do so please follow these simple steps: 1. Unregister the 4D Server service using the steps outlined in the Unregistering the Database as a Service section above. 2. Re-Register the service using the steps outlined in the Registering 4D Server as a Service section above; making sure to launch the new version of 4D at step #1. Intermediate Structure Updates When you have a new version of the Structure that needs to be deployed at your client locations you will want to follow these simple instructions on getting the new structure loaded: 3. Unregister the 4D Server service using the steps outlined in the Unregistering the Database as a Service section above. 4. Re-Register the service using the steps outlined in the Registering 4D Server as a Service section above; making sure to open the new structure at step #2. General Troubleshooting This section covers some general troubleshooting for some of the most common problems. Why are the 4D menu items concerning Services unavailable? There are a few reasons that this may be happening: 1. You do not currently have a database loaded. The services menu is only available when a database is loaded. If no database is loaded the menu will look like the following 15

screenshot: 2. The 4D Server application is currently running as service. When the application is running as a service the menu items concerning services (registering and unregistering) are unavailable. 3. The 4D Server application must be launched with explicit Admin privileges. On certain Windows Operating Systems such as Vista and Windows 7, applications are launched with lowered privileges even when logged in to the machine as an admin. In this situation the menu would look like the following screenshot: 16

To get around this you should explicitly launch the application as an admin by right clicking on it and choosing the option to Run as administrator as depicted in the following screenshot: This can also be configured in the Properties for the application under the Compatibility tab: 17

Why am I unable to interact with the service? Beginning with Windows Vista, you won't be able to interact with the desktop when running your application as a service. This is basically the same for any Windows release since Vista: http://msdn.microsoft.com/en-us/library/bb203962(vs.85).aspx As a workaround, you could simply launch 4D and connect to the server as a client, then administer the database from there. This could be accomplished either from the same machine running the server or from any other machine that has access to the server via the network. Another workaround may be to not launch it as a service at all, but to instead use the following approach: 1) Setup a user to login automatically. 2) Use a batch file in combination with a 4DLink file to launch 4D and the appropriate database. The batch file may look like this: "C:\4D Server\4D Server.exe" "C:\autostart.4Dlink" The autostart.4dlink file may look like this: <?xml version="1.0" encoding="utf-8"?><database_shortcut structure_file="file:///d:/4d/myapp.4dc" data_file="file:///d:/4d/myapp.4dd"/> 3) Optionally (for added security), you can also lock the workstation using the following command: "rundll32.exe user32.dll, LockWorkStation". This can be issued either through a batch file in the startup folder or in the registry. The batch file for this may look like this: rundll32.exe user32.dll, LockWorkStation In this workaround, the database is not running as a service, but it is started automatically, and the screen is locked for added security. This allows the console user to interact with the actual 4D Server window. Conclusion This Technical Note described the general concepts surrounding running 4D Server as a Service. Tips for maintaining the service including starting and 18

stopping the server from either the Service control panel or the Command Prompt were discussed. Handling of intermediate updates including structure updates and 4D software updates were also discussed. This information should allow the 4D developer the necessary knowledge for deploying their 4D Server applications as a Service on Microsoft Windows operating systems. 19