Plone-5-1-6-UI-old-stable does not work on Windows Server 2016?

Hi Everyone, i'm french and my english will not be quite good but ...

I'm trying to install Plone-5-1-6-UI-old-stable on a Virtual Machine running Windows Server 2016 Standard (1607/14393.3443) because this is the only way my company allows me to do it ...

Can you help me to understand why (and how to fix it) do i get this error ? Thanks a lot !

    Microsoft Windows [version 10.0.14393]
(c) 2016 Microsoft Corporation. Tous droits réservés.

C:\Users\Administrateur.DW28B3>cd C:\Users\Administrateur.DW28B3\Downloads\Plone-5-1-6-UI-old-stable\Plone-5.1.6-UnifiedInstaller

C:\Users\Administrateur.DW28B3\Downloads\Plone-5-1-6-UI-old-stable\Plone-5.1.6-UnifiedInstaller>windows_install.bat standalone --password=admin

C:\Users\Administrateur.DW28B3\Downloads\Plone-5-1-6-UI-old-stable\Plone-5.1.6-UnifiedInstaller>python helper_scripts\windows_install.py standalone --password=Rers.76021
Creating instance home and buildout command.
Running create_instance.py
Copying buildout skeleton
Building Zope/Plone; this takes a while...

C:\Users\Administrateur.DW28B3\Plone\zinstance>\Users\Administrateur.DW28B3\Plone\Python-2.7\Scripts\buildout.exe
Creating directory 'C:\\Users\\Administrateur.DW28B3\\Plone\\zinstance\\parts'.
Creating directory 'C:\\Users\\Administrateur.DW28B3\\Plone\\zinstance\\develop-eggs'.
Unused options for buildout: 'backups-dir'.
Installing instance.
Generated script 'C:\\Users\\Administrateur.DW28B3\\Plone\\zinstance\\bin\\instance'.
Generated interpreter 'C:\\Users\\Administrateur.DW28B3\\Plone\\zinstance\\parts\\instance\\bin\\interpreter'.
Installing repozo.
Generated script 'C:\\Users\\Administrateur.DW28B3\\Plone\\zinstance\\bin\\repozo'.
Installing zopepy.
Generated interpreter 'C:\\Users\\Administrateur.DW28B3\\Plone\\zinstance\\bin\\zopepy'.
Installing unifiedinstaller.
Generated script 'C:\\Users\\Administrateur.DW28B3\\Plone\\zinstance\\bin\\plonectl'.
Buildout succeeded.
Note: pep425tags runtime warnings may be ignored.

######################  Installation Complete  ######################

Plone successfully installed at \Users\Administrateur.DW28B3\Plone\zinstance
See \Users\Administrateur.DW28B3\Plone\zinstance\README.html
for startup instructions.

Use the account information below to log into the Zope Management Interface
The account has full 'Manager' privileges.

  Username: admin
  Password: admin

This account is created when the object database is initialized. If you change
the password later (which you should!), you'll need to use the new password.

Use this account only to create Plone sites and initial users. Do not use it
for routine login or maintenance.

C:\Users\Administrateur.DW28B3\Downloads\Plone-5-1-6-UI-old-stable\Plone-5.1.6-UnifiedInstaller>cd C:\Users\Administrateur.DW28B3\Plone\zinstance

C:\Users\Administrateur.DW28B3\Plone\zinstance>bin\plonectl start
instance: ERROR: Zope is not installed as Windows service.

C:\Users\Administrateur.DW28B3\Plone\zinstance>bin\instance install demand
Installed Zope as Windows Service "Zope1671617396".

C:\Users\Administrateur.DW28B3\Plone\zinstance>bin\plonectl start
instance: Traceback (most recent call last):
  File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\plone.recipe.zope2instance-4.4.1-py2.7.egg\plone\recipe\zope2instance\ctl.py", line 229, in do_start
    win32serviceutil.StartService(name)
  File "c:\users\administrateur.dw28b3\plone\python-2.7\lib\site-packages\win32\lib\win32serviceutil.py", line 417, in StartService
    win32service.StartService(hs, args)
error: (1053, 'StartService', 'Le service n\x92a pas r\xe9pondu assez vite \xe0 la demande de lancement ou de contr\xf4le.')

