Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] winGRASS -subprocess ended with a non-zero return code #2255

Open
valterhydrodynamics opened this issue Mar 7, 2022 · 55 comments
Open
Labels
bug Something isn't working windows Microsoft Windows specific

Comments

@valterhydrodynamics
Copy link

valterhydrodynamics commented Mar 7, 2022

Describe the bug

  1. GRASS GIS ("Long term" and 8.0.1") does not start up. See: GRASS error #2253
  2. Also I'm unable to to run a simple grass algorithm in a QGIS session, from processing toolbox.
  3. Issue with the Windows binary?

To Reproduce
Steps to reproduce the behavior:

  1. Go to: 'I used the OSGeo4W network installer in: https://qgis.org/en/site/forusers/download.html#, "osgeo4w-setup.exe"'
  2. Click on 'win GRASS GIS'
  3. Compute (example of the error message:
    //
    Launching GUI in the background, please wait...
    Microsoft Windows [Version 10.0.19042.1526]
    (c) Microsoft Corporation. Todos os direitos reservados.
    C:\Users\Particular\Documents>Traceback (most recent call last):
    File "C:\OSGeo4W\apps\Python39\lib\site-packages\wx\core.py", line 3407, in
    lambda event: event.callable(*event.args, **event.kw) )
    File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\wxgui.py", line 88, in show_main_gui
    mainframe = GMFrame(parent=None, id=wx.ID_ANY, workspace=self.workspaceFile)
    File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\lmgr\frame.py", line 156, in init
    self._createConsole(self.notebook)
    File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\lmgr\frame.py", line 379, in _createConsole
    self.goutput = GConsoleWindow(
    File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\gui_core\goutput.py", line 127, in init
    self.cmdPrompt = GPromptSTC(
    File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\gui_core\prompt.py", line 155, in init
    GPrompt.init(self, parent=parent, giface=giface, menuModel=menuModel)
    File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\gui_core\prompt.py", line 57, in init
    self.mapList = self._getListOfMaps()
    File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\gui_core\prompt.py", line 114, in _getListOfMaps
    result["raster"] = grass.list_strings("raster")
    File "C:\OSGeo4W\apps\grass\grass80\etc\python\grass\script\core.py", line 1462, in list_strings
    for line in read_command(
    File "C:\OSGeo4W\apps\grass\grass80\etc\python\grass\script\core.py", line 606, in read_command
    return handle_errors(returncode, stdout, args, kwargs)
    File "C:\OSGeo4W\apps\grass\grass80\etc\python\grass\script\core.py", line 429, in handle_errors
    raise CalledModuleError(module=module, code=code, returncode=returncode)
    grass.exceptions.CalledModuleError: Module run g.list --q -m type=raster ended with an error.
    The subprocess ended with a non-zero return code: 3221225785. See errors above the traceback or in the error output.
    //
  4. See error
    grass.exceptions.CalledModuleError: Module run g.list --q -m type=raster ended with an error.
    The subprocess ended with a non-zero return code: 3221225785. See errors above the traceback or in the error output.

Expected behavior
Should open the GUI or let execute GRASS GIS processing algorithm in inside QGIS processing toolbox.

Screenshots
#2253

System description (please complete the following information):

  • Operating System: Windows, version 10.0.19042.1526
  • GRASS GIS version [e.g. 7.8.7 or 8.0.1]

Additional context
Add any other context about the problem here.

@valterhydrodynamics valterhydrodynamics added the bug Something isn't working label Mar 7, 2022
@hellik hellik changed the title [Bug] [Bug] winGRASS -subprocess ended with a non-zero return code Mar 7, 2022
@hellik hellik added the windows Microsoft Windows specific label Mar 7, 2022
@hellik
Copy link
Member

hellik commented Mar 7, 2022

see GRASS user ML

grass.exceptions.CalledModuleError: Module run None g.list --q -m type=raster ended with error Process ended with non-zero return code 3221225785. See errors in the (error) output.

have a look into there

@ninsbl
Copy link
Member

ninsbl commented Mar 7, 2022

@valterhydrodynamics , could you please try to install the gdal303-runtime package in OSGeo4W and report back?
Start the installer, choose advanced setup. The package is found in the "Libs" section. You can also filter gdal30...
The discussion @hellik referenced points to GDAL runtime as a likely culprit...

@hellik
Copy link
Member

hellik commented Mar 7, 2022

@valterhydrodynamics , could you please try to install the gdal303-runtime package in OSGeo4W and report back? Start the installer, choose advanced setup. The package is found in the "Libs" section. You can also filter gdal30... The discussion @hellik referenced points to GDAL runtime as a likely culprit...

see also here: #679

yes, it seems a dll/library clash of gdal and/or sqlite

@hellik
Copy link
Member

hellik commented Mar 7, 2022

@valterhydrodynamics , could you please try to install the gdal303-runtime package in OSGeo4W and report back? Start the installer, choose advanced setup. The package is found in the "Libs" section. You can also filter gdal30... The discussion @hellik referenced points to GDAL runtime as a likely culprit...

@valterhydrodynamics see also here https://githubmemory.com/repo/OSGeo/grass/issues/1579?page=2

could you open the OSGeo4W shell and type

echo %PATH%

and

gdalinfo --version

into the shell

here

C:\OSGeo4W>echo %PATH%
C:\OSGeo4W\apps\qt5\bin;
C:\OSGeo4W\apps\Python39\Scripts;
C:\OSGeo4W\bin;
C:\WINDOWS\system32;
C:\WINDOWS;
C:\WINDOWS\system32\WBem
C:\OSGeo4W>gdalinfo --version
GDAL 3.4.1, released 2021/12/27

@valterhydrodynamics
Copy link
Author

see GRASS user ML

grass.exceptions.CalledModuleError: Module run None g.list --q -m type=raster ended with error Process ended with non-zero return code 3221225785. See errors in the (error) output.

have a look into there

This "déjà vu"! Le me see

@valterhydrodynamics
Copy link
Author

see GRASS user ML

grass.exceptions.CalledModuleError: Module run None g.list --q -m type=raster ended with error Process ended with non-zero return code 3221225785. See errors in the (error) output.

have a look into there
Well, this didn't work this time:
//
O problema está resolvido, graças à dica do Pedro Venâncio que chamou a atenção para a DLL "libcurl.dll":
Caso esteja em:
C:\Windows\System32\libcurl.dll
devo renomear ou eliminar, para o programa ler 1.º em :
C:\OSGeo4W64\bin\libcurl.dll
//

@valterhydrodynamics
Copy link
Author

My results:
1)
C:\OSGeo4W>echo %PATH%

C:\OSGeo4W\apps\qt5\bin;
C:\OSGeo4W\apps\Python39\Scripts;
C:\OSGeo4W\bin;
C:\WINDOWS\system32;
C:\WINDOWS;C:\WINDOWS\system32\WBem

I don't have "C:\WINDOWS;"

C:\OSGeo4W>gdalinfo --version
GDAL 3.4.1, released 2021/12/27

@valterhydrodynamics
Copy link
Author

@valterhydrodynamics , could you please try to install the gdal303-runtime package in OSGeo4W and report back? Start the installer, choose advanced setup. The package is found in the "Libs" section. You can also filter gdal30... The discussion @hellik referenced points to GDAL runtime as a likely culprit...

see also here: #679

yes, it seems a dll/library clash of gdal and/or sqlite

I did this setup "gdal303-runtime", still the same issue

@valterhydrodynamics
Copy link
Author

Did a "Express Install" with the "OSGeo4W net release setup program", after deleted previous installation, and give the following messages, despite having "gdal304-runtime" installed. Having the same issues with grass and with grass algorithm inside qgis. What else...

1

2

@hellik
Copy link
Member

hellik commented Mar 8, 2022

Have you tried grass itself outside of qgis?

@valterhydrodynamics
Copy link
Author

Did a "Express Install" with the "OSGeo4W net release setup program", after deleted previous installation, and give the following messages, despite having "gdal304-runtime" installed. Having the same issues with grass and with grass algorithm inside qgis. What else...

1

2

Also:
Using this two tools (https://stackoverflow.com/questions/53682315/error-on-libcurl-dll-when-using-gdal-of-osgeo4w-in-django):
Dependencies
Process Explorer 64

  • Checked "gdal304.dll"

1

@valterhydrodynamics
Copy link
Author

Tried again the recent GRASS GIS 8.0.0-3 [https://grass.osgeo.org/], having the same issue:

//
Starting GRASS GIS...
WARNING: Concurrent mapset locking is not supported on Windows
Cleaning up temporary files...

      __________  ___   __________    _______________
     / ____/ __ \/   | / ___/ ___/   / ____/  _/ ___/
    / / __/ /_/ / /| | \__ \\_  \   / / __ / / \__ \
   / /_/ / _, _/ ___ |___/ /__/ /  / /_/ // / ___/ /
   \____/_/ |_/_/  |_/____/____/   \____/___//____/

Welcome to GRASS GIS 8.0.0
GRASS GIS homepage: https://grass.osgeo.org
This version running through: Command Prompt (C:\WINDOWS\system32\cmd.exe)
Help is available with the command: g.manual -i
See the licence terms with: g.version -c
See citation options with: g.version -x
If required, restart the GUI with: g.gui wxpython
When ready to quit enter: exit

Launching GUI in the background, please wait...
Microsoft Windows [Version 10.0.19042.1526]
(c) Microsoft Corporation. Todos os direitos reservados.

C:\Users\Particular>Traceback (most recent call last):
File "C:\Program Files\GRASS GIS 8.0\Python39\lib\site-packages\wx\core.py", line 3407, in
lambda event: event.callable(*event.args, **event.kw) )
File "C:\Program Files\GRASS GIS 8.0\gui\wxpython\wxgui.py", line 88, in show_main_gui
mainframe = GMFrame(parent=None, id=wx.ID_ANY, workspace=self.workspaceFile)
File "C:\Program Files\GRASS GIS 8.0\gui\wxpython\lmgr\frame.py", line 156, in init
self._createConsole(self.notebook)
File "C:\Program Files\GRASS GIS 8.0\gui\wxpython\lmgr\frame.py", line 379, in _createConsole
self.goutput = GConsoleWindow(
File "C:\Program Files\GRASS GIS 8.0\gui\wxpython\gui_core\goutput.py", line 127, in init
self.cmdPrompt = GPromptSTC(
File "C:\Program Files\GRASS GIS 8.0\gui\wxpython\gui_core\prompt.py", line 155, in init
GPrompt.init(self, parent=parent, giface=giface, menuModel=menuModel)
File "C:\Program Files\GRASS GIS 8.0\gui\wxpython\gui_core\prompt.py", line 57, in init
self.mapList = self._getListOfMaps()
File "C:\Program Files\GRASS GIS 8.0\gui\wxpython\gui_core\prompt.py", line 114, in _getListOfMaps
result["raster"] = grass.list_strings("raster")
File "C:\Program Files\GRASS GIS 8.0\etc\python\grass\script\core.py", line 1462, in list_strings
for line in read_command(
File "C:\Program Files\GRASS GIS 8.0\etc\python\grass\script\core.py", line 606, in read_command
return handle_errors(returncode, stdout, args, kwargs)
File "C:\Program Files\GRASS GIS 8.0\etc\python\grass\script\core.py", line 429, in handle_errors
raise CalledModuleError(module=module, code=code, returncode=returncode)
grass.exceptions.CalledModuleError: Module run g.list --q -m type=raster ended with an error.
The subprocess ended with a non-zero return code: 3221225785. See errors above the traceback or in the error output.
//

@valterhydrodynamics
Copy link
Author

Could be the problem here?
image

@hellik
Copy link
Member

hellik commented Mar 8, 2022

Could be the problem here? image

There is some dependencies dll hell going on, as something is in %PATH% interfering with OSGeo4W

Some possible dll:

sqlite
gdal
curl
Many others....

IIRC in the grass wiki link, I've posted, there is some example how to use dependency Walker as a tool.

Try to start winGRASS in the OSGeo4W shell by typing:

grass80

In text mode, see if you can enter a grass Session and use dependency walker

@valterhydrodynamics
Copy link
Author

Could be the problem here? image

There is some dependencies dll hell going on, as something is in %PATH% interfering with OSGeo4W

Some possible dll:

sqlite gdal curl Many others....

IIRC in the grass wiki link, I've posted, there is some example how to use dependency Walker as a tool.

Try to start winGRASS in the OSGeo4W shell by typing:

grass80

In text mode, see if you can enter a grass Session and use dependency walker

Not sure where is the link you mention, to be able to follow your example

@hellik
Copy link
Member

hellik commented Mar 8, 2022

Could be the problem here? image

There is some dependencies dll hell going on, as something is in %PATH% interfering with OSGeo4W
Some possible dll:
sqlite gdal curl Many others....
IIRC in the grass wiki link, I've posted, there is some example how to use dependency Walker as a tool.
Try to start winGRASS in the OSGeo4W shell by typing:
grass80
In text mode, see if you can enter a grass Session and use dependency walker

Not sure where is the link you mention, to be able to follow your example

https://grasswiki.osgeo.org/wiki/WinGRASS_errors#searching_for_dependency_library_issues_with_dependency_walker

@hellik
Copy link
Member

hellik commented Mar 8, 2022

https://grasswiki.osgeo.org/wiki/WinGRASS_errors#searching_for_dependency_library_issues_with_dependency_walker

download dependency walker, here e.g.

D:\dl\depends22_x64

  • unzip the zip file
  • according the wiki entry, add following to the start script, in OSGeo4W

C:\OSGeo4W\bin\grass80.bat

rem do a dependency walk
rem add these lines
for %%d in (%GISBASE%\lib\*) do depends /c /f:1 /ot:%APPDATA%\GRASS8\depwalk_lib.log %%d
for %%e in (%GISBASE%\bin\*) do depends /c /f:1 /ot:%APPDATA%\GRASS8\depwalk_bin.log %%e

then start the OSGeo4W shell and change into the directory where you unzipped dependency walker, here

C:\OSGeo4W>cd D:\dl\depends22_x64
C:\OSGeo4W>d:

and then start grass8 within the OSGeo4W shell, here

D:\dl\depends22_x64>grass80

and follow the steps in the wiki

    start OSGeo4W winGRASS session and wait some minutes while dependenxy walker is working
    go to the windows folder %APPDATA%\GRASS7\, e.g. C:\Users\YourUsername\AppData\Roaming\GRASS8
    check the 2 log files with a text editor for the library name causing issues, e.g. for gdal300.dll

@hellik
Copy link
Member

hellik commented Mar 8, 2022

Did a "Express Install" with the "OSGeo4W net release setup program", after deleted previous installation, and give the following messages, despite having "gdal304-runtime" installed. Having the same issues with grass and with grass algorithm inside qgis. What else...

1

2

is the mentioned dll installed?

@valterhydrodynamics
Copy link
Author

Did a "Express Install" with the "OSGeo4W net release setup program", after deleted previous installation, and give the following messages, despite having "gdal304-runtime" installed. Having the same issues with grass and with grass algorithm inside qgis. What else...
1
2

is the mentioned dll installed?

Yes:
image

@valterhydrodynamics
Copy link
Author

Helmut,
Not sure what's going on here:
image

@valterhydrodynamics
Copy link
Author

Helmut, Not sure what's going on here: image

This is what was added:
image

@hellik
Copy link
Member

hellik commented Mar 9, 2022

Helmut, Not sure what's going on here: image

You are in the drive K:, but not in the folder depends22_×64.

Steps:

  • K:\
  • K:\ cd depends22_x64

then you are in the folder where dependency walker exe sits, then type grass80 to start from there.

@valterhydrodynamics
Copy link
Author

Helmut, Not sure what's going on here: image

You are in the drive K:, but not in the folder depends22_×64.

Steps:

* K:\

* K:\ cd depends22_x64

then you are in the folder where dependency walker exe sits, then type grass80 to start from there.

UPS, my fault

@valterhydrodynamics
Copy link
Author

Well, this a lot a information

image

@valterhydrodynamics
Copy link
Author

What should be done?

image

@hellik
Copy link
Member

hellik commented Mar 10, 2022

What should be done?

image

searching for gdal, sqlite, curl in the text files and look if there is some error indication.

@hellik
Copy link
Member

hellik commented Mar 10, 2022

do you have any other CAD or GIS installed on your box?

@valterhydrodynamics
Copy link
Author

What should be done?
image

searching for gdal, sqlite, curl in the text files and look if there is some error indication.

Well

The last page lines of both files say that there are some dependency issues (following figure)
image

The lighter ascii file "depwalk_bin.log" [59.4 KB], doesn't contain the "gdal, sqlite, curl". The last lines, 711 - 712, have:
//
depwalk_bin.log

Error: At least one required implicit or forwarded dependency was not found.
Warning: At least one delay-load dependency module was not found.
//

Concerning the heavier file [1.28 MB]:
depwalk_lib.log
I get many "Error opening file ..." from line 9483 to 10066.
Line n.º 10094: c:\osgeo4w\bin\LIBCURL.DLL not loaded;
Line n.º 10086: c:\osgeo4w\bin\GDAL304.DLL not loaded;
Line n.º 101104: c:\osgeo4w\bin\SQLITE3.DLL not loaded;
(and many others...)
In the last lines, 105354 - 103357, there is:
//
Error: At least one required implicit or forwarded dependency was not found.
Error: At least one module has an unresolved import due to a missing export function in an implicitly dependent module.
Warning: At least one delay-load dependency module was not found.
Warning: At least one module has an unresolved import due to a missing export function in a delay-load dependent module.
//

I'm a little confused, any guidance is well appreciated

@valterhydrodynamics
Copy link
Author

Oh yes: CAD: FreeCAD; NanoCAD, Autocad Civil 3D; Microstation GIS: QGIS; GRASS GIS; SAGA GIS; ArcGIS Data base PostgreSQL 4x, PostGIS; Fluid Mechanics: OpenFOAM & ParaView]; HY-8; HEC-RAS; HEC-HMS; HEC-DSSVue; HEC-MetVue; MACRA Studio; SisCCoH; EPA/SWMM; EPANET; Autodesk Storm and Sanitary Analysis Others: GNU Octave; OBS Studio; LibreOffice

I guess some of them causing the dll clash. are there other software in this list which doesn't work cause of the same issue.

may I suggest a radical ;-) way of testing?

temporary program folder renaming of the software in this list e.g. freecad, nanocad, saga gis, arcgis etc; then start OSGeo4W winGRASS and see if it is starting.

Yes, HEC-HMS [https://www.hec.usace.army.mil/software/hec-hms/] also doesn't work properly . The development team said that should be some related with gdal ...

@valterhydrodynamics
Copy link
Author

Oh yes: CAD: FreeCAD; NanoCAD, Autocad Civil 3D; Microstation GIS: QGIS; GRASS GIS; SAGA GIS; ArcGIS Data base PostgreSQL 4x, PostGIS; Fluid Mechanics: OpenFOAM & ParaView]; HY-8; HEC-RAS; HEC-HMS; HEC-DSSVue; HEC-MetVue; MACRA Studio; SisCCoH; EPA/SWMM; EPANET; Autodesk Storm and Sanitary Analysis Others: GNU Octave; OBS Studio; LibreOffice

I guess some of them causing the dll clash. are there other software in this list which doesn't work cause of the same issue.

may I suggest a radical ;-) way of testing?

temporary program folder renaming of the software in this list e.g. freecad, nanocad, saga gis, arcgis etc; then start OSGeo4W winGRASS and see if it is starting.

Did to GNU Octave; GIMP; OBS-studio; OPENFOAM; FREECAD_019; HEC-HMS; PG_Admin; Autodesk.
The winGrass error was the same...

@hellik
Copy link
Member

hellik commented Mar 10, 2022

open the OSGeo4W shell and type

C:\OSGeo4W>where sqlite3.dll
C:\OSGeo4W>where GDAL304.DLL
C:\OSGeo4W>where SQLITE3.DLL

all should live in

C:\OSGeo4W\bin\

and if there are more in %PATH%, more should be listed

@valterhydrodynamics
Copy link
Author

They are there
image

@valterhydrodynamics
Copy link
Author

valterhydrodynamics commented Mar 13, 2022

Reinstalled WINDOWS OS and now, runs well!

@hellik
Copy link
Member

hellik commented Mar 13, 2022

Reinstalled WINDOWS OS and now, runs well!

Radical method ;-) though, fine it does work now.

I guess something was sitting in c:\windows crashing gdal and co . Unfortunately it's very hard to solve dll hell issues in Windows.

@valterhydrodynamics
Copy link
Author

Just installed pgAdmin4, to work with PostgreSQL Postgis, with the setup packaged by EDB (1), and my winGRASS GIS 80 just don't run.
Also my HEC-HMS 4.9 don't execute simple operations.
This 2 programs were working before the pgAdmin4... Gives the message:
//
Starting GRASS GIS...
WARNING: Concurrent mapset locking is not supported on Windows
Cleaning up temporary files...

      __________  ___   __________    _______________
     / ____/ __ \/   | / ___/ ___/   / ____/  _/ ___/
    / / __/ /_/ / /| | \__ \\_  \   / / __ / / \__ \
   / /_/ / _, _/ ___ |___/ /__/ /  / /_/ // / ___/ /
   \____/_/ |_/_/  |_/____/____/   \____/___//____/

Welcome to GRASS GIS 8.0.1
GRASS GIS homepage: https://grass.osgeo.org
This version running through: Command Prompt (C:\WINDOWS\system32\cmd.exe)
Help is available with the command: g.manual -i
See the licence terms with: g.version -c
See citation options with: g.version -x
If required, restart the GUI with: g.gui wxpython
When ready to quit enter: exit

Launching GUI in the background, please wait...
Microsoft Windows [Version 10.0.19042.1586]
(c) Microsoft Corporation. Todos os direitos reservados.

C:\Users\Valter\Documents>Traceback (most recent call last):
File "C:\OSGeo4W\apps\Python39\lib\site-packages\wx\core.py", line 3407, in
lambda event: event.callable(*event.args, **event.kw) )
File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\wxgui.py", line 88, in show_main_gui
mainframe = GMFrame(parent=None, id=wx.ID_ANY, workspace=self.workspaceFile)
File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\lmgr\frame.py", line 156, in init
self._createConsole(self.notebook)
File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\lmgr\frame.py", line 379, in _createConsole
self.goutput = GConsoleWindow(
File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\gui_core\goutput.py", line 127, in init
self.cmdPrompt = GPromptSTC(
File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\gui_core\prompt.py", line 155, in init
GPrompt.init(self, parent=parent, giface=giface, menuModel=menuModel)
File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\gui_core\prompt.py", line 57, in init
self.mapList = self._getListOfMaps()
File "C:\OSGeo4W\apps\grass\grass80\gui\wxpython\gui_core\prompt.py", line 114, in _getListOfMaps
result["raster"] = grass.list_strings("raster")
File "C:\OSGeo4W\apps\grass\grass80\etc\python\grass\script\core.py", line 1462, in list_strings
for line in read_command(
File "C:\OSGeo4W\apps\grass\grass80\etc\python\grass\script\core.py", line 606, in read_command
return handle_errors(returncode, stdout, args, kwargs)
File "C:\OSGeo4W\apps\grass\grass80\etc\python\grass\script\core.py", line 429, in handle_errors
raise CalledModuleError(module=module, code=code, returncode=returncode)
grass.exceptions.CalledModuleError: Module run g.list --q -m type=raster ended with an error.
The subprocess ended with a non-zero return code: 3221225785. See errors above the traceback or in the error output.
//
This is the same error in my latest issue, that I solved unistalling everything.
When installing the wizard creates the possibility to register, for example, raster services that are disable by default, in Windows OS. I confirmed the options to be unacessary to setup / register later.
Any clue how the prevent this?

(1) https://www.enterprisedb.com/downloads/postgres-postgresql-downloads

@valterhydrodynamics
Copy link
Author

valterhydrodynamics commented Mar 22, 2022

Can someone confirm if the path for "GDAL_DATA" and "PROJ_LIB" should pin point some other thing?
See the image bellow:
image
I just uninstalled postgreSQL, but WinGRASS GIS still don't open...

@valterhydrodynamics
Copy link
Author

Can someone confirm if the path for "GDAL_DATA" and "PROJ_LIB" should pin point some other thing? See the image bellow: image I just uninstalled postgreSQL, but WinGRASS GIS still don't open...

Could this be a mismatch in my default configuration?

@valterhydrodynamics
Copy link
Author

More notes:
Found this site: http://www.bostongis.com/PrinterFriendly.aspx?content_name=postgis_tut01
The problem could be here, see the image bellow: i had an environment variable set, but then I overwrite it:

image

Do I need to repoint the environment variables, and how should be done?

@hellik
Copy link
Member

hellik commented Mar 23, 2022

More notes: Found this site: http://www.bostongis.com/PrinterFriendly.aspx?content_name=postgis_tut01 The problem could be here, see the image bellow: i had an environment variable set, but then I overwrite it:

image

Do I need to repoint the environment variables, and how should be done?

that could be the culprit.

C:\OSGeo4W>echo %PROJ_LIB%
C:\OSGeo4W\share\proj

what does this command in your box?

  1. without postgis installed
  2. with postgis installed

@hellik
Copy link
Member

hellik commented Mar 23, 2022

Just installed pgAdmin4, to work with PostgreSQL Postgis, with the setup packaged by EDB (1), and my winGRASS GIS 80 just don't run.
Also my HEC-HMS 4.9 don't execute simple operations.

so it seems to be again a dll hell issue, as HEC-HMS doesn't work too.

@hellik
Copy link
Member

hellik commented Mar 23, 2022

Can someone confirm if the path for "GDAL_DATA" and "PROJ_LIB" should pin point some other thing? See the image bellow: image I just uninstalled postgreSQL, but WinGRASS GIS still don't open...

Could this be a mismatch in my default configuration?

C:\OSGeo4W>echo %GDAL_DATA%
C:\OSGeo4W\share\gdal

@valterhydrodynamics
Copy link
Author

valterhydrodynamics commented Mar 23, 2022

More notes: Found this site: http://www.bostongis.com/PrinterFriendly.aspx?content_name=postgis_tut01 The problem could be here, see the image bellow: i had an environment variable set, but then I overwrite it:
image
Do I need to repoint the environment variables, and how should be done?

that could be the culprit.

C:\OSGeo4W>echo %PROJ_LIB%
C:\OSGeo4W\share\proj

what does this command in your box?

  1. without postgis installed
  2. with postgis installed

Here are the results, strange .... ones ...
1. without postgis installed
//
C:\OSGeo4W>echo %PROJ_LIB%
C:\OSGeo4W\share\proj

C:\OSGeo4W>share\proj
'share\proj' is not recognized as an internal or external command, operable program or batch file.

C:\OSGeo4W>
//
2. with postgis installed
//
C:\OSGeo4W>echo %PROJ_LIB%
C:\OSGeo4W\share\proj

C:\OSGeo4W>\share\proj
O sistema não conseguiu localizar o caminho especificado.

C:\OSGeo4W>
//

@valterhydrodynamics
Copy link
Author

Just installed pgAdmin4, to work with PostgreSQL Postgis, with the setup packaged by EDB (1), and my winGRASS GIS 80 just don't run.
Also my HEC-HMS 4.9 don't execute simple operations.

so it seems to be again a dll hell issue, as HEC-HMS doesn't work too.

Yes, again...

@valterhydrodynamics
Copy link
Author

Don't know if I deleted some question, sorry about that!

@hellik
Copy link
Member

hellik commented Mar 23, 2022

More notes: Found this site: http://www.bostongis.com/PrinterFriendly.aspx?content_name=postgis_tut01 The problem could be here, see the image bellow: i had an environment variable set, but then I overwrite it:
image
Do I need to repoint the environment variables, and how should be done?

that could be the culprit.

C:\OSGeo4W>echo %PROJ_LIB%
C:\OSGeo4W\share\proj

what does this command in your box?

  1. without postgis installed
  2. with postgis installed

Here are the results, strange .... ones ... 1. without postgis installed // C:\OSGeo4W>echo %PROJ_LIB% C:\OSGeo4W\share\proj

C:\OSGeo4W>share\proj 'share\proj' is not recognized as an internal or external command, operable program or batch file.

C:\OSGeo4W> // 2. with postgis installed // C:\OSGeo4W>echo %PROJ_LIB% C:\OSGeo4W\share\proj

C:\OSGeo4W>\share\proj O sistema não conseguiu localizar o caminho especificado.

C:\OSGeo4W> //

It seems postgis PROJ is interfering with OSGeo4W PROJ.

Maybe it's worth to bring this also to the postgis community.

@hellik
Copy link
Member

hellik commented Mar 23, 2022

no clue here at the moment to solve this issue.

@valterhydrodynamics
Copy link
Author

valterhydrodynamics commented Mar 23, 2022

Thanks, I will seek that "forum"

@valterhydrodynamics
Copy link
Author

More notes: Found this site: http://www.bostongis.com/PrinterFriendly.aspx?content_name=postgis_tut01 The problem could be here, see the image bellow: i had an environment variable set, but then I overwrite it:
image
Do I need to repoint the environment variables, and how should be done?

that could be the culprit.

C:\OSGeo4W>echo %PROJ_LIB%
C:\OSGeo4W\share\proj

what does this command in your box?

  1. without postgis installed
  2. with postgis installed

Here are the results, strange .... ones ... 1. without postgis installed // C:\OSGeo4W>echo %PROJ_LIB% C:\OSGeo4W\share\proj
C:\OSGeo4W>share\proj 'share\proj' is not recognized as an internal or external command, operable program or batch file.
C:\OSGeo4W> // 2. with postgis installed // C:\OSGeo4W>echo %PROJ_LIB% C:\OSGeo4W\share\proj
C:\OSGeo4W>\share\proj O sistema não conseguiu localizar o caminho especificado.
C:\OSGeo4W> //

It seems postgis PROJ is interfering with OSGeo4W PROJ.

Maybe it's worth to bring this also to the postgis community.

I post the issue here: https://app.element.io/#/room/#postgis:osgeo.org

I will give feedback, i hope!

@robe2
Copy link

robe2 commented Mar 24, 2022

I had @valterhydrodynamics try changing his env and all look to be pointing at the osgeo4w install of proj and gdal paths so that doesn't seem to be the issue.

@valterhydrodynamics
Copy link
Author

Yesterday had a great help from Regina Obe [https://app.element.io/#/room/#postgis:osgeo.org]
The issue remains...
Will work with a virtual box to manage the situation
Thanks for all, for your time

@valterhydrodynamics
Copy link
Author

valterhydrodynamics commented Mar 26, 2022

  1. I formatted and installed win10-64 (yes, again...);
  2. Created a virtual machine;
  3. Installed QGIS+GRASS(7.8.7, by default...)+GDAL with the Express Install of OSGeo4W net release setup program - in the final, gave the following message:
    //
    crssync.exe - Entry point not found
    Could not find procedure entry point opj_encoder_set_extra_options in DLL (dynamic-link library): C:\OSGeo4W\bin\304.dll

image

//
4) Clicked "OK" and finished the installation;
5) QGIS and GRASS are working :-)

@valterhydrodynamics
Copy link
Author

  1. I formatted and installed win10-64 (yes, again...);
  2. Created a virtual machine;
  3. Installed QGIS+GRASS(7.8.7, by default...)+GDAL with the Express Install of OSGeo4W net release setup program - in the final, gave the follwoing message:
    //
    Could not find procedure entry point opj_encoder_set_extra_options in DLL (dynamic-link library): C:\OSGeo4W\bin\304.dll
    //
  4. Clicked "OK" and finish the instalation;
  5. QGIS and GRASS are working :-)
    Sem Título
  1. Have to try PostGIS; then should post more results

@jorgemcunha
Copy link

Hi valter, i', facing the same issue. Can you please confirm that your solution was to setup a VM ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working windows Microsoft Windows specific
Projects
None yet
Development

No branches or pull requests

5 participants