On Aug 28, 2019, at 11:14 AM, Mike Beatty wrote:

> Running into an issue trying to get a v16.6 built application to run as a 
> service, wondering if anyone has this in place before we ramp up the 
> troubleshooting.
> 
> A few notes — this is on a client remote server, which is administered        
> by a third party that will not allow us to have administrative access. The 
> machine does have a 2003 app running as a service. We can run the application 
> outside of services without an issue. We have switched between running as the 
> local account to use interactive desktop, but when we try to view the 
> message, we get kicked out of machine — the third party group loses 
> connection for roughly 60 seconds, then reports seeing both a power shell 
> window and a command prompt. When running as an administrator account, as is 
> the 2003 version, the service will start, then inexplicably stop. Windows 
> logs don’t shed much light on the issue.
> 
> We are going to start trying other means to find cause/resolution, just 
> wanted to see if anyone is running this config successfully.

I’ll give you the info that I know and hopefully it can get you pointed in the 
right direction and get it working. 

I ran into issues when I upgraded a v12 4D Server app on Window Server 2012 to 
v16 running as a service. Something has changed between v12 and v16 — probably 
security updates to prevent virus infestation in addition to 4D Server internal 
changes — that makes running 4D Server as a Windows Service fail if you try to 
use “Local System account”. I could never get this to work. Also since you 
can’t do “Local System account” you can’t do “Allow service to interact with 
desktop”. So get used to not having that available any longer. 

The first task is for you or the third party IT to RDC to the machine and start 
up 4D Server as a desktop application. Make sure you are not getting any 
messages like select a data file. Once you get 4D Server able to start up as a 
desktop application and show the Administration window with no message you can 
then move to setting up the Windows Service.

When you start 4D Server as a desktop application, go to the File menu and 
choose “Register Current Database as Service”. If this is grayed out, you need 
to launch 4D Server with Administrator privileges. Right-click 4D Server.exe 
and choose “Run as administrator” to start 4D Server instead of double-clicking 
it. This will create an entry in Windows Services for 4D Server. Quit 4D 
Server. You are more likely for success doing it this way than to try and 
create the service from scratch.

Go to Windows Services and edit the 4D Server entry. Go to “Log on” tab and 
choose “This account”. You will have to specify an account to use. Use the 
“Browse” button to find it as you can’t just put in a typical name like 
“administrator”. It has a special format that the Browse button will give you. 
Do this or it won’t work. Put in the account password and save it. Make sure 
the account you use in the service has administrator rights, not just a “user” 
account. This is important!

Now start the service. You should see it start and stay running. Try connecting 
with 4D Client to prove it is working. 

Pat Bensky and John Baughman also ran into this issue with a recent 4D Server 
setup as a Window Service. You can make it work, but you have to do it a 
certain way. Any other way and it will act just like you are reporting. It 
starts and thens stops.

So the IT guys will hate this with a passion. That is because every time they 
change the password for the account you used, someone will have to go edit the 
service on this machine and update the password. Prepare for them to have a 
literal “fit” when you tell them this. 

That’s life. That’s the way it is now with 4D Server running as a Windows 
Service.

And if I’m completely wrong about any of this and you have found a way to NOT 
have to set things up like this, please post how you did it. I’d love to go 
back to using “Local System account”. Versions before 4D Server v16 and Windows 
Server 2012 didn’t have this issue. So be sure to specify what 4D version you 
are using and what Windows Server version you are using. 

Tim

*****************************************
Tim Nevels
Innovative Solutions
785-749-3444
[email protected]
*****************************************

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to