Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Other Things Gentoo
  • Search

Keeping the log of each console history [solved]

Still need help with Gentoo, and your question doesn't fit in the above forums? Here is your last bastion of hope.
Post Reply
Advanced search
5 posts • Page 1 of 1
Author
Message
Tin
Guru
Guru
Posts: 305
Joined: Thu Dec 22, 2005 10:10 am
Location: Namur, Belgium
Contact:
Contact Tin
Website

Keeping the log of each console history [solved]

  • Quote

Post by Tin » Wed Jul 19, 2006 7:27 am

Hello all, here have I a little trick to ask you.
The purpose is

I want to keep all the console history (commands typed and results)
I use aterm and tried to do some stupid stuff like

aterm > aterm.log
or
aterm | tee aterm.log

I looked into the aterm manual, but find nothing.

Each time I launch aterm, I want to keep all I typed and the result (all you can see in the aterm history lines, not only the commands history) in a log file.
As soon as I can do that, I will use it wisely by naming the log files with the date and time, and put in the cron a command to clean the logs that are too old.

I searched with google, but with words like console, history, keep, log, I find plenty of garbage but not what I am looking for :-(

Thank you for your precious help :wink:
Last edited by Tin on Wed Jul 19, 2006 9:44 am, edited 1 time in total.
Tin, the gentoobie
Top
oKtosiTe
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 122
Joined: Mon Aug 15, 2005 6:30 pm
Location: Halmstad, Sweden

  • Quote

Post by oKtosiTe » Wed Jul 19, 2006 8:12 am

Looks like you want the history of your shell, not your terminal. Don't know how one would go about logging the results though.
Ask Ubuntu | Super User
Top
Tin
Guru
Guru
Posts: 305
Joined: Thu Dec 22, 2005 10:10 am
Location: Namur, Belgium
Contact:
Contact Tin
Website

  • Quote

Post by Tin » Wed Jul 19, 2006 8:25 am

I am going forward in my search and here are the temporary results :

Yes, you are right for one point, I should look to the bash options and not to the aterm.
I tried to launch
bash | tee test.log
and what I have in test.log are the result of the commands I typed.
It is encouraging and it is a good start, we could imagine to try to merge the bash history with this log file
BUT
After thinking a bit more about it, I really need the terminal history because of these reasons :

The terminal history contains the commands I typed AND the result.
The terminal history contains also the commands and result I typed in sub-shells and especially in telnet or ssh sessions (and at work, the purpose is to keep the traces of what I really did on customers machines)

I know that with konsole, I could play with dcop to save the terminal history before closing it but since I move from kde to fluxbox, I try to find such a solution with aterm.

I continue to search :-)
Tin, the gentoobie
Top
oKtosiTe
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 122
Joined: Mon Aug 15, 2005 6:30 pm
Location: Halmstad, Sweden

  • Quote

Post by oKtosiTe » Wed Jul 19, 2006 8:33 am

I don't see how it would be possible to log the "results" of, say, elinks or less or...
Hope your search will be fruitful.
Ask Ubuntu | Super User
Top
Tin
Guru
Guru
Posts: 305
Joined: Thu Dec 22, 2005 10:10 am
Location: Namur, Belgium
Contact:
Contact Tin
Website

  • Quote

Post by Tin » Wed Jul 19, 2006 9:43 am

Ok, solution found :

use the "script" application

When you are in the terminal, type script -f my_log_file and ALL the stuff you type and all the results are logged into your file in real time.

Especially interesting for example if somebody else has to follow what you are doing, so he/she can do a tail -f on the file.

It is very impressive because the logging is realtime, there is no buffering.

I LOVE linux !
Tin, the gentoobie
Top
Post Reply

5 posts • Page 1 of 1

Return to “Other Things Gentoo”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic