title: How do I change directories using Paramiko?
body: <p><a href="https://stackoverflow.com/questions/8916650/paramiko-stderr-object-wont-reset">Drush commands not executing using Paramiko</a></p>
  
  <p>I posted the above question regarding a persistent error message that I receive using Paramiko. I do not think it is related to my next question, but it might be.</p>
  
  <p>I can successfully connect to my server via SSH using Paramiko. I can execute commands like ls or pwd. What I can't seem to do is change directories. I can send the command "cd .." for example, but when I follow up with "pwd" it shows that I haven't changed directories. It just lists the initial directory I am in when I log in. </p>
  
  <pre><code>&gt;&gt;&gt; stdin, stdout, stderr = myssh.exec_command("pwd")
  &gt;&gt;&gt; stdout.readlines()
  ['/big/dom/home/myid\n']
  &gt;&gt;&gt; stdin, stdout, stderr = myssh.exec_command("cd ../")
  &gt;&gt;&gt; stdout.readlines()
  []
  &gt;&gt;&gt; stdin, stdout, stderr = myssh.exec_command("pwd")
  &gt;&gt;&gt; stdout.readlines()
  ['/big/dom/home/myid\n']
  &gt;&gt;&gt;
  </code></pre>
  
  <p>Am I misunderstanding what is going on here? Should I not be able to change directories? Or if I can, should I be doing it in some other way than using exec_command?</p>