If the OEM repository is down OMS will try to reconnect when It's up again. At least that functionality work in the latest versions of EM12c.
It's worth looking at the startup script for 12c Cloud Control is : /etc/init.d/gcstartup
For more information kindly refer to the document : http://docs.oracle.com/cd/E24628_01/install.121/e24089/getstrtd_things_to_know.htm#EMADV12174
-- Kirill Loifman, dadbm.com
This is a part of my old script to do the same manually:
echo -n $"Starting $prog: "
su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl start"
su - $ORA_OWNER -c "$ORA_HOME/bin/dbstart"
su - $ORA_OWNER -c "$AGENT_HOME/bin/emctl start agent"
su - $ORA_OWNER -c "$OMS_HOME/bin/emctl start oms"
echo -n $"Stopping $prog: "
su - $ORA_OWNER -c "$OMS_HOME/bin/emctl stop oms -all"
su - $ORA_OWNER -c "$AGENT_HOME/bin/emctl stop agent"
su - $ORA_OWNER -c "$ORA_HOME/bin/dbshut"
su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl stop listener_ohegc"
-- Kirill Loifman
Please note, that additional component installs (BI Publisher, JVMD, etc) may have additional startup/shutdown pieces and should proceed the OMS shutdown, and follow OMS startup.
shutdown BI publisher
shutdown repository (if needed)
The agent generally doesn't have to be shutdown during OMS maintenance (except if instructed during EM upgrades), however if you enable out of band notifications or such, you may want to start a blackout on the agent if you're shutting down for a planned maintenance activity.