- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: command history recall
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
02-26-2003 06:04 AM
02-26-2003 06:04 AM
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 06:07 AM
02-26-2003 06:07 AM
Re: command history recall
add this to your profile
set -o vi
HISTFILE=$HOME/.sh_history
HISTSIZE=100
Robert-Jan.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 06:08 AM
02-26-2003 06:08 AM
Re: command history recall
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 06:08 AM
02-26-2003 06:08 AM
Re: command history recall
#set -o vi
or
#ksh -o vi
THanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 06:12 AM
02-26-2003 06:12 AM
Re: command history recall
Have you set in your user profile the followings statements?:
EDITOR=vi
export EDITOR
HISTFILE=/.sh_history; export HISTFILE
HISTSIZE=
Where
And the correct way to invoke commands is by [Esc-Key] + K
Rgds
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 06:17 AM
02-26-2003 06:17 AM
Re: command history recall
I have EDITOR=VI and set -o vi in my profile.
Please help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 06:29 AM
02-26-2003 06:29 AM
Re: command history recall
here is a part of my /root/.profile
--cut----
# Be sure that VUE does not invoke tty commands
if [ ! "$VUE" ]; then
# -- Do trick to set the display in case of remote login
HOST=`who am i -R |awk '{print $NF}' | sed "s/(\(.*\))/\1/"`
if [ "$HOST" != "" ] && [ "$HOST" != ":0" ] && [ "$HOST" != ":0.0" ];
then
if [ "$HOST" = `who am i -R |awk '{print $NF}' | sed "s/(\(.*\))/\1/"` ]
then
HOST=$HOST:0.0
fi
echo " +--<<"
echo " | Remote login detected, setting DISPLAY to $HOST"
echo " +-->>"
DISPLAY=$HOST
export DISPLAY
fi
# Set up the terminal:
if [ "$TERM" = "" ]
then
eval ` tset -s -Q -m ':?hp' `
else
eval ` tset -s -Q `
fi
case `tty` in
*console*) TERM=hp ;;
*) TERM=vt100 ;;
esac
stty erase "^H" kill "^U" intr "^C" eof "^D"
stty hupcl ixon ixoff
tabs
echo
echo "Value of TERM has been set to \"$TERM\". "
export TERM
EDITOR=vi
export EDITOR
fi # if !VUE
---cut----
try it.
Robert-Jan.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 06:47 AM
02-26-2003 06:47 AM
Re: command history recall
Maybe a terminal definition is involved, try setting your TERM=hp or TERM=vt100.
If this work, pls check your current stty assignament and compare it with your original TERM definiton.
#stty -a
Rgds.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 06:59 AM
02-26-2003 06:59 AM
Re: command history recall
Trying the following shoud work.
set -o vi
or
EDITOR=vi
export EDITOR
Also set the history file size.
John Jayaseelan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 07:13 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 08:20 AM
02-26-2003 08:20 AM
Re: command history recall
EDITOR=/usr/dt/bin/dtpad.
But, EDITOR-vi is in my $HOME/.profile. So it doesn't appear that my .profile is being run, or else EDITOR is getting overwritten somewhere. Got any other suggestions?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 08:22 AM
02-26-2003 08:22 AM
Re: command history recall
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2003 05:26 PM
02-26-2003 05:26 PM
Re: command history recall
here's how:
1. login as root
2. edit your .profile
# vi .profile
3. then add:
EDITOR=vi;export EDITOR
HISTFILE=/.sh_history
HISTSIZE=500
export HISTFILE HISTSIZE
4. save the file and exit
5. to test:
# /.profile
even when you logged out you should still have this profile as it is being hard coded in the root's profile.
that's it!
regards,
danny