LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 04-12-2006, 01:52 AM   #1
alaios
Senior Member
 
Registered: Jan 2003
Location: Aachen
Distribution: Opensuse 11.2 (nice and steady)
Posts: 2,203

Rep: Reputation: 45
Where is the bash log file?


Hi where should i Findthe bash log files?
 
Old 04-12-2006, 01:56 AM   #2
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
Do you mean the ~/.bash_history file? Or the /var/log/pacct process accounting file?
 
Old 04-12-2006, 01:54 PM   #3
alaios
Senior Member
 
Registered: Jan 2003
Location: Aachen
Distribution: Opensuse 11.2 (nice and steady)
Posts: 2,203

Original Poster
Rep: Reputation: 45
And if i want to change the historus size? (I want to keep more lines of history)
 
Old 04-12-2006, 02:41 PM   #4
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
There are environment variables you can set for this. HISTFILESIZE is the maximum number of files to store in the history file (the default on bash is 500). HISTSIZE is the maximum number of commands to remember in the command history during a session (the default here is 500 also).

Have a look at man bash and search for these as well as for .bash_profile and .bashrc for more info.
 
Old 04-28-2006, 01:42 AM   #5
alaios
Senior Member
 
Registered: Jan 2003
Location: Aachen
Distribution: Opensuse 11.2 (nice and steady)
Posts: 2,203

Original Poster
Rep: Reputation: 45
Quote:
Originally Posted by gilead
Or the /var/log/pacct process accounting file?

This file dos not exist
 
Old 04-28-2006, 03:28 AM   #6
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
That's right - you need to enable process accounting in your kernel and as root execute the following:
Code:
touch /var/log/pacct
chown root:root /var/log/pacct
chmod 0644 /var/log/pacct
if [ -x /sbin/accton ]
then 
  /sbin/accton /var/log/pacct 
  echo "Process accounting turned on." 
fi
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
cannot log in as root in bash .? Alt-F4witty Linux - Laptop and Netbook 4 01-05-2004 11:59 AM
How to control log file size in /var/log? yan Linux - General 2 10-13-2003 05:00 PM
what log file generator that support squid log? heero82 Linux - Software 2 07-11-2003 08:52 PM
iptables, changing log file from /var/log/messages acid2000 Linux - Networking 3 03-11-2003 08:38 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:23 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration