Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [history]

The history command can be used to retrieve commands you have previously typed in a shell.

-4
votes
0answers
68 views

How can I get the history of all no success commands that i typed on Ubuntu? [on hold]

when I run history, it gives just the success commands.
2
votes
1answer
44 views

Save all command and all output (using script across terminals)

For a short period of time, I want to save the command history and output of every command I run in any terminal I open. It should all go in the same file. So basically I want to run a command (or ...
0
votes
0answers
38 views

up and down arrow key doesn't working in ubuntu 1804

i've installed ubuntu 1804 i wanna choose the privious command to run of course i can using 'history' command to check but using up/down key to choose is more convinient, like in other OS
3
votes
1answer
124 views

How to clear history in Gedit? (Ubuntu 18.04)

I was just wondering how to clear the recently opened documents history on Gedit? I've looked but can't find anything on it. Thanks in Advanced!
1
vote
0answers
45 views

Terminal/Shell config Question

Ubuntu 18.04.1 LTS TERM=wyse60 SHELL=/bin/bash set -o vi telnet using TinyTerm v4.20.1306 with wyse60 emulation My question is: Is there something I can add to .bash_profile to allow .bash_history ...
5
votes
1answer
607 views

Command history seems to be missing the first 75 lines

A couple of years ago, I did the automatic distribution update from 14.04 to 16.04. For the first time in my life, I was able to continue to use the computer after the automatic distribution update. ...
0
votes
0answers
50 views

capture the command that launched the running process in my shell

I try to make the title of my windows in GNU screen automatically equal to the path of the working directory PLUS the process running if there is one (e.g: npm start or vim file.js) for that purpose ...
1
vote
1answer
60 views

Bionic Beaver Nautilus list of visited servers

Newly switched from 16.04 LTS to Bionic Beaver. Yet in 16.04 several smb servers were stored to Nautilus server history (or so, sorry don't know the exact terminology). Now after upgrade to B. Beaver ...
0
votes
2answers
85 views

Cleaning up the whole trace of one's activity on ubuntu

I am working on an ubuntu 16.04 LTS, The computer I am working on is temporarily in my possession, given to me by my employer. So at some point I have to give it back. What exactly should I consider ...
2
votes
1answer
265 views

Ubuntu 16.04 experienced an internal error

My Ubuntu was stuck in a login loophole hence I removed lightdm and installed gdm instead. Somewhere in the instructions someone suggested to add a sleep 1 in a file. After I did so the system has ...
2
votes
1answer
41 views

Erase Recent Folder in Nautilus via Terminal Command

Can I empty out Recent folder in Nautilus by typing terminal command, and if yes, do I have to re-log in to my system to see the effect?
0
votes
1answer
43 views

How can I audit commands executed by a user without installing acct

I want to audit commands executed for two accounts on my ubuntu desktop about a year ago. I know of acct [sudo apt-get install acct] where I can run lastcomm, dump-acct, dump-utmp but I want a ...
2
votes
2answers
71 views

Cannot connect to the internet after cleaning history

I was using a friend's laptop with an Ubuntu 16 OS. I was asked to clean the historic files an after browsing a few websites, I used: cat /dev/null > ~/.bash_history command which appear not ...
1
vote
1answer
64 views

Usermod and history output

I used usermod -G without the -a option, now the main user has only 2 groups. I want to restore all the previous groups but the problem is that i need to list all the groups before the changes I am ...
9
votes
1answer
303 views

Is there any way to check history only of current session?

I wanted to know if there is any command or any other way I can check my command history only in the current session.
2
votes
0answers
158 views

How to delete bash history for specific date range [duplicate]

I know how to delete the complete history of all the commands I have ran in my bash terminal, however, I don't want to delete all the history. What I want is to delete the history for a specific ...
1
vote
0answers
49 views

Wanted to disable history -c for all users except the one with sudo rights?

I am able to secure .bash_history and .profile files so that user cannot delete or edit those files and cannot change shell as well. I needed this for bastion host for all production instances. I ...
12
votes
1answer
350 views

Terminal replacing ! followed by a number with a command

I'm very confused about my ubuntu terminal session, it seems to replace sections in commands that start by ! followed by a number with seemingly random commands. It does that with !87 replacing it ...
1
vote
1answer
3k views

How can I clear screen command history? [duplicate]

I'm using screen command after ssh to a public remote machine with Ubuntu 14.04 so that I could continue my sessions whenever I want. I've found that some admins are tracking my command history and ...
0
votes
2answers
198 views

How to store the output of `pwd` along with regular commands in history? [duplicate]

I want to know how I can include the current working directory (output of pwd) to the commands stored in .bash_history file. I want this because sometimes same command is executed from different ...
-1
votes
2answers
151 views

Add to History Script not working

I am trying to add lines from a file to my history, but it just adds the program code! What am I doing wrong? #!/bin/bash HISTFILE=~/.bash_history set -o history cat file.txt | while read line do ...
4
votes
1answer
942 views

Can I get the commands from history executed in bash in the last 15 mins?

I want to put in place a cron job that sends me notification about a particular command executed in the last 15 mins. I can get the history along with timestamp using export HISTTIMEFORMAT='%F %T', ...
16
votes
1answer
3k views

How can I view history in terminal for specific date?

How can I view the terminal history for a specific date? For example today is 4-apr and I want to view the history of 31-mar
3
votes
2answers
337 views

!x not found - bash script

I made a simple bash script to run a range of commands in your history, but it's not working. read -p "control + c to cancel" for i in $(seq $1 $2) ...
6
votes
3answers
15k views

Finding an old command in the shell history [duplicate]

How can I find an old command I ran in my terminal? I used an appengine command and wish to just find it in my local command history without researching it online again.
0
votes
0answers
72 views

Terminal can't scroll after overnight idle computing

I'm on unbuntu 16.04, using ubuntu terminal, running zsh with oh-my-zsh. I'm on a ssh session to a remote computer with the same configuration. I launched a big computing and forgot to output the ...
0
votes
1answer
132 views

How to clear search history in 'Artha'?

Artha is a dictionary application for Ubuntu. I want to know that is there a way to delete the search history from it?
1
vote
1answer
62 views

Upon restart my ubuntu commands history number changed

While restarting my ubuntu 16.04 OS, my terminal commands history numbers is changed, only the history numbers is changed my history is saving perfectly. History numbers always display numbers between ...
0
votes
2answers
1k views

Laptop web camera “active” history

Is there a way to see the history of when my web camera has been active? For example during the previous day?
6
votes
5answers
971 views

Searchable Clipboard Manager, like ctrl-r in bash

I am looking for a clipboard manager with search functionality. I love CtrlR in the bash shell and would like to have the same functionality like that in clipboard manager for my desktop. Up to now I ...
4
votes
1answer
55 views

Thunderbird: History of seen Messages

Is there a way in thunderbird to step backward and forward in the history of last messages? Like in firefox: It has a history of the last visited pages. I would like to have a history of the last ...
1
vote
3answers
601 views

View terminal history without the line number

How can I get the Ubuntu terminal history without the line number? history history command returns the previous commands with line number. I am looking for something like: cd tizen-sdk\tools ...
5
votes
1answer
2k views

What's the difference between “history -w” and the action of closing a shell session?

I did some tests about history: I ran history-c and then logged out. This cleared history for the current shell. I ran history -c && history -w. This deleted everything. I deleted the entire ...
8
votes
2answers
4k views

How to save terminal history to a file from a bash file?

I am trying to create a bash script that will save the terminal history to a file called hist.txt. Using history > hist.txt doesn't seem to work in the bash script, but works fine when executed in ...
3
votes
4answers
2k views

How do I make Bash history undeleteable?

The Bash history can get deleted just by deleting the file which contains. How can I protect the history from being cleared / deleted?
0
votes
0answers
89 views

Ubuntu Server Full Log?

Is there anyway to check a full log since the build of Ubuntu Server? I have tried last lastlog Which shows last logged users, and: sudo less /var/log/auth.log It's great BUT it only shows the ...
3
votes
1answer
202 views

Star in Bash history

I'm just scrolling through all the commands i have recently used in computer which is running Ubuntu. I have found one line which looks like blank but i'm not sure about it it contains star right ...
2
votes
1answer
387 views

Bash reverse-i-search wrong prompt output

After modifying my .bashrc to add color to prompt, reverse-i-search output formatting is messed up. Typing CTRL+R to start a new search, prompt output is OK: After pressing right arrow to modify the ...
0
votes
2answers
90 views

Is there a way to make some entries in history “sticky”?

I use the history / CtrlR thing quite a bit, but from time to time either a command I use regularly (but not regularly enough, apparently) "fades out" behind my command history threshold, or some ...
12
votes
5answers
35k views

bash shell output history file location

Where does the bash shell store the actual terminal session? I want to read the output of commands I used before. All I can find googling is how to store the output of a command. Since output is ...
1
vote
0answers
110 views

How to Show History of Port State/Activity?

Let's say I have an open port on my PC like 6789. I use this port for a special purpose. But, suddenly I found the port 6789 is not listed in netstat -ntlp (port closed). How can I see the history of ...
1
vote
1answer
3k views

How to delete chat history in skype for only one contact in Linux

I'm trying to delete chat history for only one contact in Linux. I've tried sqlite: http://www.sqlite.org/download.html but it removes chat conversation for a while and after restart skype it ...
0
votes
1answer
6k views

Putty SSH client command history? [duplicate]

I connect to my server via Putty SSH client. With the key ↑ I see previous entered commands, one by one. I just wondering is there a some command, which show all previous entered commands out of a ...
0
votes
1answer
47 views

Same commands execute when restart terminal

So, some time ago, I copied csv data from a webpage into terminal to save it to a csv file, like echo "field1,field2,field3,...,fieldn, with about 20 lines of text. I did this because I couldn't ...
1
vote
0answers
42 views

Record date when command was executed in the terminal? [duplicate]

bash_history lists only the previous commands executed. Is it possible to record the times ie. date when they were executed?
0
votes
1answer
980 views

How to run an anonymous terminal session?

This question by Paranoid Panda asks about incognito terminal use. This means history is not recorded in bash_history; so you can't access commands that were entered during that session. However this ...
0
votes
1answer
198 views

Lost firefox tabs due to crash

I use the Save Session version 1.3.1.6.1 plugin in firefox to save my current sessions. I had kept 3 windows full of tabs for all almost a year when yesterday my firefox crashed. Now I can't find any ...
1
vote
1answer
59 views

How to record all modifications to directories, subdirectories and files in one session?

How can I record all the modifications to directories, subdirectories and files made during one session (ie. during login time)? For example, listing all the files/folders that were modified, and ...
-2
votes
3answers
192 views

Any way to see if a long running process bash command succeeded? [closed]

I have a long running process that was parsing text and my laptop died at some point because it was unplugged. I really don't want to unnecessarily run the process again because it takes over a day, ...
3
votes
1answer
723 views

How to remove command-line history from a specific time period?

How can I remove command-line history over a specific time period? Is it possible do so with only one command?