Skip to content

Mars Server Reference Sheet for CSCI 316

  • Server: mars.cs.qc.cuny.edu
  • Username Format: xxxxx_yyyy316
    • xxxxx = Last name (lowercase, ≤5 chars) or first 5 letters if longer
    • yyyy = First name (lowercase, ≤4 chars) or first 4 letters if longer
  • Initial Password: q + last 7 digits of CUNYfirst ID
  • Required: Change password on first login
  • From Off-Campus: QC VPN (GlobalProtect) must be connected
  • From On-Campus: Connect to qwifi-secured wireless network
  • Note: Must set up CUNY login MFA before installing GlobalProtect VPN client
  1. ssh xxxxx_yyyy316@mars.cs.qc.cuny.edu
  2. (Enter initial password)
  3. passwd (Change your password)
  4. (Log off and log back in with new password)
  5. source /home/faculty/ykong/316setup (Get 0.25 pt extra credit if by Sept 11)
  6. cl (Test that Clisp works)

Once logged in, run:

Terminal window
source /home/faculty/ykong/316setup

Benefits: Enables cl command (Clisp) and kawa command (Scheme); qualifies for 0.25 pt extra credit if completed by Thursday, September 11.

TaskCommandLocationNotes
Connect to Marsssh xxxxx_yyyy316@mars.cs.qc.cuny.eduLocal: PowerShell/TerminalFirst time: type yes to continue
Fix host key issuessh-keygen -R mars.cs.qc.cuny.eduLocal: PowerShell/TerminalRun if “REMOTE HOST IDENTIFICATION HAS CHANGED”
Start ClispclRemote: Mars promptAfter running 316setup
Start Kawa SchemekawaRemote: Mars promptFor Scheme solutions; requires 316setup
Copy file to Marsscp local_file.ext xxxxx_yyyy316@mars.cs.qc.cuny.edu:destination/:Local: PowerShell/TerminalRequires QC VPN or qwifi network
Copy file from Marsscp xxxxx_yyyy316@mars.cs.qc.cuny.edu:remotefile.ext .Local: PowerShell/TerminalRequires QC VPN or qwifi network
Change passwordpasswdRemote: Mars promptRun after first login
  1. Place solution file in home directory on mars: your-last-name-N.lsp (where N = assignment number)
  2. At the xxxxx_yyyy316@mars:~$ prompt, enter:
Terminal window
submit_lisp_asn your-last-name N

Example: To submit Assignment 5, if your name is David Touretzky:

Terminal window
submit_lisp_asn touretzky 5

Check submitted assignment — Run on mars:

Terminal window
ckasn

At resulting Lisp > prompt:

(quickcheck 'last_name assignment_number)

Example:

(quickcheck 'touretzky 5)
Terminal window
submit_TJ_asn1

File location: TJ1asn/Parser.java (home directory on mars)

Terminal window
submit_TJ_asn2

File location: TJasn/ParserAndTranslator.java (home directory on mars)

Terminal window
submit_TJ_asn3

File location: TJasn/virtualMachine (home directory on mars)

Checking Submission Status and Late Submissions

Section titled “Checking Submission Status and Late Submissions”

Run these commands at the xxxxx_yyyy316@mars:~$ prompt to check submission timestamps (ctimes):

Terminal window
ls -lLc submitted-Lisp-assignments # Lisp Assignments 2–5
ls -lLc submitted-TinyJ-assignments/TJ1asn/Parser.java # TinyJ Assignment 1
ls -lLc submitted-TinyJ-assignments/TJasn/ParserAndTranslator.java # TinyJ Assignment 2
ls -lLc submitted-TinyJ-assignments/TJasn/virtualMachine # TinyJ Assignment 3

Interpretation:

  • “total 0” or “No such file or directory” = No submission found
  • ctime after due date = Late submission
  • ctime before due date = On-time submission
  • General deadline: Noon on Wednesday, December 24, 2025
  • Condition: Mars must be operating normally and accessible
  • Important: If mars becomes inaccessible after 6 p.m. on the assignment’s due date, the deadline will NOT be extended
  • nano: Easy for beginners
  • vim: Powerful but steep learning curve
  • emacs: Full-featured editor
  • less: View-only file viewer
CommandPurposeLocationExample
ls -lList files with detailsRemote: Marsls -l TJ1asn/
cdChange directoryRemote: Marscd TJ1asn
pwdPrint working directoryRemote: Marspwd
catView file contentsRemote: Marscat CS316ex0.java
lessPage through fileRemote: Marsless Parser.java.txt
diff -cCompare filesRemote: Marsdiff -c 0.sol 0.out
javacCompile JavaRemote: Marsjavac TJ1asn/Parser.java
javaRun JavaRemote: Marsjava TJasn.TJ ...
clStart ClispRemote: Marscl
kawaStart SchemeRemote: Marskawa
  • If mars becomes inaccessible after 6 p.m. on the due date, the deadline will NOT be extended
  • Late submissions accepted only if mars is operational
  • Recommendation: Submit well before 6 p.m. on the due date, ideally by noon
  • Files must be in correct location on mars
  • Java code must compile without errors on mars
  • Late submission penalty: -1 point per late submission if 4+ assignments are submitted late
  • Submit early to avoid issues with mars availability
  • Do not rely on copying files from PC/Mac as an excuse for late submission
  • Test copying files from your PC/MAC to mars ahead of time before relying on it for assignment submission
  • Problems with file copying will not be considered legitimate reasons for late submission
  1. SSH to mars
  2. /home/faculty/ykong/TJ1setup (At mars prompt)
  3. ls -l TJ1asn/ (Verify files exist)
  4. Check assignment document for specific Parser.java placeholder locations
  1. SSH to mars
  2. /home/faculty/ykong/TJ2setup
  3. Download TJasn.jar via scp to local machine
  1. SSH to mars
  2. /home/faculty/ykong/TJ3setup
  3. Implement virtual machine instruction classes
TaskCommandLocation
Start ClispclRemote: Mars prompt
Load file(load "filename")Remote: Clisp > prompt
Test solution(quickcheck 'last_name N)Remote: Clisp > prompt (after ckasn)
Exit Clisp(quit) or Ctrl+DRemote: Clisp > prompt
View SDRAW(sdraw expression)Remote: Clisp > prompt
IssueSolution
Cannot connect to marsVerify QC VPN is connected or on qwifi network
”REMOTE HOST IDENTIFICATION HAS CHANGED”Run ssh-keygen -R mars.cs.qc.cuny.edu
command not found for cl or kawaRun source /home/faculty/ykong/316setup
File copy failsEnsure QC VPN is connected; try SFTP client as alternative
Compilation fails on marsCheck working directory is home (~) for TinyJ; check class paths
Clisp gives “Break …>” promptSyntax error in code. Fix with ctrl+D
ls -lLc submitted-* shows “total 0”File not found in expected location; verify submission command