Script for checking hardware failures on Solaris

Hi all,
I am trying to write a script that checks failures/faults on the Solaris servers(8/9/10) using commands prtdiag -v, echo | format,metastat errors and iostat errors .
Does anyone have scripts like that?
Cheers

please share the script...It doesn't work that way.
These are technical forums, not replacements for you doing your own work.
People will be happy to respond with suggestions when you show what you have done but you need to display that you have done some effort first. You have not pasted any of your script here so no one can suggest any improvements to your work.
Go read the first two replies. They give you a lot of possibilities.

Similar Messages

  • Can SunMC send mail alert to sysadmin for any hardware failure?

    Hi All
    for SunMC 3.61 or 4.0,, Sunmc can send mail alert to sysadmin if hardware failure.
    1. I noticed that the email actions from Attribute Editor Actions Panel is not for all the hardware attribute.
    is there any way to send mail alert to sysadmin for any hardware failure?
    2. does SunMC monitor Sun Fire T2000 hardware fully?

    Hi EricTan,
    erictan wrote:
    Hi All
    for SunMC 3.61 or 4.0,, Sunmc can send mail alert to sysadmin if hardware failure.
    1. I noticed that the email actions from Attribute Editor Actions Panel is not for all the hardware attribute.
    is there any way to send mail alert to sysadmin for any hardware failure?The out-of-the box notifications in SunMC must be set up for every data point on every system, which can be a pain to configure and manage in all but the smallest environments. And as you've noticed, for some hardware attributes there are no "Actions" tabs the allow you to configure email. To gain the features of centralized notification, and to get alarms from all sources of events in SunMC, you should consider installing [PrimeAlert EventAction|http://www.halcyoninc.com/products/EventAction/index.php] . It ships with a 30-day eval license, and if you need any help setting it up, please let me know.
    2. does SunMC monitor Sun Fire T2000 hardware fully?Yes, the Tx000 series systems have some of the best hardware support available in SunMC. As an example you can look at a T2000 screenshot and list of hardware info [in this post about SunMC and xVM Ops Center|http://forums.halcyoninc.com/showthread.php?t=109] .
    Regards,
    Regards,
    [email protected]
    [http://www.HalcyonInc.com|http://www.HalcyonInc.com]
    New !! : [http://forums.HalcyonInc.com|http://forums.HalcyonInc.com] !!

  • Power Shell Script for Check Remote machinces are live or not

    I have required a Power Shell Script for Check multiple Remote machines are live or not.Please guide me

    This will do it.
    http://gallery.technet.microsoft.com/Ping-IP-Adress-Range-d90ce82d
    ¯\_(ツ)_/¯

  • Script for 'Check Links Before Opening Document' preference

    I'm trying to find the VB script for changing the "Check Links Before Opening Document" checkbox on the File Handling panel in the Preferences dialog? I haven't found any documentation referring to the Links items on that panel.
    Bob

    Thanks for the info.
    Was there a document you pulled this from?
    I have an old document from CS2 days that is invaluable for providing a detailed list of available script methods and properties. Obviously things that have been added in subsequent InDesign releases aren't in this document. Later InDesign CS releases offer script SDKs that contain helpful sample scripts but I don't find a detailed summary similar to one from CS2. Have I just not found them? Or how does one find the script method/property for things not contained in the sample scripts?

  • Executing a powershell script for checking duplicate users while creating a AD user throug ADUC console.

    Hi,
    I have a text file in which some SamAccountNames are present.I need to check the file while creating a new users through ADUC console.If a username that is going to create through ADUC console is present in the file, then it should prompt a message
    that the user is already present in the text file.
    Is there any possibility of contacting the powershell script from the ADUC console.If so, then while creating a new user through ADUC console, what is the proceedure for executing that powershell script.
    please provide me the approriate solutions.
    Thanks
    Prasanthi k

    Run the below Powershell Script for users are exist or not in AD. Later you can create the users.
    #Find Users exist in AD or Not?
    #Biswajit Biswas
    $users = get-content c:\users.txt
    foreach ($user in $users) {
    $User = Get-ADUser -Filter {(samaccountname -eq $user)}
    If ($user -eq $Null) {"User does not exist in AD ($user)" }
    Else {"User found in AD ($user)"}
    Active Directory Users attributes-Powershell
    http://gallery.technet.microsoft.com/scriptcenter/Getting-Users-ALL-7417b71d
    Regards~Biswajit
    Disclaimer: This posting is provided & with no warranties or guarantees and confers no rights.
    MCP 2003,MCSA 2003, MCSA:M 2003, CCNA, MCTS, Enterprise Admin
    MY BLOG
    Domain Controllers inventory-Quest Powershell
    Generate Report for Bulk Servers-LastBootUpTime,SerialNumber,InstallDate
    Generate a Report for installed Hotfix for Bulk Servers

  • ECMA script for checking active workflows for an list item

    Hi i am having more than 1 workflow associated with the list if there is any workflow that is active for an item then i need to prevent starting another workflow for the same item. I am using the following code to achieve the same. Can anyone please provide
    me the ECMA object model equivalent for achieving the same.
        //Check for any active workflows for the document
            private void CheckForActiveWorkflows()
                // Parameters 'List' and 'ID' will be null for site workflows.
                if (!String.IsNullOrEmpty(Request.Params["List"]) && !String.IsNullOrEmpty(Request.Params["ID"]))
                    this.workflowList = this.Web.Lists[new Guid(Request.Params["List"])];
                    this.workflowListItem = this.workflowList.GetItemById(Convert.ToInt32(Request.Params["ID"]));
                SPWorkflowManager manager = this.Site.WorkflowManager;
                SPWorkflowCollection workflowCollection = manager.GetItemActiveWorkflows(this.workflowListItem);
                if (workflowCollection.Count > 0)
                    SPUtility.TransferToErrorPage("An workflow is already running for the document. Kindly complete it before starting a new workflow");
            }

    Hi,
    According to your post, my understanding is that you wanted to use ECMA script to check active workflows for an list item.
    You can use the Workflow web service "/_vti_bin/workflow.asmx"
    - GetWorkflowDataForItem operation in particular.
    Here is a great blog for you to take a look at:
    http://jamestsai.net/Blog/post/Using-JavaScript-to-check-SharePoint-list-item-workflow-status-via-Web-Service.aspx
    In addition, you can use
    SPServices. For more information, please refer to:
    http://sharepoint.stackexchange.com/questions/72962/is-there-a-way-to-check-if-a-workflow-is-completed-using-javascript
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • Unix script for checking the user account status

    Hi All,
    i have created one unix script to check the status of the user in diff databases.
    #!/bin/ksh
    useracctreport.txt if [ ! -f hh ];
    then
    echo "Database file does not exist"
    fi
    echo "Enter Username"
    read USER
    echo "Enter the password"
    stty -echo
    read PASS
    stty echo
    for j in `cat users`
    do
    j="`echo $j| tr '[a-z]' '[A-Z]'`"
    for i in `cat hh`
    do
    sqlplus -s $USER/$PASS\@$i <<EOF >> useracctreport.txt
    column USERNAME format a8
    column ACCOUNT_STATUS format a5
    !echo "*****User $j Status in $i DB*****"
    select USERNAME,ACCOUNT_STATUS from dba_users where username=('$j');
    select OBJECT_TYPE,count(*) from dba_objects where owner='$j' group by object_type;
    EOF
    done
    done
    In log file ,i get the below error when its unable to connect to the DB.
    SP2-0306: Invalid option.
    Usage: CONN[ECT] [logon] [AS {SYSDBA|SYSOPER}] | [INTERNAL]
    where <logon> ::= <username>[<password>][@<connect_string>] | /
    SP2-0306: Invalid option.
    Usage: CONN[ECT] [logon] [AS {SYSDBA|SYSOPER}] | [INTERNAL]
    where <logon> ::= <username>[<password>][@<connect_string>] | /
    SP2-0157: unable to CONNECT to ORACLE after 3 attempts, exiting SQL*Plus
    ERROR:
    ORA-01017: invalid username/password; logon denied
    Is there any way i can supress this error?
    and is there any other way i can make this script faster.Thanks a lot for your help

    Hi,
    The failing line is
    sqlplus -s $USER/$PASS\@$i <<EOF >> useracctreport.txtYou should test the connect statement you provide to sqlplus. For example:
    CONSTRING=$USER/$PASS\@$i
    echo Connect string used: $CONSTRING
    sqlplus -s $CONSTRING <<EOF >> useracctreport.txtCheck the echoed value. It's malformed. Correct it appropriately.
    Yoann.

  • Bash script for checking link status

    So I'm doing some SEO work I've been tasked with checking a couple hundred thousand back links for quality.  I found myself spending a lot of time navigating to sites that no longer existed.  I figured I would make a bash script that checks if the links are active first.  The problem is my script is slower than evolution.  I'm no bash guru or anything so I figured maybe I would see if there are some optimizations you folks can think of.  Here is what I am working with:
    #!/bin/bash
    while read line
    do
    #pull page source and grep for domain
    curl -s "$line" | grep "example.com"
    if [[ $? -eq 0 ]]
    then
    echo \"$line\",\"link active\" >> csv.csv else
    echo \"$line\",\"REMOVED\" >> csv.csv
    fi
    done < <(cat links.txt)
    Can you guys think of another way of doing this that might be quicker?  I realize the bottleneck is curl (as well as the speed of the remote server/dns servers) and that there isn't really a way around that.  Is there another tool or technique I could use within my script to speed up this process?
    I will still have to go through the active links one by one and analyze by hand but I don't think there is a good way of doing this programmatically that wouldn't consume more time than doing it by hand (if it's even possible).
    Thanks

    I know it's been awhile but I've found myself in need of this yet again.  I've modified Xyne's script a little to work a little more consistently with my data.  The problem I'm running into now is that urllib doesn't accept IRIs.  No surprise there I suppose as it's urllib and not irilib.  Does anyone know of any libraries that will convert an IRI to a URI?  Here is the code I am working with:
    #!/usr/bin/env python3
    from threading import Thread
    from queue import Queue
    from urllib.request import Request, urlopen
    from urllib.error import URLError
    import csv
    import sys
    import argparse
    parser = argparse.ArgumentParser(description='Check list of URLs for existence of link in html')
    parser.add_argument('-d','--domain', help='The domain you would like to search for a link to', required=True)
    parser.add_argument('-i','--input', help='Text file with list of URLs to check', required=True)
    parser.add_argument('-o','--output', help='Named of csv to output results to', required=True)
    parser.add_argument('-v','--verbose', help='Display URLs and statuses in the terminal', required=False, action='store_true')
    ARGS = vars(parser.parse_args())
    INFILE = ARGS['input']
    OUTFILE = ARGS['output']
    DOMAIN = ARGS['domain']
    REMOVED = 'REMOVED'
    EXISTS = 'EXISTS'
    NUMBER_OF_WORKERS = 50
    #Workers
    def worker(input_queue, output_queue):
    while True:
    url = input_queue.get()
    if url is None:
    input_queue.task_done()
    input_queue.put(None)
    break
    request = Request(url)
    try:
    response = urlopen(request)
    html = str(response.read())
    if DOMAIN in html:
    status = EXISTS
    else:
    status = REMOVED
    except URLError:
    status = REMOVED
    output_queue.put((url, status))
    input_queue.task_done()
    #Queues
    input_queue = Queue()
    output_queue = Queue()
    #Create threads
    for i in range(NUMBER_OF_WORKERS):
    t = Thread(target=worker, args=(input_queue, output_queue))
    t.daemon = True
    t.start()
    #Populate input queue
    number_of_urls = 0
    with open(INFILE, 'r') as f:
    for line in f:
    input_queue.put(line.strip())
    number_of_urls += 1
    input_queue.put(None)
    #Write URL and Status to csv file
    with open(OUTFILE, 'a') as f:
    c = csv.writer(f, delimiter=',', quotechar='"')
    for i in range(number_of_urls):
    url, status = output_queue.get()
    if ARGS['verbose']:
    print('{}\n {}'.format(url, status))
    c.writerow((url, status))
    output_queue.task_done()
    input_queue.get()
    input_queue.task_done()
    input_queue.join()
    output_queue.join()
    The problem seems to be when I use urlopen
    response = urlopen(request)
    with a URL like http://www.rafo.co.il/בר-פאלי-p1
    urlopen fails with an error like this:
    Exception in thread Thread-19:
    Traceback (most recent call last):
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/threading.py", line 639, in _bootstrap_inner
    self.run()
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/threading.py", line 596, in run
    self._target(*self._args, **self._kwargs)
    File "./linkcheck.py", line 35, in worker
    response = urlopen(request)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/urllib/request.py", line 160, in urlopen
    return opener.open(url, data, timeout)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/urllib/request.py", line 473, in open
    response = self._open(req, data)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/urllib/request.py", line 491, in _open
    '_open', req)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/urllib/request.py", line 451, in _call_chain
    result = func(*args)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/urllib/request.py", line 1272, in http_open
    return self.do_open(http.client.HTTPConnection, req)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/urllib/request.py", line 1252, in do_open
    h.request(req.get_method(), req.selector, req.data, headers)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/http/client.py", line 1049, in request
    self._send_request(method, url, body, headers)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/http/client.py", line 1077, in _send_request
    self.putrequest(method, url, **skips)
    File "/usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/http/client.py", line 941, in putrequest
    self._output(request.encode('ascii'))
    UnicodeEncodeError: 'ascii' codec can't encode characters in position 5-8: ordinal not in range(128)
    I'm not too familiar with how character encoding works so I'm not sure where to start.  What would be a quick and dirty way (if one exists) to get URLs like this to play nicely with python's urlopen?

  • CSS Script for checking RADIUS Service

    Hi,
    We are using CSS 11501 boxes for load-sharing RADIUS (NAC) requests between different ACS Servers.
    How can I configure a keepalive method for checking the RADIUS service on the ACS Servers ?
    If this needs to be a script then Can anyone provide some hints\tips ?
    Thanks,
    Naman

    This needs to be a script.
    The best way would be to sniff a request/response from a known user [or fake user], then extract the udp header + payload in hex format, then create a CSS script to send the hex formatted query and to verify that the hex formatted response matches the server response.
    I believe the ap-kal-dns script uses a similar approach so you can look at it to get an idea of what you have to do.
    Gilles.

  • Script for checking the replication process in Netscape Directory Sever 4.1

    Hi,
    We are using Netscape Directory Server 4.1.6 in our production environment. Where we want to know is there any script available to check the replication process. Or can we write a script to check the process.
    Waiting for your replies at the earliest.
    Thanks,
    Syed A.

    Hi Syed,
    Replication state is very easy to see in 4.x and earlier. The last changenumber in the supplier changelog is visible (on the root DSE IIRC), and each consumer suffix has an operational attribute "copiedfrom" that tells you the name of the supplier, the database generation id, and the last change replayed from the supplier.
    So a script that compares the results of
    ldapsearch -h <supplier> -s base -b "" "objectclass=*" lastchangenumber
    and
    ldapsearch -h <consumer> -s base -b <base_suffix> "objectclass=*" copiedFrom
    will show you if a replica has fallen out of sync. It won't tell you more than how many changes behind the replica is, though, because pre-5.x changenumbers are sequential integers, not timestamps.
    However, the change that corresponds to the changenumber is clearly visible under the "cn=changelog" suffix. So if you look at the change itself you can see the timestamp on it.
    For more info on the status of replication, you should be able to query the agreements on the supplier. Those live under the "Netscape Machine Data Suffix", which you can also find on the supplier's root DSE:
    ldapsearch -h <supplier> -s base -b "" "objectclass=*" netscapemdsuffix
    And of course the error logs will usually tell you if replication is failing outright.
    I may be off on some of the attribute names, but if you do some investigating along these lines, you should be able to figure it out.

  • Script for Checking the Server Status

    Hi All,
         I just need the script for monitoring the server status through the WLST.My scenario:I have 2 server in Running State.If any one of the server get failed or in not RUNNING state then i use the script for starting that server automatically.I tried some of the script but it is not working properly .If any one have the sample script please share with me.
    Regards,
    Ove.

    Hi Syed,
    Replication state is very easy to see in 4.x and earlier. The last changenumber in the supplier changelog is visible (on the root DSE IIRC), and each consumer suffix has an operational attribute "copiedfrom" that tells you the name of the supplier, the database generation id, and the last change replayed from the supplier.
    So a script that compares the results of
    ldapsearch -h <supplier> -s base -b "" "objectclass=*" lastchangenumber
    and
    ldapsearch -h <consumer> -s base -b <base_suffix> "objectclass=*" copiedFrom
    will show you if a replica has fallen out of sync. It won't tell you more than how many changes behind the replica is, though, because pre-5.x changenumbers are sequential integers, not timestamps.
    However, the change that corresponds to the changenumber is clearly visible under the "cn=changelog" suffix. So if you look at the change itself you can see the timestamp on it.
    For more info on the status of replication, you should be able to query the agreements on the supplier. Those live under the "Netscape Machine Data Suffix", which you can also find on the supplier's root DSE:
    ldapsearch -h <supplier> -s base -b "" "objectclass=*" netscapemdsuffix
    And of course the error logs will usually tell you if replication is failing outright.
    I may be off on some of the attribute names, but if you do some investigating along these lines, you should be able to figure it out.

  • Problem in Sap script for Check printing

    Hi all,
      I have problem in Check printing for FI Module. In Tcode f-58 i am taking the printout of checks. For my user they want to move the main window in upwards, but the sap script <b>F110_PRENUM_CHCK</b> not allowing to move upwards. how to do this, its urgent. plz
    point wil be sure.
    Gowri

    Hi
    Copy the script F110_prenum_chek to some ZCHECK and do the changes.
    Why you can't change the MAIN window towards up?
    You can changes ths ize of it by adjusting the setting of it .
    generally we use some pre printed stationary for this in which all the line item data with doc numbers is printed on top and the check will be in bottom
    and in check we just print the few fields in the right positions.
    <b>Reward points for useful Answers</b>
    Regards
    Anji

  • Script for check table exeststance

    Hi,
    We have 20 instances
    I want to create a shell script like
    1. it will check existence of the table in dba schema
    2. then will check existence of data in the table
    Also send the mail to distro if table is not exits

    I have created one script
    Is it ok ?
    #!/bin/ksh
    for conn in `cat conn_mkt.lst`
    do
    mkt=`echo $conn |cut -d "/" -f1 | cut -b 1-3`
    inst=`echo $conn |cut -d "@" -f2|cut -d "|" -f1`
    owner=`echo $conn |cut -d "/" -f1`
    rm -rf Log/check_table_${mkt}.log
    rm -rf Log/check_count_${mkt}.log
    sqlplus -s ****/****@${inst} <<EOF
    set feed off verify on pages 200 echo on serveroutput on
    spool Log/check_table_${mkt}.log
    select table_name from dba_tables where owner='DBA' and table_name='USR_CONTROL_LOGIN';
    spool off;
    exit
    EOF
    if [ -s Log/check_table_${mkt}.log ]; then
    sqlplus -s ****/****@${inst} <<EOF
    set feed off verify on pages 200 echo on serveroutput on
    spool Log/check_count_${mkt}.log
    select count(1) from TLG_DBA.USR_CONTROL_LOGIN;
    spool off;
    exit;
    EOF
    mailx -s " Table USR_CONTROL_LOGIN is exists in $mkt `cat Log/check_count_${mkt}.log`" <email>
    else
    mailx -s I " Table USR_CONTROL_LOGIN is not exists in $mkt " <email>
    done

  • Script for checking a box in safari menu?

    how does one do this? What I'm looking for is a script that will open Safari and check the "Disable WebCore Caches" box on the "Show Caches Window" submenu in the "Debug" menu, and I'm totally out of my league...thanks
    InteliMac   Mac OS X (10.4.8)  

    Hi Dread
    Had a lot of trouble figuring out where the "Debug" menu was for a start, only
    to find it is a hidden menu within Safari, and to unlock it you need to do as the script says below.
    Type the following into terminal, with Safari closed, then activate Safari
    and theirs the "Debug" menu.
    % defaults write com.apple.Safari IncludeDebugMenu 1
    type the below with Safari closed to deactivate the "Debug" menu.
    % defaults write com.apple.Safari IncludeDebugMenu 0
    ok, got this far, just having a wee issue in getting the check box to change it's value to 1,
    tell application "Safari"
    activate
    end tell
    tell application "System Events"
    tell process "Safari"
    tell menu bar 1
    tell menu bar item "Debug"
    tell menu "Debug"
    click menu item "Show Caches Window"
    --click checkbox "Disable WebCore Caches" of menu item "Show Caches Window" of menu 1 of menu bar item "Debug" of menu bar 1
    --or
    set value of checkbox "Disable WebCore Caches" to 1
    end tell
    end tell
    end tell
    end tell
    end tell
    Budgie

  • Scripts for checking Windows Production Servers Disk Space

    Hi Friends,
    I am looking for some simple scripts (DOS Based or which can be run in restrictive env)by which I can get the Servers Disk Space statistics when I run it from my local machine. My L1 team members are responsible for verifying Disk Space primarily C and D:
    everyday and they send status of the same by logging onto each and every servers. If I can get some simple scripts which can be run easily, that would be really helpful. 
    Thanx in Advance. 
    Keep Rocking :)
    Saurabh

    Hi,
    You may want to check this script out from the TechNet Gallery. 
    http://gallery.technet.microsoft.com/PowerShell-Script-to-fa8305ea
    Cheers.
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Milton Goh
    MCSE, MCSA, MCITP, MOF, ITIL, AIIM SharePoint Specialist
    Blog |
    Twitter

Maybe you are looking for

  • Printing to a shared Windows printer

    I can't seem to print to a shared Vista printer on my home network. I've scoured the Internet and this support site and have run into brick walls. According to the Apple web site: "Shared Windows printers automatically appear in the Mac OS X Printer

  • Get error while exe map:RPE-01008:Recovery of this request is in Progress

    While executing the maps having 250million records fetch from oracle DB itself.traget also having index on PK of two coloumn. I am getting error :RPE-01008: Recovery of this request is in progress. Pls help... Thanks in advance :)

  • Outlook 2010 cached mode cannot see GAL but Outlook 2007 can via Exchange 2010

    Hi, I have a problem similar to this but with a different cause. Our OAB config looks good from both Outlook 2007 and Outlook 2010. Both can see the GAL in non-cached mode but in cached mode only 2007 can see the GAL. In 2010 it's just not there. Eve

  • Nano beeping when connected to computer?

    Recently, my Nano died because the battery was depleted entirely. I plugged it into my computer to begin charging it and a generic picture of a battery appeared and it began beeping, twice every interval. Was this something normal or not?

  • BT Infinity - IP address at Router.

    This question relates to the Internet side of my BT Infinity connection. Does any one know if BT setup Static TCP/IP or use DHCP? If they use DHCP what is the lease time ? I know that I have DHCP running on my LAN side.