Dpace 7 beta 1 on docker (windows 10)

60 views
Skip to first unread message

Massimiliano CILURZO

unread,
Apr 13, 2020, 3:41:27 AM4/13/20
to DSpace Technical Support
Dear All,
     I'm new with Docker, and have tried to install Dspace 7 beta 1 on Docker (Windows 10), I have followed the instructions here:
If I try to see if everything is up the system say:
$ docker ps -a
CONTAINER ID        IMAGE                                COMMAND                  CREATED             STATUS                        PORTS                                            NAMES
8985988339ee        dspace/dspace-angular:latest         "docker-entrypoint.s…"   About an hour ago   Exited (255) 14 minutes ago   0.0.0.0:3000->3000/tcp, 0.0.0.0:9876->9876/tcp   dspace-angular
c0a4a146fdf2        dspace/dspace:dspace-7_x-jdk8-test   "/dspace-docker-tool…"   About an hour ago   Exited (255) 14 minutes ago   8009/tcp, 0.0.0.0:8080->8080/tcp                 dspace
eca915721325        dspace/dspace-postgres-pgcrypto      "docker-entrypoint.s…"   About an hour ago   Exited (255) 14 minutes ago   5432/tcp                                         dspacedb
8c404dc2ec06        dspace/dspace-solr                   "docker-entrypoint.s…"   About an hour ago   Exited (255) 14 minutes ago   0.0.0.0:8983->8983/tcp                           dspacesolr

So I imagine that system is working. But if I try with the browser to go to http://localhost:8080 or 3000 the result is "Error connection refused".

Could you give me some advice on what's wrong?
Thanks
Best regards
Massimiliano

Tim Donohue

unread,
Apr 14, 2020, 12:46:43 PM4/14/20
to DSpace Technical Support, Massimiliano CILURZO
Hi Massimiliano,

That "Exited (255)" status on each of your docker instances means that the Docker instance crashed.  See: https://stackoverflow.com/questions/50691770/what-does-docker-container-exit-status-255-mean

So, those Docker instances appear to be hitting some sort of error, and there's suggestions (from that StackOverflow question) for how to possibly debug the errors here: https://medium.com/@pimterry/5-ways-to-debug-an-exploding-docker-container-4f729e2c0aa8

I'm also curious if you could share the version of Docker Desktop you are using (on Windows 10 it should be in the "About Docker Desktop" in your Docker taskbar icon).  You also may want to look at your Docker Desktop settings.  For example, I've found that running DSpace via Docker Desktop on Windows 10 uses a fair amount of memory.  So, in the Settings, of Docker Desktop, I have my Docker Desktop settings using 5GB of memory, 1GB of Swap, 120GB of storage and 4 CPUs.  If you have significantly less memory or storage, you might want to increase it (if possible).

Those are just a few initial ideas.  But, if you find a more specific error message from Docker (using the suggestions from StackOverflow) please feel free to share them here, as it might help us to better debug the problem (and improve our DSpace 7 on Docker instructions if necessary)

Tim


From: 'Massimiliano CILURZO' via DSpace Technical Support <dspac...@googlegroups.com>
Sent: Monday, April 13, 2020 2:41 AM
To: DSpace Technical Support <dspac...@googlegroups.com>
Subject: [dspace-tech] Dpace 7 beta 1 on docker (windows 10)
 
--
All messages to this mailing list should adhere to the DuraSpace Code of Conduct: https://duraspace.org/about/policies/code-of-conduct/
---
You received this message because you are subscribed to the Google Groups "DSpace Technical Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dspace-tech...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dspace-tech/bbfc8312-717e-491d-ac6c-23b9c2bfa3a6%40googlegroups.com.

Massimiliano CILURZO

unread,
Apr 14, 2020, 3:01:04 PM4/14/20
to DSpace Technical Support
Dear Tim, 
  Thanks for you answer.

My docker version is 2.2.0.5 (43884)
Engine 19.03.08
Notary  0.6.1
Compose 1.25.4
Kubernates v1.15.5.
My setting was:
CPUs: 2
Memory 2.00 GB
Swap: 1.00 GB

