Re: [Dspace-tech] problem executing create-administrator
Quoting Keith Gilbertson : > For what it's worth, I've had somewhat similar problems executing the > scripts in the bin directory after transferring them from a > Windows-based machine to a Unix-like system. > > You might check that the line endings in the file haven't been changed > to DOS-style endings, and if they have, convert them back with a command > such as dos2unix. Not sure this is the same issue but maybe worth > checking into. > In the case of files crossing the ms-windows/unix platforms, as well as having line ending conventions appropriate to the platform, for unix-like systems, you should check that the execute permissions are set for the script. What I've found when unpacking package.zip files on unix is the unexpected loss of the execute permissions. To show the execute permissions, use stat FILENAME stat /bin/sh stat ./create-administrator Look for x in the 'access' field. To add execute permissions, use man chmod chmod u+x FILENAME > > felipe Melero wrote: > > Yes, I'm running it from dspace/bin directory but no way to get it > > working... > > > > surely is a matter of unix, I'm a chrooted user... > > >8-- snipped Cheerio. -- Van Ly : U. of Sydney Library This message was sent using IMP, the Internet Messaging Program. -- Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB ___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
Re: [Dspace-tech] problem executing create-administrator
Hi Felipe, When I first encountered the create-administrator script, I had problems. You might want to double-check all the earlier steps have been done well before using the command. Otherwise, # to make sure the script is in the current working directory ls # call the script ./create-administrator # otherwise cd [to where dspace is]/bin ./create-administrator As for sed and java, if your PATH environment variable is set appropriately and all necessary packages have been installed, try these on your command line # to show your PATH printenv |fgrep PATH # the absolute path to these commands should show type sed type java or you could try # perhaps as root updatedb # as dspace user locate sed locate java to show the shell you have, try printenv |fgrep SHELL I use redhat as well. -- Van Ly From: felipe Melero Sent: Wed 7/01/2009 11:22 PM To: dspace tech Subject: [Dspace-tech] problem executing create-administrator Hi all, I have a problem executing the script create-adminstrator, I get the following error: "bad interpreter". -bash-3.00$ ./create-administrator : bad interpreter: No such file or directory if I change the line inside the script #!/bin/sh to #!/bin/bash I get other errors: -bash-3.00$ ./create-administrator ./dsrun: line 61: sed: command not found ./dsrun: line 70: java: command not found Does anybody know how to make it work? I have Red Hat Linux if helps. Thanks in advance, Felipe -- Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
Re: [Dspace-tech] problem executing create-administrator
On Wed, Jan 7, 2009 at 4:46 PM, Keith Gilbertson wrote: > For what it's worth, I've had somewhat similar problems executing the > scripts in the bin directory after transferring them from a > Windows-based machine to a Unix-like system. > > You might check that the line endings in the file haven't been changed > to DOS-style endings, and if they have, convert them back with a command > such as dos2unix. Not sure this is the same issue but maybe worth > checking into. IMHO there is no reason/excuse for software to employ shellscripts when the software is supposed to be multi-platform. Why not write the scripts in a portable scripting language? Python and Perl spring to mind. Both are available for Windoze. Projects that needs scripts could use python, say, and the install could come with an ActivePython distribution which you can run/install if you need it. > >>> I have a problem executing the script > >>> create-adminstrator, I > >>> get the following error: "bad interpreter". > >>> > >>> -bash-3.00$ ./create-administrator > >>> : bad interpreter: No such file or directory > > -- Regards, Andrew M. http://www.andrewpetermarlow.co.uk -- Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
Re: [Dspace-tech] problem executing create-administrator
Does the system find it in your path if you type which java or which sed? --Dale --- Dale Poulter Automation Coordinator Library Information Technology Services Vanderbilt University Suite 700 110 21st Avenue South Nashville, TN 37240 (615)343-5388 (615)343-8834 (fax) (615)207-9705 (cell) dale.poul...@vanderbilt.edu From: felipe Melero [mailto:fmel...@unav.es] Sent: Wednesday, January 07, 2009 10:21 AM To: dspace tech Subject: Re: [Dspace-tech] problem executing create-administrator Yes, I'm running it from dspace/bin directory but no way to get it working... surely is a matter of unix, I'm a chrooted user... regards Felipe Robin Taylor escribió: That's good. #!/bin/sh at the start of the script just tells the OS what shell it should use to run the script, and it seems you have the required shell so you shouldn't have to change it to use bash. What directory were you in when you ran ./create-administrator ? Were you in the dspace/bin directory ? Cheers, Robin. Robin Taylor Main Library University of Edinburgh Tel. 0131 6515208 -Original Message- From: felipe Melero [mailto:fmel...@unav.es] Sent: 07 January 2009 12:56 To: dspace tech Subject: Re: [Dspace-tech] problem executing create-administrator Hi Robin, it seems that is present on the machine, as well as bash. -bash-3.00$ ls -l /bin/sh -rwxr-xr-x 1 root root 616248 Apr 12 2006 /bin/sh regards, Felipe Robin Taylor escribió: Hi felipe, I don't have a machine with Red Hat on it near so would you mind entering... ls -l /bin/sh ...and tell me what the response is ? It sounds like /bin/sh is not present on your machine. If that is the case then you will need to change script dsrun as well as create-administrator. Cheers, Robin. Robin Taylor Main Library University of Edinburgh Tel. 0131 6515208 -Original Message- From: felipe Melero [mailto:fmel...@unav.es] Sent: 07 January 2009 12:22 To: dspace tech Subject: [Dspace-tech] problem executing create-administrator Hi all, I have a problem executing the script create-adminstrator, I get the following error: "bad interpreter". -bash-3.00$ ./create-administrator : bad interpreter: No such file or directory if I change the line inside the script #!/bin/sh to #!/bin/bash I get other errors: -bash-3.00$ ./create-administrator ./dsrun: line 61: sed: command not found ./dsrun: line 70: java: command not found Does anybody know how to make it work? I have Red Hat Linux if helps. Thanks in advance, Felipe -- Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
Re: [Dspace-tech] problem executing create-administrator
For what it's worth, I've had somewhat similar problems executing the scripts in the bin directory after transferring them from a Windows-based machine to a Unix-like system. You might check that the line endings in the file haven't been changed to DOS-style endings, and if they have, convert them back with a command such as dos2unix. Not sure this is the same issue but maybe worth checking into. felipe Melero wrote: > Yes, I'm running it from dspace/bin directory but no way to get it > working... > > surely is a matter of unix, I'm a chrooted user... > > regards > Felipe > > Robin Taylor escribió: >> That's good. #!/bin/sh at the start of the script just tells the OS what >> shell it should use to run the script, and it seems you have the required >> shell so you shouldn't have to change it to use bash. What directory were >> you in when you ran ./create-administrator ? Were you in the dspace/bin >> directory ? >> >> Cheers, Robin. >> >> >> Robin Taylor >> Main Library >> University of Edinburgh >> Tel. 0131 6515208 >> >> >>> -Original Message----- >>> From: felipe Melero [mailto:fmel...@unav.es] >>> Sent: 07 January 2009 12:56 >>> To: dspace tech >>> Subject: Re: [Dspace-tech] problem executing create-administrator >>> >>> Hi Robin, >>> it seems that is present on the machine, as well as bash. >>> >>> -bash-3.00$ ls -l /bin/sh >>> -rwxr-xr-x 1 root root 616248 Apr 12 2006 /bin/sh >>> >>> regards, >>> Felipe >>> >>> Robin Taylor escribió: >>> >>> Hi felipe, >>> >>> I don't have a machine with Red Hat on it near so would >>> you mind entering... >>> >>> ls -l /bin/sh >>> >>> ...and tell me what the response is ? >>> >>> It sounds like /bin/sh is not present on your machine. >>> If that is the case then you will need to change script dsrun >>> as well as create-administrator. >>> >>> Cheers, Robin. >>> >>> >>> >>> >>> >>> Robin Taylor >>> Main Library >>> University of Edinburgh >>> Tel. 0131 6515208 >>> >>> >>> >>> -Original Message- >>> From: felipe Melero [mailto:fmel...@unav.es] >>> Sent: 07 January 2009 12:22 >>> To: dspace tech >>> Subject: [Dspace-tech] problem executing >>> create-administrator >>> >>> Hi all, >>> >>> I have a problem executing the script >>> create-adminstrator, I >>> get the following error: "bad interpreter". >>> >>> -bash-3.00$ ./create-administrator >>> : bad interpreter: No such file or directory >>> >>> if I change the line inside the script >>> #!/bin/sh to >>> #!/bin/bash I get other errors: >>> >>> -bash-3.00$ ./create-administrator >>> ./dsrun: line 61: sed: command not found >>> ./dsrun: line 70: java: command not found >>> >>> Does anybody know how to make it work? I have >>> Red Hat Linux if helps. >>> >>> Thanks in advance, >>> >>> Felipe >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >> >> >> > > > -- > Check out the new SourceForge.net Marketplace. > It is the best place to buy or sell services for > just about anything Open Source. > http://p.sf.net/sfu/Xq1LFB > > > ___ > DSpace-tech mailing list > DSpace-tech@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/dspace-tech > -- Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB ___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
Re: [Dspace-tech] problem executing create-administrator
Yes, I'm running it from dspace/bin directory but no way to get it working... surely is a matter of unix, I'm a chrooted user... regards Felipe Robin Taylor escribió: That's good. #!/bin/sh at the start of the script just tells the OS what shell it should use to run the script, and it seems you have the required shell so you shouldn't have to change it to use bash. What directory were you in when you ran ./create-administrator ? Were you in the dspace/bin directory ? Cheers, Robin. Robin Taylor Main Library University of Edinburgh Tel. 0131 6515208 -Original Message- From: felipe Melero [mailto:fmel...@unav.es] Sent: 07 January 2009 12:56 To: dspace tech Subject: Re: [Dspace-tech] problem executing create-administrator Hi Robin, it seems that is present on the machine, as well as bash. -bash-3.00$ ls -l /bin/sh -rwxr-xr-x 1 root root 616248 Apr 12 2006 /bin/sh regards, Felipe Robin Taylor escribió: Hi felipe, I don't have a machine with Red Hat on it near so would you mind entering... ls -l /bin/sh ...and tell me what the response is ? It sounds like /bin/sh is not present on your machine. If that is the case then you will need to change script dsrun as well as create-administrator. Cheers, Robin. Robin Taylor Main Library University of Edinburgh Tel. 0131 6515208 -Original Message- From: felipe Melero [mailto:fmel...@unav.es] Sent: 07 January 2009 12:22 To: dspace tech Subject: [Dspace-tech] problem executing create-administrator Hi all, I have a problem executing the script create-adminstrator, I get the following error: "bad interpreter". -bash-3.00$ ./create-administrator : bad interpreter: No such file or directory if I change the line inside the script #!/bin/sh to #!/bin/bash I get other errors: -bash-3.00$ ./create-administrator ./dsrun: line 61: sed: command not found ./dsrun: line 70: java: command not found Does anybody know how to make it work? I have Red Hat Linux if helps. Thanks in advance, Felipe -- Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
Re: [Dspace-tech] problem executing create-administrator
Hi Robin, it seems that is present on the machine, as well as bash. -bash-3.00$ ls -l /bin/sh -rwxr-xr-x 1 root root 616248 Apr 12 2006 /bin/sh regards, Felipe Robin Taylor escribió: Hi felipe, I don't have a machine with Red Hat on it near so would you mind entering... ls -l /bin/sh ...and tell me what the response is ? It sounds like /bin/sh is not present on your machine. If that is the case then you will need to change script dsrun as well as create-administrator. Cheers, Robin. Robin Taylor Main Library University of Edinburgh Tel. 0131 6515208 -Original Message- From: felipe Melero [mailto:fmel...@unav.es] Sent: 07 January 2009 12:22 To: dspace tech Subject: [Dspace-tech] problem executing create-administrator Hi all, I have a problem executing the script create-adminstrator, I get the following error: "bad interpreter". -bash-3.00$ ./create-administrator : bad interpreter: No such file or directory if I change the line inside the script #!/bin/sh to #!/bin/bash I get other errors: -bash-3.00$ ./create-administrator ./dsrun: line 61: sed: command not found ./dsrun: line 70: java: command not found Does anybody know how to make it work? I have Red Hat Linux if helps. Thanks in advance, Felipe -- Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
[Dspace-tech] problem executing create-administrator
Hi all, I have a problem executing the script *create-adminstrator*, I get the following error: "bad interpreter". -bash-3.00$ ./create-administrator : bad interpreter: No such file or directory if I change the line inside the script * #!/bin/sh* to *#!/bin/bash* I get other errors: -bash-3.00$ ./create-administrator ./dsrun: line 61: sed: command not found ./dsrun: line 70: java: command not found Does anybody know how to make it work? I have Red Hat Linux if helps. Thanks in advance, Felipe -- Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech