Script for getting mail if database is down

Hi Friends,
OS Version : IBM AIX 5,2
Oracle version : 9.2.0.7
I am executing the following script for getting mail alert if database is down. some how the script is not working
check_stat=`ps -ef|grep ${ORACLE_SID}|grep pmon|wc -l`;
oracle_num=`expr $check_stat`
if [ $oracle_num -lt 1 ]
then
exit 0
fi
# Test to see if Oracle is accepting connections
$ORACLE_HOME/bin/sqlplus -s "/as sysdba" > /tmp/check_$ORACLE_SID.ora
select name from v$database;
exit
# If not, exit and e-mail . . .
check_stat=`cat /tmp/check_$ORACLE_SID.ora|grep -i error|wc -l`;
oracle_num=`expr $check_stat`
if [ $oracle_num -ne 0 ]
then
mailx -s "$ORACLE_SID is down!" [email protected] < /tmp/check_$ORACLE_SID.ora
exit 16
fi
I am saving this as .sh file and executing at command prompt. It is just hanging, but not throwing any error.
I would like to know if there is anything to be modified in the script or please provide me any such script. Thanks in advance

HI there.
I have a script I use that works really well. It sends out an email only if the database is down and also reads an ini file to process a blackout period and a priority level of the database... High priority databases are monitored every 5 minutes and Medium priority databases every hour.
There are two scripts, the shell script and the .ini file and I have two cron entries...
Check script:_
#!/bin/ksh
# check_oracle_status.sh
# Script to check if Oracle db's are up and running.
# Script is passed a priority field and reads check_oracle_status.ini
# to determine which db's to check. If db is down an email is sent.
# Priority Levels:
# H - Checks db's with "H"igh Priority every 5 minutes (cron)
# M - Checks db's with "M"edium Priority every hour (cron)
# L - db's with "L"ow Priority currently not checked
# Script Change History:
# ======================
# October 29th, 2009 - Initial Creation
# Set environment
export SCRIPTHOME=/opt/oracle/admin/scripts
export INIFILE=$SCRIPTHOME/check_oracle_status.ini
export PRIORITY=$1
. $HOME/.profile
db=`grep -i ":$PRIORITY" $INIFILE | cut -d":" -f1`
check_database()
sqlplus <<! > $SCRIPTHOME/check.out
/ as sysdba
select * from dba_data_files;
exit
grep ORA- $SCRIPTHOME/check.out > $SCRIPTHOME/error.out
if (( $? )); then
echo ""
else
mailx -s "Oracle instance $i is currently UNAVAILABLE" +<email address>+ < $SCRIPTHOME/error.out
fi
for i in $db ; do
fields=`grep $i $INIFILE | awk -F':' '{ total = total + NF }; END {print total}'`
export ORACLE_SID=$i
if [ $fields -gt 2 ]; then
BLACKOUT_START=`grep -i "$ORACLE_SID" $INIFILE | cut -d":" -f3`
BLACKOUT_END=`grep -i "$ORACLE_SID" $INIFILE | cut -d":" -f4`
CURRENT_HOUR=`date +%H`
CHECK_BASE=YES
if [ $BLACKOUT_START -gt $BLACKOUT_END ]; then
(( $CURRENT_HOUR >= $BLACKOUT_START || $CURRENT_HOUR <= $BLACKOUT_END )) && CHECK_BASE=
else
(( $CURRENT_HOUR >= $BLACKOUT_START && $CURRENT_HOUR <= $BLACKOUT_END )) && CHECK_BASE=
fi
if [ -n "$CHECK_BASE" ]; then
check_database
fi
else
check_database
fi
done
rm $SCRIPTHOME/check.out $SCRIPTHOME/error.out
INI File:_
oracle1:L
oracle2:M:17:08
oracle3:M
oracle5:M:17:08
oracle6:H
oracle7:M:17:08
oracle8:M
oracle9:M
Where oracle1,2,3 etc is your sid
L M and H your priority level
17 is blackout start (5 PM)
08 is blackout end (8 AM)
Note: Blackout is just a start hour and an end hour and must contain both or none and my script can only process one blackout per database. I guess if you
needed a second blackout you could add another line with different times for that sid
Cron entries:_
# Check Oracle Status
# The check_oracle_status.sh script monitors "H"igh priority databases every 5 minutes
# and "M"edium priority databases every hour
0,5,10,15,20,25,30,35,40,45,50,55 * * * * /opt/oracle/admin/scripts/check_oracle_status.sh H > /dev/null 2>&1
0 * * * * /opt/oracle/admin/scripts/check_oracle_status.sh M > /dev/null 2>&1
Not sure if you require blackouts or priority levels but this setup works great at our site.
Hope this helps.

