Solved

Trying to repeat a command (for example, r ls)

Posted on 2004-10-12
3
276 Views
Last Modified: 2006-11-17
When I type
ls -lt

I get my desired results, but when I try to repeat

r ls

I get this error message

ksh: ls:  not found
0
Comment
Question by:booksplus
  • 2
3 Comments
 
LVL 20

Accepted Solution

by:
tfewster earned 50 total points
ID: 12296599
Does any command history work?  e.g. Esc K to recall the previous command?

Does $HOME/.sh_history exist, and is it being updated each time you use a command?

Does `set |grep HIST` indicate your history file is somewhere other than $HOME/.sh_history ? And if so, do you have write permission on that file?
0
 
LVL 20

Expert Comment

by:tfewster
ID: 12300779
Thank you - But what _was_ the problem in the end?
0
 

Author Comment

by:booksplus
ID: 12301083
The problem was that the .sh_history did not exist.  AND HISTFILE = /dev/null.  So I set HISTFILE=$HOME/.sh_history
and touched .sh_history.  Works now.  Thanks.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

A metadevice consists of one or more devices (slices). It can be expanded by adding slices. Then, it can be grown to fill a larger space while the file system is in use. However, not all UNIX file systems (UFS) can be expanded this way. The conca…
I promised to write further about my project, and here I am.  First, I needed to setup the Primary Server.  You can read how in this article: Setup FreeBSD Server with full HDD encryption (http://www.experts-exchange.com/OS/Unix/BSD/FreeBSD/A_3660-S…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now