Re: [dspace-tech] Re: Correct permissions prior to using Maven and Ant while installing Dspace 6.3

2022-08-24 Thread Night Librarian
Thank you, Mark!

Worked like a charm!

-- 
All messages to this mailing list should adhere to the Code of Conduct: 
https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
--- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dspace-tech/ca378ab8-7b42-46d5-8915-bd9c951f0e86n%40googlegroups.com.


Re: [dspace-tech] Re: Correct permissions prior to using Maven and Ant while installing Dspace 6.3

2022-08-23 Thread Mark H. Wood
On Mon, Aug 22, 2022 at 08:18:43PM -0700, Night Librarian wrote:
> I have a tiny question. I want to run the installation as a tomcat user, 
> instead of dspace, as described in this conversation. Howerver, when I try 
> to run on Ubuntu 20.4:
> 
> sudo su - tomcat
> 
> I get:
> 
> "This account is currently not available."
> 
> 
> Do I need to be a superuser to run mvn and ant?  And if not, can I switch 
> to just "tomcat" user like this?
> 
> su tomcat
> 
> Because when I try, I am prompted for password, which I don't have, 
> probably because I didn't create a "tomcat" account manually, so I end up 
> with:
> 
> su: Authentication failure
> 
> How can I run install as a tomcat user?

"This account is currently not available." -- you'll probably find
that the user 'tomcat' has '/sbin/nologin' for its shell.  That's
where this message comes from.  You can override that by specifying
the shell to use:

  sudo su - tomcat -s /bin/sh

You'll probably find that the encrypted password for 'tomcat' is "!"
which means "don't accept *any* password".  So you need 'sudo' or
being superuser to 'su' to 'tomcat'.  The account effectively has a
password that can never be known or guessed, because nothing will ever
encrypt to "!".

-- 
Mark H. Wood
Lead Technology Analyst

University Library
Indiana University - Purdue University Indianapolis
755 W. Michigan Street
Indianapolis, IN 46202
317-274-0749
www.ulib.iupui.edu

-- 
All messages to this mailing list should adhere to the Code of Conduct: 
https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
--- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dspace-tech/YwTISLgJz0HOeW0r%40IUPUI.Edu.


signature.asc
Description: PGP signature


[dspace-tech] Re: Correct permissions prior to using Maven and Ant while installing Dspace 6.3

2022-08-22 Thread Night Librarian
Greetings!

I have a tiny question. I want to run the installation as a tomcat user, 
instead of dspace, as described in this conversation. Howerver, when I try 
to run on Ubuntu 20.4:

sudo su - tomcat

I get:

"This account is currently not available."


Do I need to be a superuser to run mvn and ant?  And if not, can I switch 
to just "tomcat" user like this?

su tomcat

Because when I try, I am prompted for password, which I don't have, 
probably because I didn't create a "tomcat" account manually, so I end up 
with:

su: Authentication failure

How can I run install as a tomcat user?

On Thursday, May 5, 2022 at 12:41:58 a.m. UTC-3 darryl@usask.ca wrote:

> Ashim, those permissions look pretty restrictive.  Does the build and 
> install actually work for you?
>
> I know the install docs mention the "dspace" user, but it also states 
> "you must ensure the Tomcat owner also owns [dspace], OR you can create a 
> new 'dspace' user account, and ensure that Tomcat also runs as that 
> account".  We went with the former (because that was easier and more 
> standard than changing the account Tomcat runs as), and made sure the "
> tomcat" user and group owned all the files.
>
> This is mostly from memory, but for the [dspace] directory I did 
> something like:
>
>  sudo mkdir [dspace]
>  sudo chown tomcat:tomcat [dspace]
>  sudo chmod 2775 [dspace]
>
> And for the [dspace-source] directory I did something like:
>
>  # Set the permissions
>  sudo chown -R tomcat:tomcat [dspace-source]
>  sudo chmod -R ug+rw [dspace-source]
>  # Build DSpace
>  sudo su - tomcat
>  cd [dspace-source]
>  $ Install
>  mvn package
>  cd dspace/target/dspace-installer
>  ant fresh_install
>
> I won't say that that's the only way, or even the correct way, but that 
> worked for us.
>
> - Darryl
>
> On Wednesday, May 4, 2022 at 4:02:46 PM UTC-6 fru9...@gmail.com wrote:
>
>> Hello, 
>>
>> Does setting these permissions allow you tu run ant ?
>>
>> Kind regards,
>>
>> On Wednesday, April 28, 2021 at 3:51:32 PM UTC+1 ashim@nipfp.org.in 
>> wrote:
>>
>>> Dear Dspace Experts, 
>>>
>>> I wish to know the correct permissions for the directories [dspace] 
>>> and [dspace-source] prior to running Maven and Ant. 
>>>
>>> I am using the definitions of [dspace] and [dspace-source] as on this 
>>> page: 
>>>
>>> https://wiki.lyrasis.org/display/DSDOC6x/Installing+DSpace 
>>>
>>> Here is what I have been doing till now: 
>>>
>>> For Running Maven (as user dspace): 
>>> I first make sure that the dspace user owns the [dspace-source] 
>>> directory. 
>>>
>>> sudo chmod 700 -R [dspace-source] 
>>> ( Basically rwx for [dspace-source]) 
>>> mvn package 
>>>
>>> For Running Ant as user dspace: 
>>>
>>> sudo chmod 500 -R [dspace-source] 
>>> ( Basically READ and EXECUTE permission for [dspace-source]) 
>>> sudo chmod 200 -R [dspace] 
>>> ( Amounts to WRITE permission for [dspace]) 
>>> sudo chmod u+x -R [dspace] 
>>> This is so that the installed files can be executed 
>>> sudo chmod g+s -R [dspace] 
>>> This is so that the newly created files in [dspace] should inherit the 
>>> group ( which is the same as the dspace user). so that permissions are 
>>> inherited. 
>>> sudo chmod 700 -R [dspace-source] 
>>>
>>> Then I do, as user dspace:- 
>>> cd [dspace-source]/dspace/target/dspace-installer 
>>> ant fresh_install 
>>>
>>> Can someone here comment on my attempt ? Please share the best practice. 
>>>
>>> Thank you, 
>>> Ashim 
>>>
>>

-- 
All messages to this mailing list should adhere to the Code of Conduct: 
https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
--- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dspace-tech/8485b515-7e89-4d5f-96c1-246ddf7c05a7n%40googlegroups.com.


Re: [dspace-tech] Re: Correct permissions prior to using Maven and Ant while installing Dspace 6.3

2022-05-04 Thread Ashim Kapoor
Dear Fru and Darryl,

If my memory serves me correctly, I do think these settings worked for me.

I could be mistaken though.

I will do an experiment and again use the settings which I was curious
about and let you know. You will have to give me some time though for
me to do this experiment.

Best,
Ashim


On Thu, 5 May 2022 at 09:12, darryl@usask.ca
 wrote:
>
> Ashim, those permissions look pretty restrictive.  Does the build and install 
> actually work for you?
>
> I know the install docs mention the "dspace" user, but it also states "you 
> must ensure the Tomcat owner also owns [dspace], OR you can create a new 
> 'dspace' user account, and ensure that Tomcat also runs as that account".  We 
> went with the former (because that was easier and more standard than changing 
> the account Tomcat runs as), and made sure the "tomcat" user and group owned 
> all the files.
>
> This is mostly from memory, but for the [dspace] directory I did something 
> like:
>
>  sudo mkdir [dspace]
>  sudo chown tomcat:tomcat [dspace]
>  sudo chmod 2775 [dspace]
>
> And for the [dspace-source] directory I did something like:
>
>  # Set the permissions
>  sudo chown -R tomcat:tomcat [dspace-source]
>  sudo chmod -R ug+rw [dspace-source]
>  # Build DSpace
>  sudo su - tomcat
>  cd [dspace-source]
>  $ Install
>  mvn package
>  cd dspace/target/dspace-installer
>  ant fresh_install
>
> I won't say that that's the only way, or even the correct way, but that 
> worked for us.
>
> - Darryl
>
> On Wednesday, May 4, 2022 at 4:02:46 PM UTC-6 fru9...@gmail.com wrote:
>>
>> Hello,
>>
>> Does setting these permissions allow you tu run ant ?
>>
>> Kind regards,
>>
>> On Wednesday, April 28, 2021 at 3:51:32 PM UTC+1 ashim@nipfp.org.in 
>> wrote:
>>>
>>> Dear Dspace Experts,
>>>
>>> I wish to know the correct permissions for the directories [dspace]
>>> and [dspace-source] prior to running Maven and Ant.
>>>
>>> I am using the definitions of [dspace] and [dspace-source] as on this page:
>>>
>>> https://wiki.lyrasis.org/display/DSDOC6x/Installing+DSpace
>>>
>>> Here is what I have been doing till now:
>>>
>>> For Running Maven (as user dspace):
>>> I first make sure that the dspace user owns the [dspace-source] directory.
>>>
>>> sudo chmod 700 -R [dspace-source]
>>> ( Basically rwx for [dspace-source])
>>> mvn package
>>>
>>> For Running Ant as user dspace:
>>>
>>> sudo chmod 500 -R [dspace-source]
>>> ( Basically READ and EXECUTE permission for [dspace-source])
>>> sudo chmod 200 -R [dspace]
>>> ( Amounts to WRITE permission for [dspace])
>>> sudo chmod u+x -R [dspace]
>>> This is so that the installed files can be executed
>>> sudo chmod g+s -R [dspace]
>>> This is so that the newly created files in [dspace] should inherit the
>>> group ( which is the same as the dspace user). so that permissions are
>>> inherited.
>>> sudo chmod 700 -R [dspace-source]
>>>
>>> Then I do, as user dspace:-
>>> cd [dspace-source]/dspace/target/dspace-installer
>>> ant fresh_install
>>>
>>> Can someone here comment on my attempt ? Please share the best practice.
>>>
>>> Thank you,
>>> Ashim
>
> --
> All messages to this mailing list should adhere to the Code of Conduct: 
> https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
> ---
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/dspace-tech/93d3d862-38ff-4951-b66e-2d3e0d14c39dn%40googlegroups.com.

-- 
All messages to this mailing list should adhere to the Code of Conduct: 
https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
--- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dspace-tech/CAGEJAoFj78%2BT4-ZeNTvd457xM3DWtZs0%3DGiy1brnC4Bh6-0otw%40mail.gmail.com.


[dspace-tech] Re: Correct permissions prior to using Maven and Ant while installing Dspace 6.3

2022-05-04 Thread darryl....@usask.ca
Ashim, those permissions look pretty restrictive.  Does the build and 
install actually work for you?

I know the install docs mention the "dspace" user, but it also states "you 
must ensure the Tomcat owner also owns [dspace], OR you can create a new '
dspace' user account, and ensure that Tomcat also runs as that account".  
We went with the former (because that was easier and more standard than 
changing the account Tomcat runs as), and made sure the "tomcat" user and 
group owned all the files.

This is mostly from memory, but for the [dspace] directory I did something 
like:

 sudo mkdir [dspace]
 sudo chown tomcat:tomcat [dspace]
 sudo chmod 2775 [dspace]

And for the [dspace-source] directory I did something like:

 # Set the permissions
 sudo chown -R tomcat:tomcat [dspace-source]
 sudo chmod -R ug+rw [dspace-source]
 # Build DSpace
 sudo su - tomcat
 cd [dspace-source]
 $ Install
 mvn package
 cd dspace/target/dspace-installer
 ant fresh_install

I won't say that that's the only way, or even the correct way, but that 
worked for us.

- Darryl

On Wednesday, May 4, 2022 at 4:02:46 PM UTC-6 fru9...@gmail.com wrote:

> Hello, 
>
> Does setting these permissions allow you tu run ant ?
>
> Kind regards,
>
> On Wednesday, April 28, 2021 at 3:51:32 PM UTC+1 ashim@nipfp.org.in 
> wrote:
>
>> Dear Dspace Experts, 
>>
>> I wish to know the correct permissions for the directories [dspace] 
>> and [dspace-source] prior to running Maven and Ant. 
>>
>> I am using the definitions of [dspace] and [dspace-source] as on this 
>> page: 
>>
>> https://wiki.lyrasis.org/display/DSDOC6x/Installing+DSpace 
>>
>> Here is what I have been doing till now: 
>>
>> For Running Maven (as user dspace): 
>> I first make sure that the dspace user owns the [dspace-source] 
>> directory. 
>>
>> sudo chmod 700 -R [dspace-source] 
>> ( Basically rwx for [dspace-source]) 
>> mvn package 
>>
>> For Running Ant as user dspace: 
>>
>> sudo chmod 500 -R [dspace-source] 
>> ( Basically READ and EXECUTE permission for [dspace-source]) 
>> sudo chmod 200 -R [dspace] 
>> ( Amounts to WRITE permission for [dspace]) 
>> sudo chmod u+x -R [dspace] 
>> This is so that the installed files can be executed 
>> sudo chmod g+s -R [dspace] 
>> This is so that the newly created files in [dspace] should inherit the 
>> group ( which is the same as the dspace user). so that permissions are 
>> inherited. 
>> sudo chmod 700 -R [dspace-source] 
>>
>> Then I do, as user dspace:- 
>> cd [dspace-source]/dspace/target/dspace-installer 
>> ant fresh_install 
>>
>> Can someone here comment on my attempt ? Please share the best practice. 
>>
>> Thank you, 
>> Ashim 
>>
>

-- 
All messages to this mailing list should adhere to the Code of Conduct: 
https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
--- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dspace-tech/93d3d862-38ff-4951-b66e-2d3e0d14c39dn%40googlegroups.com.


[dspace-tech] Re: Correct permissions prior to using Maven and Ant while installing Dspace 6.3

2022-05-04 Thread Fru Emmanuel
Hello, 

Does setting these permissions allow you tu run ant ?

Kind regards,

On Wednesday, April 28, 2021 at 3:51:32 PM UTC+1 ashim@nipfp.org.in 
wrote:

> Dear Dspace Experts,
>
> I wish to know the correct permissions for the directories [dspace]
> and [dspace-source] prior to running Maven and Ant.
>
> I am using the definitions of [dspace] and [dspace-source] as on this page:
>
> https://wiki.lyrasis.org/display/DSDOC6x/Installing+DSpace
>
> Here is what I have been doing till now:
>
> For Running Maven (as user dspace):
> I first make sure that the dspace user owns the [dspace-source] directory.
>
> sudo chmod 700 -R [dspace-source]
> ( Basically rwx for [dspace-source])
> mvn package
>
> For Running Ant as user dspace:
>
> sudo chmod 500 -R [dspace-source]
> ( Basically READ and EXECUTE permission for [dspace-source])
> sudo chmod 200 -R [dspace]
> ( Amounts to WRITE permission for [dspace])
> sudo chmod u+x -R [dspace]
> This is so that the installed files can be executed
> sudo chmod g+s -R [dspace]
> This is so that the newly created files in [dspace] should inherit the
> group ( which is the same as the dspace user). so that permissions are
> inherited.
> sudo chmod 700 -R [dspace-source]
>
> Then I do, as user dspace:-
> cd [dspace-source]/dspace/target/dspace-installer
> ant fresh_install
>
> Can someone here comment on my attempt ? Please share the best practice.
>
> Thank you,
> Ashim
>

-- 
All messages to this mailing list should adhere to the Code of Conduct: 
https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
--- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dspace-tech/5e473a69-be58-4c14-ad98-6316281cc969n%40googlegroups.com.