1748093 Members
5871 Online
108758 Solutions
New Discussion юеВ

Sql Developer

 
SOLVED
Go to solution
Teriyaki1973
Visitor

Sql Developer

Ok I am very new to this so bear with me.

I have recently been given access to a server with HP-UX 11i v3 installed on it. I am supposed to be developing a database which is to go on this server. Oracle has been installed on the server by someone else as I have little unix experience. I had tried to run sqlplus and this works ok. However when I try to run sqldeveloper by typing

$ sh sqldeveloper.sh

 

I receive the message

 

sqldeveloper.sh[2]: bash: not found

 

I think I am receiving this message because sqldeveloper requires the bash shell to open. It doesn't appear that the bash shell is installed on this server. Is it possible to open sqldeveloper using the Bourne shell only? If so how do I do it.

 

 

9 REPLIES 9
Dennis Handly
Acclaimed Contributor

Re: Sql Developer

>Is it possible to open sqldeveloper using the Bourne shell only?

 

(This is HP-UX, not Windows, you don't open scripts, you run, invoke or execute them.)

 

What does your script look like?  What are your first few lines?

Also, since this is HP-UX, Bourne shell is long gone.  There's the Posix shell, sh and ksh.

Teriyaki1973
Visitor

Re: Sql Developer

Hi thanks for your reply. The script is:-

 

#!bin/bash

cd "'dirname $0'"/sqldeveloper/bin && bash sqldeveloper $*

 

I am guessing that the first bit is trying to invoke the bash shell and the second part is trying to invoke sqldeveloper using the bash shell?

 

 

Dennis Handly
Acclaimed Contributor

Re: Sql Developer

>The script is:

 

You should change this to use the posix shell:

#!/bin/sh

cd "$(dirname $0)"/sqldeveloper/bin && ./sqldeveloper "$@"

 

>I am guessing that the first bit is trying to invoke the bash shell and the second part is trying to invoke sqldeveloper using the bash shell?

 

Yes.  If sqldeveloper is a binary, no need to use bash at all.

 

 

Teriyaki1973
Visitor

Re: Sql Developer

Ok thanks for that. It took me a bit of time to make the changes you suggested as it appears in my set up @ is a kill character. My systems administrator just shrugged his shoulders when I asked him how to sort it. Anyway I have fixed the problem myself and have made the changes you have suggested. I now receive the following:-

 

$ sh sqldeveloper.sh

interpreter "/bin/bash" not found

file link resolves to "/usr/bin/bash"

sqldeveloper.sh[2]: ./sqldeveloper: not found.

 

Is it possible that sqldeveloper actually is somehow tied into the bash shell??? I am still lost but I know a bit more about UNIX than I did this morning.

Dennis Handly
Acclaimed Contributor

Re: Sql Developer

>as it appears in my set up @ is a kill character. My systems administrator just shrugged his shoulders when I asked him how to sort it.

 

Huh?  That should be obvious, in your ~/.profile

# Set up the terminal:
        if [ "${-%%*i*}" != "$-" ]; then
           /bin/stty kill "^U"
        fi

 

And if you need more settings:

/bin/stty erase "^H" kill "^U" intr "^C" eof "^D" susp "^z"

 

$ sh sqldeveloper.sh

interpreter "/bin/bash" not found

file link resolves to "/usr/bin/bash"

sqldeveloper.sh[2]: ./sqldeveloper: not found.

 

You shouldn't have to use "sh" before sqldeveloper.sh.  Make sure it is executable:

chmod a+x sqldeveloper.sh

 

Invoke it as: ./sqldeveloper.sh

 

>Is it possible that sqldeveloper actually is somehow tied into the bash shell?

 

Possibly.  What does "file sqldeveloper" show?

Teriyaki1973
Visitor
Solution

Re: Sql Developer

I agree that the systems administrator was less than helpful.

 

file sqldeveloper shows

sqldeveloper: ascii text

 

which wasn't what i was expecting. The first line of the the file was trying to open the bash shell so I changed it. Ta da Sqldeveloper now loads with errors but I am getting somewhere.

 

Thanks for your help.

 

Dennis Handly
Acclaimed Contributor

Re: Sql Developer

>The first line of the the file was trying to open the bash shell so I changed it. sqldeveloper now loads with errors

 

That explains it.  What lines have errors?

Teriyaki1973
Visitor

Re: Sql Developer

I was a bit premature about the errors. It's actually just a warning message about fonts. I get sqldeveloper up and running fine now. The only problem is it is so slow. I have actually figured out I can use ssh tunneling to connect sqldeveloper running on my PC to the database on the server and it runs a lot faster. Thanks for your help.
Dennis Handly
Acclaimed Contributor

Re: Sql Developer

> Thanks for your help.

 

If you are happy with the answers you were given please assign kudos.