bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

history EINTR bug


From: gregrwm
Subject: history EINTR bug
Date: Thu, 12 Feb 2015 08:06:14 -0600

i now suspect bash does not properly handle EINTR while handling history.

this just happened:
bash: history: write error: Interrupted system call

so i searched and found:
http://www.gnu.org/software/libc/manual/html_node/Interrupted-Primitives.html
http://stackoverflow.com/questions/5909717/interrupted-system-call-error-when-writing-to-a-pipe
http://unix.stackexchange.com/questions/102784/occasional-error-from-bash-on-aix-interrupted-system-call

i experienced the above error with bash43-030.  having experienced the
above error, and read the above pages, i now suspect bash might not
handle EINTR properly when handling history, either when servicing the
history command, or when saving history at exit.  this could explain
my seeing the above error sometimes when piping history to less.  and
this could explain the repetition of history in the quoted bug report
below.

i am happy to hear from you if you have questions, or even if you
don't.  many thanks for all your bashing.
greg

On 16 January 2014 at 16:42, gregrwm <backuppc-users@whitleymott.net> wrote:
> Configuration Information [Automatically generated, do not change]:
> Machine: i686
> OS: linux-gnu
> Compiler: gcc
> Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='i686'
> -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='i686-pc-linux-gnu'
> -DCONF_VENDOR='pc' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash'
> -DSHELL -DHAVE_CONFIG_H   -I.  -I../bash -I../bash/include
> -I../bash/lib  -D_FORTIFY_SOURCE=2 -g -O2 -fstack-protector
> --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall
> uname output: Linux celerypad 3.13.0-3-generic #18-Ubuntu SMP Mon Jan
> 13 19:16:46 UTC 2014 i686 i686 i686 GNU/Linux
> Machine Type: i686-pc-linux-gnu
>
> Bash Version: 4.2
> Patch Level: 45
> Release Status: release
>
> Description:
> portions of bash history appear repeatedly in .bash_history, and thus earlier
> session history is prematurely discarded.
>
> Repeat-By:
> not predictably repeatable.  no idea of the causing condition.
>
> Observations:
> in both examples below, the history file begins with two copies of a
> portion of the offending session, followed by *preceeding* session
> commands, followed by additional repetition of the offending session,
> followed by another session.
>
> Example #1 history:
>   first repetition:
>      1  2014-01-15Wed17:00:30  10ut  (/root/.bash_history ) root 10ut ,pts/2
>      2  2014-01-15Wed17:10:38  10ut  dfm
>      3  2014-01-15Wed17:11:11  10ut  aagi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>      4  2014-01-15Wed17:11:27  10ut  rqb vim-doc
>      5  2014-01-15Wed17:11:47  10ut  agi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>
>   second repetition:
>      6  2014-01-15Wed17:00:30  10ut  (/root/.bash_history ) root 10ut ,pts/2
>      7  2014-01-15Wed17:10:38  10ut  dfm
>      8  2014-01-15Wed17:11:11  10ut  aagi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>      9  2014-01-15Wed17:11:27  10ut  rqb vim-doc
>     10  2014-01-15Wed17:11:47  10ut  agi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>
>   *prior* session(s):
>     11  2014-01-15Wed16:31:18  10ut  apt-get install openssh-server screen
>     12  2014-01-15Wed16:31:32  10ut  apt-get install openssh-server
>     13  2014-01-15Wed16:32:04  10ut  df -m
>     14  2014-01-15Wed16:32:27  10ut  mkdir /ql
>     15  2014-01-15Wed16:32:33  10ut  mount /dev/sda1 /ql
>     16  2014-01-15Wed16:32:46   0ut  (/root/.bash_history ) root 0ut ,tty1
>     17  2014-01-15Wed16:33:59   0ut  . /ql/home/greg/
>     18  2014-01-15Wed16:34:14   0ut  rqa trusty-alternate-i386
>     19  2014-01-15Wed16:34:46   0ut  apt-get install openssh-server
>     20  2014-01-15Wed16:35:59   0ut  ag update
>     21  2014-01-15Wed16:36:48   0ut  apt-get update
>     22  2014-01-15Wed16:37:55   0ut  apt-get install openssh-server
>
>   third repetition:
>     23  2014-01-15Wed17:00:30  10ut  (/root/.bash_history ) root 10ut ,pts/2
>     24  2014-01-15Wed17:10:38  10ut  dfm
>     25  2014-01-15Wed17:11:11  10ut  aagi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     26  2014-01-15Wed17:11:27  10ut  rqb vim-doc
>     27  2014-01-15Wed17:11:47  10ut  agi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     28  2014-01-15Wed17:13:18  10ut  agi vim
>     29  2014-01-15Wed17:14:44  10ut  rqb vim
>     30  2014-01-15Wed17:14:53  10ut  agi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     31  2014-01-15Wed17:44:09  10ut  llt /var/local/?p*/*
>     32  2014-01-15Wed17:44:15  10ut  llt {,/*}/var/local/?p*/*
>     33  2014-01-15Wed17:44:48  10ut  rqa vlc
>     34  2014-01-15Wed17:48:08  10ut  dfm
>     35  2014-01-15Wed17:48:23  10ut  agi lubuntu-desktop
>
>   fourth repetition:
>     36  2014-01-15Wed17:00:30  10ut  (/root/.bash_history ) root 10ut ,pts/2
>     37  2014-01-15Wed17:10:38  10ut  dfm
>     38  2014-01-15Wed17:11:11  10ut  aagi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     39  2014-01-15Wed17:11:27  10ut  rqb vim-doc
>     40  2014-01-15Wed17:11:47  10ut  agi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     41  2014-01-15Wed17:13:18  10ut  agi vim
>     42  2014-01-15Wed17:14:44  10ut  rqb vim
>     43  2014-01-15Wed17:14:53  10ut  agi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     44  2014-01-15Wed17:44:09  10ut  llt /var/local/?p*/*
>     45  2014-01-15Wed17:44:15  10ut  llt {,/*}/var/local/?p*/*
>     46  2014-01-15Wed17:44:48  10ut  rqa vlc
>     47  2014-01-15Wed17:48:08  10ut  dfm
>     48  2014-01-15Wed17:48:23  10ut  agi lubuntu-desktop
>
>   fifth repetition, complete session:
>     49  2014-01-15Wed17:00:30  10ut  (/root/.bash_history ) root 10ut ,pts/2
>     50  2014-01-15Wed17:10:38  10ut  dfm
>     51  2014-01-15Wed17:11:11  10ut  aagi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     52  2014-01-15Wed17:11:27  10ut  rqb vim-doc
>     53  2014-01-15Wed17:11:47  10ut  agi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     54  2014-01-15Wed17:13:18  10ut  agi vim
>     55  2014-01-15Wed17:14:44  10ut  rqb vim
>     56  2014-01-15Wed17:14:53  10ut  agi vim vim-doc htop twm xterm 
> vnc4server xvnc4viewer vlc vlc-plugin-jack xpdf
>     57  2014-01-15Wed17:44:09  10ut  llt /var/local/?p*/*
>     58  2014-01-15Wed17:44:15  10ut  llt {,/*}/var/local/?p*/*
>     59  2014-01-15Wed17:44:48  10ut  rqa vlc
>     60  2014-01-15Wed17:48:08  10ut  dfm
>     61  2014-01-15Wed17:48:23  10ut  agi lubuntu-desktop
>     62  2014-01-15Wed18:04:46  10ut  agi rsync
>     63  2014-01-15Wed18:06:33  10ut  rqa rsync
>     64  2014-01-15Wed18:06:56  10ut  rqb rsync
>     65  2014-01-15Wed18:07:01  10ut  - /var/local/dpkg/rqa.2014-01-15.rsync
>     66  2014-01-15Wed18:07:40  10ut  agi lubuntu-desktop
>     67  2014-01-15Wed21:42:36  10ut  rqb lubuntu-desktop
>     68  2014-01-16Thu10:41:56  10ut  htop
>     69  2014-01-16Thu10:46:35  10ut  dfm
>     70  2014-01-16Thu10:47:21  10ut  swapon -s
>     71  2014-01-16Thu10:51:43  10ut  cfdisk
>     72  2014-01-16Thu10:57:08  10ut  ll /d*/d*/*d/*
>     73  2014-01-16Thu11:02:17  10ut  lt /~/*fst*
>     74  2014-01-16Thu11:29:50  10ut  b {,/*}/etc/fstab
>     75  2014-01-16Thu11:32:02  10ut  cfdisk
>     76  2014-01-16Thu11:36:29  10ut  eb
>
>   additional sessions:
>     77  2014-01-15Wed17:17:19  20ut  (/root/.bash_history 
> 2014-01-15Wed17:13:09) root 20ut ,pts/3
>     78  2014-01-15Wed17:17:24  20ut  ll /d*/d*/*d/*
>     79  2014-01-15Wed17:18:37  20ut  cfdisk
>     80  2014-01-15Wed17:30:34  20ut  lt 
> {,/*}/boot/grub{,/*}/*{grub*c*f,menu*lst}*
>     81  2014-01-15Wed17:31:08  20ut  lt 
> {,/*}/boot/grub{,/*}/*{grub*c*f,menu*lst,core*im*}*
>     82  2014-01-15Wed17:48:52  20ut  - /var/local/dpkg/rqb.2014-01-15.vim-doc
>     83  2014-01-15Wed17:56:41  20ut  llt {,/*}/h*/*/.ss*/*
>     84  2014-01-15Wed17:57:08  20ut  lu {,/*}/h*/*/.ss*/*
>     85  2014-01-15Wed17:57:29  20ut  - /ql/home/k/.ssh
>     86  2014-01-15Wed18:12:11  20ut  cP /tmp/10_linux /etc/grub.d/10_linux
>     87  2014-01-15Wed18:12:16  20ut  b /etc/grub.d/10_linux
>     88  2014-01-15Wed18:14:07  20ut  mv -vb /hu /hx
>     89  2014-01-15Wed18:14:12  20ut  mount /hx
>     90  2014-01-15Wed18:14:56  20ut  b /hx/boot/grub/menu.lst
>     91  2014-01-15Wed18:15:35  20ut  lt {,/*}/etc/default/grub
>     92  2014-01-15Wed18:15:41  20ut  vid {,/*}/etc/default/grub
>     93  2014-01-15Wed18:17:02  20ut  b {,/*}/etc/default/grub
>     94  2014-01-16Thu10:36:51  20ut  u mino
>     95  2014-01-15Wed17:15:33  00ut  (/root/.bash_history 
> 2014-01-15Wed17:13:09) root 00ut ,pts/1
>     96  2014-01-15Wed17:16:07  00ut  lt {,/*}/etc/grub.d/40_custom
>     97  2014-01-15Wed17:16:14  00ut  lt {,/*}/etc/fstab
>     98  2014-01-15Wed17:16:18  00ut  b {,/*}/etc/fstab
>     99  2014-01-15Wed17:16:22  00ut  b {,/*}/etc/grub.d/40_custom
>    100  2014-01-15Wed17:16:35  00ut  vim /etc/fstab
>    101  2014-01-15Wed18:09:40  00ut  LLt. /tmp
>    102  2014-01-15Wed18:13:26  00ut  dfm
>    103  2014-01-15Wed18:13:34  00ut  md /hu
>    104  2014-01-15Wed18:13:37  00ut  mount /hu
>    105  2014-01-15Wed18:13:51  00ut  t /etc/fstab
>    106  2014-01-16Thu11:38:04  00ut  eb
>
> Example #2 history:
>   first repetition:
>      1  2014-01-06Mon15:42:19  00us  (/root/.bash_history ) root 00us ,pts/0
>      2  2014-01-06Mon15:42:32  00us  ag update
>      3  2014-01-06Mon15:45:08  00us  dfm
>      4  2014-01-06Mon15:45:29  00us  bim /etc/fstab
>      5  2014-01-06Mon15:48:53  00us  . /pl/var/cache/ap
>      6  2014-01-06Mon15:48:55  00us  . /pl/var/cache/apt
>      7  2014-01-06Mon15:49:00  00us  LLt.
>      8  2014-01-06Mon15:49:15  00us  - *
>      9  2014-01-06Mon16:41:00  00us  . /etc/init.d
>     10  2014-01-06Mon16:41:17  00us  ll *ootl*
>     11  2014-01-06Mon16:41:43  00us  -~ *ootl*
>     12  2014-01-06Mon16:42:18  00us  l *remo*
>     13  2014-01-06Mon19:41:25  00us  -~ /etc/grub.d/30_os-prober
>     14  2014-01-06Mon19:41:45  00us  b /etc/grub.d/10_linux
>     15  2014-01-06Mon19:41:50  00us  b /etc/grub.d/00_header
>     16  2014-01-06Mon19:51:50  00us  agp gcc-4.6-base
>     17  2014-01-06Mon19:52:50  00us  rqb gcc-4.6-base
>     18  2014-01-06Mon19:53:32  00us  agp friendly-recovery
>     19  2014-01-06Mon19:55:35  00us  agp grub-gfxpayload-lists
>
>   second repetition:
>     20  2014-01-06Mon15:42:19  00us  (/root/.bash_history ) root 00us ,pts/0
>     21  2014-01-06Mon15:42:32  00us  ag update
>     22  2014-01-06Mon15:45:08  00us  dfm
>     23  2014-01-06Mon15:45:29  00us  bim /etc/fstab
>     24  2014-01-06Mon15:48:53  00us  . /pl/var/cache/ap
>     25  2014-01-06Mon15:48:55  00us  . /pl/var/cache/apt
>     26  2014-01-06Mon15:49:00  00us  LLt.
>     27  2014-01-06Mon15:49:15  00us  - *
>     28  2014-01-06Mon16:41:00  00us  . /etc/init.d
>     29  2014-01-06Mon16:41:17  00us  ll *ootl*
>     30  2014-01-06Mon16:41:43  00us  -~ *ootl*
>     31  2014-01-06Mon16:42:18  00us  l *remo*
>     32  2014-01-06Mon19:41:25  00us  -~ /etc/grub.d/30_os-prober
>     33  2014-01-06Mon19:41:45  00us  b /etc/grub.d/10_linux
>     34  2014-01-06Mon19:41:50  00us  b /etc/grub.d/00_header
>     35  2014-01-06Mon19:51:50  00us  agp gcc-4.6-base
>     36  2014-01-06Mon19:52:50  00us  rqb gcc-4.6-base
>     37  2014-01-06Mon19:53:32  00us  agp friendly-recovery
>     38  2014-01-06Mon19:55:35  00us  agp grub-gfxpayload-lists
>
>   *prior* session(s):
>     39  2014-01-07Tue02:35:32  00us  pg SCR
>     40  2014-01-07Tue02:35:56  00us  (/root/.bash_history 
> 2014-01-06Mon19:55:40) root 00us ,pts/6
>     41  2014-01-07Tue02:36:03  00us  pg SC
>     42  2014-01-07Tue02:27:53   0us  (/root/.bash_history 
> 2014-01-06Mon19:55:40) root 0us ,pts/5
>     43  2014-01-07Tue02:35:19   0us  sa
>
>   third repetition, complete session:
>     44  2014-01-06Mon15:42:19  00us  (/root/.bash_history ) root 00us ,pts/0
>     45  2014-01-06Mon15:42:32  00us  ag update
>     46  2014-01-06Mon15:45:08  00us  dfm
>     47  2014-01-06Mon15:45:29  00us  bim /etc/fstab
>     48  2014-01-06Mon15:48:53  00us  . /pl/var/cache/ap
>     49  2014-01-06Mon15:48:55  00us  . /pl/var/cache/apt
>     50  2014-01-06Mon15:49:00  00us  LLt.
>     51  2014-01-06Mon15:49:15  00us  - *
>     52  2014-01-06Mon16:41:00  00us  . /etc/init.d
>     53  2014-01-06Mon16:41:17  00us  ll *ootl*
>     54  2014-01-06Mon16:41:43  00us  -~ *ootl*
>     55  2014-01-06Mon16:42:18  00us  l *remo*
>     56  2014-01-06Mon19:41:25  00us  -~ /etc/grub.d/30_os-prober
>     57  2014-01-06Mon19:41:45  00us  b /etc/grub.d/10_linux
>     58  2014-01-06Mon19:41:50  00us  b /etc/grub.d/00_header
>     59  2014-01-06Mon19:51:50  00us  agp gcc-4.6-base
>     60  2014-01-06Mon19:52:50  00us  rqb gcc-4.6-base
>     61  2014-01-06Mon19:53:32  00us  agp friendly-recovery
>     62  2014-01-06Mon19:55:35  00us  agp grub-gfxpayload-lists
>     63  2014-01-06Mon19:56:31  00us  agp laptop-detect
>     64  2014-01-06Mon19:57:52  00us  agp libapt-inst1.4
>     65  2014-01-06Mon19:58:54  00us  agp libbind9-80
>     66  2014-01-07Tue02:39:16  00us  agi aria2
>     67  2014-01-07Tue02:42:52  00us  . /tmp
>     68  2014-01-07Tue02:43:18  00us   u mino
>     69  2014-01-07Tue09:45:15  00us  eb
>
>   additional session:
>     70  2014-01-06Mon15:42:55  10us  (/root/.bash_history ) root 10us ,pts/1
>     71  2014-01-06Mon15:44:53  10us  agu
>     72  2014-01-06Mon15:47:53  10us  k %
>     73  2014-01-06Mon15:48:27  10us  umount /var/cache/apt
>     74  2014-01-06Mon15:48:34  10us  ag update
>     75  2014-01-06Mon15:49:36  10us  agu
>     76  2014-01-06Mon19:45:23  10us  rqa agu
>     77  2014-01-06Mon19:54:02  10us  rql friendly-recovery
>     78  2014-01-07Tue02:55:47  10us  vim /pv/etc/grub.d/40_custom
>     79  2014-01-07Tue09:30:23  10us  dfm
>     80  2014-01-07Tue09:39:01  10us  mv /tmp/t* /
>     81  2014-01-07Tue09:39:06  10us  ll. /
>     82  2014-01-07Tue09:41:22  10us  apt-get install xorg
>     83  2014-01-07Tue09:43:28  10us  rqb xorg
>     84  2014-01-07Tue09:45:25  10us  eb
>
> Example #1 .bash_history:
>  #1389826830
>  (/root/.bash_history ) root 10ut ,pts/2
>  #1389827438
>  dfm
>  #1389827471
>  aagi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389827487
>  rqb vim-doc
>  #1389827507
>  agi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389826830
>  (/root/.bash_history ) root 10ut ,pts/2
>  #1389827438
>  dfm
>  #1389827471
>  aagi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389827487
>  rqb vim-doc
>  #1389827507
>  agi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389825078
>  apt-get install openssh-server screen
>  #1389825092
>  apt-get install openssh-server
>  #1389825124
>  df -m
>  #1389825147
>  mkdir /ql
>  #1389825153
>  mount /dev/sda1 /ql
>  #1389825166
>  (/root/.bash_history ) root 0ut ,tty1
>  #1389825239
>  . /ql/home/greg/
>  #1389825254
>  rqa trusty-alternate-i386
>  #1389825286
>  apt-get install openssh-server
>  #1389825359
>  ag update
>  #1389825408
>  apt-get update
>  #1389825475
>  apt-get install openssh-server
>  #1389826830
>  (/root/.bash_history ) root 10ut ,pts/2
>  #1389827438
>  dfm
>  #1389827471
>  aagi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389827487
>  rqb vim-doc
>  #1389827507
>  agi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389827598
>  agi vim
>  #1389827684
>  rqb vim
>  #1389827693
>  agi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389829449
>  llt /var/local/?p*/*
>  #1389829455
>  llt {,/*}/var/local/?p*/*
>  #1389829488
>  rqa vlc
>  #1389829688
>  dfm
>  #1389829703
>  agi lubuntu-desktop
>  #1389826830
>  (/root/.bash_history ) root 10ut ,pts/2
>  #1389827438
>  dfm
>  #1389827471
>  aagi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389827487
>  rqb vim-doc
>  #1389827507
>  agi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389827598
>  agi vim
>  #1389827684
>  rqb vim
>  #1389827693
>  agi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389829449
>  llt /var/local/?p*/*
>  #1389829455
>  llt {,/*}/var/local/?p*/*
>  #1389829488
>  rqa vlc
>  #1389829688
>  dfm
>  #1389829703
>  agi lubuntu-desktop
>  #1389826830
>  (/root/.bash_history ) root 10ut ,pts/2
>  #1389827438
>  dfm
>  #1389827471
>  aagi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389827487
>  rqb vim-doc
>  #1389827507
>  agi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389827598
>  agi vim
>  #1389827684
>  rqb vim
>  #1389827693
>  agi vim vim-doc htop twm xterm vnc4server xvnc4viewer vlc vlc-plugin-jack 
> xpdf
>  #1389829449
>  llt /var/local/?p*/*
>  #1389829455
>  llt {,/*}/var/local/?p*/*
>  #1389829488
>  rqa vlc
>  #1389829688
>  dfm
>  #1389829703
>  agi lubuntu-desktop
>  #1389830686
>  agi rsync
>  #1389830793
>  rqa rsync
>  #1389830816
>  rqb rsync
>  #1389830821
>  - /var/local/dpkg/rqa.2014-01-15.rsync
>  #1389830860
>  agi lubuntu-desktop
>  #1389843756
>  rqb lubuntu-desktop
>  #1389890516
>  htop
>  #1389890795
>  dfm
>  #1389890841
>  swapon -s
>  #1389891103
>  cfdisk
>  #1389891428
>  ll /d*/d*/*d/*
>  #1389891737
>  lt /~/*fst*
>  #1389893390
>  b {,/*}/etc/fstab
>  #1389893522
>  cfdisk
>  #1389893789
>  eb
>  #1389827839
>  (/root/.bash_history 2014-01-15Wed17:13:09) root 20ut ,pts/3
>  #1389827844
>  ll /d*/d*/*d/*
>  #1389827917
>  cfdisk
>  #1389828634
>  lt {,/*}/boot/grub{,/*}/*{grub*c*f,menu*lst}*
>  #1389828668
>  lt {,/*}/boot/grub{,/*}/*{grub*c*f,menu*lst,core*im*}*
>  #1389829732
>  - /var/local/dpkg/rqb.2014-01-15.vim-doc
>  #1389830201
>  llt {,/*}/h*/*/.ss*/*
>  #1389830228
>  lu {,/*}/h*/*/.ss*/*
>  #1389830249
>  - /ql/home/k/.ssh
>  #1389831131
>  cP /tmp/10_linux /etc/grub.d/10_linux
>  #1389831136
>  b /etc/grub.d/10_linux
>  #1389831247
>  mv -vb /hu /hx
>  #1389831252
>  mount /hx
>  #1389831296
>  b /hx/boot/grub/menu.lst
>  #1389831335
>  lt {,/*}/etc/default/grub
>  #1389831341
>  vid {,/*}/etc/default/grub
>  #1389831422
>  b {,/*}/etc/default/grub
>  #1389890211
>  u mino
>  #1389827733
>  (/root/.bash_history 2014-01-15Wed17:13:09) root 00ut ,pts/1
>  #1389827767
>  lt {,/*}/etc/grub.d/40_custom
>  #1389827774
>  lt {,/*}/etc/fstab
>  #1389827778
>  b {,/*}/etc/fstab
>  #1389827782
>  b {,/*}/etc/grub.d/40_custom
>  #1389827795
>  vim /etc/fstab
>  #1389830980
>  LLt. /tmp
>  #1389831206
>  dfm
>  #1389831214
>  md /hu
>  #1389831217
>  mount /hu
>  #1389831231
>  t /etc/fstab
>  #1389893884
>  eb
>
> Example #2 .bash_history:
>  #1389044539
>  (/root/.bash_history ) root 00us ,pts/0
>  #1389044552
>  ag update
>  #1389044708
>  dfm
>  #1389044729
>  bim /etc/fstab
>  #1389044933
>  . /pl/var/cache/ap
>  #1389044935
>  . /pl/var/cache/apt
>  #1389044940
>  LLt.
>  #1389044955
>  - *
>  #1389048060
>  . /etc/init.d
>  #1389048077
>  ll *ootl*
>  #1389048103
>  -~ *ootl*
>  #1389048138
>  l *remo*
>  #1389058885
>  -~ /etc/grub.d/30_os-prober
>  #1389058905
>  b /etc/grub.d/10_linux
>  #1389058910
>  b /etc/grub.d/00_header
>  #1389059510
>  agp gcc-4.6-base
>  #1389059570
>  rqb gcc-4.6-base
>  #1389059612
>  agp friendly-recovery
>  #1389059735
>  agp grub-gfxpayload-lists
>  #1389044539
>  (/root/.bash_history ) root 00us ,pts/0
>  #1389044552
>  ag update
>  #1389044708
>  dfm
>  #1389044729
>  bim /etc/fstab
>  #1389044933
>  . /pl/var/cache/ap
>  #1389044935
>  . /pl/var/cache/apt
>  #1389044940
>  LLt.
>  #1389044955
>  - *
>  #1389048060
>  . /etc/init.d
>  #1389048077
>  ll *ootl*
>  #1389048103
>  -~ *ootl*
>  #1389048138
>  l *remo*
>  #1389058885
>  -~ /etc/grub.d/30_os-prober
>  #1389058905
>  b /etc/grub.d/10_linux
>  #1389058910
>  b /etc/grub.d/00_header
>  #1389059510
>  agp gcc-4.6-base
>  #1389059570
>  rqb gcc-4.6-base
>  #1389059612
>  agp friendly-recovery
>  #1389059735
>  agp grub-gfxpayload-lists
>  #1389083732
>  pg SCR
>  #1389083756
>  (/root/.bash_history 2014-01-06Mon19:55:40) root 00us ,pts/6
>  #1389083763
>  pg SC
>  #1389083273
>  (/root/.bash_history 2014-01-06Mon19:55:40) root 0us ,pts/5
>  #1389083719
>  sa
>  #1389044539
>  (/root/.bash_history ) root 00us ,pts/0
>  #1389044552
>  ag update
>  #1389044708
>  dfm
>  #1389044729
>  bim /etc/fstab
>  #1389044933
>  . /pl/var/cache/ap
>  #1389044935
>  . /pl/var/cache/apt
>  #1389044940
>  LLt.
>  #1389044955
>  - *
>  #1389048060
>  . /etc/init.d
>  #1389048077
>  ll *ootl*
>  #1389048103
>  -~ *ootl*
>  #1389048138
>  l *remo*
>  #1389058885
>  -~ /etc/grub.d/30_os-prober
>  #1389058905
>  b /etc/grub.d/10_linux
>  #1389058910
>  b /etc/grub.d/00_header
>  #1389059510
>  agp gcc-4.6-base
>  #1389059570
>  rqb gcc-4.6-base
>  #1389059612
>  agp friendly-recovery
>  #1389059735
>  agp grub-gfxpayload-lists
>  #1389059791
>  agp laptop-detect
>  #1389059872
>  agp libapt-inst1.4
>  #1389059934
>  agp libbind9-80
>  #1389083956
>  agi aria2
>  #1389084172
>  . /tmp
>  #1389084198
>   u mino
>  #1389109515
>  eb
>  #1389044575
>  (/root/.bash_history ) root 10us ,pts/1
>  #1389044693
>  agu
>  #1389044873
>  k %
>  #1389044907
>  umount /var/cache/apt
>  #1389044914
>  ag update
>  #1389044976
>  agu
>  #1389059123
>  rqa agu
>  #1389059642
>  rql friendly-recovery
>  #1389084947
>  vim /pv/etc/grub.d/40_custom
>  #1389108623
>  dfm
>  #1389109141
>  mv /tmp/t* /
>  #1389109146
>  ll. /
>  #1389109282
>  apt-get install xorg
>  #1389109408
>  rqb xorg
>  #1389109525
>  eb
>
> relevant portions of .bashrc:
> alias funct=function
> alias t='less -n'
> alias tn=less
> set -o notify
> set -o noclobber
> set -o physical
> shopt -s dotglob extglob nocaseglob histappend histverify histreedit
> checkwinsize
> shopt -u sourcepath
> HISTSIZE=1999
> HISTFILESIZE=49999
> HISTCONTROL=ignoredups
> HISTIGNORE=j:f:b:-:s:h:H:v:l.:ll.:lt.:llt.
> FIGNORE='.TBL:.o:~'
> HISTTIMEFORMAT="%F%a%T  " IFSo=$IFS
> funct h_()(IFS= j= b="      ";set -f;while read -r h;do IFS=$IFSo i=($h)      
>   #augment history listing with window column after date column
>    [[ ${i[2]} = \(/*/.bash_history ]]&&j=${i[${#i[@]}-2]};echo 
> "${h::28}${b:${#j}}$j${h:28}";IFS=;done)
> funct h { if [[ $@ ]];then history "$@";else history|h_ 2>&1|tn;fi;}
> funct H { history|h_|sort -k2,2 -k1n 2>&1|tn;}
> alias histtit='PROMPT_COMMAND='\''history -s "($HISTFILE $(date +%F%a%T 
> -r$HISTFILE 2>/dev/null||true)) $USER $WINDOW$((SHLVL-1))$disrel 
> $DISPLAY,$tty";unset PROMPT_COMMAND'\'
> histtit



reply via email to

[Prev in Thread] Current Thread [Next in Thread]