Find the answer to your Linux question:
Results 1 to 5 of 5
ok here's the thing, i'm on a windows machine, trying to watch logs on a remote linux servers, now since i don't like extra clicks, i simply use Code: plink ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Nov 2012
    Posts
    2

    Question remotely tailing a file without ..ah... it appearing in PS??


    ok here's the thing, i'm on a windows machine, trying to watch logs on a remote linux servers, now since i don't like extra clicks, i simply use
    Code:
    plink user:password at host tail -f /opt/companyName/log.log
    awesome, however, there's another process on said machine which one of it's functions is to seek out ANYTHING in Process List which contains the "companyName" in the command, and.. well.. kill it, DON'T ASK WHY! it's too painful, unfortunately, it can't kill my tail, but it continues to try, and thus messing itself and interrupting my work. i can't change/stop/tamper with said process as it's external, and part of application i'm trying to solve.

    so .. i need something somehow, a way, with a single click to see a live stream of this log file, now i know i can use SocketAppender in log4j (said log is in log4j) but is there any other way, in ssh maybe to see directly the file? (can't use winscp to double click it as it's huge and hangs it).

  2. #2
    Trusted Penguin Irithori's Avatar
    Join Date
    May 2009
    Location
    Munich
    Posts
    3,398
    Hi and welcome.

    Well, you could cd first and then tail. This way, only the cd will trigger that ominous process killer once (if at all).
    And yes, this process killer raises some questions

    But imho a more professional approach would be to setup a webtool like LogAnalyzer
    This way you do not need shell access, the logs are just another tab on your browser, you can search and filter the logs..
    You must always face the curtain with a bow.

  3. #3
    Just Joined!
    Join Date
    Nov 2012
    Posts
    2
    yea, however i forgot to mention the file name ALSO contains the CompanyName, thus i'm still screwed. LogAnalyzer might take a little learning curve..

  4. #4
    Trusted Penguin Irithori's Avatar
    Join Date
    May 2009
    Location
    Munich
    Posts
    3,398
    Provided you are part of an interested group (developer, quality assurance, sysadmin, project owner, etc) access to logfiles is a legitimate request.
    If that process killer blocks you, then you should openly address this with the team responsible for that tool.

    They either need to add exceptions, or install other means to access the logfiles (loganalyzer being one of them)
    You must always face the curtain with a bow.

  5. #5
    Linux Newbie
    Join Date
    Jun 2012
    Location
    SF Bay area
    Posts
    174
    I agree with the previous comments about talking with the admins of the system to come up with a reasonable solution since there's obviously some concern about enforcing rules on that system. But if you can't do something like just changing the killer script to ignore a "whitelist" of users, then you could use symlinks to gain access to the logfile without actually using the company name in the path.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •