error connecting sql through a shell script

Hi I am getting this error while connecting to sql through a shell script, whereas i am able to connect to sql directly.
It was working properly earlier, no clue why i am getting this.
Please find the log below:

FTP to <IP> completed Wed Apr 30 11:42:01 BST 2008
Program ended. Wed Apr 30 11:42:01 BST 2008
ERROR:
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
HP-UX Error: 2: No such file or directory

Enter password:
Enter password:
ERROR:
ORA-01005: null password given; logon denied

Beginnning Load Process at Wed Apr 30 11:42:02 BST 2008
ERROR:
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
HP-UX Error: 2: No such file or directory

SP2-0306: Invalid option.
Usage: CONN[ECT] [logon] [AS {SYSDBA|SYSOPER}] | [INTERNAL]
where <logon> ::= <username>[/<password>][@<connect_string>] | /
Enter password:
Enter password:
ERROR:
ORA-01005: null password given; logon denied

SP2-0157: unable to CONNECT to ORACLE after 3 attempts, exiting SQL*Plus
Ending Load Process at Wed Apr 30 11:42:03 BST 2008

Any help is appreciated.
Thanks.

Thr error means the instance of Oracle is not up and running, or you specified one that does not exist or no longer exists. Based on the file error I would day the SID you requested does not exist.