Computational Chemistry (F14CCH)
Total Page:16
File Type:pdf, Size:1020Kb
Computational Chemistry (F14CCH) Connecting to Remote Machines Using CCP1GUI CONDOR is a queuing system that can be accessed from the Linux Left Mouse Button: Turn machines of the theoretical research groups and distributes the Hold right + up or down: Zoom submitted jobs to free compute nodes. Since the machines are protected Hold wheel + move: Move by firewalls you have to connect to a specific node, Porthos, on which you were given an account. Click Atom => Select Fragment => Add Assign all elements, also the hydrogens, before creating the GAMESS Use PuTTY to connect to remote machines, porthos in this case. Open input file (click on “All X => H” in the tool panel). If you cannot see one of putty.exe, enter the hostname as porthos.chem.nott.ac.uk. The login the windows of CCP1GUI, it might be hiding outside the desktop area. is your university username and the default password is Right click on the taskbar icon => Move => hold cursor keys to the left ChangeMeSoon. When you first log in on CONDOR you must change until the window appears. your password using kpasswd! It must be strong, including mixed case letters and numbers. Creating a GAMESS Input File / Running a Local Job Compute => GAMESS-UK Copying Files from/to Porthos To exchange files with porthos in order to submit files to CONDOR for Molecule: Options => Title calculation or copy results back, you first have to copy them from the Task => select requested task Windows machine to porthos via the SSHClient. It cannot be installed in Theory: Select SCF Method (and post SCF Method, if required) the CAL but can be accessed at NAL => Accessing the Internet => Optimisation: Runtype => Opt. Coords => Cartesian SSH FTP Client Job: Job Group => Job Name (no blanks!) Select “Quick connect”: To write an input file for submisstion to CONDOR: Host name: porthos.chem.nott.ac.uk Calc => Write Inputfile (to C:\ccp1gui\jobname.in) User name: your IS user name (pcyz...) To run the job on the local machine (for short jobs): If you do not see a split window with your local machine left and the Calc => Run remote machine to the right, click on “Window => New File Transfer”. Job Crashes With ^M Characters in the Output file When logged in on porthos with the SSHClient, drag-and-drop all your If this happens, then the input file was saved in DOS-format. To change files from the Explorer or the left window to your directory on porthos that it should be sufficient if you do: (right) and vice versa. vi file.in Caution: The SSHClient also offers a small terminal but due to :set ff=unix problems with vim it is strongly recommended to use PuTTY instead. :wq PuTTY makes life a great deal easier with e.g. text colours. Do not use If you additionally see the “^M” characters in the .in file, you might also the FTP client terminal. need :%s/^M//g (to create “^M” type “Ctrl+v m”, not simply ^M!) To log off properly click on “Disconnect” in the tool bar or File => Disconnect Computational Chemistry (F14CCH) Important Unix Commands Using vim cd d change to directory d Vim has two modes: insertion mode, and command mode. You start in command cd change back to home directory mode, where almost every key and combination of keys is assigned an operation (e.g. „delete a line“). Insertion mode begins upon entering an insertion or change command ( , , , ). [ ] returns to command mode (where you can quit). Most mkdir d create new directory d i a c o Esc commands execute as soon as you type them except for “colon” commands which cp f1 [f2…] d copy files fx to directory d mv f1 [f2…] d move files fx to directory d execute when you press the enter key. mv f1 f2 move (rename) file f1 to f2 vi [f] start vim (and edit the file f if given), vim works as weel rm f delete file f vimdiff f1 f2 view the differences between files f1 f2 delete directory f (must be empty) rmdir d vimtutor basic tutorial for handling vim (very helpful, essential!) rm -r d delete non-empty directory d (be extremely careful!!!) list files in directory In Command Mode ls :w file save to file (or simply save, if file is omitted) ls -l or l list detailed output of directory :q quit (use :q! to quit without saving) pwd print working (current) directory exit quit the current shell (or return to where you came from) i enter the input mode (to enter text) Esc leave the input mode (enter command mode) undo last change <tab> use to auto-complete filenames in the shell u Ctrl-r redo last undo cat f list contents of file f Shift-v select lines (use Ctrl-v to select a text block) more f list file f by screen (scroll with space, quit with q) dd delete current line less f list file f by screen (PgUp/Down, Cursorkeys, quit with q) y copy selected lines lists all lines of file f which contain the pattern ptn grep „ptn“ f P or p paste the deleted text before or after current position list differences between files f1 and f2 (see also vimdiff!) diff f1 f2 /string search for string search forward or backward for next match man command displays the manual page of the given command N or n gg go to beginning of file G go to end of file condor_submit f submit file f to the condor queuing system replace this with that (the % means in the whole file) condor_q view the condor queue (which jobs are being processed) :%s/this/that/g condor_rm id remove the job with number id (shown by condor_q) condor_status check the status of all available condor nodes and CPUs Cut and Paste a Block of Text (e.g. New Atom Coordinates) Ctrl–v begin block selection ssh [email protected] to select the text block connect to PORTHOS via a Mac OS or Linux terminal (replacing Putty) cursor keys scp –r [email protected]:~/charmm . y to copy the selection copy the folder charmm from PORTHOS to the current directory :e file to open an existing or create a new file (if needed) scp file [email protected]:~/charmm p to paste the copied text copy the file file from the current directory to the folder charmm on PORTHOS :w save the file Computational Chemistry (F14CCH) Using CONDOR The CONDOR Submission Script Only for the CHARMM water tutorial you are going to execute CHARMM directly on To submit a job to the CONDOR queuing system, you need the input files for PORTHOS. For the other calculations you have to use a submission script (see further CHARMM or GAMESS and the submission script with the instructions for CONDOR. A down), which sends the job to one of the compute nodes. If the larger calculations submission script, e.g. for CHARMM in this case, looks like this: were run on PORTHOS, the whole queuing system may crash! universe = vanilla executable = /opt/condor/software/bin/charmm Using CHARMM with CONDOR input = build.inp output = build.out The folder charmm contains six input files for the MD simulation (md_*.inp) and the error = build.e run script for them (charmm.sub, in which you have to adapt some settings to your log = build.log job). Edit md_build.inp and change the amino acid to the one which is to be calculated. The file name prot.pdb cannot be changed, since all following scripts should_transfer_files = YES will use it. To run the simulation submit the job with when_to_transfer_output = ON_EXIT transfer_input_files = build.inp,file1,file2 condor_submit charmm.sub queue Check the output files, whether all calculations ran successfully (a skull at the end of the file is usually a bad sign). If everything looks OK, copy it with the SSHClient to For each job you have to configure the submission script appropriately. This includes your local machine to analyse it using CCP1GUI for example. the sections input, output, error and log as well as the line transfer_input_files. The latter has to list all files (separated by commas), which have to be submitted to the machine that calculates the job. Using GAMESS with CONDOR You can name the submission script however you like and can simply copy the template file to a new name, which fits the current job. Keeping the submission script Copy the .in file created by CCP1GUI to the folder gamess on PORTHOS (or create instead of always using the same makes it easier later to rerun the job in case a new folder for it and copy the submission script into it as well). The folder contains something went wrong. the run script , in which you have to adapt some settings to your job gamess.sub (see the following section for that). After this submit the job with condor_submit gamess.sub The Text File Format Differs Under Windows and Unix The most important information is at the very end of the output file. Use the “G” Unix uses a different text format than Windows does. Notepad for example will not command in vim to get there fast (rather than pressing 200 times PageDown…). recognize line feeds in a Unix text file. You can change the file format in vim using :set ff=dos and :set ff=unix, respectively. Under Windows you should not Usually it is useful to run a “rough” optimization at first using a smaller basis set and use Notepad but a decent editor, e.g.