Closed ghost closed 9 years ago
I think that privilege is supposed to be xdmp:filesystem-directory. Until we get around to fixing it, you can try changing line 738 of deploy/ml-config.xml to:
<privilege-name>xdmp:filesystem-directory</privilege-name>
Or run it as a user with the admin role.
I think that privilege is supposed to be xdmp:filesystem-directory. Until we get around to fixing it, you > can try changing line 738 of deploy/ml-config.xml to:
<privilege-name>xdmp:filesystem-directory</privilege-name>
it works .. but with some issue:
Hmmm, it looks like somehow you have stale versions of the toc files. As a workaround, try rebuilding the toc. I think if you run this XQuery in query console against the RunDMC database (with your RunDMC project /src as its root) this might fix it:
xquery version "1.0-ml";
import module namespace toc="http://marklogic.com/rundmc/api/toc" at "/apidoc/setup/toc.xqm" ;
toc:toc("8.0", "c:/Program Files/MarkLogic/Config")
If you are on linux, substitute "/opt/MarkLogic/Config" for the second param, on mac substitute "/home/username/Library/MarkLogic/Config" (where /home/username is your home directory).
We realize this installation process is not quite ready for prime time yet. Thanks for bearing with it.
Or alternately, just reloading the whole thing. You can do this against the maintenance appserver (I think it looks like port 8019 in your case). So something like this:
thanks for helping, but ..
$ sudo rpm -iv ~/Downloads/marklogic-8.0.3/MarkLogic-8.0-3.x86_64.rpm Preparing packages... MarkLogic-8.0-3.x86_64
$ sudo /etc/init.d/MarkLogic start Starting MarkLogic: [ OK ]
$ git clone https://github.com/marklogic/RunDMC.git Cloning into 'RunDMC'... remote: Counting objects: 19473, done. remote: Compressing objects: 100% (17/17), done. remote: Total 19473 (delta 7), reused 0 (delta 0), pack-reused 19455 Receiving objects: 100% (19473/19473), 59.08 MiB | 1.21 MiB/s, done. Resolving deltas: 100% (13599/13599), done. Checking connectivity... done.
$ cd RunDMC
$ deploy/build.properties user=admin password=admin app-name=RunDMC app-modules-db=filesystem modules-root=/home/%user%/repos/RunDMC/src api-port=8011 app-port=8012 xcc-port=8013 draft-port=8014 admin-port=8015 rapi-port=8016 try-port=8017 webdav-port=8018 maintenance-port=8019 default-user=admin appuser-password=Mam;N)$#JIaoP[F?fO0w app-type=mvc server-version=8 rest-options.dir=${basedir}/rest-api/config rest-ext.dir=${basedir}/rest-api/ext rest-transforms.dir=${basedir}/rest-api/transforms url-rewriter=/controller/url_rewrite.xqy error-handler=/controller/error-handler.xqy rewrite-resolves-globally= local-server=localhost mlcp-home=/home/%user%/bin/mlcp-1.3-3/bin/mlcp.sh mlcp-vmargs=-Xmx512m build-version=8.0 build-zip-path=/tmp/MarkLogic_8_pubs.zip build-clean=1 build-actions=
$ deploy/ml-config.xml [line:738]
<privilege-name>xdmp:filesystem-directory</privilege-name>
$ ls -l /tmp .. .. MarkLogic_8_pubs.zip ..
$ ./ml local bootstrap docs docs Bootstrapping your project into MarkLogic 8 on localhost...
*\ RESTART OF MARKLOGIC IS REQUIRED
... Bootstrap Complete
$ sudo /etc/init.d/MarkLogic restart Stopping MarkLogic Stopping MarkLogic: .. [ OK ] Starting MarkLogic: [ OK ]
$ ./ml local deploy_docs Trying digest auth response: #Net::HTTPInternalServerError:0x00000002a32698 response:
<head>
<title>500 Internal Server Error</title>
<meta name="robots" content="noindex,nofollow"/>
<link rel="stylesheet" href="/error.css"/>
</head>
<body>
<span class="error">
<h1>500 Internal Server Error</h1>
<dl>
<dt>SVC-FILSTAT: File status error: stat64 '/home/%user%/repos/RunDMC/src/apidoc/setup/build.xqy': Permission denied</dt>
<dd></dd>
<dt> [1.0-ml]</dt>
<dd></dd>
</dl>
</span>
</body>
</html>
$ /etc/sysconfig/MarkLogic export MARKLOGIC_USER=%user%
$ sudo /etc/init.d/MarkLogic restart Stopping MarkLogic Stopping MarkLogic: .. [ OK ] Starting MarkLogic: [ OK ]
$ ./ml local deploy_docs Trying admin@localhost:8019 Trying digest auth response: #Net::HTTPOK:0x0000000155e2a8 response: load-static-docs 8.0 PT0.139077S load-raw-docs 8.0 PT16.890207S setup-guides 8.0 PT1M7.720053S setup 8.0 PT42.965446S /setup/collection-tagger 8.0 PT1.84691S make-standalone-search-page 8.0 PT0.143359S build 8.0 PT2M9.845221S
xquery version "1.0-ml";
import module namespace toc="http://marklogic.com/rundmc/api/toc"
at "/apidoc/setup/toc.xqm" ;
toc:toc("8.0", "/opt/MarkLogic/Config/")
your query returned an empty sequence
APIDOC-ERROR (err:FOER0000): help-xsd-dir does not exist "/var/opt/MarkLogic/Config/8.0" in /apidoc/setup/setup.xqm, at 120:2, in stp:error("ERROR", ("help-xsd-dir does not exist", ""/var/opt/MarkLogic/Config/8.0"")) [1.0-ml] $code = "ERROR" $items = ("help-xsd-dir does not exist", ""/var/opt/MarkLogic/Config/8.0"") in /apidoc/setup/build.xqy, at 63:61 [1.0-ml]
load-static-docs 8.0 PT0.352925S load-raw-docs 8.0 PT16.080997S setup-guides 8.0 PT1M10.029953S setup 8.0 PT44.10702S /setup/collection-tagger 8.0 PT1.563434S make-standalone-search-page 8.0 PT0.139425S build 8.0 PT2M13.940472S
Are you logging in with your browser with a user with the admin role?
On Tue, Jun 16, 2015 at 5:54 PM, forest-counts notifications@github.com wrote:
thanks for helping, but ..
_$ sudo rpm -iv ~/Downloads/marklogic-8.0.3/MarkLogic-8.0-3.x8664.rpm Preparing packages... MarkLogic-8.0-3.x86_64
$ sudo /etc/init.d/MarkLogic start Starting MarkLogic: [ OK ]
$ git clone https://github.com/marklogic/RunDMC.git https://github.com/marklogic/RunDMC.git Cloning into 'RunDMC'... remote: Counting objects: 19473, done. remote: Compressing objects: 100% (17/17), done. remote: Total 19473 (delta 7), reused 0 (delta 0), pack-reused 19455 Receiving objects: 100% (19473/19473), 59.08 MiB | 1.21 MiB/s, done. Resolving deltas: 100% (13599/13599), done. Checking connectivity... done.
$ cd RunDMC
$ deploy/build.properties user=admin password=admin app-name=RunDMC app-modules-db=filesystem modules-root=/home/%user%/repos/RunDMC/src api-port=8011 app-port=8012 xcc-port=8013 draft-port=8014 admin-port=8015 rapi-port=8016 try-port=8017 webdav-port=8018 maintenance-port=8019 default-user=admin appuser-password=Mam;N)$#JIaoP[F?fO0w app-type=mvc server-version=8 rest-options.dir=${basedir}/rest-api/config rest-ext.dir=${basedir}/rest-api/ext rest-transforms.dir=${basedir}/rest-api/transforms url-rewriter=/controller/urlrewrite.xqy error-handler=/controller/error-handler.xqy rewrite-resolves-globally= local-server=localhost mlcp-home=/home/%user%/bin/mlcp-1.3-3/bin/mlcp.sh_ mlcp-vmargs=-Xmx512m build-version=8.0 build-zip-path=/tmp/MarkLogic_8_pubs.zip build-clean=1 build-actions=
$ deploy/ml-config.xml [line:738]
xdmp:filesystem-directory $ ls -l /tmp .. .. MarkLogic_8_pubs.zip ..
$ ./ml local bootstrap docs docs
Bootstrapping your project into MarkLogic 8 on localhost...
*\ RESTART OF MARKLOGIC IS REQUIRED
... Bootstrap Complete
$ sudo /etc/init.d/MarkLogic restart [sudo] password for ts: Stopping MarkLogic Stopping MarkLogic: .. [ OK ] Starting MarkLogic: [ OK ]
_$ ./ml local deploydocs Trying digest auth response: #Net::HTTPInternalServerError:0x00000002a32698 response:
500 Internal Server Error 500 Internal Server Error
- SVC-FILSTAT: File status error: stat64 '/home/%user%/repos/RunDMC/src/apidoc/setup/build.xqy': Permission denied
- [1.0-ml]
$ /etc/sysconfig/MarkLogic export MARKLOGIC_USER=%user%
$ sudo /etc/init.d/MarkLogic restart Stopping MarkLogic Stopping MarkLogic: .. [ OK ] Starting MarkLogic: [ OK ]
_$ ./ml local deploydocs Trying admin@localhost:8019 Trying digest auth response: #Net::HTTPOK:0x0000000155e2a8 response: load-static-docs 8.0 PT0.139077S load-raw-docs 8.0 PT16.890207S setup-guides 8.0 PT1M7.720053S setup 8.0 PT42.965446S /setup/collection-tagger 8.0 PT1.84691S make-standalone-search-page 8.0 PT0.143359S build 8.0 PT2M9.845221S
http://localhost:8011/ http://localhost:8011/ [image: apitoc] https://cloud.githubusercontent.com/assets/12884886/8194541/02d1eb06-1485-11e5-92b6-3de4f49c4826.png FIX 1
xquery version "1.0-ml"; import module namespace toc="http://marklogic.com/rundmc/api/toc"at "/apidoc/setup/toc.xqm" ;
toc:toc("8.0", "/opt/MarkLogic/Config/")
your query returned an empty sequence FIX 2
http://localhost:8019/apidoc/setup/build.xqy?version=8.0&zip= _/tmp/MarkLogic_8pubs.zip &help-xsd-dir=/var/opt/MarkLogic/Config/8.0&clean=true
APIDOC-ERROR (err:FOER0000): help-xsd-dir does not exist "/var/opt/MarkLogic/Config/8.0" in /apidoc/setup/setup.xqm, at 120:2, in stp:error("ERROR", ("help-xsd-dir does not exist", ""/var/opt/MarkLogic/Config/8.0"")) [1.0-ml] $code = "ERROR" $items = ("help-xsd-dir does not exist", ""/var/opt/MarkLogic/Config/8.0"") in /apidoc/setup/build.xqy, at 63:61 [1.0-ml]
toc:toc("8.0", "/opt/MarkLogic/Config") FIX 2.A
http://localhost:8019/apidoc/setup/build.xqy?version=8.0&zip=/tmp/MarkLogic_8_pubs.zip&help-xsd-dir= /opt/MarkLogic/Config/&clean=true
load-static-docs 8.0 PT0.352925S load-raw-docs 8.0 PT16.080997S setup-guides 8.0 PT1M10.029953S setup 8.0 PT44.10702S /setup/collection-tagger 8.0 PT1.563434S make-standalone-search-page 8.0 PT0.139425S build 8.0 PT2M13.940472S
[image: apitoc] https://cloud.githubusercontent.com/assets/12884886/8194541/02d1eb06-1485-11e5-92b6-3de4f49c4826.png
— Reply to this email directly or view it on GitHub https://github.com/marklogic/RunDMC/issues/492#issuecomment-112615696.
8011-RunDMC-apidoc http://localhost:8011/
browser doesn't ask me for auth at all
on http://localhost:**8019** port, yes with admin role
OK,if you look at the App Server configuration in the Admin Interface for the App Server on port 8011, what is the user has listed as the default user (under application-level authentication, which I assume is set for that app server)? More importantly, does that user have the admin role? If it does not, change it to one that does have the admin role and see if that solves your problem.
Another way to slice this is to do an xdmp:document-get-permissions on the document that is getting a 404. I am thinking that those documents might not have the needed permissions to be seen by a non-admin user.
under application-level authentication, which I assume is set for that app server
yes: authentication-method=application-level
More importantly, does that user have the admin role?
and yes: default-user=admin
I only сhange modules-root=/home/%user%/repos/RunDMC/src
and mlcp path, rest of all setting with default value. Clean instance of ML8 started under %user% account.
anyway, thanks for help.
Which modules-root did you change? I think you only want to change the one that is in deploy/build.properties. There are other modules-root entries in other files and those should remain set to /. Another possibility is that it cannot resolve the % characters properly. Sorry this is being such a pain for you!
And you might be able to fix this by changing your app server root path to the proper directory in the Admin Interface (for example, for the 8011 server and the 8019 server). Those should be set to a directory that MarkLogic can resolve (i.e., an absolute path) pointing to your RunDMC/src directory.
Which modules-root did you change?
deploy/build.properties
it cannot resolve the % characters properly
i know :) in app server root path
for 8011 and 8019 path is correct /home/my/repos/RunDMS/src
OK. maybe later , I'll try a different OS. f22 not officially supported for ML8
I am reopening this because I need to fix the privilege issue
The privilege error is now fixed on the
./ml local bootstrap docs
call. I still do not know why your installation failed @forest-counts. I doubt it is because of f22, but it is possible. At any rate, I am going to close this for now (as you already closed it). Feel free to file a new bug or reopen this one if you have any more info.
on CentOS 6.6 same issue. (with apiTOC)
and error message from ./ml
$ ./ml local bootstrap docs
docs
Bootstrapping your project into MarkLogic 7 on localhost...
ERROR: undefined method body=' for #<Net::HTTPOK 200 OK readbody=true> ERROR: ./deploy/lib/server_config.rb:398:in
original_bootstrap'./deploy/app_specific.rb:42:in bootstrap'deploy/lib/ml.rb:131:in
send'deploy/lib/ml.rb:131
For that issue, add the following to your deploy/local.properties file:
server-version=8
$ ./ml local bootstrap docs
docs
Bootstrapping your project into MarkLogic 8 on localhost...
ERROR: undefined method body=' for #<Net::HTTPOK 200 OK readbody=true> ERROR: ./deploy/lib/server_config.rb:398:in
original_bootstrap'./deploy/app_specific.rb:42:in bootstrap'deploy/lib/ml.rb:131:in
send'deploy/lib/ml.rb:131
load-static-docs 8.0 PT0.412328S load-raw-docs 8.0 PT18.822506S setup-guides 8.0 PT1M19.796405S setup 8.0 PT50.678975S /setup/collection-tagger 8.0 PT1.708502S make-standalone-search-page 8.0 PT0.170478S build 8.0 PT2M33.874255S
doesn't help.
You can also add the modules-root to your deploy/local.properties file (instead of updated the build.properties file):
modules-root=/my/path/to/RunDMC/src
What version of Ruby are you using? I think it like to have at least 1.9.3.
yeap, app servers (8011 and 8019) with digest auth and user with admin role
$ ruby --version ruby 1.8.7 (2013-06-27 patchlevel 374) [x86_64-linux]
That might be the problem. I had to upgrade mine. I am using:
ruby 2.2.1p85 (2015-02-26 revision 49769) [x86_64-linux]
I had to use rvm to upgrade mine, as yum only got me to 1.8.7.
Thank for help, I dont know why, but it doesn't work for me ..
What do you get now from ruby --version
? With a more recent ruby, are you still getting the same error message?
OS: Fedora-22 (4.0.4-303.fc22.x86_64 #1 SMP) MarkLogic(RHEL6): 8.0-3 (MARKLOGIC_USER=user)
ruby: 2.2.2p95 (2015-04-13 revision 50295) [x86_64-linux]
$ gem list * LOCAL GEMS * bigdecimal (1.2.6) io-console (0.4.3) json (1.8.2) net-http-digest_auth (1.4) psych (2.0.8) rdoc (4.2.0) roxy (0.2.1)
$ deploy/build.properties user=admin password=* app-name=RunDMC app-modules-db=filesystem modules-root=/home/user**/repos/RunDMC/src
api-port=8011 app-port=8012 xcc-port=8013 draft-port=8014 admin-port=8015 rapi-port=8016 try-port=8017 webdav-port=8018 maintenance-port=8019
authentication-method=application-level default-user=admin appuser-password=*** app-type=mvc server-version=8
rest-options.dir=${basedir}/rest-api/config rest-ext.dir=${basedir}/rest-api/ext rest-transforms.dir=${basedir}/rest-api/transforms
url-rewriter=/controller/url_rewrite.xqy error-handler=/controller/error-handler.xqy rewrite-resolves-globally= local-server=localhost
mlcp-home=/home/user/bin/mlcp-1.3-3/ mlcp-vmargs=-Xmx512m
build-version=8.0 build-zip-path=/home/user/Downloads/MarkLogic_8_pubs.zip build-clean=1 build-actions=
$ ./ml local bootstrap docs docs Bootstrapping your project into MarkLogic 8 on localhost... ERROR: Invalid privilege 'xdmp:filesystem-file-directory' specified for role: dmc-author (INVALID-PRIVILEGE): See MarkLogic Server error log for more details. ERROR: ... Bootstrap FAILED