Similar Messages

  • Script for forward mail as attachment

    Hi,
    I think there is no direct call for creating forward mail as attachment. I tried "forward" reply and other things.Its working fine.
    Please let me know if any one have idea for creating script for apple mail "forward as attachment".

    hm... perhaps these two functions do what you wanna do :-/
    on createmail_emlx_files_attachment_ofselection()
    tell application "Mail"
    -- get the mail selection
    set myMessages to selection
    --do it to every selected mail
    repeat with m in myMessages
    --get the folder where the emlx file is stored in
    set mypath to quoted form of POSIX path of ((account directory of account of mailbox of m) as alias)
    --get the id of that message (should be unique within each account)
    set myid to id of m
    --find the folder where this unique email (by id) is stored in
    set myfolder to quoted form of (paragraph 1 of (do shell script "find " & mypath & " -name '" & myid & ".emlx' -exec dirname {} \\;"))
    --create a compressed tar archive of this message and open this gzipped files with Apple Mail (-> attach it to a new message).
    do shell script "cd " & myfolder & ";tar -rf " & myid & ".tar " & myid & ".emlx;gzip " & myid & ".tar;mv " & myid & ".tar.gz /tmp/;open -a /Applications/Mail.app /tmp/" & myid & ".tar.gz"
    end repeat
    end tell
    end createmail_emlx_files_attachment_ofselection
    on createmail_source_attachment_ofselection()
    tell application "Mail"
    -- get the mail selection
    set myMessages to selection
    --do it to every selected mail
    repeat with m in myMessages
    set myid to id of m
    set mysource to quoted form of ((source of m) as text)
    do shell script "cd /tmp/;echo " & mysource & "|cat>/tmp/" & myid & ".txt;gzip " & myid & ".txt;open -a /Applications/Mail.app " & myid & ".txt.gz"
    end repeat
    end tell
    end createmail_source_attachment_ofselection

  • Power shell script for get a content db for a particular web application

    Hi
    what  is the power shell script for get a content db for a particular web application
    Get-SPDatabase 
    adil

    try this one
    Get-SPContentDatabase -webapplication http://url
    this will return all the database for the web applications.
    Get-SPContentDatabase -site http://contoso.com
    this will return the database name in which the contose site collection is.
    Please remember to mark your question as answered &Vote helpful,if this solves/helps your problem. ****************************************************************************************** Thanks -WS MCITP(SharePoint 2010, 2013) Blog: http://wscheema.com/blog

  • TS3276 I just upgraded to 10.8.2 and Mail is having a problem. It won't remember my password for getting mail; but it does remember the password for sending mail, i.e., smtp. Does anyone know of a fix?

    I just upgraded to 10.8.2 and Mail is having a problem. It won't remember my password for getting mail; but it does remember the password for sending mail, i.e., smtp. Does anyone know of a fix?

    The solution surprised even me, and we've been using Macs since 1984 (still have an original 128K).
    I contacted Apple support, and because we had just upgraded yesterday, clicked on the "exception" button as opposed to paying the $19.99 one-time support fee. An Apple tech called and the problem was solved in two minutes.
    Somehow during the installation of OS 10.8.2 (over 10.6.x) the key chain data for my email ISP login password got corrupted. The solution was to delete both the POP mail and SMTP entries in my keychain.
    Back to Mail, it asked for the POP password, I entered it and bingo, mail got busy downloading. Interestingly, the password was also entered into the SMTP panel.
    So, that's it. Thanks for you response, Mr. Hoffman, and regards.

  • Here are scripts for getting OAS302 working on RedHat 6.0

    People have said this doesn't work. It works. It's just the
    owsctl that doesn't work. I'm not saying that oas302 on RedHat 6
    is the best solution anyone could come up with, but it does work,
    and if you want to do it, here are some scripts that you can feel
    free to modify and use as you wish. Various variables should be
    updated with however you system is configured. Remember to start
    the wrb (i.e. the second script) before you start any listeners.
    Linux has a tendency to crash if you don't kill -KILL all the wrb
    processes at the same time (i.e. the kernel gets an uncaught
    exception and dies).
    Erik
    <disclaimer>
    I do not guarantee these will work. I do not guarantee that
    they will not destroy something important. I assume no liability
    for what these scripts may or may not do. Use them at your own
    risk. There is no expressed or implied waranty.
    </disclaimer>
    #!/bin/ksh
    # Script to start the oraweb http servers to listen for requests
    # because owsctl is kind of unpredictable under RedHat 6.0
    # set this variable to be the directory that the webserver
    # configuration drivetoryies are under (i.e.
    # /db/app/oracle/admin/ows/web/httpd_my.host.com)
    WEB_HOME=/db/app/oracle/admin/ows/web/httpd_my.host.com
    LISTENER="$2"
    if [[ -z "$LISTENER" ]]
    then
    echo "No listener name to start."
    echo "Usage: listen {start|stop} listener"
    echo "e.g.:"
    echo " listen start admin"
    exit 1
    fi
    case "$1" in
    start)
    OMN_ADDR=UDP:worf.gcg.com:2649
    OWS_ADPCFG="$ORAWEB_HOME/admin/adpspy.cfg"
    OWS_ADPSO="$ORAWEB_HOME/lib/ndwfs.so"
    OWS_ORAWEB_FREEDOMX=1
    export OWS_ADPCFG OWS_ADPSO OMN_ADDR OWS_ORAWEB_FEEDOMX
    CFG_FILE=$WEB_HOME/$LISTENER/config/sv$LISTENER.cfg
    if [[ -f "$CFG_FILE" ]]
    then
    oraweb -C $CFG_FILE
    else
    echo "Could not find config file for $LISTENER:"
    echo " $CFG_FILE"
    exit 1
    fi
    stop)
    PID_FILE=$WEB_HOME/$LISTENER/config/sv$LISTENER.pid
    if [[ -f $PID_FILE ]]
    then
    kill `cat $PID_FILE`
    if [[ $? -ne 0 ]]
    then
    echo "Could not stop oraweb $LISTENER process."
    exit 1
    fi
    else
    echo "Could not find oraweb $LISTENER PID file:"
    echo " $PID_FILE"
    exit 1
    fi
    echo "Usage: listen {start|stop} listener"
    echo "e.g.:"
    echo " listen start admin"
    exit 1
    esac
    #!/bin/ksh
    # Script to start up the Oracle Web Request Broker (wrb)
    # processes manually because owsctl doesn't work on RedHat
    # Linux 6.0
    TMP_FILE=/tmp/wrb.pids
    case "$1" in
    start)
    SLEEP=3
    if [[ -f "$TMP_FILE" ]]
    then
    echo "$TMP_FILE exits. Make sure the wrb is not
    already"
    echo "running, remove $TMP_FILE, and run this script
    again."
    exit 1
    fi
    if [[ -z "$ORAWEB_HOME" ]]
    then
    echo "ORAWEB_HOME is not set. This environment variable"
    echo "should be set to the directory where the oracle was"
    echo "lives, i.e. /app/oracle/product/8.0.5/ows/3.0"
    exit 1
    fi
    OMN_ADDR=UDP:my.host.com:2649
    OWS_ADPCFG="$ORAWEB_HOME/admin/adpspy.cfg"
    OWS_ADPSO="$ORAWEB_HOME/lib/ndwfs.so"
    OWS_ORAWEB_FEEDOMX=1 # I have no idea what this does; I read
    # about it in a newsgroup. Supposedly
    # it makes the oas run faster
    export OWS_ADPCFG OWS_ADPSO OMN_ADDR OWS_ORAWEB_FREEDOMX
    PATH=$ORAWEB_HOME/bin:$PATH
    mnaddrsrv -D &
    echo -n "$! " > $TMP_FILE
    sleep $SLEEP
    mnrpcnmsrv &
    echo -n "$! " >> $TMP_FILE
    mnorbsrv &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    wrbcfg &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    wrblog &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    wrbasrv &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    wrbahsrv &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    wrbroker &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    wrbvpm &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    wrbfac &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    wrbdm &
    echo -n "$! " >> $TMP_FILE
    sleep $SLEEP
    stop)
    kill -KILL `cat $TMP_FILE`
    if [[ $? -ne 0 ]]
    then
    echo "Could not stop wrb processes. The PIDs are in"
    echo "$TMP_FILE. If these are running, please"
    echo "stop them manually."
    else
    rm -rf $TMP_FILE
    fi
    echo "Usage: wrb {start|stop}"
    exit 1
    esac
    null

    Hi Erick,
    Your scripts for running the OAS302 on 6.0 linux had been very
    helpful.
    In fact, I dont know what would I have done without them.
    Now I am able to run the listeners and even able to create the
    packages and users in the database via the OAS 3.0.2 but the
    problem starts when accessing a procedure in the database using
    the pl/sql agent. By the way i am using Oracle 8.0.5.1 RDBMS and
    its home is different than the webserver home.
    The browser just does nothing and even does not log any error
    message ,I have to stop it after a while but all my other
    catridges are working.
    any insight will be appreciated.
    thanks,
    Vikram ( Ironically enough I work for Oracle).
    Erik Nielsen (guest) wrote:
    : People have said this doesn't work. It works. It's just the
    : owsctl that doesn't work. I'm not saying that oas302 on RedHat
    6
    : is the best solution anyone could come up with, but it does
    work,
    : and if you want to do it, here are some scripts that you can
    feel
    : free to modify and use as you wish. Various variables should
    be
    : updated with however you system is configured. Remember to
    start
    : the wrb (i.e. the second script) before you start any
    listeners.
    : Linux has a tendency to crash if you don't kill -KILL all the
    wrb
    : processes at the same time (i.e. the kernel gets an uncaught
    : exception and dies).
    : Erik
    : <disclaimer>
    : I do not guarantee these will work. I do not guarantee that
    : they will not destroy something important. I assume no
    liability
    : for what these scripts may or may not do. Use them at your own
    : risk. There is no expressed or implied waranty.
    : </disclaimer>
    : #!/bin/ksh
    : # Script to start the oraweb http servers to listen for
    requests
    : # because owsctl is kind of unpredictable under RedHat 6.0
    : # set this variable to be the directory that the webserver
    : # configuration drivetoryies are under (i.e.
    : # /db/app/oracle/admin/ows/web/httpd_my.host.com)
    : WEB_HOME=/db/app/oracle/admin/ows/web/httpd_my.host.com
    : LISTENER="$2"
    : if [[ -z "$LISTENER" ]]
    : then
    : echo "No listener name to start."
    : echo "Usage: listen {start|stop} listener"
    : echo "e.g.:"
    : echo " listen start admin"
    : exit 1
    : fi
    : case "$1" in
    : start)
    : OMN_ADDR=UDP:worf.gcg.com:2649
    : OWS_ADPCFG="$ORAWEB_HOME/admin/adpspy.cfg"
    : OWS_ADPSO="$ORAWEB_HOME/lib/ndwfs.so"
    : OWS_ORAWEB_FREEDOMX=1
    : export OWS_ADPCFG OWS_ADPSO OMN_ADDR OWS_ORAWEB_FEEDOMX
    : CFG_FILE=$WEB_HOME/$LISTENER/config/sv$LISTENER.cfg
    : if [[ -f "$CFG_FILE" ]]
    : then
    : oraweb -C $CFG_FILE
    : else
    : echo "Could not find config file for $LISTENER:"
    : echo " $CFG_FILE"
    : exit 1
    : fi
    : stop)
    : PID_FILE=$WEB_HOME/$LISTENER/config/sv$LISTENER.pid
    : if [[ -f $PID_FILE ]]
    : then
    : kill `cat $PID_FILE`
    : if [[ $? -ne 0 ]]
    : then
    : echo "Could not stop oraweb $LISTENER process."
    : exit 1
    : fi
    : else
    : echo "Could not find oraweb $LISTENER PID file:"
    : echo " $PID_FILE"
    : exit 1
    : fi
    : echo "Usage: listen {start|stop} listener"
    : echo "e.g.:"
    : echo " listen start admin"
    : exit 1
    : esac
    : #!/bin/ksh
    : # Script to start up the Oracle Web Request Broker (wrb)
    : # processes manually because owsctl doesn't work on RedHat
    : # Linux 6.0
    : TMP_FILE=/tmp/wrb.pids
    : case "$1" in
    : start)
    : SLEEP=3
    : if [[ -f "$TMP_FILE" ]]
    : then
    : echo "$TMP_FILE exits. Make sure the wrb is not
    : already"
    : echo "running, remove $TMP_FILE, and run this script
    : again."
    : exit 1
    : fi
    : if [[ -z "$ORAWEB_HOME" ]]
    : then
    : echo "ORAWEB_HOME is not set. This environment variable"
    : echo "should be set to the directory where the oracle
    was"
    : echo "lives, i.e. /app/oracle/product/8.0.5/ows/3.0"
    : exit 1
    : fi
    : OMN_ADDR=UDP:my.host.com:2649
    : OWS_ADPCFG="$ORAWEB_HOME/admin/adpspy.cfg"
    : OWS_ADPSO="$ORAWEB_HOME/lib/ndwfs.so"
    : OWS_ORAWEB_FEEDOMX=1 # I have no idea what this does; I read
    : # about it in a newsgroup. Supposedly
    : # it makes the oas run faster
    : export OWS_ADPCFG OWS_ADPSO OMN_ADDR OWS_ORAWEB_FREEDOMX
    : PATH=$ORAWEB_HOME/bin:$PATH
    : mnaddrsrv -D &
    : echo -n "$! " > $TMP_FILE
    : sleep $SLEEP
    : mnrpcnmsrv &
    : echo -n "$! " >> $TMP_FILE
    : mnorbsrv &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : wrbcfg &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : wrblog &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : wrbasrv &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : wrbahsrv &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : wrbroker &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : wrbvpm &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : wrbfac &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : wrbdm &
    : echo -n "$! " >> $TMP_FILE
    : sleep $SLEEP
    : stop)
    : kill -KILL `cat $TMP_FILE`
    : if [[ $? -ne 0 ]]
    : then
    : echo "Could not stop wrb processes. The PIDs are in"
    : echo "$TMP_FILE. If these are running, please"
    : echo "stop them manually."
    : else
    : rm -rf $TMP_FILE
    : fi
    : echo "Usage: wrb {start|stop}"
    : exit 1
    : esac
    null

  • Script for getting the online/offline status

    Hi all,
    After enabling checkbox of "Enable assistive access device" is possible to get the online/ offline status.From Menu we will get the status.Without doing this i want to get the apple mail account online/offline status.hope some help scripts for this.

    [That script|http://discussions.apple.com/message.jspa?messageID=11012484#11012484] could change the Online Status of all mail accounts. The following one will just report their Online Status. Is this what you are (were) asking for?
    --BEGINNING OF SCRIPT
    tell application "Mail" to activate
    tell application "System Events" to tell process "Mail"
    set theMenu to menu "Mailbox" of menu bar 1
    if enabled of menu item "Take All Accounts Online" of theMenu then
    return "All accounts are currently offline"
    else
    return "All accounts are currently online"
    end if
    end tell
    --END OF SCRIPT

  • Script for getting all windows Drives freespace information

    Hi All,
    Any can post the batch script to get the disk drives freespace info for multiple servers.
    Cheers,
    Govind

    This is not an Oracle Database question, so it really does not belong in this forum. You can query the WMI database in each server to find the information. Try the following search on Google:
    hey scripting guy free disk spaceCharles Hooper
    Co-author of "Expert Oracle Practices: Oracle Database Administration from the Oak Table"
    http://hoopercharles.wordpress.com/
    IT Manager/Oracle DBA
    K&M Machine-Fabricating, Inc.

  • Need script for getting Uptime for remote servers

    Hi Guys,
    I'm in need of a script to get the UP time for windows servers in number of days. i have more than 1000 servers.
    I dont want PowerShell script as i have many WIndows 2003 servers where PowerShell is not installed.
    Please help me with this.
    Thanks,
    Kiran Raj

    Hi,
    I'd look at the LastBootUpTime property that can be found by querying Win32_OperatingSystem.
    Don't retire TechNet! -
    (Don't give up yet - 12,700+ strong and growing)

  • Power Shell Script for getting the list of members of a particular collection group

    Hi Group
    I am looking for a powershell script for the below  manual process in sccm2012. please help
    Obtain the list of “All Users Group1” collection that have been defined as a Primary User of a device, and what that Users ShortName and Device name is
    Obtain the list of user from Active Directory that have their “Title” attribute equal to “Non-Employee” (samAccountName)
    For each user that is returned from AD, determine if they are assigned as a Primary User of a Device and write the Device name to a file
    Continue to append all of the applicable Device names to the file
    End Result = List of all Devices that have Users that have their AD Attribute “Title” equal to “Non-Employee”
    thanks
    VAR

    Hi,
    The Cmdlets below should be helpful for you to write the script. You could have a look.
    Get-CMUser
    Get-CMUserDeviceAffinity
    Get-ADUser
    Best Regards,
    Joyce Li
    We
    are trying to better understand customer views on social support experience, so your participation in this
    interview project would be greatly appreciated if you have time.
    Thanks for helping make community forums a great place.

  • Need VB script for getting the IIS certification information

    Hi guys,
    I have totally 1000 IIS servers  2003 & 2008
    windows and some of the  servers configured
    IIS 3rd party Security certificates. I need a script to get the certification information like expiry date & certificate vendor name.
    Regards,
    SreeM

    Post here:http://forums.iis.net/
    Look in Gallery for IIS scripts:http://gallery.technet.microsoft.com/
    ¯\_(ツ)_/¯

  • Script for: Getting the closest price within the group

    Hello
    I need some help for my script.I would like to add new field . Do you guys have an idea any OLAP functions .
    It was my simple script which doesn't give the answer I want.
    SELECT
    NO,
    SUM_QTY,
    QTY_QUOTED,
    CASE WHEN QTY_QUOTED < SUM_QTY
    THEN MAX(QTY_QUOTED)
    WHEN QTY_QUOTED = SUM_QTY
    THEN QTY_QUOTED
    WHEN QTY_QUOTED > SUM_QTY
    THEN MIN(QTY_QUOTED) END AS CLOSEST_Q
    from table1
    GROUP BY NO, SUM_QTY, QTY_QUOTED;
    output for the script below:
    No SUM_QTY QTY_QUOTED CLOSEST_Q
    567     3     2     2
    567     3     99     99
    130     140     156     156
    123     515     40     40
    911     120     600     600
    911     120     800     800
    567     3     3     3
    567     3     5     5
    911     120     700     700
    130     140     138     138
    130     140     12     12
    123     515     2     2
    I would like to see the last field below:
    No Sum_Qty Qty_Quoted The Field I want to have or  The other way I want to see
    ==== ======= ======== ================ ==================
    123 515 40 x 40
    123 515 2 40
    567 3 5 3
    567 3 2 3
    567 3 3 x 3
    567 3 99 3
    911 120 600 x 600
    911 120 700 600
    911 120 800 600
    130 140 12 138
    130 140 138 x 138
    130 140 256 138
    I willl appreciate if you can give any clue /solution or idea.
    Thanks a lot,
    Pinar

    [That script|http://discussions.apple.com/message.jspa?messageID=11012484#11012484] could change the Online Status of all mail accounts. The following one will just report their Online Status. Is this what you are (were) asking for?
    --BEGINNING OF SCRIPT
    tell application "Mail" to activate
    tell application "System Events" to tell process "Mail"
    set theMenu to menu "Mailbox" of menu bar 1
    if enabled of menu item "Take All Accounts Online" of theMenu then
    return "All accounts are currently offline"
    else
    return "All accounts are currently online"
    end if
    end tell
    --END OF SCRIPT

  • How do I set  keyboard shortcut for 'Get Mail'?

    Went to system preferences - keyboard - shortcuts - App shortcuts and added Mail.app
    Get Mail        cmd  G
    However, it doesn't work.  It just makes a nasty noise when I'm in mail and use the shortcut.

    The command is Get New Mail. It already has a keyboard shortcut, Shift-Command-N. Command-G is already used for Find Next (i.e., find the next occurrence of a find text).

  • HT3576 my Iphone 5 says i cannot get mail because server is down

    my Iphone 5 says i cannot get mail because server is down

    The incoming mail server is down - it happens to all of them at one time or another.
    Check with your email account provider.

  • Scripts for setting mail message colors quickly

    I've been frustrated at how difficult it is to set the color of a message subject etc in a mailbox. Sometimes applying a color would work, sometimes not, and many clicks required. Finally I wrote a simple script that appears in the Finder's Scripts menu, which applies a particular color to all emails that are selected. I made one version for each color I use (I use these to keep track of emails that are useful references, or that require some action, etc.) I added a leading space to the script names so they would appear at the top of the scripts menu. I wish I could connect them to buttons in the Mail window, but don't know a way to do that, and this is nearly as conveniet.
    Here's one of the scripts. Colors can be none, red, orange, blue, gray, green, purple, yellow:
    tell application "Mail"
    set selectedMessages to selection
    set nm to count of selectedMessages
    if (nm) is equal to 0 then
    display alert "No Messages Selected" message "Select the message(s) you want to color red before running this script."
    else
    repeat with nn from 1 to nm by 1
    set theMessage to item nn of selectedMessages
    set the background color of theMessage to red
    end repeat
    end if
    end tell

    HI Disha
    Check out these links. They will surely help
    http://www.geocities.com/mpioud/Z_EMAIL_ABAP_REPORT.html
    http://www.thespot4sap.com/Articles/SAP_Mail_SO_Object_Send.asp
    If you find this answer useful, please reward me for the same.
    Good luck
    Karthik Potharaju

  • Scripts for run after creating database

    HI,
    now when 10xe universal installer create database with unicode characterset we are all unabled to run Form6i (forms 6i does not support AL32UTF8) on xe.
    I would like to try to create database using EE8MSWIN1250 but I am not sure what scripts I have to run after create database on windows XP professional OS.
    Is there any list ?
    What else I have to check or run after creating database ?

    connect ... as sysdba
    @c:\oraclexe\app\oracle\product\10.2.0\server\RDBMS\ADMIN\catalog.sql
    @c:\oraclexe\app\oracle\product\10.2.0\server\RDBMS\ADMIN\catblock.sql
    @c:\oraclexe\app\oracle\product\10.2.0\server\RDBMS\ADMIN\catproc.sql
    @c:\oraclexe\app\oracle\product\10.2.0\server\RDBMS\ADMIN\catoctk.sql
    @c:\oraclexe\app\oracle\product\10.2.0\server\RDBMS\ADMIN\owminst.plb
    connect system
    @c:\oraclexe\app\oracle\product\10.2.0\server\sqlplus\admin\pupbld.sql
    @c:\oraclexe\app\oracle\product\10.2.0\server\sqlplus\admin\help\hlpbld.sql helpus.sql
    I execute that scripts and it's look like that everything working well except that I can't access Database Home Page.
    Any sugestion what I should look for.

Maybe you are looking for

  • MacBook Pro 2010 running slow

    I know there are other threads on this subject but they now seem very bloated and confusing. My 2010 MacBook Pro has ground to a halt since installing yosemite. At first the speed was bearable but now its completely frustrating, I have done all the t

  • How do I keep BI Publisher running when I log out of the console in linux?

    I am using the standalone version of BI Publisher and I want to keep it running even after I log out of the console. I have a script that starts it so I typed 'nohup start_bipub.sh &' but when I log out it shuts down anyway. I started my apache serve

  • IPad/iPhone 4s will not update

    I have a new ipad2 and iphone 4s running 5.0.1 I have just tried to update to ios 5.1 and iTunes fails to connect with the server to update. I have updated Itunes and rebooted but with no luck. Does anybody know what the problem could be? Barry

  • Portege 3440 CT - need driver for external CD-ROM

    Hello I have installed windows xp + sp2 on Portege 3440ct and PCMCIA card where is connect CD-rom is not recognized. I can't find driver here, anyone can help me? Thanks

  • Using  BIW IDES ECC5

    Hi there.. We are presently working on 4.6c & upgrading to MySAP . We have installed IDES ECC5 System (SAP ERP Central Component 5.0) in our organization. As we have never used BI or any of it's features,  how do we start using the BW IDES & learning