SFTP to Linux Using Cyberduck (Windows, Mac)

Cyberduck is a free1 cloud storage browser with support for all kinds of protocols and services. One of those protocols is SFTP, which you can use to access your files on CASLab.

For the example below, we will be demonstrating using a CASLab Linux server. If you are trying to connect to another Linux server or machine, please replace the following:

  • Nickname: Whatever you’d like to call this connection.
  • Server: The server/machine’s URL (like files.caslab.queensu.ca) or its IP address.
  • Username and Password: Your credentials to log onto that specific server/machine.

Once you have downloaded and installed Cyberduck and launch it, you should see a window that looks like this:

Click the “+” button at the bottom left side (highlighted above). This will add a new bookmark. Select “SFTP (SSH File Transfer Protocol)” from the dropdown. Give it a name like “CASLab” and use files.caslab.queensu.ca as the server. Then type your CASLab username and password and close the window.

Now you should see an item called “CASLab” (or whatever you called it) in the list.

Double click that new item to open a connection to CASLab. You may be prompted to accept an encryption key. Click “Allow.” (Check the “Always” checkbox to avoid this prompt in the future.)

And then you should see your files.

If you have any problems, please consult the FAQ first, then contact us if you’re still having difficulties.


  1. Cyberduck is donationware, which means it makes money from donations (pay what you want). It’s free, but you will be prompted to donate from time to time if you have not already donated and obtained a license key. You can get it by going to the Cyberduck website, or from the Windows / Mac store, but if you get it there, it will cost money (around $30 at the time of writing). There is no difference between the paid version and the free version – it’s just something to be aware of. ↩︎

CASLab F.A.Q.

Top questions:

What is my CASLab username and password?

As of Fall 2023, your CASLab username and password are your Queen’s NetID and password.

Note: Do not include @queensu.ca in your username.

How do I discover my Queen’s NetID and password?

General information about NetID can be found on the Queen’s NetID Information page.  To activate your NetID, go to the registration page, after which the password can be changed by following the instructions here.  You will need your student number handy.

How do I get access to the labs?

Access to CASLab teaching facilities in Goodwin Hall 230, 248, and Walter Light Hall room 310 is granted through the use of iButtons. iButtons are available for a small fee at the Campus Bookstore.

Please see the iButton enrolment tutorial for more details.

Can I run Linux and Unix applications from home?

Yes, you can remotely log in using an SSH client. See How To section for instructions.  Students wishing to use graphical applications can do so using the X2Go client.

I have downloaded Putty and tried to connect to Linux from home. It warned me that the authenticity of the host could not be established. Is this a problem?

This warning is normal and should only show up the first time you connect to the Linux machine. Feel free to disregard it.

Nothing happens when I try to SSH to a CASLab machine / I get a “connection reset” or “connection timed out” message.

This is the result of your IP address being blocked from too many failed log in attempts. Please fill out an IP unblock request from the computer and internet connection your were blocked on.

In the meantime, IP blocking is server specific, so you can still get your work done. For example, if you were blocked on linux1.caslab.queensu.ca, try linux2.caslab.queensu.ca.

What computer should I get for my studies?

See our computer recommendations here.

Use X2Go Client to Log in to CASLab Linux

CASLab Linux and Unix machines can now be accessed from home using X2Go remote technology. X2Go allows users to have full-screen sessions at nearly full speed even over fairly slow connections from home.

X2Go is already installed on all CASLab machines.

Installing X2go on your machine

Download X2Go for your platform (Win, Mac, Linux) and install it.

Mac OS X Installation Note

There are a couple of extra steps you’ll have to do to install X2Go on a Mac. When you first open X2Go, you may get the following notification:

First, if you see this, you will have to go to your system preferences and then go to “Security and Privacy.” At the bottom of the window, it should display a message about X2Go being blocked. Simply click the “Open Anyway” button and you shouldn’t have to worry about it again.

The second step is to install an X11 server which can be obtained from the xQuartz homepage. If you don’t have it installed, you’ll get this notification:

Download XQuartz from the XQuartz homepage or simply click the link in the dialogue (shown above). Installation is fairly simple. Click the icon and go through the package installation wizard.

After installing XQuartz, you must log off and log on again for it to be detected. After doing that you should be able to proceed with these instructions.

Configuring X2Go

Once you’ve installed the X2Go client, open it with this icon:

X2go_icon

You will be prompted to start a new session:

X2go_session

Fill it out as seen below. For the Host, use one of:

  • linux1.caslab.queensu.ca
  • linux2.caslab.queensu.ca
  • linux3.caslab.queensu.ca
  • linux4.caslab.queensu.ca
  • linux5.caslab.queensu.ca
  • linux6.caslab.queensu.ca
X2go_session_config

Once your session is complete, you should see something like this:

X2go_session_connect

Click on the session “CASLab Linux” to the right. You will now see:

X2go_session_connect_2

After you enter your password and click OK, something like the following will display:

X2go_session_connecting

The first time you connect, you will be prompted to save the host key. Click “Yes.”

X2go_session_connecting_firsttime

In Windows, depending on your firewall settings, you may see the following. Click “Allow access”

X2go_session_connecting_win_firewall

Once you’ve successfully connected, you will be presented with the standard CASLab Linux desktop. Congratulations! You’re connected!

(Note: Depending on settings, your desktop may look a little different.)

When you’re done, don’t forget to log out. You can do this by clicking the power button in the applications menu at the top left. (Depending on your settings, you may instead have to click your name at the top right of the screen.) If you don’t, your session will continue to bog the system down for others, even when you aren’t using it.

CASLab iButtons

Access to CASLab teaching facilities in Goodwin Hall 230/248, and Walter Light Hall room 310 is granted through the use of iButtons. iButtons are available for a small fee at the Campus Bookstore.

Enrollment

To enroll an iButton, a student must go to any CASLab door and, with their mobile device or laptop, go to the CASLab Account Management Tool. (If you don’t have a mobile device or laptop to use, ask a friend or see one of the tech staff). Log in to the Account Management Tool using your Queen’s NetID and password. Go to “Enroll an iButton.” On the next page, select the door you are standing in front of.

Now, press your iButton against the reader of the door you’re standing at and press the “Scan” button.

That’s it. It may take a few minutes to take effect.

Notes

  • iButtons need only be enrolled once. Returning students will not have to re-enroll.
  • Access to CASLab facilities is only granted to students currently enrolled in a CISC course.
  • Replacement iButtons (lost/stolen/traded) must be enrolled by the tech team. They cannot be enrolled by the student.  Please report any lost or stolen iButtons.

If you experience difficulty with iButton registration or use contact help@cs.queensu.ca.

Computer Recommendations

Specifications

  • 16GB of RAM minimum (32GB is even better.)
  • Quad core CPU (Intel i5 or higher, AMD Ryzen 5 or higher, Mac M1/M2)
  • 512GB SSD or NVMe for storage. (256GB as an absolute minimum; 1TB is ideal.)
  • Thunderbolt 3 or newer. This looks like a USB-C port but allows people to plug in external GPUs (eGPUs).  This means that you can use a laptop with an integrated (Intel) GPU day-to-day, connecting to an eGPU when needed for Deep Learning, AI, and Game Development courses.

Hardware Recommendations

If you are looking for specific brand or model recommendations, please consider:

  • Dell XPS 13 or 15
  • Lenovo ThinkPad T Series or X1 Series
  • Any Apple MacBook1
  • Microsoft Surface Studio Laptop, Surface Laptop, Surface Book (although only the Surface Studio Laptop includes the aforementioned Thunderbolt port)

Suggestions

If you are considering a gaming laptop, we recommend an Nvidia GPU, as they are the standard for scientific computing. However, if the machine has Thunderbolt 3, you will be able to sign out an appropriate eGPU when needed.

Our students will not need to purchase a copy of MATLAB, Microsoft Office or development tools, as Queen’s and the School of Computing have licenses that will cover them while they are studying here.

Depending on the budget and needs, if two devices are an option, you may like to have a larger laptop for major development and then something small like a Microsoft Surface, iPad, or Chromebook for taking notes in class. Or a gaming desktop at home that you can use for heavy duty development, and a slimmer laptop for taking back and forth. However, note that an iPad or Chromebook on their own are NOT sufficient for taking most of our courses because you will not be able to install the software you need on them.


  1. Note: Apple’s ARM-based processors (M1, M2, etc) are well-supported, but you may run into issues using it for some tasks (mainly running virtual machines, required by some courses). In these cases, we try to provide accommodations which could require you to come use one of the PCs in our labs. ↩︎

Understanding Unix and Linux File Permissions

Unix file permissions are expressed in three octal digits. Running ls -a from a Unix (or Linux) terminal on a file with permissions 644 might look like this:

-rw-r--r--    1 bhall  staff      2216  6 Dec  2007 x11_update.sh

The first, or left-most, octal digit (“6” in this example) indicates a file’s owner’s (your) permissions, the second a user group’s permissions, and the third public permissions (applying to everyone else).

Here is a table of values showing the effect that each of these octal digits has on a specific owner or user group’s permissions.

OCTALBINARY*EFFECT
0---No permissions (access blocked)
1--xExecutable**
2-w-Writable
3-wxWritable, executable
4r--Readable (read-only)
5r-xReadable, executable
6rw-Readable, writable
7rwxReadable, writable, executable
* Each octal digit can be represented in three bits corresponding, as read from left to right, to read (r), write (w) and executable (x) permissions. Thus, a 6 octal digit, normally written 110 in binary, shows up in a directory listing as rw-, meaning read and write permissions are granted, but not execute.
** Directories must have the executable bit set to be accessible

So, a file with permissions 755 would be readable, writable, and executable for you (as the file’s owner), and readable and executable, but not writable for the group and for the world (public). To apply this set of permissions to a file called myscript, you would run the following command in a terminal window:

chmod 755 myscript

Generally, folders need to have permissions 755 for everyone to be able to read the contents, and files need to have permissions 644 to be viewable but not editable by anyone other than you.

If these are web files, Apache (the web server) runs as another user, so files edited by Apache have to be writable by the Apache process, so the file(s) have to be at least group writable if Apache’s user is in your group.

Of course, you should give least permissions, so if Apache needs to edit a particular file, it should be as weak as 666, but the directory that the file lives in can be 755, and other files can be 644.

For further reading, see https://www.tutorialspoint.com/unix/unix-file-permission.htm.

Inviting External Collaborators to GitLab

Research projects that are conducted in collaboration with other institutions may require external access to code bases hosted on the department GitLab. Because the QSC GitLab registration is restricted to internal Queen’s users only, you will need to request a user be created on the external’s behalf.

Use the form below to submit an external user request. You will need to provide their basic contact info, as well as indicate their sponsoring lab group or supervisor. Please allow a few business days for the team to process the request.

Resetting Your GitLab Password

If you need to reset your password, you can click Forgot your password? on the GitLab homepage.

Once on the reset password form, enter your GitLab email address. Queen’s staff and students use their Queen’s email (netid@queensu.ca or their alias, ex. firstname.lastname@queensu.ca).

You’ll be returned to the main page with a notice saying you’ll receive an email if the address exists in the database. Please give it a few minutes for the email to arrive.

If you do not receive the reset password email, first try entering…

  1. Your email in all lowercase – GitLab tends to be case sensitive.
  2. Your other email option – If you had entered your netID@queensu.ca address, then try your alias email (ex. firstname.lastname@queensu.ca) and vice versa.

If none of the above work (or you forgot your GitLab email as an external user), contact the tech team for assistance.

When the email arrives, click Reset password link and enter your new password on the website.