- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Command Export not found in scripts
Operating System - HP-UX
1824170
Members
2490
Online
109669
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2000 04:49 AM
тАО11-20-2000 04:49 AM
Command Export not found in scripts
We are using Oracle on our HP9000 K370 under 11.0. In the backup we do a database-shutdown, calling a shutdown-scripts with the su command. The shutdown script starts with setting a few variables. However, the export of these variables produces an error-message, which is listed below.
------------------------------
su - oracle /disk01/app/oracle/admin/C2P/test.sh
export: Command not found
export: Command not found.
/disk01/app/oracle/product/8.0.5
C2K
----------------------------------
The part of the script involved is listed below.
------------------
export ORACLE_HOME=/disk01/app/oracle/product/8.0.5
export ORACLE_SID=C2P
echo $ORACLE_HOME
echo $ORACLE_SID
--------------------
I can see what is going wrong here since the echo command gives the right results.
------------------------------
su - oracle /disk01/app/oracle/admin/C2P/test.sh
export: Command not found
export: Command not found.
/disk01/app/oracle/product/8.0.5
C2K
----------------------------------
The part of the script involved is listed below.
------------------
export ORACLE_HOME=/disk01/app/oracle/product/8.0.5
export ORACLE_SID=C2P
echo $ORACLE_HOME
echo $ORACLE_SID
--------------------
I can see what is going wrong here since the echo command gives the right results.
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2000 05:08 AM
тАО11-20-2000 05:08 AM
Re: Command Export not found in scripts
Hi,
Instead of running
su - oracle /disk01/app/oracle/admin/C2P/test.sh
Supply the -c argument:-
su - oracle -c /disk01/app/oracle/admin/C2P/test.sh
Personally I would run the command:-
su oracle -c /disk01/app/oracle/admin/C2P/test.sh
and get the script to set up the necessary Oracle environment (PATH, ORACLE_HOME and ORACLE_SID).
Regards,
John
Instead of running
su - oracle /disk01/app/oracle/admin/C2P/test.sh
Supply the -c argument:-
su - oracle -c /disk01/app/oracle/admin/C2P/test.sh
Personally I would run the command:-
su oracle -c /disk01/app/oracle/admin/C2P/test.sh
and get the script to set up the necessary Oracle environment (PATH, ORACLE_HOME and ORACLE_SID).
Regards,
John
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-20-2000 05:08 AM
тАО11-20-2000 05:08 AM
Re: Command Export not found in scripts
insert as the first line in your /disk01/app/oracle/admin/C2P/test.sh
#!/sbin/sh
to ensure that the script runs in posix shell.
(i guess your oracle user has the c-shell - check it in /etc/passwd)
Also be sure that your test.sh has posix/bourne/korn shell syntax.
#!/sbin/sh
to ensure that the script runs in posix shell.
(i guess your oracle user has the c-shell - check it in /etc/passwd)
Also be sure that your test.sh has posix/bourne/korn shell syntax.
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Learn About
News and Events
Support
© Copyright 2025 Hewlett Packard Enterprise Development LP