So I have increased the memory to 3.00 GB and restarted docker and dspace.
With this configuration tomcat started. And I can reach http://localhost:8080/server
But it seems that  the user interface on http://localhost:3000 it isn't reachble.
The browser response is ERR_EMPTY_RESPONSE and ths is the log:

[1m66% [0] building 1694/1769 modules 75 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/truncatable/truncatable.component.scss [39m [22m [2K
[1m66% [0] building 1695/1769 modules 74 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-
[1m68% [0] building 1808/1870 modules 62 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [0] building 1809/1870 modules 61 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [1] building 1504/1540 modules 36 active /app/node_modules/@ngtools/webpack/src/index.js!/app/src/app/+submit-page/submit-page-routing.module.ts [39m [22m [2K
[1m68% [1] building 1505/1540 modules 35 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [0] building 1809/1871 modules 62 active /app/node_modules/@ngtools/webpack/src/index.js!/app/src/app/shared/sidebar/filter/sidebar-filter.reducer.ts [39m [22m [2K
[1m68% [0] building 1810/1871 modules 61 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [0] building 1810/1872 modules 62 active /app/node_modules/@ngtools/webpack/src/index.js!/app/src/app/core/services/route.reducer.ts [39m [22m [2K
[1m68% [0] building 1811/1872 modules 61 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [1] building 1506/1540 modules 34 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [0] building 1811/1873 modules 62 active /app/node_modules/@ngtools/webpack/src/index.js!/app/src/app/core/services/route.effects.ts [39m [22m [2K
[1m68% [0] building 1812/1873 modules 61 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [1] building 1507/1540 modules 33 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [1] building 1508/1540 modules 32 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [1] building 1509/1540 modules 31 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [0] building 1813/1873 modules 60 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [0] building 1813/1874 modules 61 active /app/node_modules/@ngtools/webpack/src/index.js!/app/src/app/shared/mocks/dspace-rest-v2/endpoint-mocking-rest.service.ts [39m [22m [2K
[1m68% [0] building 1814/1874 modules 60 active /app/node_modules/raw-loader/index.js??ref--8-0!/app/node_modules/postcss-loader/src/index.js??ref--8-1!/app/node_modules/sass-loader/dist/cjs.js??ref--8-2!/app/node_modules/sass-resources-loader/lib/loader.js??ref--8-3!/app/src/app/shared/object-list/item-list-element/item-types/publication/publication-list-element.component.scss [39m [22m [2K
[1m68% [0] building 1814/1875 modules 61 active /app/node_modules/@ngtools/webpack/src/index.js!/app/src/app/shared/mocks/dspace-rest-v2/mocks/mock-response-map.ts [39m [22m [2K
[1m6
[2K [1G [1myarn run v1.22.0 [22m
[2K [1G [2m$ yarn run build && npm-run-all -p webpack:watch server:watch [22m
[2K [1G [2m$ yarn run clean:bld && yarn run clean:dist [22m
[2K [1G [2m$ rimraf build [22m
[2K [1G [2m$ rimraf dist [22m
[2K [1G [2m$ node ./scripts/webpack.js --progress --mode development [22m

 even for postgres on 5432 port there is a problem the answer is  connection refused this is the log:

2020-04-14 18:09:09.693 UTC [24] LOG: database system was not properly shut down; automatic recovery in progress

2020-04-14 18:09:09.894 UTC [24] LOG: redo starts at 0/2028210

2020-04-14 18:09:09.971 UTC [24] LOG: invalid record length at 0/20285B0: wanted 24, got 0

2020-04-14 18:09:09.971 UTC [24] LOG: redo done at 0/2028578

2020-04-14 18:09:09.971 UTC [24] LOG: last completed transaction was at log time 2020-04-14 18:05:09.920487+00

2020-04-14 18:09:11.769 UTC [1] LOG: database system is ready to accept connections


According to you why it seems that angular and postgres are working but I can't reach them?
For the installation instructions with docker, on windows 10 I have a suggestion. it could be trivial what I'm saying, so sorry in advance, but after the installation of docker it is necessary to switch the docker system to linux.
Thanks

Best regards
Massimiliano
To unsubscribe from this group and stop receiving emails from it, send an email to dspac...@googlegroups.com.
Message has been deleted
Message has been deleted

Massimiliano CILURZO

unread,
Apr 15, 2020, 2:01:59 PM4/15/20
to DSpace Technical Support
Hi Tim, 

        I have noticed that in the angular log there was an error on yarn: 
package.json not found
So I installed again it with yarn install and then yarn update, I have cleared the cache with yarn clear cache.
And then the new interface on port 3000 it is visible on the browser.
The interface is started is up but without elements if I do a search the system say loading..
If I try to login with dspacedemo+submit@gmail.com dspace the system say:
Http failure response for (unknown url): 0 Unknown Error
I have tried to connect to postgres on 5432 but say connection refused.
Even if from the log it seems up.
If I try to create the admin user or load entities the system goes in error. for example after 
docker-compose -p d7 -f docker/cli.yml run --rm dspace-cli create-administrator -e te...@test.edu -f admin -l user -p admin -c en 
.the error is: 
FileNotFoundError: [Errno 2] No such file or directory: '.\\docker/cli.yml'
cli.yml doesn't exist there are d7.cli.yml or d6.cli.yml.
Best regards
Massimiliano

Il giorno martedì 14 aprile 2020 18:46:43 UTC+2, Tim Donohue ha scritto:
- mostra testo citato -

Tim Donohue

unread,
Apr 15, 2020, 3:15:44 PM4/15/20
to DSpace Technical Support, Massimiliano CILURZO
Hi Massimiliano,

The errors you are receiving are not making much sense to me.  I've retried all the steps listed here on Windows 10: 
https://wiki.lyrasis.org/display/DSPACE/Try+out+DSpace+7#TryoutDSpace7-InstallviaDocker

These are all working for me using Windows 10, Docker Desktop v2.2.0.5, and Windows Powershell (I've also done some basic testing with Windows Command Prompt, and it seems like it works there too).

Please make sure you are running all "docker-compose" commands from the *root directory* of the "dspace-angular" project (e.g. C:\dspace-angular\, or wherever you placed the code on your local system).  These various commands will *not* work in other directories.   Additionally, you should not need to run 'yarn' at all when using Docker (as all the necessary yarn commands run automatically in Docker).

At a basic level, all you should need to run is:

# Pull down (download) the latest docker images
docker-compose -f docker/docker-compose.yml pull

Then:

# Starts up all Docker images
docker-compose -p d7 -f docker/docker-compose.yml -f docker/docker-compose-rest.yml up -d

At this point, you should see an empty DSpace 7 site.  Then you can proceed with adding content (per the instructions) and/or adding a new Admin account (again, per the instructions on the wiki page). 

You may want to step back & try this initial setup again to first ensure those two commands result in an empty DSpace 7 site (both the UI on port 3000 and the REST API on port 8080).  

In order to complete reset everything in Docker, you can run these commands to remove all existing images and content:

# First, stop any running containers
docker stop $(docker ps -a -q)

# Then remove all Docker containers, volumes & images
docker system prune --all

# At this point, your Docker install is totally empty and you can start from the initial "pull" command followed by the "up -d"

I'm hoping that restarting will show us if things are working as expected, and make it easier to debug things step by step.  Currently, it's really difficult for anyone to debug this issue, as we don't know exactly where things started to go wrong.  It's also possible that things initially failed from a simple lack of available memory, and restarting (with increased memory) will cause everything to now work.

Good luck, and let us know how it goes.

Tim


From: 'Massimiliano CILURZO' via DSpace Technical Support <dspac...@googlegroups.com>
Sent: Wednesday, April 15, 2020 1:01 PM

To: DSpace Technical Support <dspac...@googlegroups.com>
Subject: [dspace-tech] Re: Dpace 7 beta 1 on docker (windows 10)
 
--
All messages to this mailing list should adhere to the DuraSpace Code of Conduct: https://duraspace.org/about/policies/code-of-conduct/
---
You received this message because you are subscribed to the Google Groups "DSpace Technical Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dspace-tech...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dspace-tech/13c33a04-33a7-4850-a62b-92328c19afda%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages