CS2030 AY19/20 Semester 2
  • Introduction
  • Textbook Contributions
  • Peer Learning Tasks
  • Piazza Participation
  • Setting Up Lab Environment
  • Setting Up Java
  • Setting Up Vim
  • Setting Up MacVim
  • Setting Up Sunfire and PE Nodes
  • Setting Up Checkstyle
  • Textbook
  • CS2030 Java Style Guide
  • CS2030 Javadoc Specification
  • JDK 11 Download Link
  • Codecrunch
  • Github Repo
  • Piazza Forum

  • Setting Up Sunfire and Accessing PE Nodes


    From this tutorial, you should be able to access the PE nodes via Sunfire via SSH.

    1. You will need to have an SoC UNIX Account. If you do not have an SoC UNIX Account, please apply for it here

    2. Once you have an SoC UNIX Account, you will need to enable access to the SoC Compute Cluster here

    3. You will then need an ssh client. For Wndows Users, you should have set up Windows Subsystem for Linux. You can find the link here

    4. Alternatively, if you wish to have a Graphical User Interface (GUI), you can download either XShell with Xftp, PuTTY. Do note that only Windows Users are able to install XShell or PuTTY.

    The Following Insturctions can be done in both Windows and Mac Terminals.

    1. To SSH into the sunfire remote server, type in ssh YOUR_UNIX_SIC_USERNAME@sunfire-r.comp.nus.edu.sg. The Username should have be your SoC UNIX Account Usernane.

    From there, you should be able to see this screen.

    1. To then access the pe-nodes when they are up, do the same thing. Type in ssh plabXXXX@peYYY where XXXX and YYY are your userid and hostname given to you by the account slip respectively.
    1. Once done, you are able to access the files.

    2. If you wish to exit, please type in the exit command. DO NOT close your terminal without exiting from the remote server.

    Alternatively, You can use SSH Tunnels via Port Forwarding.

    1. Local port forwarding means that a port of the SSH client (your machine) is forwarded to the SSH server (sunfire.comp.nus.edu.sg), which opens a connection to a preset destination server (e.g. pe107). This method causes the host to seem as if it is hosted on a local port, e.g. localhost:PORT_NUMBER.

    2. To use local port forwarding, execute the following command:
      ssh -L PORT_NUMBER:peYYY.comp.nus.edu.sg:22 YOUR_UNIX_SIC_USERNAME@sunfire-r.comp.nus.edu.sg
      where the PORT_NUMBER has to be defined by you. (e.g: 2030) and peYYY is the hostname mentioned in your plab slip.

    1. Following which, you will need to to open a separate SSH connection from your machine to localhost at port PORT_NUMBER which you defined earlier. THis can be done via the following command:
      ssh plabXXXX@localhost -p PORT_NUMBER where plabXXXX is the userid given to you in your plab slip and PORT_NUMBER is the port number which you defined earlier.
    1. For example, if you wish to retrieve files from sunfire to your local directory or vice versa, you can use the scp command.

    2. There are a few commands that you will need to learn to copy files. These can all be found here.

    3. For example, I would wish to transfer Test.java from sunfire into my local directory:

    I would need to use the following command: scp (YOUR_UNIX_SOC_USERNAME)@sunfire-r.comp.nus.edu.sg:Test.java /home/seanlowjk

    1. From here, you should be able to view it inside your local directory.