- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: History command
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
Discussions
Discussions
Forums
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
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
тАО04-22-2010 03:59 AM
тАО04-22-2010 03:59 AM
Re: History command
this directory
/root
must exist!
Does it???
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:04 AM
тАО04-22-2010 04:04 AM
Re: History command
export HISTFILE=/.sh_history (if your home is "/"; is it is /root and it exists, put /root/.sh_history)
export HISTFILE=5000
Then, try again by logout/login.
Regards,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:11 AM
тАО04-22-2010 04:11 AM
Re: History command
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:11 AM
тАО04-22-2010 04:11 AM
Solutionumask 022
touch $HOME/.sh_history
export HISTORY=$HOME/.sh_history
export HISTFILE=5000
>> $HOME=/
A very bad default location for root's $HOME. Create a separate /root directory and move all of root's files to /root, then change /etc/passwd so the $HOME directory is /root and not /, like this:
root:*:0:3:root user:/root:/sbin/sh
If you move root's $HOME on every Unix platform you have, you may avoid a total disaster in joining the rm -r * club.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:25 AM
тАО04-22-2010 04:25 AM
Re: History command
If you simply export these variables and then logout, the change is gone. You need to write it to .profile to make it permanent and working.
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:26 AM
тАО04-22-2010 04:26 AM
Re: History command
# history
sh: fc: Cannot access or open the history file.
# pwd
/
#
#
after exporting HISTFILE AND HISTSIZE logout than login same problem. You tell me from my side what infomation required, so history command work.
Dev
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:29 AM
тАО04-22-2010 04:29 AM
Re: History command
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:35 AM
тАО04-22-2010 04:35 AM
Re: History command
# echo $SHELL
/sbin/sh
m using shell.
Regards,
Dev
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:37 AM
тАО04-22-2010 04:37 AM
Re: History command
If you do not put these in root's ".profile" you will lose the variables each time you log out of the system......
Regards,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2010 04:38 AM
тАО04-22-2010 04:38 AM
Re: History command
export HISTFILE=/root/.sh_history
export HISTSIZE=5000
to your .profile and do
# mkdir /root
logout and back in.
To change root's home, modify /etc/passwd.
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!