C:\Users\Administrateur.DW28B3\Plone\zinstance>bin\instance start
Traceback (most recent call last):
  File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\plone.recipe.zope2instance-4.4.1-py2.7.egg\plone\recipe\zope2instance\ctl.py", line 229, in do_start
    win32serviceutil.StartService(name)
  File "c:\users\administrateur.dw28b3\plone\python-2.7\lib\site-packages\win32\lib\win32serviceutil.py", line 417, in StartService
    win32service.StartService(hs, args)
error: (1053, 'StartService', 'Le service n\x92a pas r\xe9pondu assez vite \xe0 la demande de lancement ou de contr\xf4le.')

C:\Users\Administrateur.DW28B3\Plone\zinstance>

What happens if you try bin\instance fg or bin\instance console?

1 Like

:sunny: Thanks for replying so quickly SteveM,

I tried it :

C:\Users\Administrateur.DW28B3\Plone\zinstance>bin\instance console
Traceback (most recent call last):
  File "C:\Users\Administrateur.DW28B3\Plone\zinstance\bin\instance-script.py", line 269, in <module>
    + sys.argv[1:]))
  File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\plone.recipe.zope2instance-4.4.1-py2.7.egg\plone\recipe\zope2instance\ctl.py", line 647, in main
    c.onecmd(' '.join(options.args))
  File "C:\Python27\Lib\cmd.py", line 221, in onecmd
    return func(arg)
  File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\plone.recipe.zope2instance-4.4.1-py2.7.egg\plone\recipe\zope2instance\ctl.py", line 523, in do_console
    self.do_foreground(arg, debug=False)
  File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\plone.recipe.zope2instance-4.4.1-py2.7.egg\plone\recipe\zope2instance\ctl.py", line 581, in do_foreground
    self._exitstatus = subprocess.call(command, env=env)
  File "C:\Python27\Lib\subprocess.py", line 172, in call
    return Popen(*popenargs, **kwargs).wait()
  File "C:\Python27\Lib\subprocess.py", line 394, in __init__
    errread, errwrite)
  File "C:\Python27\Lib\subprocess.py", line 644, in _execute_child
    startupinfo)
WindowsError: [Error 2] Le fichier spÚcifiÚ est introuvable

... and it gives the same error with bin\instance fg

C:\Users\Administrateur.DW28B3\Plone\zinstance>bin\instance fg
Traceback (most recent call last):
  File "C:\Users\Administrateur.DW28B3\Plone\zinstance\bin\instance-script.py", line 269, in <module>
    + sys.argv[1:]))
  File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\plone.recipe.zope2instance-4.4.1-py2.7.egg\plone\recipe\zope2instance\ctl.py", line 647, in main
    c.onecmd(' '.join(options.args))
  File "C:\Python27\Lib\cmd.py", line 221, in onecmd
    return func(arg)
  File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\zdaemon-4.2.0-py2.7.egg\zdaemon\zdctl.py", line 554, in do_fg
    self.do_foreground(arg)
  File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\plone.recipe.zope2instance-4.4.1-py2.7.egg\plone\recipe\zope2instance\ctl.py", line 581, in do_foreground
    self._exitstatus = subprocess.call(command, env=env)
  File "C:\Python27\Lib\subprocess.py", line 172, in call
    return Popen(*popenargs, **kwargs).wait()
  File "C:\Python27\Lib\subprocess.py", line 394, in __init__
    errread, errwrite)
  File "C:\Python27\Lib\subprocess.py", line 644, in _execute_child
    startupinfo)
WindowsError: [Error 2] Le fichier spÚcifiÚ est introuvable

which file would be missing ?

Thanks a lot !
With best regards

Is the file in the traceback (C:\Users\Administrateur.DW28B3\Plone\zinstance\bin\instance-script.py) available to the user identity running the program? If it belongs to an adminstrator, you probably need to run your command-line console as administrator.

Hello SteveM, I had already taken care of performing each of the command lines (including the installation of Python 2.7 and Plone) as an administrator (with the console running in administrator mode)

but I have carefully looked at the security settings of the instance-script.py/.pyc files as you suggested, as well as those of subprocess.py/.pyc (which also seems to be involved ...) and this gives:

Knowing that I am well identified as administrator and that I execute all the commands as administrator (including for CMD) from the beginning, do you think there is something abnormal there?

Just in case ..., on line 336 of subprocess.py, I tried to change "Shell = False" to "Shell = True" and then bin \ instance console (like bin \ instance fg) gives:

C:\Users\Administrateur.DW28B3\Plone\zinstance\bin>instance console
'"C:\Python38-32"' n’est pas reconnu en tant que commande interne
ou externe, un programme exécutable ou un fichier de commandes.

("is not recognized as an internal or external command, operable program or batch file.")

Is it normal that the script then searches for C: \ Python38-32 when it is Python27 which is the installed version (both in C: and by the Plone-5-1-6-UI-old-stable installer) ?

C:\Users\Administrateur.DW28B3\Plone\zinstance\bin>python
Python 2.7.17 (v2.7.17:c2f86d86e6, Oct 19 2019, 21:01:17) [MSC v.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>

Given my last observation (Python 38 !? expected instead of 27), I hunted everything that could remain of a python 3 version on the virtual machine, restarted everything and ...

bin\instance console could serve Zope and Plone on localhost: 8080!

Wanting to test bin\instance fg too, I first had to delete all the .pid and .lock files in zinstance / var before doing so:

C:\Users\Administrateur.DW28B3\Plone\zinstance\bin>instance fg
2020-03-03 13:12:41 INFO ZServer HTTP server started at Tue Mar  3 13:12:41 2020
        Hostname: dw28b3
        Port: 8080
2020-03-03 13:12:56 WARNING ZODB.FileStorage Ignoring index for C:\Users\Administrateur.DW28B3\Plone\zinstance\var\filestorage\Data.fs
2020-03-03 13:13:05 WARNING z3c.autoinclude resolve('adodbapi') raised import error: No module named apibase
2020-03-03 13:13:09 WARNING z3c.autoinclude resolve('adodbapi') raised import error: No module named apibase
2020-03-03 13:13:15 WARNING z3c.autoinclude resolve('adodbapi') raised import error: No module named apibase
2020-03-03 13:13:22 INFO Zope Ready to handle requests

It serves then Zope and Plone on localhost: 8080!

... but the matter is that bin\instance start (as bin\plonectl start) still give the same error as described upper :

C:\Users\Administrateur.DW28B3\Plone\zinstance\bin>instance start
Traceback (most recent call last):
File "c:\users\administrateur.dw28b3\plone\buildout-cache\eggs\plone.recipe.zope2instance-4.4.1-py2.7.egg\plone\recipe\zope2instance\ctl.py", line 229, in do_start
win32serviceutil.StartService(name)
File "c:\users\administrateur.dw28b3\plone\python-2.7\lib\site-packages\win32\lib\win32serviceutil.py", line 417, in StartService
win32service.StartService(hs, args)
error: (1053, 'StartService', 'Le service n\x92a pas r\xe9pondu assez vite \xe0 la demande de lancement ou de contr\xf4le.')

@smcmahon , what do you advise me to do so that the installation is as stable as possible? Can I consider putting it into production with bin\instance console only? May the process stop in case of VM reboot ? It seems ... Then i will probably have to manually delete all the .pid and .lock files in zinstance/var each time ?

bin\instance console is fine. Don't use "fg" except for debugging; it slows things down too much.

instance console should not create a .pid file. Lock files should be cleaned up on exit. If they aren't, they should be overwritten -- unless they're being held open by another instance.

instance console should also be something for which you can set up a Windows service through the Windows service control application.

By the way, man of us in the Linux world use "console" for production since it allows for control by a service management utility like supervisor.

1 Like

Thank you very much for these details, which reassure me about the planned production start-up (the final rendering should resemble that currently hosted by a provider: http://rers.objectis.net ).

It remains for me to find the way to automate the startup of the instance each time the VM is restarted. As a MacUser (who had successfully installed Plone at home in less than 15 minutes on OSX), something tells me that I will still have fun with Windows ... :wink: Anyway, I'll try to find that on my side now.

Thanks again !

Plone Foundation Code of Conduct