Advertisement
Guest User

Untitled

a guest
Jul 23rd, 2019
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.30 KB | None | 0 0
  1. ### Seperate Submit Node
  2.  
  3. Setup keys on the **Submit Host**
  4.  
  5. ```bash
  6. $ ssh centos@3.209.41.48
  7. $ cat ~/.ssh/id_rsa.pub
  8. ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC747i1LltXnYkTTdXw4/qjuSxZS+zgg/kYgTrwdyejgTQPyjKfN0/2HudIdt83C2ZeTKqW1DU16HShKwPFCY8KUHtSgLaw7q4QV1grPMCAX7lZhIja0+pEsrt/30ME5ps51EqSmN4sAk1Jl9FaOi8YVZkuV++8gBwTKe2PKLFQ709HVP4yzJdx2epiJsENszqdTMkcjX4dr11X4C+lZsOxt7kRlH8GZ2CHAG3UGsgFf5sArClhqXMFwGiSCDIpIpL70EsY5u2Dpaj9Tb9lge4RSHzdjn6Ro1++4hBdHSj5FhrdC5cmemts3MMmS752hfU8oHWGdg3ZeMRJEq4ICIJb centos@ip-10-6-0-241.ec2.internal
  9. ```
  10.  
  11. Copy that key to the **master node** of the cluster:
  12.  
  13. ```bash
  14. pcluster ssh [cluster]
  15. vim ~/.ssh/authorized_keys
  16. # add key to the bottom
  17. ```
  18.  
  19. Then setup aliases on the **master node**, changing the ip and username based on the output of `pcluster ssh [cluster] -d`:
  20.  
  21. ```bash
  22. echo "
  23. # link submit node to master
  24. alias qhost='ssh -i ~/.ssh/id_rsa ec2-user@3.210.138.67 qhost'
  25. alias qrsh='ssh -i ~/.ssh/id_rsa ec2-user@3.210.138.67 qrsh'
  26. alias qstat='ssh -i ~/.ssh/id_rsa ec2-user@3.210.138.67 qstat'
  27. " >> ~/.bashrc
  28. source ~/.bashrc
  29. ```
  30.  
  31. **Warning** this won't work for qsub unless the file you're submitting is also on the master instance. You'd need to setup a shared drive and then qsub, for example if /home was shared, then `qsub $(pwd)/submit_script.sh` from the home directory would work
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement