Re: Sql Developer (784 Views)
Reply
Visitor
Teriyaki1973
Posts: 5
Registered: ‎07-21-2011
Message 1 of 10 (911 Views)
Accepted Solution

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.

 

 

Please use plain text.
Acclaimed Contributor
Dennis Handly
Posts: 24,896
Registered: ‎03-06-2006
Message 2 of 10 (904 Views)

Re: Sql Developer

[ Edited ]

>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.

Please use plain text.
Visitor
Teriyaki1973
Posts: 5
Registered: ‎07-21-2011
Message 3 of 10 (895 Views)

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?

 

 

Please use plain text.
Acclaimed Contributor
Dennis Handly
Posts: 24,896
Registered: ‎03-06-2006
Message 4 of 10 (879 Views)

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.

 

 



Please use plain text.
Visitor
Teriyaki1973
Posts: 5
Registered: ‎07-21-2011
Message 5 of 10 (868 Views)

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.

Please use plain text.
Acclaimed Contributor
Dennis Handly
Posts: 24,896
Registered: ‎03-06-2006
Message 6 of 10 (808 Views)

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?

Please use plain text.
Visitor
Teriyaki1973
Posts: 5
Registered: ‎07-21-2011
Message 7 of 10 (804 Views)

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.

 

Please use plain text.
Acclaimed Contributor
Dennis Handly
Posts: 24,896
Registered: ‎03-06-2006
Message 8 of 10 (797 Views)

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?

Please use plain text.
Visitor
Teriyaki1973
Posts: 5
Registered: ‎07-21-2011
Message 9 of 10 (794 Views)

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.
Please use plain text.
Acclaimed Contributor
Dennis Handly
Posts: 24,896
Registered: ‎03-06-2006
Message 10 of 10 (784 Views)

Re: Sql Developer

> Thanks for your help. 

 

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

Please use plain text.
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation