- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: .bash_history
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 01:55 AM
01-22-2004 01:55 AM
.bash_history
I´ve defined for "root" (.bash_profile)the following :
HISTFILE=/.bash_history
HISTSIZE=1000
Checking the .bash_history there are no new entries,,
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 02:49 AM
01-22-2004 02:49 AM
Re: .bash_history
Should be
HISTFILE=/root/.bash_history
HISTFILE=1000
export $HISTFILE
hth
J
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 02:54 AM
01-22-2004 02:54 AM
Re: .bash_history
less .bash_profile
HISTFILE=/root/.bash_history
HISTSIZE=20480
export both one,,,
Login again,,,and there are no entries in .bash_history
strange,,,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 03:05 AM
01-22-2004 03:05 AM
Re: .bash_history
env | more
see if the variables are set.
If not, take actons already recommended.
Check the permissions on .bash_history
They need to be rw by the owner and root needs to own it.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 03:34 AM
01-22-2004 03:34 AM
Re: .bash_history
All checked,,and continuos without entries
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 04:05 AM
01-22-2004 04:05 AM
Re: .bash_history
REAL equals the user name as you su to root.
REAL=`logname`
HISTFILE=$HOME/.sh_$REAL
export HISTFILE
HISTSIZE=1000; export HISTSIZE
Modify as you can to fit your shell...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 04:09 AM
01-22-2004 04:09 AM
Re: .bash_history
bash should create a history without you setting any of these variables. So to establish a baseline I do suggest to remove the current
.bash_history and remove the environment variables from the profile.
The login again, check if the history file gets/created filled.
In teh next step put in your environment variables again. Put echo statements in the script to make sure it actually gets executed during root login,
use printenv | grep -i hist to make sure the variables have been set.
HTH, Martin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 04:15 AM
01-22-2004 04:15 AM
Re: .bash_history
I do this b/c I have several folks who have root access and I like to keep all our history files separate just because it is neater imho.
HPUX creates a generic catch-all history file as well, but I like to break it out for each root user, not for security, but for ease of reference and esp if more than one user is logged in as root at one time, which happens occasionally.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 07:24 AM
01-22-2004 07:24 AM
Re: .bash_history
what does the
env |grep HIST
command returns?
there are more files for profile settings:
.bashrc
/etc/bashrc
/etc/profile
Best regards...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 10:21 PM
01-22-2004 10:21 PM
Re: .bash_history
What history file are you looking at?
/.bash_history or /root/.bash_history?
Have you made sure that you are looking in root's homedir?
Finally, it may be worth reading some documentation on bash... ;-)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-23-2004 01:21 AM
01-23-2004 01:21 AM
Re: .bash_history
Thats why I recommended using $HOME... that way you are SURE what profile you are utilizing.