PuTTY: Change default SSH login directory [closed] PuTTY: Change default SSH login directory [closed] linux linux

PuTTY: Change default SSH login directory [closed]


You can also change the directory within PuTTY itself:

  1. Configuration → Connection → SSH

  2. Fill in the "Remote command" field with the following:

    cd subdir/subdir ; /bin/bash


  • Add cd subdir/subdir to ~/.bashrc or ~/.bash_profile, or
  • change the home directory of the user.


You could use screen to keep your current directory by always logging into the same screen session.

Add the screen command with parameters to your putty saved session under SSH>Remote Command.See the screen documentation for which parameters to use.

screen -R -O -t mysession -S mysession -f