Re: Is there a log file of ...?

2018-09-08 Thread Brad Rogers
On Sat, 8 Sep 2018 21:42:56 +0200
Michael Wagner  wrote:

Hello Michael,

>to search after you hit CTRL-R and type the beginnning of the command 
>you search for.

In point of fact, you can type any part of the string.  Sooner or later,
it'll match the full command and argument set you're after.

-- 
 Regards  _
 / )   "The blindingly obvious is
/ _)radnever immediately apparent"
If you ain't sticking your knives in me, you will be eventually
Monsoon - Robbie Williams


pgp_LkVojo4mt.pgp
Description: OpenPGP digital signature


Re: Is there a log file of ...?

2018-09-08 Thread Michael Wagner
On Sep 08, 2018 at 18:12:02, to...@tuxteam.de wrote:
> On Sat, Sep 08, 2018 at 05:55:57PM +0200, Michael Wagner wrote:
> > On Sep 08, 2018 at 15:29:44, to...@tuxteam.de wrote:
> > > And while we're at it, CTRL-R and start typing a substring of
> > > the past command you're looking for: the more letters you have,
> > > the more specific the match becomes (also called "reverse
> > > incremental search").
> > > 
> > > Takes a bit to get used to, but is... magic.
> > > 
> > > I'm surprised it is so little known.
> > 
> > This is one of the first things I set when installing a new Debian.
> > But you must set it explicitly in /etc/inputrc systemwide or in your 
> > ~/.inputrc. I don't how this behaviour is in other distris.
> 
> Hm. I have no .inputrc. I have the impression that on my box
> it is the default (Debian stretch, but it seems to have been
> default for a long time).
> 
> Wait a minute! I've a minimal schroot installation around...
> yes, it seems to be default behaviour.

You are right. I mixed it up with 

# alternate mappings for "page up" and "page down" to search the history
"\e[5~": history-search-backward
"\e[6~": history-search-forward

to search after you hit CTRL-R and type the beginnning of the command 
you search for.

Michael

-- 
Lesser artists borrow. Great artists steal.


signature.asc
Description: PGP signature


Re: Is there a log file of ...?

2018-09-08 Thread Curt
On 2018-09-08, Michael Wagner  wrote:
>
> On Sep 08, 2018 at 15:29:44, to...@tuxteam.de wrote:
>> And while we're at it, CTRL-R and start typing a substring of
>> the past command you're looking for: the more letters you have,
>> the more specific the match becomes (also called "reverse
>> incremental search").
>>=20
>> Takes a bit to get used to, but is... magic.
>>=20
>> I'm surprised it is so little known.
>
> This is one of the first things I set when installing a new Debian.
> But you must set it explicitly in /etc/inputrc systemwide or in your=20
> ~/.inputrc. I don't how this behaviour is in other distris.

Is that right? I don't remember ever having set it (though I use the
functionality).

I wouldn't know how to set it if I had to set it. Maybe something like

bind '"\C-r": backward-search-history'

?

I'm reading forward-search-history is bound to (get you into big
trouble) Ctrl+S, but that that combo is also the flow control sequence
for the terminal driver, so the shell never sees it (unless you disable
flow control--'stty -ixon'). You can also enable an alternative key
binding, of course. I'm only parroting here what I've just read (famous
last weasel words).



Re: Is there a log file of ...?

2018-09-08 Thread Jack Dangler




On 09/08/2018 11:55 AM, Michael Wagner wrote:

On Sep 08, 2018 at 15:29:44, to...@tuxteam.de wrote:

And while we're at it, CTRL-R and start typing a substring of
the past command you're looking for: the more letters you have,
the more specific the match becomes (also called "reverse
incremental search").

Takes a bit to get used to, but is... magic.

I'm surprised it is so little known.

This is one of the first things I set when installing a new Debian.
But you must set it explicitly in /etc/inputrc systemwide or in your
~/.inputrc. I don't how this behaviour is in other distris.

Just my 2¢
Michael


It is set on default in Mint...



Re: Is there a log file of ...?

2018-09-08 Thread tomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Sat, Sep 08, 2018 at 05:55:57PM +0200, Michael Wagner wrote:
> On Sep 08, 2018 at 15:29:44, to...@tuxteam.de wrote:
> > And while we're at it, CTRL-R and start typing a substring of
> > the past command you're looking for: the more letters you have,
> > the more specific the match becomes (also called "reverse
> > incremental search").
> > 
> > Takes a bit to get used to, but is... magic.
> > 
> > I'm surprised it is so little known.
> 
> This is one of the first things I set when installing a new Debian.
> But you must set it explicitly in /etc/inputrc systemwide or in your 
> ~/.inputrc. I don't how this behaviour is in other distris.

Hm. I have no .inputrc. I have the impression that on my box
it is the default (Debian stretch, but it seems to have been
default for a long time).

Wait a minute! I've a minimal schroot installation around...
yes, it seems to be default behaviour.

Cheers
- -- t
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAluT9NIACgkQBcgs9XrR2kZ06QCeKyz1qVyLDDbUayen+b1t0sjH
4XQAniFQ9b4UI9/s82DIhHcysRxMDnVp
=cJhS
-END PGP SIGNATURE-



Re: Is there a log file of ...?

2018-09-08 Thread Michael Wagner
On Sep 08, 2018 at 15:29:44, to...@tuxteam.de wrote:
> And while we're at it, CTRL-R and start typing a substring of
> the past command you're looking for: the more letters you have,
> the more specific the match becomes (also called "reverse
> incremental search").
> 
> Takes a bit to get used to, but is... magic.
> 
> I'm surprised it is so little known.

This is one of the first things I set when installing a new Debian.
But you must set it explicitly in /etc/inputrc systemwide or in your 
~/.inputrc. I don't how this behaviour is in other distris.

Just my 2¢
Michael

-- 
BOFH excuse #419:
Repeated reboots of the system failed to solve problem


signature.asc
Description: PGP signature


Re: Is there a log file of ...?

2018-09-08 Thread tomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Sat, Sep 08, 2018 at 03:21:33PM +0200, Hans wrote:
> Am Samstag, 8. September 2018, 15:05:29 CEST schrieb Jude DaShiell:
> Also usefull:
> 
> history -l   | grep what-you-remember
> 
> if you can just remeber a part of the command you used.

And while we're at it, CTRL-R and start typing a substring of
the past command you're looking for: the more letters you have,
the more specific the match becomes (also called "reverse
incremental search").

Takes a bit to get used to, but is... magic.

I'm surprised it is so little known.

Cheers
- -- t
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAluTzsgACgkQBcgs9XrR2karKQCfRpCN5ODlcxrondLB184BsTQy
DOEAn3m7yHX+FmHxJSIL52l4w2IqCVUA
=zNhm
-END PGP SIGNATURE-



Re: Is there a log file of ...?

2018-09-08 Thread Hans
Am Samstag, 8. September 2018, 15:05:29 CEST schrieb Jude DaShiell:
Also usefull:

history -l   | grep what-you-remember

if you can just remeber a part of the command you used.


Have fun!

Best

Hans

> If using bash, try using the up-arrow and you should be shown your
> command history.  If your history is large enough, you'll find the
> command you used to rename the file.
> On Fri, 7 Sep 2018, Richard Owlett
> 






Re: Is there a log file of ...?

2018-09-08 Thread Jude DaShiell
If using bash, try using the up-arrow and you should be shown your
command history.  If your history is large enough, you'll find the
command you used to rename the file.
On Fri, 7 Sep 2018, Richard Owlett
wrote:

> Date: Fri, 7 Sep 2018 15:46:31
> From: Richard Owlett 
> To: debian-user 
> Subject: Is there a log file of ...?
> Resent-Date: Fri,  7 Sep 2018 19:47:20 + (UTC)
> Resent-From: debian-user@lists.debian.org
>
> Earlier today when launching a long used from a console rather than by
> clicking on an icon, I got a strange WARNING message.
>
> I reported it on a related Usenet group. I got a reply from a Windows user
> suggesting several things to investigate. A key sub-string, and its usage,
> caught my attention. I used the Mate Search Tool to locate any file with that
> sub-string. Found one. Rather than deleting it I just added some characters to
> the beginning of the filename. The purpose was to easily restore things to the
> original state. It _*APPARENTLY*_ solved my problem. Later a different path of
> investigation was suggested.
>
> I wish to restore the old filename to run a test of the 2nd suggestion.
>
> Real world intervenes - i.e. Murphy's Law
> By a weird chain of associations I was able discover its *NEW* name.
> Still not sure of its original name - but that's another issue to be explored
> on a different group.
>
> To repeat my subject line: "Is there a log file of ...?"
> In this case I know the file's extension and VERY approximately when the name
> was changed.
>
> In the appropriate time period I know that there were no more than a dozen
> files created/destroyed/renamed.
>
> Is there a relevant log file?
>
> TIA
>
>
>
>

-- 



Re: Is there a log file of ...?

2018-09-08 Thread Richard Owlett

On 09/07/2018 09:53 PM, David Wright wrote:

On Fri 07 Sep 2018 at 14:46:31 (-0500), Richard Owlett wrote:

[snip]
In the appropriate time period I know that there were no more than a
dozen files created/destroyed/renamed.


This would be very useful in future if you were unsure of the name and
location of the file sporting its new name. One way to locate those
files is like this:

$ find / -type f -cmin -2880 -a -cmin +1440 -print | less

will find files whose status information was modified between 24 and
48 hours ago. If you renamed a file, that should affect the ctime.
You can choose your numbers appropriately and focus the search by
changing / to something more specific, or even adding -name \*.ext
where ext is the known extension.


That's what I want. Thank you.





Re: Is there a log file of ...?

2018-09-07 Thread David Wright
On Fri 07 Sep 2018 at 14:46:31 (-0500), Richard Owlett wrote:
> Earlier today when launching a long used from a console rather than by
> clicking on an icon, I got a strange WARNING message.

Is that an indication that you were expecting some difference in
the result of launching (un)said command?

If so, starting with a   script   command might be advisable; this
will capture the console dialogue in a file (default "typescript").

> I reported it on a related Usenet group. I got a reply from a Windows
> user suggesting several things to investigate. A key sub-string, and
> its usage, caught my attention. I used the Mate Search Tool to locate
> any file with that sub-string. Found one. Rather than deleting it I
> just added some characters to the beginning of the filename. The
> purpose was to easily restore things to the original state. It
> _*APPARENTLY*_ solved my problem. Later a different path of
> investigation was suggested.
> 
> I wish to restore the old filename to run a test of the 2nd suggestion.
> 
> Real world intervenes - i.e. Murphy's Law
> By a weird chain of associations I was able discover its *NEW* name.
> Still not sure of its original name - but that's another issue to be
> explored on a different group.

I'm not quite sure why, given the new name, you can't recognise the
difference between what you typed at the beginning of the filename
and the remaining original part. That is, unless the file was called
ydjhsmjeieeiigeiujqkmq and you prefixed it with udcrxaglskqnebkf.
But ho hum…

> To repeat my subject line: "Is there a log file of ...?"
> In this case I know the file's extension and VERY approximately when
> the name was changed.
> 
> In the appropriate time period I know that there were no more than a
> dozen files created/destroyed/renamed.

This would be very useful in future if you were unsure of the name and
location of the file sporting its new name. One way to locate those
files is like this:

$ find / -type f -cmin -2880 -a -cmin +1440 -print | less

will find files whose status information was modified between 24 and
48 hours ago. If you renamed a file, that should affect the ctime.
You can choose your numbers appropriately and focus the search by
changing / to something more specific, or even adding -name \*.ext
where ext is the known extension.

> Is there a relevant log file?

Not in arrears. That's why it's worth copy/pasting the lines around
the warning when you post it, rather than taking the zero-content
approach as here and elsewhere. Then you could just look back at
the post. Similarly for the script. (I use the bash function
 { script "typescript-$HOSTNAME-$(date +%Y-%m-%d-%H-%M-%S)-$1" }
so that script is labelled and also can't overwrite the same file
"typescript" each time you invoke it.)

Cheers,
David.



Re: Is there a log file of ...?

2018-09-07 Thread Reco
Hi.

On Fri, Sep 07, 2018 at 02:46:31PM -0500, Richard Owlett wrote:
> In this case I know the file's extension and VERY approximately when the
> name was changed.
> 
> In the appropriate time period I know that there were no more than a dozen
> files created/destroyed/renamed.
> 
> Is there a relevant log file?

There is, but you had have to enable it first.
It's called kernel audit facility, the package is "auditd".

Reco



Re: Is there a log file of ...?

2018-09-07 Thread Dan Purgert
Richard Owlett wrote:
> [...]
> Still not sure of its original name - but that's another issue to be 
> explored on a different group.
>
> [...]
>
> Is there a relevant log file?

Logfile of "user mv'd fileA to Filea1?  Nope.  At least not unless
you've aliased mv / cp / rm to log what they're up to.


-- 
|_|O|_| Registered Linux user #585947
|_|_|O| Github: https://github.com/dpurgert
|O|O|O| PGP: 05CA 9A50 3F2E 1335 4DC5  4AEE 8E11 DDF3 1279 A281



Re: Put date on log file names?

2010-05-17 Thread Camaleón
On Mon, 17 May 2010 13:59:02 -0400, vr wrote:

 Due to message volume, I'm considering rotating my mail logs daily at my
 local time midnight and retaining about 30 days worth of files on
 disk. I'd like to have the date in the file names so visually I'll know
 what span is in each file.
 
 Can this be done? (put dates into the file name)

Sure, I do :-)

man logrotate → dateext

 Should this be done? (put the date into the file name)

Sure, I do in my fetchmail logs :-)
 
 If you're doing something like this already, how did you do it?

By defining dateext variable info the logrotate script.

***
dateext
Archive  old  versions  of  log  files  adding a daily extension like
MMDD instead of simply adding a number.
***

Greetings,

-- 
Camaleón


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/pan.2010.05.17.18.40...@gmail.com



Re: Put date on log file names?

2010-05-17 Thread Chris Jackson

vr wrote:

Due to message volume, I'm considering rotating my mail logs daily at my 
local time midnight and retaining about 30 days worth of files on 
disk. I'd like to have the date in the file names so visually I'll know 
what span is in each file.


Can this be done? (put dates into the file name)



You need the dateext option in the logrotate config. That'll mean your 
archives have the date extension, and the current one is just whatever 
it's normally called, which I guess should be OK for you?



Should this be done? (put the date into the file name)



Never caused me any problems ;)

--
Chris Jackson
Shadowcat Systems Ltd.


--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org

Archive: http://lists.debian.org/4bf1874f.60...@shadowcat.co.uk



Re: Put date on log file names?

2010-05-17 Thread Timo Boettcher
Hi!

* vr debian-u...@iotk.net wrote:
 I'd like to have the date in the file names so visually I'll know
 what span is in each file.

 Can this be done? (put dates into the file name)
Depends. See the other posts about logrotate
 Should this be done? (put the date into the file name)
No clue

 If you're doing something like this already, how did you do it?
I am logging to syslog (the protocol) and replaced syslog (the package)
with syslog-ng. syslog-ng can be configured to do this:

destination df_syslog {
file(/var/log/$HOST/$YEAR/$MONTH/$DAY/syslog
template($ISODATE $HOST $MSG\n)
owner(root) group(root) perm(0600) dir_perm(0700) create_dirs(yes));
};

This is a snipped that configures a file in a directory-structure matching
the hostname and the date (you should be able to guess the details...)

http://www.syslog.org/syslog-ng/v2/ has some more examples.

 Timo


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20100517211206.ga5...@spinnennetz.org



Re: color ls and log file perms...

1998-10-09 Thread Santiago Vila Doncel
On Sat, 3 Oct 1998, D'jinnie wrote:

 Where is the color file for the color option of ls? In slackware it's
 /etc/DIRCOLORS but I can't seem to locate it on debian :(

Maybe you are looking for this:

dircolors --print-database

[ Complete details in info format ].


Re: color ls and log file perms...

1998-10-04 Thread Torsten Hilbrich
On: Sat, 3 Oct 1998 22:37:01 -0500 (CDT) D'jinnie  writes:

 Also - since logs get rotated every night, how can I change the
 group and permissions (group readable) for all log files? I would
 like to be able to view/edit them from my user account instead of
 root...

Add your user to the group adm.

Torsten