[osgeo4w-dev] Offline installer from cache not working

BADAWI Marwan marwan.badawi at scalian.com
Thu Apr 23 04:01:38 PDT 2026


Hello,

First of all I apologize if this is not the right place to post this, but I couldn't find anywhere else. If it's not, could you direct me to where I can post this problem  with the installer?

I am trying to create an offline OSGeo4W install process to install QGIS 4 on sensitive no-internet computers. We are developing an internal plugin for QGIS and need the dev tools provided in the OSGeo4W installer.

First, I manually installed QGIS and GDAL using Express install. This generated an installed.db file which I use as a reference list for all packages. The install goes smoothly and everything works as expected.

Then I created a local cache folder using the package list from the installed.db file using the following command: osgeo4w-setup.exe --quiet-mode --arch x86_64 --autoaccept --no-desktop --download --local-package-dir C:\OSGEO_CACHE --site http://www.norbit.de/osgeo4w/v2 --packages $PkgList


I tried installing offline with two different command lines:
1: osgeo4w-setup.exe --quiet-mode --arch x86_64 --autoaccept --no-desktop --local-install C:\OSGEO_CACHE --packages $PkgList

Everything goes well until the post-install process where the 2 following scripts generate an error because they cannot find zlib.dll: "etc\postinstall\grass.bat", and  "etc\postinstall\qgis-common.bat ".

And when I try to run QGIS from the start menu (or even from the OSgeo4W shell), I get the following error:
"Could not load qgis_app.dll. Check MyPath\OsGeow4W\bin\qgis-bin.env for correct environment paths."

And the file looks OK, containing all the correct paths.

2: osgeo4w-setup.exe --quiet-mode --arch x86_64 --autoaccept --no-desktop --local-install C:\OSGEO_CACHE -C Libs -C Desktop -C Commandline_Utilities
No errors during install, but the end result is the same. Whenever I try running QGis, I get the same error "Could not load qgis_app.dll. Check MyPath\OsGeow4W\bin\qgis-bin.env for correct environment paths."

I also tried not using --quiet-mode, but I am also getting the same issue.

Why does a full online install work, but the offline one doesn't? Am I doing something wrong?

Thank you!

Marwan

PS : I tired attaching the log and the installed.db files, but the message was too big and was awaiting admin action for over 2 days, so I cancelled it.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/osgeo4w-dev/attachments/20260423/9a48de7a/attachment-0001.htm>


More information about the osgeo4w-dev mailing list