How to disable/ set logging level /preferences PER Mac OS X application?





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}







4















I find my Mac's syslogd "Cosole" logs become unusable when some badly written app (PathFinder.app in this case) incessantly spews into syslogd all day long.. I read somewhere that you could disable logging PER app by..





  1. Creating an alias to the executable bundle inside the App "package", and then ONLY launching that alias FROM the terminal. The process was... Browse to /Applications/ObnoxiousLogger.app, right click, "Show Package Contents", and then Browse to...



    /Applications/ObnoxiousLogger.app/Contents/MacOS/ObnoxiousLogger



    Then you make the alias through the GUI and remember to always launch the app from that alias, again ONLY via the terminal.



    This is annoying, as you HAVE to create the alias via the Finder (symlinking doesn't work, and there is no way to create an alias via the terminal). And if it gets launched ANY other way, youre back to square one, logorrhea.. This method DID work, but for a very short amount of time.



  2. It would seem you could set this via a launchctl command, or a plist variable, but this isn't an app that is opened by launchd, and launchd's documentation is so all-over the place, but I guess this is a possibility, I suppose.


  3. I saw something about sending the log to /dev/null, but it wasn't clear if this was some kind of syslogd pipe, or command, or an /etc/syslogd.conf setting, or what...



Please let me know if you have a surefire way to selectively silence logging per application, or even better, increase or decrease the logging verbosity, per process / command, etc in Mac OS X.










share|improve this question

























  • Consider accepting answers to your questions if they solve the issue by clicking the checkmark next to them, or alternatively edit your questions or comment on answers why they don't work for you.

    – Daniel Beck
    Jun 5 '11 at 16:43


















4















I find my Mac's syslogd "Cosole" logs become unusable when some badly written app (PathFinder.app in this case) incessantly spews into syslogd all day long.. I read somewhere that you could disable logging PER app by..





  1. Creating an alias to the executable bundle inside the App "package", and then ONLY launching that alias FROM the terminal. The process was... Browse to /Applications/ObnoxiousLogger.app, right click, "Show Package Contents", and then Browse to...



    /Applications/ObnoxiousLogger.app/Contents/MacOS/ObnoxiousLogger



    Then you make the alias through the GUI and remember to always launch the app from that alias, again ONLY via the terminal.



    This is annoying, as you HAVE to create the alias via the Finder (symlinking doesn't work, and there is no way to create an alias via the terminal). And if it gets launched ANY other way, youre back to square one, logorrhea.. This method DID work, but for a very short amount of time.



  2. It would seem you could set this via a launchctl command, or a plist variable, but this isn't an app that is opened by launchd, and launchd's documentation is so all-over the place, but I guess this is a possibility, I suppose.


  3. I saw something about sending the log to /dev/null, but it wasn't clear if this was some kind of syslogd pipe, or command, or an /etc/syslogd.conf setting, or what...



Please let me know if you have a surefire way to selectively silence logging per application, or even better, increase or decrease the logging verbosity, per process / command, etc in Mac OS X.










share|improve this question

























  • Consider accepting answers to your questions if they solve the issue by clicking the checkmark next to them, or alternatively edit your questions or comment on answers why they don't work for you.

    – Daniel Beck
    Jun 5 '11 at 16:43














4












4








4


4






I find my Mac's syslogd "Cosole" logs become unusable when some badly written app (PathFinder.app in this case) incessantly spews into syslogd all day long.. I read somewhere that you could disable logging PER app by..





  1. Creating an alias to the executable bundle inside the App "package", and then ONLY launching that alias FROM the terminal. The process was... Browse to /Applications/ObnoxiousLogger.app, right click, "Show Package Contents", and then Browse to...



    /Applications/ObnoxiousLogger.app/Contents/MacOS/ObnoxiousLogger



    Then you make the alias through the GUI and remember to always launch the app from that alias, again ONLY via the terminal.



    This is annoying, as you HAVE to create the alias via the Finder (symlinking doesn't work, and there is no way to create an alias via the terminal). And if it gets launched ANY other way, youre back to square one, logorrhea.. This method DID work, but for a very short amount of time.



  2. It would seem you could set this via a launchctl command, or a plist variable, but this isn't an app that is opened by launchd, and launchd's documentation is so all-over the place, but I guess this is a possibility, I suppose.


  3. I saw something about sending the log to /dev/null, but it wasn't clear if this was some kind of syslogd pipe, or command, or an /etc/syslogd.conf setting, or what...



Please let me know if you have a surefire way to selectively silence logging per application, or even better, increase or decrease the logging verbosity, per process / command, etc in Mac OS X.










share|improve this question
















I find my Mac's syslogd "Cosole" logs become unusable when some badly written app (PathFinder.app in this case) incessantly spews into syslogd all day long.. I read somewhere that you could disable logging PER app by..





  1. Creating an alias to the executable bundle inside the App "package", and then ONLY launching that alias FROM the terminal. The process was... Browse to /Applications/ObnoxiousLogger.app, right click, "Show Package Contents", and then Browse to...



    /Applications/ObnoxiousLogger.app/Contents/MacOS/ObnoxiousLogger



    Then you make the alias through the GUI and remember to always launch the app from that alias, again ONLY via the terminal.



    This is annoying, as you HAVE to create the alias via the Finder (symlinking doesn't work, and there is no way to create an alias via the terminal). And if it gets launched ANY other way, youre back to square one, logorrhea.. This method DID work, but for a very short amount of time.



  2. It would seem you could set this via a launchctl command, or a plist variable, but this isn't an app that is opened by launchd, and launchd's documentation is so all-over the place, but I guess this is a possibility, I suppose.


  3. I saw something about sending the log to /dev/null, but it wasn't clear if this was some kind of syslogd pipe, or command, or an /etc/syslogd.conf setting, or what...



Please let me know if you have a surefire way to selectively silence logging per application, or even better, increase or decrease the logging verbosity, per process / command, etc in Mac OS X.







macos console launchd syslogd asl






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited May 18 '11 at 17:54









Daniel Beck

93.6k12236288




93.6k12236288










asked May 2 '11 at 22:17









mralexgraymralexgray

5332520




5332520













  • Consider accepting answers to your questions if they solve the issue by clicking the checkmark next to them, or alternatively edit your questions or comment on answers why they don't work for you.

    – Daniel Beck
    Jun 5 '11 at 16:43



















  • Consider accepting answers to your questions if they solve the issue by clicking the checkmark next to them, or alternatively edit your questions or comment on answers why they don't work for you.

    – Daniel Beck
    Jun 5 '11 at 16:43

















Consider accepting answers to your questions if they solve the issue by clicking the checkmark next to them, or alternatively edit your questions or comment on answers why they don't work for you.

– Daniel Beck
Jun 5 '11 at 16:43





Consider accepting answers to your questions if they solve the issue by clicking the checkmark next to them, or alternatively edit your questions or comment on answers why they don't work for you.

– Daniel Beck
Jun 5 '11 at 16:43










5 Answers
5






active

oldest

votes


















5














You may want to look at asl.conf(5) which allows you to ignore/process log messages on quite a fine-grained level.



Something like:



? [= Sender ObnoxiousLogger] ignore


should do the trick. If you still want to see the more serious messages from the obnoxious sender, something along the lines of:



? [= Sender ObnoxiousLogger] [> Level error] ignore


might be more appropriate.



Note: after editing /etc/asl.conf, don't forget to kill -HUP your syslogd.






share|improve this answer


























  • Thx for asl.conf. An ObnoxiousLogger can have an even severer effect than "stealing CPU": Preventing system sleep, as those frequent disk writes continuously reset the sleep timer! My culprit is Google Chrome, both on Mac & Win. I hope it's an innocent bug. But it's hard to believe: 1) Having users online all the time is a mayor business goal, as online-time==ad-time. Tempting to achieve this by tempering with the device sleep mechanism… 2) A Chrome bug reported 2012-07-28 still not fixed.

    – porg
    Aug 7 '14 at 11:17













  • My system.log contains unwanted lines in this format: <date> <hostname> <sender>: <function or object id> <message> <sender> comes in different flavors: [some kind of hexadecimal id].com.google.Chrome[decimal PID] Google Chrome[decimal PID] Q.1) How do I match Google Chrome as sender within conf.asl? Used ? [= Sender <sendername>] ignore. As <sendername> I tried: Chrome, Google Chrome, "Google Chrome", com.google.Chrome, .com.google.Chrome Q.2) What's the correct commandline to notify syslogd? Used sudo kill -HUP pidOfMySylogd. What shall be the exit code? In my case it was nil.

    – porg
    Aug 7 '14 at 11:47



















3














Just create a File » New Database Search…, looking for Facility contains "console" and Sender does not contain "ObnoxiousLogger", and ignore the default Console Messages database search?



enter image description here





You can use the following command to set individual log filtering levels for specific processes:



syslog -c processname -d


This will set the log level of currently running instances of processname to all messages of debug level or higher. the possible levels are each character of pacewnid: (Panic), Alert, Critical, Error, Warning, Notice, Info, and Debug.



So, to only enable logging of warning messages and higher for Finder, use:



syslog -c Finder -w


You will need to repeat this whenever you restart the process in question.






share|improve this answer


























  • I have similar searches setup for just stuff I want to see.. but is there any way to prevent "ObnoxiousLogger" from ever hitting the syslog facility, at all? My concern: all that chatter must be robbing at least a few cpu cycles, no?

    – mralexgray
    May 19 '11 at 16:38











  • @mralexgray Added some further research to my answer. Unfortunately, I don't have an obnoxiously logging process running right now, so I cannot perform any reliable testing. Answer is therefore primarily based on man syslog.

    – Daniel Beck
    May 19 '11 at 17:32



















1














The proposed solution by Torsten doesn't seem to work. It seems adding those configuration to the global asl.conf doesn't have the expected effect the way the rules are handled.



A solution to this problem, I found, after I almost went berserk fighting with the main asl.conf, is to use separate asl/* configuration files for each filter. Those files must be stored in /etc/asl/



e.g. to ignore "com.example.Sender" and filter its log spam from system.log we could create a file /etc/asl/com.example.Sender with the following content:



? [= Sender com.example.Sender] claim only
* ignore


The claim only for the match (a "Sender" in the example) causes the rules in the master asl.conf to be ignored which means things won't end up in system.log.



Don't forget to restart syslogd, of course.






share|improve this answer

































    1














    I am on MacOS Mojave (10.14.3) and this post was helpful to me so I want to clarify what worked for me as I have not seen it all together in a single place. In my case I wanted to filter out Microsoft OneNote messages which were constantly spamming my system.log file at a rate of 5 a second. Sample message:



    Feb  3 22:52:49 MyMacMini-2 Microsoft OneNote[393]: [ACT]:[TASKSCHEDULER]:[Info]:opQueue=0x6000012d7760 after call to waitUntilAllOperationsAreFinished


    So I edited /etc/asl.conf with the following rule:



    # Disable Microsoft OneNote logging as is filling up system.log!
    ? [= Sender Microsoft OneNote] ignore


    You need to add this before the line that says:



    # Rules for /var/log/system.log


    As otherwise it will not work. Then just restart syslogd with this command and the messages should be gone from system.log:



    sudo killall -HUP syslogd





    share|improve this answer































      0














      I posted a more detailed answer at AskDifferent.



      Put in /etc/asl.conf a rule like the following



      ? [= Sender foobar] [<= Level error] notify com.apple.foobar
      op key value op key value
      -----query 1----- -----query 2---- ---------action--------


      In order to ignore messages in both system.log and in Console.app, you should add rules to ignore messages before the following comment in asl.conf.



      # Flat file configurations formerly in syslog.conf



      Example with modifier S, which ignores messages matching that substring from SIMBL Agent.



      ? [= Sender SIMBL Agent] [S= Message warning: failed to get scripting definition from] ignore
      op -key-- ---value--- mod --key-- --------------------value-----------------------
      --------query 1------- -----------------------query 2------------------------------- action


      After adding a rule restart the daemon with sudo killall HUP syslogd.



      Tested successfully in OS X 10.8.5.






      share|improve this answer


























        Your Answer








        StackExchange.ready(function() {
        var channelOptions = {
        tags: "".split(" "),
        id: "3"
        };
        initTagRenderer("".split(" "), "".split(" "), channelOptions);

        StackExchange.using("externalEditor", function() {
        // Have to fire editor after snippets, if snippets enabled
        if (StackExchange.settings.snippets.snippetsEnabled) {
        StackExchange.using("snippets", function() {
        createEditor();
        });
        }
        else {
        createEditor();
        }
        });

        function createEditor() {
        StackExchange.prepareEditor({
        heartbeatType: 'answer',
        autoActivateHeartbeat: false,
        convertImagesToLinks: true,
        noModals: true,
        showLowRepImageUploadWarning: true,
        reputationToPostImages: 10,
        bindNavPrevention: true,
        postfix: "",
        imageUploader: {
        brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
        contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
        allowUrls: true
        },
        onDemand: true,
        discardSelector: ".discard-answer"
        ,immediatelyShowMarkdownHelp:true
        });


        }
        });














        draft saved

        draft discarded


















        StackExchange.ready(
        function () {
        StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f278231%2fhow-to-disable-set-logging-level-preferences-per-mac-os-x-application%23new-answer', 'question_page');
        }
        );

        Post as a guest















        Required, but never shown

























        5 Answers
        5






        active

        oldest

        votes








        5 Answers
        5






        active

        oldest

        votes









        active

        oldest

        votes






        active

        oldest

        votes









        5














        You may want to look at asl.conf(5) which allows you to ignore/process log messages on quite a fine-grained level.



        Something like:



        ? [= Sender ObnoxiousLogger] ignore


        should do the trick. If you still want to see the more serious messages from the obnoxious sender, something along the lines of:



        ? [= Sender ObnoxiousLogger] [> Level error] ignore


        might be more appropriate.



        Note: after editing /etc/asl.conf, don't forget to kill -HUP your syslogd.






        share|improve this answer


























        • Thx for asl.conf. An ObnoxiousLogger can have an even severer effect than "stealing CPU": Preventing system sleep, as those frequent disk writes continuously reset the sleep timer! My culprit is Google Chrome, both on Mac & Win. I hope it's an innocent bug. But it's hard to believe: 1) Having users online all the time is a mayor business goal, as online-time==ad-time. Tempting to achieve this by tempering with the device sleep mechanism… 2) A Chrome bug reported 2012-07-28 still not fixed.

          – porg
          Aug 7 '14 at 11:17













        • My system.log contains unwanted lines in this format: <date> <hostname> <sender>: <function or object id> <message> <sender> comes in different flavors: [some kind of hexadecimal id].com.google.Chrome[decimal PID] Google Chrome[decimal PID] Q.1) How do I match Google Chrome as sender within conf.asl? Used ? [= Sender <sendername>] ignore. As <sendername> I tried: Chrome, Google Chrome, "Google Chrome", com.google.Chrome, .com.google.Chrome Q.2) What's the correct commandline to notify syslogd? Used sudo kill -HUP pidOfMySylogd. What shall be the exit code? In my case it was nil.

          – porg
          Aug 7 '14 at 11:47
















        5














        You may want to look at asl.conf(5) which allows you to ignore/process log messages on quite a fine-grained level.



        Something like:



        ? [= Sender ObnoxiousLogger] ignore


        should do the trick. If you still want to see the more serious messages from the obnoxious sender, something along the lines of:



        ? [= Sender ObnoxiousLogger] [> Level error] ignore


        might be more appropriate.



        Note: after editing /etc/asl.conf, don't forget to kill -HUP your syslogd.






        share|improve this answer


























        • Thx for asl.conf. An ObnoxiousLogger can have an even severer effect than "stealing CPU": Preventing system sleep, as those frequent disk writes continuously reset the sleep timer! My culprit is Google Chrome, both on Mac & Win. I hope it's an innocent bug. But it's hard to believe: 1) Having users online all the time is a mayor business goal, as online-time==ad-time. Tempting to achieve this by tempering with the device sleep mechanism… 2) A Chrome bug reported 2012-07-28 still not fixed.

          – porg
          Aug 7 '14 at 11:17













        • My system.log contains unwanted lines in this format: <date> <hostname> <sender>: <function or object id> <message> <sender> comes in different flavors: [some kind of hexadecimal id].com.google.Chrome[decimal PID] Google Chrome[decimal PID] Q.1) How do I match Google Chrome as sender within conf.asl? Used ? [= Sender <sendername>] ignore. As <sendername> I tried: Chrome, Google Chrome, "Google Chrome", com.google.Chrome, .com.google.Chrome Q.2) What's the correct commandline to notify syslogd? Used sudo kill -HUP pidOfMySylogd. What shall be the exit code? In my case it was nil.

          – porg
          Aug 7 '14 at 11:47














        5












        5








        5







        You may want to look at asl.conf(5) which allows you to ignore/process log messages on quite a fine-grained level.



        Something like:



        ? [= Sender ObnoxiousLogger] ignore


        should do the trick. If you still want to see the more serious messages from the obnoxious sender, something along the lines of:



        ? [= Sender ObnoxiousLogger] [> Level error] ignore


        might be more appropriate.



        Note: after editing /etc/asl.conf, don't forget to kill -HUP your syslogd.






        share|improve this answer















        You may want to look at asl.conf(5) which allows you to ignore/process log messages on quite a fine-grained level.



        Something like:



        ? [= Sender ObnoxiousLogger] ignore


        should do the trick. If you still want to see the more serious messages from the obnoxious sender, something along the lines of:



        ? [= Sender ObnoxiousLogger] [> Level error] ignore


        might be more appropriate.



        Note: after editing /etc/asl.conf, don't forget to kill -HUP your syslogd.







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited Aug 10 '11 at 16:11









        3498DB

        15.9k114862




        15.9k114862










        answered Aug 10 '11 at 9:25









        Torsten GrustTorsten Grust

        6614




        6614













        • Thx for asl.conf. An ObnoxiousLogger can have an even severer effect than "stealing CPU": Preventing system sleep, as those frequent disk writes continuously reset the sleep timer! My culprit is Google Chrome, both on Mac & Win. I hope it's an innocent bug. But it's hard to believe: 1) Having users online all the time is a mayor business goal, as online-time==ad-time. Tempting to achieve this by tempering with the device sleep mechanism… 2) A Chrome bug reported 2012-07-28 still not fixed.

          – porg
          Aug 7 '14 at 11:17













        • My system.log contains unwanted lines in this format: <date> <hostname> <sender>: <function or object id> <message> <sender> comes in different flavors: [some kind of hexadecimal id].com.google.Chrome[decimal PID] Google Chrome[decimal PID] Q.1) How do I match Google Chrome as sender within conf.asl? Used ? [= Sender <sendername>] ignore. As <sendername> I tried: Chrome, Google Chrome, "Google Chrome", com.google.Chrome, .com.google.Chrome Q.2) What's the correct commandline to notify syslogd? Used sudo kill -HUP pidOfMySylogd. What shall be the exit code? In my case it was nil.

          – porg
          Aug 7 '14 at 11:47



















        • Thx for asl.conf. An ObnoxiousLogger can have an even severer effect than "stealing CPU": Preventing system sleep, as those frequent disk writes continuously reset the sleep timer! My culprit is Google Chrome, both on Mac & Win. I hope it's an innocent bug. But it's hard to believe: 1) Having users online all the time is a mayor business goal, as online-time==ad-time. Tempting to achieve this by tempering with the device sleep mechanism… 2) A Chrome bug reported 2012-07-28 still not fixed.

          – porg
          Aug 7 '14 at 11:17













        • My system.log contains unwanted lines in this format: <date> <hostname> <sender>: <function or object id> <message> <sender> comes in different flavors: [some kind of hexadecimal id].com.google.Chrome[decimal PID] Google Chrome[decimal PID] Q.1) How do I match Google Chrome as sender within conf.asl? Used ? [= Sender <sendername>] ignore. As <sendername> I tried: Chrome, Google Chrome, "Google Chrome", com.google.Chrome, .com.google.Chrome Q.2) What's the correct commandline to notify syslogd? Used sudo kill -HUP pidOfMySylogd. What shall be the exit code? In my case it was nil.

          – porg
          Aug 7 '14 at 11:47

















        Thx for asl.conf. An ObnoxiousLogger can have an even severer effect than "stealing CPU": Preventing system sleep, as those frequent disk writes continuously reset the sleep timer! My culprit is Google Chrome, both on Mac & Win. I hope it's an innocent bug. But it's hard to believe: 1) Having users online all the time is a mayor business goal, as online-time==ad-time. Tempting to achieve this by tempering with the device sleep mechanism… 2) A Chrome bug reported 2012-07-28 still not fixed.

        – porg
        Aug 7 '14 at 11:17







        Thx for asl.conf. An ObnoxiousLogger can have an even severer effect than "stealing CPU": Preventing system sleep, as those frequent disk writes continuously reset the sleep timer! My culprit is Google Chrome, both on Mac & Win. I hope it's an innocent bug. But it's hard to believe: 1) Having users online all the time is a mayor business goal, as online-time==ad-time. Tempting to achieve this by tempering with the device sleep mechanism… 2) A Chrome bug reported 2012-07-28 still not fixed.

        – porg
        Aug 7 '14 at 11:17















        My system.log contains unwanted lines in this format: <date> <hostname> <sender>: <function or object id> <message> <sender> comes in different flavors: [some kind of hexadecimal id].com.google.Chrome[decimal PID] Google Chrome[decimal PID] Q.1) How do I match Google Chrome as sender within conf.asl? Used ? [= Sender <sendername>] ignore. As <sendername> I tried: Chrome, Google Chrome, "Google Chrome", com.google.Chrome, .com.google.Chrome Q.2) What's the correct commandline to notify syslogd? Used sudo kill -HUP pidOfMySylogd. What shall be the exit code? In my case it was nil.

        – porg
        Aug 7 '14 at 11:47





        My system.log contains unwanted lines in this format: <date> <hostname> <sender>: <function or object id> <message> <sender> comes in different flavors: [some kind of hexadecimal id].com.google.Chrome[decimal PID] Google Chrome[decimal PID] Q.1) How do I match Google Chrome as sender within conf.asl? Used ? [= Sender <sendername>] ignore. As <sendername> I tried: Chrome, Google Chrome, "Google Chrome", com.google.Chrome, .com.google.Chrome Q.2) What's the correct commandline to notify syslogd? Used sudo kill -HUP pidOfMySylogd. What shall be the exit code? In my case it was nil.

        – porg
        Aug 7 '14 at 11:47













        3














        Just create a File » New Database Search…, looking for Facility contains "console" and Sender does not contain "ObnoxiousLogger", and ignore the default Console Messages database search?



        enter image description here





        You can use the following command to set individual log filtering levels for specific processes:



        syslog -c processname -d


        This will set the log level of currently running instances of processname to all messages of debug level or higher. the possible levels are each character of pacewnid: (Panic), Alert, Critical, Error, Warning, Notice, Info, and Debug.



        So, to only enable logging of warning messages and higher for Finder, use:



        syslog -c Finder -w


        You will need to repeat this whenever you restart the process in question.






        share|improve this answer


























        • I have similar searches setup for just stuff I want to see.. but is there any way to prevent "ObnoxiousLogger" from ever hitting the syslog facility, at all? My concern: all that chatter must be robbing at least a few cpu cycles, no?

          – mralexgray
          May 19 '11 at 16:38











        • @mralexgray Added some further research to my answer. Unfortunately, I don't have an obnoxiously logging process running right now, so I cannot perform any reliable testing. Answer is therefore primarily based on man syslog.

          – Daniel Beck
          May 19 '11 at 17:32
















        3














        Just create a File » New Database Search…, looking for Facility contains "console" and Sender does not contain "ObnoxiousLogger", and ignore the default Console Messages database search?



        enter image description here





        You can use the following command to set individual log filtering levels for specific processes:



        syslog -c processname -d


        This will set the log level of currently running instances of processname to all messages of debug level or higher. the possible levels are each character of pacewnid: (Panic), Alert, Critical, Error, Warning, Notice, Info, and Debug.



        So, to only enable logging of warning messages and higher for Finder, use:



        syslog -c Finder -w


        You will need to repeat this whenever you restart the process in question.






        share|improve this answer


























        • I have similar searches setup for just stuff I want to see.. but is there any way to prevent "ObnoxiousLogger" from ever hitting the syslog facility, at all? My concern: all that chatter must be robbing at least a few cpu cycles, no?

          – mralexgray
          May 19 '11 at 16:38











        • @mralexgray Added some further research to my answer. Unfortunately, I don't have an obnoxiously logging process running right now, so I cannot perform any reliable testing. Answer is therefore primarily based on man syslog.

          – Daniel Beck
          May 19 '11 at 17:32














        3












        3








        3







        Just create a File » New Database Search…, looking for Facility contains "console" and Sender does not contain "ObnoxiousLogger", and ignore the default Console Messages database search?



        enter image description here





        You can use the following command to set individual log filtering levels for specific processes:



        syslog -c processname -d


        This will set the log level of currently running instances of processname to all messages of debug level or higher. the possible levels are each character of pacewnid: (Panic), Alert, Critical, Error, Warning, Notice, Info, and Debug.



        So, to only enable logging of warning messages and higher for Finder, use:



        syslog -c Finder -w


        You will need to repeat this whenever you restart the process in question.






        share|improve this answer















        Just create a File » New Database Search…, looking for Facility contains "console" and Sender does not contain "ObnoxiousLogger", and ignore the default Console Messages database search?



        enter image description here





        You can use the following command to set individual log filtering levels for specific processes:



        syslog -c processname -d


        This will set the log level of currently running instances of processname to all messages of debug level or higher. the possible levels are each character of pacewnid: (Panic), Alert, Critical, Error, Warning, Notice, Info, and Debug.



        So, to only enable logging of warning messages and higher for Finder, use:



        syslog -c Finder -w


        You will need to repeat this whenever you restart the process in question.







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited May 19 '11 at 17:30

























        answered May 18 '11 at 17:53









        Daniel BeckDaniel Beck

        93.6k12236288




        93.6k12236288













        • I have similar searches setup for just stuff I want to see.. but is there any way to prevent "ObnoxiousLogger" from ever hitting the syslog facility, at all? My concern: all that chatter must be robbing at least a few cpu cycles, no?

          – mralexgray
          May 19 '11 at 16:38











        • @mralexgray Added some further research to my answer. Unfortunately, I don't have an obnoxiously logging process running right now, so I cannot perform any reliable testing. Answer is therefore primarily based on man syslog.

          – Daniel Beck
          May 19 '11 at 17:32



















        • I have similar searches setup for just stuff I want to see.. but is there any way to prevent "ObnoxiousLogger" from ever hitting the syslog facility, at all? My concern: all that chatter must be robbing at least a few cpu cycles, no?

          – mralexgray
          May 19 '11 at 16:38











        • @mralexgray Added some further research to my answer. Unfortunately, I don't have an obnoxiously logging process running right now, so I cannot perform any reliable testing. Answer is therefore primarily based on man syslog.

          – Daniel Beck
          May 19 '11 at 17:32

















        I have similar searches setup for just stuff I want to see.. but is there any way to prevent "ObnoxiousLogger" from ever hitting the syslog facility, at all? My concern: all that chatter must be robbing at least a few cpu cycles, no?

        – mralexgray
        May 19 '11 at 16:38





        I have similar searches setup for just stuff I want to see.. but is there any way to prevent "ObnoxiousLogger" from ever hitting the syslog facility, at all? My concern: all that chatter must be robbing at least a few cpu cycles, no?

        – mralexgray
        May 19 '11 at 16:38













        @mralexgray Added some further research to my answer. Unfortunately, I don't have an obnoxiously logging process running right now, so I cannot perform any reliable testing. Answer is therefore primarily based on man syslog.

        – Daniel Beck
        May 19 '11 at 17:32





        @mralexgray Added some further research to my answer. Unfortunately, I don't have an obnoxiously logging process running right now, so I cannot perform any reliable testing. Answer is therefore primarily based on man syslog.

        – Daniel Beck
        May 19 '11 at 17:32











        1














        The proposed solution by Torsten doesn't seem to work. It seems adding those configuration to the global asl.conf doesn't have the expected effect the way the rules are handled.



        A solution to this problem, I found, after I almost went berserk fighting with the main asl.conf, is to use separate asl/* configuration files for each filter. Those files must be stored in /etc/asl/



        e.g. to ignore "com.example.Sender" and filter its log spam from system.log we could create a file /etc/asl/com.example.Sender with the following content:



        ? [= Sender com.example.Sender] claim only
        * ignore


        The claim only for the match (a "Sender" in the example) causes the rules in the master asl.conf to be ignored which means things won't end up in system.log.



        Don't forget to restart syslogd, of course.






        share|improve this answer






























          1














          The proposed solution by Torsten doesn't seem to work. It seems adding those configuration to the global asl.conf doesn't have the expected effect the way the rules are handled.



          A solution to this problem, I found, after I almost went berserk fighting with the main asl.conf, is to use separate asl/* configuration files for each filter. Those files must be stored in /etc/asl/



          e.g. to ignore "com.example.Sender" and filter its log spam from system.log we could create a file /etc/asl/com.example.Sender with the following content:



          ? [= Sender com.example.Sender] claim only
          * ignore


          The claim only for the match (a "Sender" in the example) causes the rules in the master asl.conf to be ignored which means things won't end up in system.log.



          Don't forget to restart syslogd, of course.






          share|improve this answer




























            1












            1








            1







            The proposed solution by Torsten doesn't seem to work. It seems adding those configuration to the global asl.conf doesn't have the expected effect the way the rules are handled.



            A solution to this problem, I found, after I almost went berserk fighting with the main asl.conf, is to use separate asl/* configuration files for each filter. Those files must be stored in /etc/asl/



            e.g. to ignore "com.example.Sender" and filter its log spam from system.log we could create a file /etc/asl/com.example.Sender with the following content:



            ? [= Sender com.example.Sender] claim only
            * ignore


            The claim only for the match (a "Sender" in the example) causes the rules in the master asl.conf to be ignored which means things won't end up in system.log.



            Don't forget to restart syslogd, of course.






            share|improve this answer















            The proposed solution by Torsten doesn't seem to work. It seems adding those configuration to the global asl.conf doesn't have the expected effect the way the rules are handled.



            A solution to this problem, I found, after I almost went berserk fighting with the main asl.conf, is to use separate asl/* configuration files for each filter. Those files must be stored in /etc/asl/



            e.g. to ignore "com.example.Sender" and filter its log spam from system.log we could create a file /etc/asl/com.example.Sender with the following content:



            ? [= Sender com.example.Sender] claim only
            * ignore


            The claim only for the match (a "Sender" in the example) causes the rules in the master asl.conf to be ignored which means things won't end up in system.log.



            Don't forget to restart syslogd, of course.







            share|improve this answer














            share|improve this answer



            share|improve this answer








            edited Aug 8 '16 at 0:16

























            answered Aug 8 '16 at 0:10









            HaruHaru

            11617




            11617























                1














                I am on MacOS Mojave (10.14.3) and this post was helpful to me so I want to clarify what worked for me as I have not seen it all together in a single place. In my case I wanted to filter out Microsoft OneNote messages which were constantly spamming my system.log file at a rate of 5 a second. Sample message:



                Feb  3 22:52:49 MyMacMini-2 Microsoft OneNote[393]: [ACT]:[TASKSCHEDULER]:[Info]:opQueue=0x6000012d7760 after call to waitUntilAllOperationsAreFinished


                So I edited /etc/asl.conf with the following rule:



                # Disable Microsoft OneNote logging as is filling up system.log!
                ? [= Sender Microsoft OneNote] ignore


                You need to add this before the line that says:



                # Rules for /var/log/system.log


                As otherwise it will not work. Then just restart syslogd with this command and the messages should be gone from system.log:



                sudo killall -HUP syslogd





                share|improve this answer




























                  1














                  I am on MacOS Mojave (10.14.3) and this post was helpful to me so I want to clarify what worked for me as I have not seen it all together in a single place. In my case I wanted to filter out Microsoft OneNote messages which were constantly spamming my system.log file at a rate of 5 a second. Sample message:



                  Feb  3 22:52:49 MyMacMini-2 Microsoft OneNote[393]: [ACT]:[TASKSCHEDULER]:[Info]:opQueue=0x6000012d7760 after call to waitUntilAllOperationsAreFinished


                  So I edited /etc/asl.conf with the following rule:



                  # Disable Microsoft OneNote logging as is filling up system.log!
                  ? [= Sender Microsoft OneNote] ignore


                  You need to add this before the line that says:



                  # Rules for /var/log/system.log


                  As otherwise it will not work. Then just restart syslogd with this command and the messages should be gone from system.log:



                  sudo killall -HUP syslogd





                  share|improve this answer


























                    1












                    1








                    1







                    I am on MacOS Mojave (10.14.3) and this post was helpful to me so I want to clarify what worked for me as I have not seen it all together in a single place. In my case I wanted to filter out Microsoft OneNote messages which were constantly spamming my system.log file at a rate of 5 a second. Sample message:



                    Feb  3 22:52:49 MyMacMini-2 Microsoft OneNote[393]: [ACT]:[TASKSCHEDULER]:[Info]:opQueue=0x6000012d7760 after call to waitUntilAllOperationsAreFinished


                    So I edited /etc/asl.conf with the following rule:



                    # Disable Microsoft OneNote logging as is filling up system.log!
                    ? [= Sender Microsoft OneNote] ignore


                    You need to add this before the line that says:



                    # Rules for /var/log/system.log


                    As otherwise it will not work. Then just restart syslogd with this command and the messages should be gone from system.log:



                    sudo killall -HUP syslogd





                    share|improve this answer













                    I am on MacOS Mojave (10.14.3) and this post was helpful to me so I want to clarify what worked for me as I have not seen it all together in a single place. In my case I wanted to filter out Microsoft OneNote messages which were constantly spamming my system.log file at a rate of 5 a second. Sample message:



                    Feb  3 22:52:49 MyMacMini-2 Microsoft OneNote[393]: [ACT]:[TASKSCHEDULER]:[Info]:opQueue=0x6000012d7760 after call to waitUntilAllOperationsAreFinished


                    So I edited /etc/asl.conf with the following rule:



                    # Disable Microsoft OneNote logging as is filling up system.log!
                    ? [= Sender Microsoft OneNote] ignore


                    You need to add this before the line that says:



                    # Rules for /var/log/system.log


                    As otherwise it will not work. Then just restart syslogd with this command and the messages should be gone from system.log:



                    sudo killall -HUP syslogd






                    share|improve this answer












                    share|improve this answer



                    share|improve this answer










                    answered Feb 3 at 23:36









                    TurribeachTurribeach

                    111




                    111























                        0














                        I posted a more detailed answer at AskDifferent.



                        Put in /etc/asl.conf a rule like the following



                        ? [= Sender foobar] [<= Level error] notify com.apple.foobar
                        op key value op key value
                        -----query 1----- -----query 2---- ---------action--------


                        In order to ignore messages in both system.log and in Console.app, you should add rules to ignore messages before the following comment in asl.conf.



                        # Flat file configurations formerly in syslog.conf



                        Example with modifier S, which ignores messages matching that substring from SIMBL Agent.



                        ? [= Sender SIMBL Agent] [S= Message warning: failed to get scripting definition from] ignore
                        op -key-- ---value--- mod --key-- --------------------value-----------------------
                        --------query 1------- -----------------------query 2------------------------------- action


                        After adding a rule restart the daemon with sudo killall HUP syslogd.



                        Tested successfully in OS X 10.8.5.






                        share|improve this answer






























                          0














                          I posted a more detailed answer at AskDifferent.



                          Put in /etc/asl.conf a rule like the following



                          ? [= Sender foobar] [<= Level error] notify com.apple.foobar
                          op key value op key value
                          -----query 1----- -----query 2---- ---------action--------


                          In order to ignore messages in both system.log and in Console.app, you should add rules to ignore messages before the following comment in asl.conf.



                          # Flat file configurations formerly in syslog.conf



                          Example with modifier S, which ignores messages matching that substring from SIMBL Agent.



                          ? [= Sender SIMBL Agent] [S= Message warning: failed to get scripting definition from] ignore
                          op -key-- ---value--- mod --key-- --------------------value-----------------------
                          --------query 1------- -----------------------query 2------------------------------- action


                          After adding a rule restart the daemon with sudo killall HUP syslogd.



                          Tested successfully in OS X 10.8.5.






                          share|improve this answer




























                            0












                            0








                            0







                            I posted a more detailed answer at AskDifferent.



                            Put in /etc/asl.conf a rule like the following



                            ? [= Sender foobar] [<= Level error] notify com.apple.foobar
                            op key value op key value
                            -----query 1----- -----query 2---- ---------action--------


                            In order to ignore messages in both system.log and in Console.app, you should add rules to ignore messages before the following comment in asl.conf.



                            # Flat file configurations formerly in syslog.conf



                            Example with modifier S, which ignores messages matching that substring from SIMBL Agent.



                            ? [= Sender SIMBL Agent] [S= Message warning: failed to get scripting definition from] ignore
                            op -key-- ---value--- mod --key-- --------------------value-----------------------
                            --------query 1------- -----------------------query 2------------------------------- action


                            After adding a rule restart the daemon with sudo killall HUP syslogd.



                            Tested successfully in OS X 10.8.5.






                            share|improve this answer















                            I posted a more detailed answer at AskDifferent.



                            Put in /etc/asl.conf a rule like the following



                            ? [= Sender foobar] [<= Level error] notify com.apple.foobar
                            op key value op key value
                            -----query 1----- -----query 2---- ---------action--------


                            In order to ignore messages in both system.log and in Console.app, you should add rules to ignore messages before the following comment in asl.conf.



                            # Flat file configurations formerly in syslog.conf



                            Example with modifier S, which ignores messages matching that substring from SIMBL Agent.



                            ? [= Sender SIMBL Agent] [S= Message warning: failed to get scripting definition from] ignore
                            op -key-- ---value--- mod --key-- --------------------value-----------------------
                            --------query 1------- -----------------------query 2------------------------------- action


                            After adding a rule restart the daemon with sudo killall HUP syslogd.



                            Tested successfully in OS X 10.8.5.







                            share|improve this answer














                            share|improve this answer



                            share|improve this answer








                            edited Apr 13 '17 at 12:45









                            Community

                            1




                            1










                            answered Feb 13 '17 at 14:36









                            1.618031.61803

                            24828




                            24828






























                                draft saved

                                draft discarded




















































                                Thanks for contributing an answer to Super User!


                                • Please be sure to answer the question. Provide details and share your research!

                                But avoid



                                • Asking for help, clarification, or responding to other answers.

                                • Making statements based on opinion; back them up with references or personal experience.


                                To learn more, see our tips on writing great answers.




                                draft saved


                                draft discarded














                                StackExchange.ready(
                                function () {
                                StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f278231%2fhow-to-disable-set-logging-level-preferences-per-mac-os-x-application%23new-answer', 'question_page');
                                }
                                );

                                Post as a guest















                                Required, but never shown





















































                                Required, but never shown














                                Required, but never shown












                                Required, but never shown







                                Required, but never shown

































                                Required, but never shown














                                Required, but never shown












                                Required, but never shown







                                Required, but never shown







                                Popular posts from this blog

                                Plaza Victoria

                                In PowerPoint, is there a keyboard shortcut for bulleted / numbered list?

                                How to put 3 figures in Latex with 2 figures side by side and 1 below these side by side images but in...