I am going to have all my data transferred to a new PC. Is it possible to transfer the command history of the previous Linux to the new system as well? So that when I type the
history command, I get the same results as I did on the old system.
If you're using Bash then the history is kept in the file,
.bash_history, in your home directory.
This file can be copied from one system to another, it's just a text file.
$ tail -4 ~/.bash_history #1385239516 alias|grep cdc #1385240451 exit
The file is filled with lines that include a timestamp followed by the command that ran at that timestamp.
If you transfer the home directory contents as well, then yes. In bash it's /home/user/.bash_history, for example.