log personal message to /var/log/messages

August 14th, 2006 mysurface Posted in Admin, backquote, logger, tail | Hits: 162094 | 29 Comments »

To log personal messages to /var/log/messages when you write script, you can use logger

simple example:

logger i am testing

And check the result with tail, it display last 10 line of messages by default

tail /var/log/messages

To put more info to log file, you can specified the timestamp with scriptname by this

logger -t `basename $0` i am still testing

basename is to display scriptname without ./ or the parent’s path, back quote (`) is to pass the result string to logger.

29 Responses to “log personal message to /var/log/messages”

  1. Thanks, very useful!!!

  2. I have a doubt.How do I write a a message from my program to /var/log/messages ? Is this possible? How?

  3. devendra koli Says:

    Thank you so much

  4. DuevEbeverlee Says:

    get and get big save for more detail

  5. My family members always say that I am killing my time here at net, however I know I am getting knowledge everyday by reading such
    nice content.

  6. Hmm it appears like your blog ate my first comment
    (it was super long) so I guess I’ll just sum it up what I had written and say, I’m thoroughly enjoying your blog.
    I as well am an aspiring blog blogger but I’m still new to everything. Do you have any tips and hints for inexperienced blog writers? I’d genuinely appreciate it.

  7. This is a topic that’s near to my heart… Thank you!

    Exactly where are your contact details though?

  8. I usually do not write a comment, but I browsed a ton of remarks here log personal message to /var/log/messages ?
    Linux by Examples. I actually do have a couple of questions for you
    if you tend not to mind. Is it only me or do some of the remarks appear as if they are coming from brain dead folks?
    :-P And, if you are posting at additional sites, I would like to follow everything new you
    have to post. Could you make a list of every one of all your social networking sites
    like your twitter feed, Facebook page or linkedin profile?

    Feel free to visit my webpage :: The Baby Télécharger Le Film

  9. I’m impressed, I must say. Rarely do I encounter a blog that’s both equally educative
    and interesting, and let me tell you, you’ve hit the nail on the head.

    The issue is something too few men and women are speaking
    intelligently about. I am very happy I came
    across this in my hunt for something concerning this.

    my blog post: Match Retour Télécharger Le Film

  10. My brother suggested I would possibly like this web site.
    He used to be entirely right. This put up actually made my day.
    You can not believe just how a lot time I had spent for this info!


    my weblog Avis de mistral Télécharger Le Film

  11. Right here is the perfect site for everyone who wishes to understand this topic.

    You know so much its almost tough to argue with you (not that I personally would
    want to…HaHa). You definitely put a brand new spin
    on a topic that’s been written about for years.

    Great stuff, just excellent!

    Here is my homepage; Dark Touch Télécharger Le Film

  12. Thanks for one’s marvelous posting! I quite enjoyed reading it, you happen to be a great author.
    I will be sure to bookmark your blog and will come back someday.
    I want to encourage one to continue your great job, have a nice day!

    Here is my blog; la vérité sur l’affaire Ilan Halimi Télécharger Le Film

  13. Hi, yup this article is truly good and I have learned lot of things
    from it concerning blogging. thanks.

    Here is my weblog :: Le Vent se lève Télécharger le film

  14. ??????????????? ???????????????????????????????????????????????

    ???????????????????? ???????????????
    ??????????????? ??10?????????????????????? ?????????????????????????

    ???????wwwwwwwwwwwwwwwwwwwww ?? (is.gd) ???????? ???? ???wwwwwwwwwwwwwwwwwwww

  15. With Flash enabled, rich media content can be effortlessly
    displayed in Pulse News, allowing for video clips and audio
    together with the usual text-based news feeds. First, in these kinds of leak investigations, reporters will never be targeted.

    If it really is worth your time and effort and concentration be rest assured
    you are going to find it with the Hindi Samachar.
    We witness dramatic differences if we compare these
    periods of Indian Cinema.

    They become doubtful concerning which one of the two
    (reading, listening) matters most. Some people just
    cannot help themselves: it’s the way they’re made (the best way
    I react when a menu offers me a range of ‘Salad’s’ – salad’s
    what. samsung chromebook review then; tr.im, Allow yourself to have the truth of one’s creative experience.
    SEO content writing is a marketing strategy that requires article writing
    so that you can improve the availability of a specific

  16. […] Fuente Compartir // Sharrre jQuery(document).ready(function(){ jQuery('#twitter').sharrre({ share: { twitter: true }, template: '{total}', enableHover: false, enableTracking: true, buttons: { twitter: {via: 'yvoictra'}}, click: function(api, options){ api.simulateClick(); api.openPopup('twitter'); } }); jQuery('#facebook').sharrre({ share: { facebook: true }, template: '{total}', enableHover: false, enableTracking: true, click: function(api, options){ api.simulateClick(); api.openPopup('facebook'); } }); jQuery('#googleplus').sharrre({ share: { googlePlus: true }, template: '{total}', enableHover: false, enableTracking: true, urlCurl: 'http://egomezm.es/wp-content/themes/hueman/js/sharrre.php', click: function(api, options){ api.simulateClick(); api.openPopup('googlePlus'); } }); jQuery('#pinterest').sharrre({ share: { pinterest: true }, template: '{total}', enableHover: false, enableTracking: true, buttons: { pinterest: { description: 'Logear mensajes personales en el /var/log/messages' } }, click: function(api, options){ api.simulateClick(); api.openPopup('pinterest'); } }); }); […]

  17. I do not know if it’s just me or if perhaps everyone else encountering issues with your website.
    It appears as if some of the written text within your posts are running off the screen.
    Can somebody else please provide feedback and let me know if this is happening to them too?
    This may be a issue with my browser because I’ve had this happen previously.
    Appreciate it

  18. The time can also be hired as the official electrical technician of a certain activity.

    Besides, it’s good if you are not competent for
    the job. Brisbane electricians in residential work, install click here hot-water
    tanks, automatic dishwashers, and clothes dryers. Before we start
    putting click here too much on an already overloaded system it is best left to the professionals.
    Working without a contract and choosing someone because they are cheap.

  19. ? do trust all the ideas you have offered for your post.

    They aar? very convincing and will certainly work.

    Still, th? posts are too brief for novices.
    May you please lengthen th?em a bit from next time?
    Thanks for the post.

    Also ?isit my pa?e … electrician hourly ?ate (Leonore)

  20. Thank you for the auspicious writeup. It in fact was once a leisure account it.
    Glance advanced to more brought agreeable from you! By the way, how could we keep up a

  21. No other metallic can compete with copper whyen we discuss electrical conductivity.

  22. Se ils internet sites similaires personnelles que le vôtre, vous pouvez généralement renseigner pour un échange de lien.

  23. Hello There. I found your blog the use of msn. That
    is a very well written article. I will make sure to bookmark it and return to learn more of your useful info.
    Thank you for the post. I will definitely return.

  24. Curso Anual 2015/16, de Noviembre a Junio, todos y cada uno de los Sábados según el horario y niveles de
    edad indicados., Inglaterra, Canadá, Australia, Malta, Irlanda, Con el curso
    de ABA English, asimismo vas a recibir el certificado oficial emitido por American & British Academy
    por cada nivel que superes., Irlanda, Canadá, Australia,
    El curso de inglés de ABA English cuenta también con videoclases desarrolladas para apresurar y afianzar el aprendizaje de la gramática inglesa., Canadá pasando por Reino Unido, Australia, Hola me siento tan feliz
    de poder aprender el ingles me es una nueva bien importante y estoy
    a gusto de enterarme.

  25. I am regular reader, how are you everybody? This article posted at this site
    is in fact nice.

  26. What’s up, of course thks post is genuinely fastidius and
    I have learned lot of things from it regarding
    blogging. thanks.

  27. Hurrah! In the end I got a web site from where
    I know how to genuinely get useful data regarding my
    study and knowledge.

  28. I like looking through a post that can make people think.
    Also, thanks for allowing me too comment!

  29. Hello to all, the contents pressent at thi? web page are t?uly remarkable ffor
    pedople knowledge, ?ell, kesep up the ?ood wortk fellows.

    H??e ?s my pae :: Rons Williams RacingsSummary

Leave a Reply