Re: [MarkLogic Dev General] mlcp copy database issue

2015-04-24 Thread Basavaraj Kalloli
Hi,

We have resolved this by using the below command: this uses the new
advanced XDBC server and setting the max split size to 2 because the server
used to restart in-between because of large batch copy.

*mlcp.sh copy -mode local -input_host source -input_port 8000
-input_database input_database \*
*-input_username username -input_password password \*
*-output_host localhost -output_port 8000 -output_username admin \*
*-output_password admin -output_database sample -thread_count 2
-max_split_size 2*

On Thu, Apr 23, 2015 at 4:57 PM, David Ennis 
wrote:

> HI.
>
> From Query Console, I would look at a sample of the documents and check
> the permissions:
> https://docs.marklogic.com/xdmp:document-get-permissions
>
> Then from there work backwards and make sure that your user's role has
> read access to those documents.
>
>
>
>
>
> Kind Regards,
> David Ennis
>
>
> David Ennis
> *Content Engineer*
>
> [image: HintTech]  
> Mastering the value of content
> creative | technology | content
>
> Delftechpark 37i
> 2628 XJ Delft
> The Netherlands
> T: +31 88 268 25 00
> M: +31 63 091 72 80
>
> [image: http://www.hinttech.com] 
>   
> 
>
> On 23 April 2015 at 08:35, jaydip rananavare 
> wrote:
>
>> Hello All,
>>
>> We are using mlcp copy command to copy content between two databases but
>> we are facing an issue.
>>
>> *Problem:*
>> When we run the command it is able to connect to source database but it
>> does not read any content hence nothing gets copied.
>>
>> *What we are doing:*
>> Here is our command:
>> ./mlcp.sh copy \
>>   -input_host "source-host" \
>>   -input_port "8000" \
>>   -input_username "read-only-user" \
>>   -input_password "" \
>>   -input_database "source-db" \
>>   -directory_filter "/some-directory/" \
>>   -output_host "target-host" \
>>   -output_port "8000" \
>>   -output_username "admin" \
>>   -output_password "" \
>>   -output_database "target-db"
>>
>> *What we think is causing problem:*
>> We think that the user that we are using to connect to source machine
>> does not have correct privileges. We followed this document [
>> https://docs.marklogic.com/guide/ingestion/content-pump#id_47736] and
>> granted [hadoop-user-read] role but still it did not work (mlcp can connect
>> to source database but cannot read content). The same command works and
>> copies content if we use admin user to connect to source database.
>>
>> It is not clear what minimal roles/privileges we need to setup so that
>> given command will work. Could you please help us?
>>
>> -Regards,
>>
>> *Jaydip Rananavare*
>>
>>
>> ___
>> General mailing list
>> General@developer.marklogic.com
>> Manage your subscription at:
>> http://developer.marklogic.com/mailman/listinfo/general
>>
>>
>
> ___
> General mailing list
> General@developer.marklogic.com
> Manage your subscription at:
> http://developer.marklogic.com/mailman/listinfo/general
>
>
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] mlcp copy database issue

2015-04-23 Thread David Ennis
HI.

>From Query Console, I would look at a sample of the documents and check the
permissions:
https://docs.marklogic.com/xdmp:document-get-permissions

Then from there work backwards and make sure that your user's role has read
access to those documents.





Kind Regards,
David Ennis


David Ennis
*Content Engineer*

[image: HintTech]  
Mastering the value of content
creative | technology | content

Delftechpark 37i
2628 XJ Delft
The Netherlands
T: +31 88 268 25 00
M: +31 63 091 72 80

[image: http://www.hinttech.com] 
  


On 23 April 2015 at 08:35, jaydip rananavare 
wrote:

> Hello All,
>
> We are using mlcp copy command to copy content between two databases but
> we are facing an issue.
>
> *Problem:*
> When we run the command it is able to connect to source database but it
> does not read any content hence nothing gets copied.
>
> *What we are doing:*
> Here is our command:
> ./mlcp.sh copy \
>   -input_host "source-host" \
>   -input_port "8000" \
>   -input_username "read-only-user" \
>   -input_password "" \
>   -input_database "source-db" \
>   -directory_filter "/some-directory/" \
>   -output_host "target-host" \
>   -output_port "8000" \
>   -output_username "admin" \
>   -output_password "" \
>   -output_database "target-db"
>
> *What we think is causing problem:*
> We think that the user that we are using to connect to source machine does
> not have correct privileges. We followed this document [
> https://docs.marklogic.com/guide/ingestion/content-pump#id_47736] and
> granted [hadoop-user-read] role but still it did not work (mlcp can connect
> to source database but cannot read content). The same command works and
> copies content if we use admin user to connect to source database.
>
> It is not clear what minimal roles/privileges we need to setup so that
> given command will work. Could you please help us?
>
> -Regards,
>
> *Jaydip Rananavare*
>
>
> ___
> General mailing list
> General@developer.marklogic.com
> Manage your subscription at:
> http://developer.marklogic.com/mailman/listinfo/general
>
>
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


Re: [MarkLogic Dev General] mlcp copy database issue

2015-04-23 Thread Dave Cassel
Jaydip, you can use Query Console to look into document permissions with the 
xdmp:document-get-permissions()<http://docs.marklogic.com/xdmp:document-get-permissions>
 function. What you'll get back are sets of capability/role-id pairings. You 
can look up the role names with 
sec:get-role-names()<http://docs.marklogic.com/sec:get-role-names> (note that 
this function needs to be run against the Security database, while the first is 
to be run against your content database.

Presumably you'll find at least one role that has read permission and you can 
add that role to read-only-user.

After you've done the copy, you should check that you got the number of 
documents you expected. If you didn't, there may be other documents that 
require a different role to be seen.

--
Dave Cassel<http://davidcassel.net>, @dmcassel<https://twitter.com/dmcassel>
Developer Community Manager
MarkLogic Corporation<http://www.marklogic.com/>
Data Innovation Summit<http://fedscoop.com/events/datainnovationsummit/2015/> 
May 7th in DC


From: jaydip rananavare 
mailto:jaydiprananav...@gmail.com>>
Reply-To: MarkLogic Developer Discussion 
mailto:general@developer.marklogic.com>>
Date: Thursday, April 23, 2015 at 2:35 AM
To: "General@developer.marklogic.com<mailto:General@developer.marklogic.com>" 
mailto:General@developer.marklogic.com>>
Subject: [MarkLogic Dev General] mlcp copy database issue

Hello All,

We are using mlcp copy command to copy content between two databases but we are 
facing an issue.

Problem:
When we run the command it is able to connect to source database but it does 
not read any content hence nothing gets copied.

What we are doing:
Here is our command:
./mlcp.sh copy \
  -input_host "source-host" \
  -input_port "8000" \
  -input_username "read-only-user" \
  -input_password "" \
  -input_database "source-db" \
  -directory_filter "/some-directory/" \
  -output_host "target-host" \
  -output_port "8000" \
  -output_username "admin" \
  -output_password "" \
  -output_database "target-db"

What we think is causing problem:
We think that the user that we are using to connect to source machine does not 
have correct privileges. We followed this document 
[https://docs.marklogic.com/guide/ingestion/content-pump#id_47736] and granted 
[hadoop-user-read] role but still it did not work (mlcp can connect to source 
database but cannot read content). The same command works and copies content if 
we use admin user to connect to source database.

It is not clear what minimal roles/privileges we need to setup so that given 
command will work. Could you please help us?


-Regards,

Jaydip Rananavare
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general


[MarkLogic Dev General] mlcp copy database issue

2015-04-22 Thread jaydip rananavare
Hello All,

We are using mlcp copy command to copy content between two databases but we
are facing an issue.

*Problem:*
When we run the command it is able to connect to source database but it
does not read any content hence nothing gets copied.

*What we are doing:*
Here is our command:
./mlcp.sh copy \
  -input_host "source-host" \
  -input_port "8000" \
  -input_username "read-only-user" \
  -input_password "" \
  -input_database "source-db" \
  -directory_filter "/some-directory/" \
  -output_host "target-host" \
  -output_port "8000" \
  -output_username "admin" \
  -output_password "" \
  -output_database "target-db"

*What we think is causing problem:*
We think that the user that we are using to connect to source machine does
not have correct privileges. We followed this document [
https://docs.marklogic.com/guide/ingestion/content-pump#id_47736] and
granted [hadoop-user-read] role but still it did not work (mlcp can connect
to source database but cannot read content). The same command works and
copies content if we use admin user to connect to source database.

It is not clear what minimal roles/privileges we need to setup so that
given command will work. Could you please help us?

-Regards,

*Jaydip Rananavare*
___
General mailing list
General@developer.marklogic.com
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general