title: How can I get all .log and .txt files when I SSH into a server
body: <p>I'm using the Paramiko module to log into a server (ssh on some and sftp on others). I can get text and log files from specific folders on the server no problem. But there are many sub-directories that have .txt and .log files. I read some where that the get method will not accept (*.txt). Does anyone know a way around this. Here is the code that I'm currently using to log into a server and get a specific log:</p>
  
  <pre><code> import paramiko
   import sys
   import os
  
  
  
  
  
   ssh = paramiko.SSHClient()
   ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
   ssh.connect('10.5.48.74', username='root', password='******')
  
   ftp = ssh.open_sftp()
   ftp.get('/var/opt/crindbios/log/crindbios.log', '.')
   ftp.close()
  </code></pre>