Howto to get the year timestamp in syslog and logadm files

5.10 Generic_141414-10 sun4u sparc
Howto to get the year timestamp in syslog and logadm
We have to keep logs files for a long time, I was exploring logs in /var/adm/secure and noticed that log files over a year old did not have a year time stamp, they are in this format:
Nov 12 09:09:16
And on the face of it. /varlog/syslog is the same, I thought no problem, there will be something in syslog.conf or logadm.conf I change and it will be fixed, but I cannot find any options to change this, how do I get the year in my log files?
The "date" command does output the year:
Friday, September 14, 2012  7:57:36 AM

My guess is that the fields in a message logged by syslog are fixed, so you can't add a field to it.
The reason for this is simply that there might be other applications parsing your syslog messages, or there might be other systems syslogging to your system, and that would break if you would add fields.
The easiest workaround is probably to keep better track of your logs by either implementing an annual rotation of them from crontab, or log the date using the "logger" command on a regular basis.
A third option would be to look at syslog-ng or rsyslog, which is more flexible when it comes to storing logs, and among other things can store them into a SQL db..
.7/M.

Similar Messages

  • When I run the Free exec Download, I get the Windows XP "thud" sound and message "File is corrupt." I downloaded again and got same error.

    I am running Windows XP Servicepack 3. I clicked the Free Download, saved it using IE8, and then tried to run it. A couple of seconds after I pressed ENTER on the filename, I got that infamous Windows XP "thud" sound along with the message that the file is corrupt.

    Hi knobman- I'm not sure why the file would be corrupt. I would recommend downloading from the official Mozilla site only. You can click this link to get the latest and best version [just select 'Windows' and it should go]:
    http://www.mozilla.org/en-US/firefox/new/
    Hope that helps!

  • Get the year out of a date

    I have a date '12/02/1989'. how do i get the year out of this date.
    or take a sysdate and get the year out of it.
    Thanks

    this?
    SQL> ed
    Wrote file afiedt.buf
      1  SELECT EXTRACT (YEAR FROM TO_DATE('12/02/1989','mm/dd/yyyy')) year
      2* FROM dual
      3  /
          YEAR
          1989
    or this/
    SQL> ed
    Wrote file afiedt.buf
      1  SELECT to_char( TO_DATE('12/02/1989','mm/dd/yyyy'),'YYYY') year
      2* FROM dual
    SQL> /
    YEAR
    1989too late
    Message was edited by:
    devmiral

  • HOWTO Get the text of "combo box" and "labe" controls with JavaAccessBridge

    HOWTO Get the text of "combo box" and "labe" controls with JavaAccessBridge.
    Please help,
    I'm trying to use the Java Access Bridge (JAB) 2.1 to get the text in Java Applet controls. I've been able to use the sample code in AccessInfo.cpp sample that comes with JAB to get text from "text" controls in a Java Applet. To clarify, I am referring to the "role" in the AccessibleContextInfo struct being set to "text" or "combo box" or "label".
    The problem is, when I use the AccessInfo.cpp sample to get text from a "combo box", the accessibleText data member comes back as FALSE, and thus any of the JAB text functions like GetAccessibleTextInfo fail to get any text information from "combo box" or "label" controls.
    I've also tried GetCurrentAccessibleValueFromContext on the "combo box" and "label" controls, but the text returned is empty.
    Can anyone help?

    I have new information in regards to this issue. A contact from Sun did get to me in email and relayed that that "label" objects store their text in the "name" data member of the AccessibleContext structure. This was a big help.
    But I'm still stuck trying to get information from "combo box" and other controls, like "push button". The contact said, the Java Access Bridge does not provide all the information because it is already implemented by other interfaces like AccessibleComponent, AccessibleAction, or AccessibleSelection. The contact did not allude to whether these opther interfaces can be used along side the Java Access Bridge or not. So, I'm left a step closer to the goal, but still stuck without the full solution.
    Can one take the Java Access Bridge functions, like say those used in the Ferret sample, and close the gap to get text back from "combo box", "push button", and other controls by using some other API in conjunction?

  • If I get the iphone 5 with plan and contract with 2 years or 3 can i pay $25 each mouth for just ulimited texting and 250 min of talking.

    If I get the iphone 5 with plan and contract with 2 years or 3 can i pay $25 each mouth for just ulimited texting and 250 min of talking.

    Ask the carrier instead of making yourself look like a fool by posting such a question in a user to user technical support forum.

  • Recently i have been getting the color wheel a lot and it is screwing with my happiness.  Any thoughts on how to clean the computer up so this stops?

    Recently i have been getting the color wheel a lot and it is screwing with my happiness.  Any thoughts on how to clean the computer up so this stops?

    Back up all data immediately as your boot drive may be failing.
    If you have more than one user account, these instructions must be carried out as an administrator.
    Triple-click anywhere in the line below on this page to select it:
    syslog -k Sender kernel -k Message CReq 'Channel t|GPU D|I/O|Previous Sh' | tail | open -ef
    Copy the selected text to the Clipboard (command-C).
    Launch the Terminal application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid.
    Paste into the Terminal window (command-V).
    The command may take a noticeable amount of time to run. Wait for a new line ending in a dollar sign (“$”) to appear.
    A TextEdit window will open with the output of the command. If the command produced no output, the window will be empty. Post the contents of the TextEdit window (not the Terminal window), if any — the text, please, not a screenshot. The title of the window doesn't matter, and you don't need to post that.

  • How do I get the last changed date & time of a file in app server?

    Hi Experts,
    How do I get the last changed date & time of a file in app server?
    Thanks!
    - Anthony -

    Hi,
    that's what I use...
      CALL 'C_DIR_READ_FINISH'.             " just to be sure
      CALL 'C_DIR_READ_START' ID 'DIR' FIELD p_path.
      IF sy-subrc <> 0.
        EXIT. "Error
      ENDIF.
      DO.
        CLEAR l_srvfil.
        CALL 'C_DIR_READ_NEXT'
          ID 'TYPE'   FIELD l_srvfil-type
          ID 'NAME'   FIELD l_srvfil-file
          ID 'LEN'    FIELD l_srvfil-size
          ID 'OWNER'  FIELD l_srvfil-owner
          ID 'MTIME'  FIELD l_mtime
          ID 'MODE'   FIELD l_srvfil-attri.
    *    l_srvfil-dir = p_path .
        IF sy-subrc = 1.
          EXIT.
        ENDIF." sy-subrc <> 0.
        PERFORM p_to_date_time_tz
          USING    l_mtime
          CHANGING l_srvfil-mod_time
                   l_srvfil-mod_date.
        TRANSLATE l_srvfil-type TO UPPER CASE.               "#EC TRANSLANG
        PERFORM translate_attribute CHANGING l_srvfil-attri.
        CHECK:
          NOT l_srvfil-file = '.',
          l_srvfil-type = 'D' OR
          l_srvfil-type = 'F' .
        APPEND l_srvfil TO lt_srvfil.
      ENDDO.
      CHECK NOT lt_srvfil IS INITIAL.
      pt_srvfil = lt_srvfil.
    FORM p_to_date_time_tz  USING    p_ptime  TYPE p
                            CHANGING p_time   TYPE syuzeit
                                     p_date   TYPE sydatum.
      DATA:
        l_abaptstamp TYPE timestamp,
        l_time       TYPE int4,
        l_opcode     TYPE x VALUE 3,
        l_abstamp    TYPE abstamp.
      l_time = p_ptime.
      CALL 'RstrDateConv'
        ID 'OPCODE' FIELD l_opcode
        ID 'TIMESTAMP' FIELD l_time
        ID 'ABAPSTAMP' FIELD l_abstamp.
      l_abaptstamp = l_abstamp.
      CONVERT TIME STAMP l_abaptstamp TIME ZONE sy-zonlo INTO DATE p_date
          TIME p_time.
    ENDFORM.                    " p_to_date_time_tz
    Regards,
    Clemens

  • Concerning Epson Printer 4880: after changing the Ink from Photo Black to Matte Black I'm not getting the Epson Software in Photoshop and Lightroom. I can not select the paper medium, I don't see my profiles. What is wrong?

    Concerning Epson Printer 4880: after changing the Ink from Photo Black to Matte Black I'm not getting the Epson Software in Photoshop and Lightroom. I can not select the paper medium, I don't see my profiles. What is wrong?

    That is priceless!!!  Thanks!  I sure needed a good laugh after spending/wasting hours & days trying to either get my c6280 to give up on its Ink System Failure fixation, or find a decent replacement.  Unfortunately I need the Smart Web Printing feature that I guess only HP has, or I'd try a different brand. And now even HP has very few models with that available.
     My error msg is a little different from those previously stated, but close:  0xc18a0201.  Even tho there were frustrations with my c6280, I did like several of its unique features which are hard to find now under $100.  I hate how HP (& I suppose other brands also) are CONSTANTLY changing models & then of course ink cartridges.
    Oh heavens, I've had the c6280 a whopping 2 1/2 years!   I'm sure they want us poor slobs to have to buy a new one every year & a day!  To say nothing of the exorbitant prices for ink.  And now if this one is really dead in the water, I have SIX unused #02 ink cartridges which I cannot return---I got them in a combo pack, & for some reason have wound up with THREE lite pink & THREE lite blue cartridges, while having to buy extras of the other colors, that ran out before the others!!!   Yeah, & what's with that not being able to print in BLACK if a color runs out????
    Anyway I really loved your essay!   It's a classic!  And says it all!  I hate that we have to be 'slaves' to the electronic 'wonders'!!!

  • I keep getting the "connect to itunes" screen and have to restore my ipad.  it will also drop the wifi connection every few mintues.  what can be causing this?

    I keep getting the "connect to itunes" screen and have to connect to itunes and do a restore on it.  It will not pick up my ipad so I either have to do a restore or restore to new and it will work fine for a day or so except for dropping the wifi connection.  What can be causing this?  I have had this pad since January of this year and have not had any problems until recently. 

    If you have to keep restoring your iPad with iTunes repeatedly and there is no change after restoring as a new iPad or not from the iPad's backup, your iPad has a major problem - likely a hardware problem. The iPad includes a one year warranty. You can call AppleCare or make an appointment at an Apple store if there is one nearby.

  • Over the years I have installed and upgraded Photoshop and Lightroom

    Over the years I have installed and upgraded Photoshop and Lightroom, but unfortunately my hard drive crashed and I was wondering how I could reinstall them without the apps?

    Are you saying you visited the My Account link at Adobe.com, per Curt's suggestion, and they don't have your serial number info on file, and you don't have your original media or serial number info?
    If that's truly the case, get out your credit card because you're basically out of luck.  It's really no one's responsibility but yours to manage your purchase information.
    If your software loss was substantial, monetarily, you might call your insurance company.  I have no idea whether they pay under those kinds of circumstances, but it's worth a check.  But most folks have pretty high deductables on their homeowners' policies.
    If you DO have your serial number, there are ways to get most older versions of Adobe Creative Suite software from Adobe's web site.
    -Noel

  • How to get the values of all elements and sub elements from  following xml

    how to get the values of all elements and sub elements from following xml...
    <?xml version="1.0" encoding="UTF-8" ?>
    <List_AML_Finacle xmlns="http://3i-infotech.com/Cust_AML_Finacle.xsd"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://3i-infotech.com/Cust_AML_Finacle.xsd List_AML_Finacle.xsd">
    <TransactionID>TransactionID</TransactionID>
    <Match>
    <Src_Matched_Field>Src_Matched_Field</Src_Matched_Field>
    <List_Matched_Field>
    <FSFM_Matches>
    <NUMBER>NUMBER</NUMBER>
    <TERROR>TERROR</TERROR>
    <TU>TU</TU>
    <NAMEU>NAMEU</NAMEU>
    <DESCRIPT>DESCRIPT</DESCRIPT>
    <KODCR>KODCR</KODCR>
    <KODCN>KODCN</KODCN>
    <AMR>AMR</AMR>
    <ADDRESS>ADDRESS</ADDRESS>
    <SD>SD</SD>
    <RG>RG</RG>
    <ND>ND</ND>
    <VD>VD</VD>
    <GR>GR</GR>
    <YR>YR</YR>
    <MR>MR</MR>
    <CB_DATE>CB_DATE</CB_DATE>
    <CE_DATE>CE_DATE</CE_DATE>
    <DIRECTOR>DIRECTOR</DIRECTOR>
    <FOUNDER>FOUNDER</FOUNDER>
    <TERRTYPE>TERRTYPE</TERRTYPE>
    </FSFM_Matches>
    <OfacMatchDetails>
    <UID>UID</UID>
    <TITLE>TITLE</TITLE>
    <SDNTYPE>SDNTYPE</SDNTYPE>
    <REMARKS>REMARKS</REMARKS>
    <ID_UID>ID_UID</ID_UID>
    <IDTYPE>IDTYPE</IDTYPE>
    <IDNUMBER>IDNUMBER</IDNUMBER>
    <IDCOUNTRY>IDCOUNTRY</IDCOUNTRY>
    <ISSUEDATE>ISSUEDATE</ISSUEDATE>
    <EXPIRATIONDATE>EXPIRATIONDATE</EXPIRATIONDATE>
    <ADDRESS1>ADDRESS1</ADDRESS1>
    <ADDRESS2>ADDRESS2</ADDRESS2>
    <ADDRESS3>ADDRESS3</ADDRESS3>
    <CITY>CITY</CITY>
    <STATEORPROVINCE>STATEORPROVINCE</STATEORPROVINCE>
    <POSTALCODE>POSTALCODE</POSTALCODE>
    <COUNTRY>COUNTRY</COUNTRY>
    </OfacMatchDetails>
    </List_Matched_Field>
    </Match>
    </List_AML_Finacle>

    avoid multi post
    http://forum.java.sun.com/thread.jspa?threadID=5249519

  • I am experiencing some major problems with my MacBook Pro. I have had some issues with it turning on/off at random times, but today, when starting, I get the grey start-up screen and a recovery bar. After filling in approx 1/4 of the way, the machine dies

    I am experiencing some major problems with my MacBook Pro. I have had some issues with it turning on/off at random times, but today, when starting, I get the grey start-up screen and a recovery bar. After filling in approx 1/4 of the way, the machine dies. After starting it in recovery mode, it will not allow me to download OS X Mavericks- it says the disk is locked. Any ideas? I do not have a back-up and do not want to erase everything before I have explored my options. Help?

    try forcing internet recover, hold 3 keys - command, option, r - you should see a spinning globe
    most people will tell you to do both pram and smc resets (google) and if you still have issues, either clean install (easy) or troubleshoot (hard)

  • I keep getting the message, "Windows cannot find 'c:\Program Files (x86)\Mozilla Firefox\firefox.exe'. Make sure you typed the name correctly, and then try again." I get it when I either try to open it from the Start menu or from the desktop icon.

    I've just installed Firefox on my laptop and keep getting the message, "Windows cannot find 'c:\Program Files (x86)\Mozilla Firefox\firefox.exe'. Make sure you typed the name correctly, and then try again." I get this message whenever I either try to open it from the Start menu or from the desktop icon. I've never gotten it to work and even uninstalled it and then redownloaded it and still cannot get it to open. Any help would be greatly appreciated!!!!

    Are you installing from the official site? http://www.mozilla.com/firefox
    If you use Windows Explorer (My Computer) to check that path, is the Mozilla Firefox folder there? That is the normal installation location, but I think it's worth checking.
    If the folder isn't there or firefox.exe is not in it, I wonder whether some other software might be interfering. You might want to run some supplemental security scans. These two tools are highly regarded:
    Malwarebytes Anti-malware : http://www.malwarebytes.org/products/malwarebytes_free
    SUPERAntiSpyware : http://www.superantispyware.com/

  • HT204053 When I initially try to sign in to iCloud, I get the "Account not verified" screen and I am told to check my email for instructions to verify.  No email is ever sent. My ID and password work on all other Apple app's.  Why not for iCloud?

    When I initially try to sign in to iCloud, I get the "Account not verified" screen and I am told to check my email for instructions to verify.  No email is ever sent. My ID and password work on all other Apple app's.  Why not for iCloud?

    I've tried both. First, I tried on my pc, where iTunes had installed iCloud when it last updated. I have iTunes installed on this computer (and on my iPad and iPhone), but that wasn't the issue.
    So I went online, thinking I needed a separate iCloud Apple ID, but it prompted me for my current Apple ID and gave me the message about my ID being "valid" but not an iCloud account," which, lol, was what it had asked me to do in order to create one. I checked, and at least one other user is having the same issue. I'll attempt to copy/paste the Support request url: https://discussions.apple.com/thread/4430653?tstart=0
    Thank you for any help you can give.
    Trish

  • How can I get the cursor's position in a opened file and display a menu?

    Hello,
    I want to make a program by which I will be able to display a panel/pops up menu at the corsor's current position, (In any text/doc file or in the desktop, we can display a menu by right click of the mouse.) Now I want my program to do the same task.
    More clearly-
    1. First I would save some words or sentences in a file(aa.txt).
    2. Then I would open another text file/ a word/ excel/ or any other editor( bb.txt / cc.doc / dd.xls / ee.html ).
    3. While editing or writing something in the opened file, if I click the right mouse button/ press a key (ctrl+space), a menu will appear containing the sentences I saved in the file(aa.txt) previously.
    My program will tell me the cursor's position in bb.txt / cc.doc / dd.xls / ee.html that i opened. And display a menu. my problem is not reading / writing in a file.
    My problem is how can I get the cursor's position in a opened file display a menu at that position by a mouse/key action*.
    Would you please help me on this regard.
    Thanks

    DrClap wrote:
    I think the OP wants to start up an application like MS Word and then operate it from a Java program.Doesn't The Monkey's Paw do that? What a second, according to Wikipedia:
    [http://en.wikipedia.org/wiki/The_Monkey%27s_Paw]
    <quote>
    ...the paw of a dead monkey is a talisman that grants its possessor three wishes, but the wishes come with an enormous price.
    The moral of the story is contained in this description of the paw: "It had a spell put on it by an old fakir," said the sergeant-major, "a very holy man. He wanted to show that fate ruled people's lives, and that those who interfered with it did so to their sorrow."
    </quote>
    So I guess that a non-sequitor ... or is it?

Maybe you are looking for