# Log in as 'oracle', the owner of the 10g Database software.
su - oracle

# Set up your environment to reference the 10g installation.
# Your 10g ORACLE_HOME might have a different path, adjust as
# necessary.
export ORACLE_HOME=/u01/app/oracle/product/10.2.0/db_1
# Put ORACLE_HOME/bin first, in case 11g bin is already in the path.
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_SID=orcl

# Start up the 10g database
echo "STARTUP" | sqlplus / as sysdba

# Create a PFILE (for editing parameters for the upgrade)
echo "CREATE PFILE FROM SPFILE;" | sqlplus / as sysdba

# Create a backup of the PFILE (for future reference)
cp $ORACLE_HOME/dbs/initorcl.ora $ORACLE_HOME/dbs/initorcl.ora.bak
