Bug 195245 - shells/lshell 0.9.16 fails to log to syslog
Summary: shells/lshell 0.9.16 fails to log to syslog
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: John Marino
URL:
Keywords: patch, patch-ready
Depends on:
Blocks:
 
Reported: 2014-11-21 10:56 UTC by Damien Fleuriot
Modified: 2015-02-06 12:09 UTC (History)
2 users (show)

See Also:


Attachments
Make lshell/checkconfig.py send syslog data to /var/run/log instead of non-existent /dev/log (581 bytes, patch)
2014-11-21 10:56 UTC, Damien Fleuriot
no flags Details | Diff
Patch for 0.9.15.1 (583 bytes, patch)
2014-11-21 10:58 UTC, Damien Fleuriot
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Damien Fleuriot 2014-11-21 10:56:53 UTC
Created attachment 149667 [details]
Make lshell/checkconfig.py send syslog data to /var/run/log instead of non-existent /dev/log

Summary:
shells/lshell doesn't log anything to syslog


Tested versions:
- 0.9.15.1
- 0.9.16


Synopsis:
lshell can log either to a file or to syslog depending on its configuration file.

Sadly, lshell tries to log through /dev/log which hasn't existed on FreeBSD for a long while.

Creating a symbolic link /dev/log -> /var/run/log didn't seem to fix the problem.


How to reproduce:
Install vanilla shells/lshell
Instruct it to log to syslog in /usr/local/etc/lshell.conf
'[global]'
'logfilename	: syslog'
Rehash terminal, invoke lshell
Type commands, nope, syslog gets nothing


How to fix:
0.9.15.1 : Edit line 929 of lshellmodule/lshell.py to correctly point to /var/run/log
0.9.16 : Edit line 310 of lshell/checkconfig.py to correctly point to /var/run/log
Recompile, reinstall


Patch against 0.9.16 attached
Comment 1 Damien Fleuriot 2014-11-21 10:58:28 UTC
Created attachment 149668 [details]
Patch for 0.9.15.1

Only for 0.9.15.1 , the other attachment is for 0.9.16
Comment 2 John Marino freebsd_committer freebsd_triage 2015-01-25 18:02:48 UTC
This port has no maintainer, patch looks straightforward and PR description is excellent.  Promote to patch-ready status.
Comment 3 John Marino freebsd_committer freebsd_triage 2015-02-06 10:02:56 UTC
I didn't follow why there is a patch for version that was replaced in August 2014 (0.9.15.1).  What was the point of providing that?  FWIW, I grabbed this one first so it caused confusion when it didn't apply (it was named Patch-*, I was looking for the patch, easy mistake to make)
Comment 4 commit-hook freebsd_committer freebsd_triage 2015-02-06 10:07:48 UTC
A commit references this bug:

Author: marino
Date: Fri Feb  6 10:07:21 UTC 2015
New revision: 378519
URL: https://svnweb.freebsd.org/changeset/ports/378519

Log:
  shells/lshell: fix syslog file location (/dev/log => /var/run/log)

  PR:		195245
  Submitted by:	dam (my.gd)
  Approved by:	n/a (unmaintained)

Changes:
  head/shells/lshell/Makefile
  head/shells/lshell/files/
  head/shells/lshell/files/patch-lshell_checkconfig.py
Comment 5 John Marino freebsd_committer freebsd_triage 2015-02-06 10:08:19 UTC
Thanks
Comment 6 Damien Fleuriot 2015-02-06 11:39:49 UTC
(In reply to John Marino from comment #3)

I should have clarified, sorry about the confusion.

I've provided a patch for 0.9.15.1 because we are not using 0.9.16 here.

0.9.16 causes a problem on *all* the boxes we've tried running it on, where certain commands (like ls) make the lshell process go in the background, at which point we can either kill it, or bring it back up with fg.

I'm gonna have to file a PR for that one.
Comment 7 John Marino freebsd_committer freebsd_triage 2015-02-06 12:00:28 UTC
but 0.9.15.1  is not in ports so there is nothing to patch.
Apparently  you are maintaining it locally or just never updated.
Comment 8 Damien Fleuriot 2015-02-06 12:09:31 UTC
Yup, we're keeping it locked so as to retain 0.9.15.1 which still works for us.

I really need to look into the backgrounding problem with 0.9.16 at some point and see if I can come up with a patch.


Once again my apologies for the confusion, will be more careful on my next PR.