Any Dtrace script to log the username/UID, process time & process name

Dear all,
We're looking for "any tools to log the username/UID, process time & process name by individual user or group on the Solaris 10 OS level".
Do you have any Dtrace script ready to do it.
Please advise and comments.
Thanks,
William Lo

Why not use bsm/auditing..?
.7/M.

Similar Messages

  • How do I automatically log the battery percentage and time on my Retina Macbook Pro to an excel spreadsheet? (OSX 10.9.4)

    Hello! So I own a 13" rMBP, and I'm running OSX 10.9.4.
    How do I log my battery percentage with the date, probably down to the hour, preferably to an Excel file?
    I want to track the rate at which my battery discharges, so that in the future I can compare the present rate of discharge with the past and see exactly how much my battery has deteriorated by. I'll take averages over long periods of time to account for, e.g. the fact that watching Netflix drains my battery faster than editing an essay. I also want a solution that uses negligible power in the background.
    I've spent hours looking for an app that both calculates the rate of discharge and keeps all data, but I haven't found any. Eventually I decided that hopefully it isn't too difficult to write an AppleScript or something that simply logs the system clock and battery percentage in tandem every hour or so.
    Thank you for your time!
    Herman

    What Barney said.
    Here is the script to create a CSV text file with
    Date
    Time
    Current Battery Percentage as an integer
    #!/bin/bash
    batterycsv="$HOME/battery.csv"
    export GREP_OPTIONS="--color=never"
    # if you want the percentage sign too, exclude the second egrep
    battpct=$(pmset -g ps | egrep -o "(\d+)%" | egrep -o "\d+")
    datetime=$(date "+%Y-%m-%d %H:%M")
    printf "%s,%s,%s\n" $datetime $battpct >> $batterycsv
    Output on a fully charged MacBook Air to battery.csv will be individual lines of the following format:
    2014-08-09,19:49,100

  • How can I localize the text of process names, task names and user actions within a process?

    I'm very interested in using the capabilities of Adobe LiveCycle Process Management for my project, however I have one rather large concern...   I hope someone here can tell me whether there's a way to address it.
    Since I work for the Government of Canada, I have to meet certain requirements relating to bilingualism of the user interface.  It's my understanding that the Workspace portion of LiveCycle has already has support for French.
    But what about the design of my processes?  How can I display text to a user in the language of their choice when they're interacting with my processes? ... in particular, I'm thinking about the process name, task names, and user actions.
    I hope that this is possible without too much pain.  I imagine this must be a pretty common requirement!
    Thanks in advance to all who respond.

    You can completely change the content of whole pdf by using "renderPDFForm" operation under service "FormsService". in this operation there is Template category where you can set the Locale.
    And if you need to change the other workspace options like Complete, Save as Draft , you can then import workspace ui project and then change apppropriate values.
    Thanks,
    Prashast

  • I don´t get any Java Script referral on the: Exc in ev handl: Error: Bad NPObject as private data, what is then my problem?

    Exc in ev handl: Error: Bad NPObject as private data
    This is the pop up that keeps annoying me in FF. You send me the question: The box that the error is in says something about JavaScript?
    I´m answering NO!

    This issue can be caused by an extension that isn't working properly (McAfee Site Advisor).
    *https://support.mozilla.com/kb/Troubleshooting+extensions+and+themes
    Start Firefox in <u>[[Safe Mode]]</u> to check if one of the extensions is causing the problem (switch to the DEFAULT theme: Firefox (Tools) > Add-ons > Appearance/Themes).
    *Don't make any changes on the Safe mode start window.
    *https://support.mozilla.com/kb/Safe+Mode

  • I have inherited a computer that was used by multiple people to access their gmail. When I click on the username box a string of names are prompted. How do I remove these so only the one or two relevant ones are now prompted?

    I am 5.0 version firefox.

    *Click the (empty) input field to open the drop down list
    *Highlight an entry in the drop down list
    *Press the Delete key (on Mac: Shift+Delete) to remove it.
    Firefox will remember new form data when entered.
    *http://kb.mozillazine.org/Deleting_autocomplete_entries

  • Is there any way to get back the actual downloading process in the bottom line without open in a new window? I always close my browser before the downloading are finished.

    In the previous version of firefox there was a 'tray' on the bottom which always showed the downloading processes. I never open the downloadings in new window, because that is disturbing me. The problem is, if I don't know whether the dowloadings are finished, I can easily abort them.

    No other application can open PageMaker files, only PageMaker. You'd need a copy of PageMaker (and license) and a Mac of ancient vintage, one with a floppy drive. The ancient Mac is needed not just to read the floppied but to run PageMaker which won't run on modern Macs.
    Frankly, if you have a paper copy, scan it and start from that!

  • Long pause at the end of DTrace script.

    Anyone else experience this? When my DTrace scripts end, it is a very long time -- around 5 minutes -- before I get my command prompt back. During this time, other users find their commands hang as well. What is going on? I would like to use DTrace to determine what DTrace is doing, but I fear a collapse of the space-time continuum.
    This does not happen on all our server, just some of the larger Oracle database servers.

    While that's happening, run this DTrace script:
    #!/usr/sbin/dtrace -s
    #pragma D option quiet
    profile:::profile-1001hz
    / arg0 /
        @addr[ arg0 ] = count();
    dtrace:::BEGIN
        printf( "Begin\n" );
    dtrace:::END
        printa( "%@u %a\n", @addr );
    }Start that right before you end your other DTrace script. You might want to redirect the output of that script to a file. Let that run for a good 20 or 30 seconds, break it. If you can't break it, don't worry because it'll just be collecting more data about what's going on and you can break it when your system starts responding again.
    FWIW, I suspect a memory paging issue of some sort. So, it would help to see the output from:
    echo ::memstat | mdb -k

  • Get Log on Username in system session ..

    Hi,
    I'm developing a windows service and i need to get log on username but the problem is service is running under system account so it always return
    system as username, is there any way to get log on username thru service which is running under system account ?? I'm using windows 7
    Thanks and regards.

    Since windows services run in Session 0, I don't think it'll show what Wall.E wants.
    On the other hand, I forgot that the current console user can be found on Win32_ComputerSystem as well. I've tested the following code can get console user name on service.
    private string GetConsoleUser()
    string username = String.Empty;
    ManagementScope scope = new ManagementScope("\\\\.\\root\\cimv2");
    ManagementObjectCollection compQuery = new ManagementObjectSearcher(scope, new SelectQuery("select * from Win32_ComputerSystem")).Get();
    foreach (ManagementObject item in compQuery)
    username = Convert.ToString(item["username"]);
    return username;

  • Script Updater to change username and password

    Can the script updater change the username and password for a bunch of test? I tried using the Global search and replace but it was not able to find the string. Please help?

    If the password is stored in the test it's self you can find it by opening the test file xxx.mom and preform there a search and replace.
    Perhaps it's better to connect the password to a variable by connecting it to a databank source. So the password is stored only once. Saves a lot of maintainance.
    -Theo

  • I want to upgrade from OS X 10.5.8 to Snow Leopard. When trying to back-up to a WD 1 TB external drive, the back-up process stalls at about 4 GB. Grateful for any clues to assist with the backup issue please.

    I want to upgrade from OS X 10.5.8 to Snow Leopard, then to Lion. When trying to back-up to a WD 1 TB external drive, the back-up process stalls at about 4 GB download. I would be very grateful for any clues to assist with the back-up process please.

    That disk is very probably formated as FAT 32, the normal format for PCs. FAT 32 cannot support files larger than 4 GB; also, it corrupts some types of Mac OS files. If you want to securely backup your mac files, you must have a disk prepared for Mac OS.
    Therefore, open Disk Utility, choose again 1 partition for your external disk and, under Options, GUID partition map (it may also be a boot disk for an intel mac), then format it as Mac OS Extended Journaled. Y0u are done.
    If you want to exchange data with PCs, you should chose Master Boot REcord and NTFS format, for this you must use a additional utility like NTFS-3G. But note that mac files may also get corrupt in NTFS format.

  • How to automate the Daily running process

    Here is the senario 
    There are 24 data transfer packages which loads data into SQL Server 2008R2 everyday using a loading tool. There is only one log table is there which shows only package name and the thru date where
    package got loaded into Database
    The package names in log table and package names in loading tool have somewhat different naming format.
    Every day I have to monitor the loading tool to see exactly on which date the packages getting data. (note that out of 25 packages 4 packages always gave t-1  date i.e. yesterday as per business
    logic
    Now I want to automate this process and set an SSRS mail alert for successful execution of packages as per business dates so how can I do that? 
    Thank you in advance

    Ok for this requirement you can do like below
    1. Add custom logging in your packages using EVent Handlers to log the execution details along with package name etc to your custom logging table
    http://consultingblogs.emc.com/jamiethomson/archive/2005/06/11/SSIS_3A00_-Custom-Logging-Using-Event-Handlers.aspx
    2. Create a SSRS report which would pull data from this log table you created and show execution data for packages for the required date range
    3. Add a data driven sunscription in SSRS to deliver the above report through email to your required distribution list
    http://technet.microsoft.com/en-us/library/aa237461(v=sql.80).aspx
    http://jesborland.wordpress.com/2010/08/26/the-power-of-reporting-services-subscriptions-%E2%80%93-data-driven-subscriptions-%E2%80%93-e-mail/
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • How the stock determination process works

    Hi All
    Can any one tell me how the stock determination process works in inventory management?
    if possible give me the steps involved in stock determination process .
    Regards
    M S K

    Hi
    i hope this helps
    http://help.sap.com/saphelp_47x200/helpdata/en/d8/2f3746996611d1b5480000e82de955/frameset.htm
    regards
    maniraj

  • Hello there, is there any way i can log onto Game Center via just my Username as i have forgotten the other details (I made the account when i was 11 - I'm now 14 and have a bad memory)

    The Question says it all really.
    Is there any way i can log onto Game Center via just my Username as i have forgotten the other details (I made the account when i was 11 - I'm now 14 and have a bad memory)?
    I remember my Username on Gamcenter but due to the recent update of iOS7, it is only letting me Sign in through my APPLE ID - which i have forgotten over time. I wish to recover my account recently because I remember purchasing Gems on the game 'Clash of Clans' and I wish I could restart playing the game.
    Many thanks for taking your time to read and answer this question.
    -Gavin Chong.

    Hey xChongy!
    I have an article here that can help you find that forgotten Apple ID:
    Apple ID: How to find your Apple ID
    http://support.apple.com/kb/HT5625
    Thanks for using the Apple Support Communities. Have a good one!
    -Braden

  • Unable to log in to the user account [username] at this time

    My Powerbook G4 is running Mac OS X 10.4.11
    Processor: 1.5 GHz PowerPC G4
    Memory: 768 MB DDR SDRAM
    Startup Disk Macintosh HD
    Serial # 4H511OAJRJ5
    Capacity 74.4 GB
    Available: 2.3 GB
    My problems began when I had a warning message that read something like, “your startup disk is getting full. Delete some files”
    Around the same time my battery was showing signs of being spent (wouldn’t take a full charge) and would shutdown my powerbook in the middle of operation. I replaced the battery within 12 hours, rebooted, and everything seemed normal; I could log in and access all programs, files, photos, music, etc. The error message reappeared to deletes some files. I ran TechTool Deluxes and it suggested repairing my Volume Directory. There were a few suggestions in green and one in red. I accepted the ones in green and made the changes. It reopened TechTool and ran again, this time everything showed up as a “red” (drastic) directory change. I did not accept. I shut down. I rebooted, and that is when my heart sank.
    My account log in screen appeared (I have my master account and a “test” account available) and I entered my log in password. After several moments, the message “You are unable to log in to the user account [username] at this time.” I can log in to my “test” account but I have not been able to access any of my files from that account. Also, my Test account appears to be running Panther instead of Tiger; could that be? Anyway, I read some similar problem posts here and was hopeful that DiskWarrior could help restore me. I purchased and ran it successfully (at least DiskWarrior said it was a success) but I still have the same results.
    I tried to access both my caches folder and my Desktop folder from my “test” account, but these are the error messages I received:
    The folder “Caches” could not be opened because you do not have sufficient access privileges.
    The folder “Desktop” could not be opened because you do not have sufficient access privileges.
    I was shocked to see my Available space was only 2.5 GB. I don’t know how that can be right.
    I’m open to anything to retrieve my files – Any suggestions?

    Around the same time my battery was showing signs of being spent (wouldn’t take a full charge) and would shutdown my powerbook in the middle of operation. I replaced the battery within 12 hours, rebooted, and everything seemed normal; I could log in and access all programs, files, photos, music, etc. The error message reappeared to deletes some files.
    You need to delete some file not try to repair the disk volume. but anyway...
    I ran TechTool Deluxes and it suggested repairing my Volume Directory. There were a few suggestions in green and one in red. I accepted the ones in green and made the changes. It reopened TechTool and ran again, this time everything showed up as a “red” (drastic) directory change. I did not accept. I shut down. I rebooted, and that is when my heart sank.
    You need to develop a full backup plan. Get an external hd and backup to it.
    My account log in screen appeared (I have my master account and a “test” account available) and I entered my log in password. After several moments, the message “You are unable to log in to the user account [username] at this time.”
    Would you be using filevault? Which would mean you need more space.
    I can log in to my “test” account but I have not been able to access any of my files from that account. Also, my Test account appears to be running Panther instead of Tiger; could that be?
    Doubtful. What does apple > about this mac say?
    Anyway, I read some similar problem posts here and was hopeful that DiskWarrior could help restore me. I purchased and ran it successfully (at least DiskWarrior said it was a success) but I still have the same results.
    I tried to access both my caches folder and my Desktop folder from my “test” account, but these are the error messages I received:
    The folder “Caches” could not be opened because you do not have sufficient access privileges.
    The folder “Desktop” could not be opened because you do not have sufficient access privileges.
    Which desktop folder? these are normal messages.
    I was shocked to see my Available space was only 2.5 GB. I don’t know how that can be right.
    Why?
    I’m open to anything to retrieve my files – Any suggestions?
    I buy an external disk with both fireware & usb and use carbon copy cloner to duplicate you hd.
    run batcmd from an admin account to let you change permissions.
    From an administrator account enable root & be careful. This will let you look at any file on the system & delete everything!!!
    Get a new admin id.
    "BatChmod is a Cocoa utility for manipulating file and folder privileges in Mac OS X. It allows the manipulation of ownership as well as the privileges associated to the Owner, Group or others."
    http://www.macchampion.com/arbysoft/Welcome.html
    As an aside, I just noticed that the button to "apply to all enclosed items' is greyed out. I started checking other folders and best I can tell, all folders on my startup volume will not allow me to apply any permission changes to all enclosed items. Think this might have something to do with the alias issue?
    I noticed that my "apply to all enclosed items' button is greyed out too. I use BatChmod fps instead.
    Get the Mac to set up an additional administrative account. You can then change the password on your old account.
    Start with your computer power off. Hold down command-s. Power on your computer.
    Type in the following:
    The first two commands will depend on your release of Mac OS X. Look at what is typed out in the console to determine the exact format.
    # Type the follow two instructions to access the startup disk in read/write. Press return after each command.
    /sbin/fsck -fy
    /sbin/mount -uw /
    cd /var/db
    pwd
    #List all files. The l is a lower case L.
    ls -a
    #The move command acts as a rename command in this format.
    mv -i .applesetupdone .applesetupdone.old
    reboot
    Once you've done that the computer reboots and it's like the first time you used the machine. Your old accounts are all safe. From there you just change all other account passwords in the account preferences!!
    Limnos adds detailed explainations:
    http://discussions.apple.com/message.jspa?messageID=8441597#8441597
    The above the idea came from a post by JoseAranda at September 9, 2006 3:48 AM
    http://www.askdavetaylor.com/howdo_i_reset_my_mac_os_x_admin_rootpassword.html
    You will need to scroll down to see this post. Search for applesetupdone
    Or see:
    http://superpixel.ch/articles/running-setup-assistant-again/
    Once you have a new administrative account, you can change the password of your old administrative account
    blue apple > System Preferences > Accounts

  • I'm trying to access a forum that requires a user name and password.  When I do it on my mac it tells me the password is incorrect but when I do it on my iPad, I can access it without any problem.  I can confirm the username and password are the same

    I am trying to access a forum for which you need a username and password but it keeps telling me the username/password i've entered are incorrect.  Bizarrely, when I enter the same username/password combination on my iPad, it grants access without any problem. 
    What could be causing this, is it an issue with cookies, caches or similar.  How can I resolve it?  The forum administrator is at a loss as to what the problem is.

    Try the following steps in Safari to see if they help:
    1) First try clearing the Safari cache.  To do this pull down the Safari menu and select 'Empty cache...', then try logging into the site again.
    2) If the issue continues then reset Safari by pulling down the Safari menu and select'Reset Safari...'. You will be presented with a list of items that can be reset. I suggest selecting the 'Reset saved names and passwords', and 'Remove all website data' options at a minimum.
    Here is a list of the options and what they do. I pulled it from the Safari help page.
    Clear history:
    Clears the list of webpages you viewed.
    Reset Top Sites:
    Clears any changes you made to Top Sites, such as adding or pinning sites. If you also clear your history, your Top Sites page reverts to showing the webpage previews displayed when you first installed Safari.
    Remove all webpage preview images:
    Clears any thumbnail images Safari saved of webpages you viewed.
    Clear the Downloads window:
    Clears the list of files you downloaded from websites. Only the names are removed; the files themselves are still on your disk until you remove them.
    Remove all website icons:
    Removes website icons, which are small graphics that help identify sites on the Internet. You see them in the Safari address field and bookmarks list, and other places. These icons are stored on your computer.
    Remove saved names and passwords:
    Removes user names and passwords that Safari automatically fills in at websites that require them (if the AutoFill feature is turned on).
    Remove other AutoFill form text:
    Removes some personal information, such as telephone numbers, that Safari uses to automatically fill in forms on webpages (if the AutoFill feature is turned on). Removing AutoFill information does not remove information from your address book.
    Close all Safari windows:
    If you don’t close all Safari windows, someone could use the Back and Forward buttons to view the webpages you visited.
    Reset all location warnings:
    Clears any information websites saved about your location.
    Remove all website data:
    Removes cookies, tracking information, and other data that websites stored on your computer.

Maybe you are looking for

  • How to know how many rows including headers and footers does subreport has from Main Report

    Hi, we are sturuggling with subreports. Main report has 3 subreports, each subreport is inplmented in a group header(3 subreports and 3 group headers). We would like to print a group header under subreport as a column header every page, and need a pa

  • Problem Installing Developer Suite on WIndows Vista

    Hi! i'm a student of computer science, and i need to install developer suite for a proyect i need to do for one of my classes. I have a problem installing developer suit on Windows Vista. After i download and unzip both disk, i run the setup from the

  • Multiple videos in one window

    Just starting out with captivate and have a query I'm hoping someone can answer - Is it possible to have one video window/player with different buttons next to it, and depending on what button the user selected, it would play a different video? For e

  • Trouble on monitor switch

    I currently have two computers (PC + Mac Mini Server) and two monitors. The PC is hooked up using two DVI cables while my Mac is using HDMI for the main monitor and Thunderbolt to HDMI for the secondary. Many times I'll use my PC on the main monitor

  • Can we reuse the view in BSP's

    Hi, I created some views but in almost all iam using the same UI elements,for that i need to create a commom view,and i need to use it in other views, but my question is is that possible ?if possible what are the ways for that? whats are the pitfalls