Skip to content

Get SSH Access

Progress: Module 1 of 4 → Page 1 of 3

Overview

In this lesson, you'll gain SSH access to the EgyGeeks server. SSH (Secure Shell) is how you'll connect to the server, deploy applications, and manage your infrastructure.

Time: 10-15 minutes

Prerequisites Checklist

Before you start, verify you have:

  • A computer with SSH client (macOS/Linux: built-in, Windows: Git Bash or PuTTY)
  • Admin contact information (email or Slack handle)
  • A text editor for key management
  • Basic familiarity with terminal/command line

Step 1: Contact the Admin

The first step is to request server access from the team admin.

Action Steps

  1. Locate the admin contact
  2. Check your team Slack/Discord
  3. Look in the team wiki or documentation
  4. Common admin names: Lead Developer, DevOps Lead, or Team Manager

  5. Send access request

  6. Message: "Hi [Admin Name], I'd like to request SSH access to the server. I'm [Your Name] and I'll be working on [Project Name]."
  7. Provide your full name and email address
  8. Include your GitHub username (if applicable)

  9. Wait for response

  10. Response time: Usually within 24 hours
  11. They'll provide you with:
    • Server IP address (e.g., 50.3.85.110)
    • Username to use for SSH
    • Instructions for the next step

Ask AI for Help

Copy this prompt to Claude or ChatGPT:

I need to request SSH access to our team's server but I'm not sure who the admin is.

Our team uses:
- Slack/Discord: [your team's communication platform]
- Server IP: 50.3.85.110

How should I find the admin and what should I say in my access request?

Step 2: Generate SSH Key (Local Machine)

Once you receive confirmation from the admin, generate an SSH key pair on your local machine.

Why SSH Keys?

SSH keys are more secure than passwords. They use public/private cryptography: - Public key (shared with server): Like a mailbox - Private key (kept secret): Like the mailbox key

Generate Key

On macOS/Linux:

# Generate SSH key (press Enter for default location)
ssh-keygen -t ed25519 -C "your-email@example.com"

# Follow prompts:
# - Save to: press Enter (default: ~/.ssh/id_ed25519)
# - Passphrase: Enter a secure passphrase (or press Enter to skip)

On Windows (Git Bash):

# Same command as macOS/Linux
ssh-keygen -t ed25519 -C "your-email@example.com"

What Gets Created

After running the command, you'll have:

~/.ssh/
├── id_ed25519          # Your PRIVATE key (KEEP SECRET!)
└── id_ed25519.pub      # Your PUBLIC key (share with admin)

View Your Public Key

# Display your public key
cat ~/.ssh/id_ed25519.pub

# Output looks like:
# ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKkZk... your-email@example.com

Ask AI for Help

Copy this prompt to Claude or ChatGPT:

I just ran this command to generate an SSH key:
ssh-keygen -t ed25519 -C "your-email@example.com"

I have two files now:
- ~/.ssh/id_ed25519
- ~/.ssh/id_ed25519.pub

Can you explain:
1. What's the difference between these two files?
2. How does public/private key authentication work?
3. Why is this more secure than passwords?
4. Which one do I share with the server admin?

Step 3: Share Public Key with Admin

Now share your public key with the admin so they can add it to the server.

Action Steps

  1. Copy your public key

    # Copy to clipboard (macOS)
    cat ~/.ssh/id_ed25519.pub | pbcopy
    
    # Copy to clipboard (Linux)
    cat ~/.ssh/id_ed25519.pub | xclip -selection clipboard
    
    # Copy to clipboard (Windows Git Bash)
    cat ~/.ssh/id_ed25519.pub | clip
    

  2. Send to admin

  3. Message: "Hi [Admin], here's my SSH public key. Please add it to my account."
  4. Paste the key in your message
  5. Double-check you're sharing the .pub file, not the private key!

  6. Confirm with admin

  7. Ask: "Can you confirm you've added my key?"
  8. Wait for confirmation before proceeding

Important: Never share your private key (id_ed25519). Only share the public key (id_ed25519.pub).

Security Check with AI

I'm about to share my SSH key with the server admin. I want to make sure I'm sharing the right file.

I have:
- ~/.ssh/id_ed25519 (private key)
- ~/.ssh/id_ed25519.pub (public key)

Questions:
1. Which file should I send to the admin?
2. What happens if I accidentally share the wrong file?
3. How can I tell the difference between them?
4. Is it safe to paste the public key in Slack/email?

Step 4: Test Your Connection

Now test that you can connect to the server using SSH.

Connect to Server

# SSH to the server
ssh username@50.3.85.110

# First time connection, you'll see:
# "The authenticity of host '50.3.85.110' can't be established..."
# Type 'yes' and press Enter to continue

Replace username with the username the admin provided.

Successful Connection

If everything works, you'll see:

$ ssh username@50.3.85.110
Welcome to EgyGeeks Server!
username@server:~$

You're now connected to the server! You can type commands here.

Verify Your Setup

Run this command on the server to verify:

# Check your username
whoami

# Check available directories
ls -la /opt/apps

# Exit the server
exit

Having Issues? Debug with AI

I'm trying to connect to the EgyGeeks server but it's not working.

Command I'm using:
ssh username@50.3.85.110

My setup:
- Operating System: [macOS/Linux/Windows]
- SSH key location: ~/.ssh/id_ed25519
- Admin confirmed my key was added: [yes/no]

Error output:
[paste your error message here]

What's wrong and how do I fix it?

Verification Steps

Complete these checks to verify you have access:

  • You can run ssh username@50.3.85.110 and connect
  • The server prompts you for a passphrase (if you set one)
  • You see the welcome message: "Welcome to EgyGeeks Server!"
  • You can run whoami and see your username
  • You can run ls -la /opt/apps and see available applications

Troubleshooting

Connection Refused

Problem: ssh: connect to host 50.3.85.110 port 22 (tcp) Connection refused

Solutions: 1. Check the IP address is correct (ask admin to confirm) 2. Make sure you're using the correct username 3. Verify your public key was added to the server 4. Check that your firewall isn't blocking port 22

Debug Connection Issues with AI

SSH connection is being refused when I try to connect.

Error message:
ssh: connect to host 50.3.85.110 port 22 (tcp) Connection refused

Troubleshooting steps I've tried:
- [x] Verified IP address with admin: 50.3.85.110
- [ ] Checked my username is correct
- [ ] Confirmed my public key was added
- [ ] Tested firewall settings

What else should I check? How do I debug SSH connection refused errors?

Permission Denied

Problem: Permission denied (publickey,password).

Solutions: 1. Verify your public key was added to ~/.ssh/authorized_keys on server 2. Check key permissions: ls -la ~/.ssh/ should show id_ed25519 as 600 3. Regenerate your key pair and resend to admin 4. Ask admin to manually add your key

Keys Not Found

Problem: ssh: Could not resolve hostname

Solutions: 1. Check you have internet connection 2. Verify the IP address is correct 3. Try: ssh -v username@50.3.85.110 for verbose output 4. Check firewall rules


Summary

You've successfully: - Requested SSH access from the admin - Generated a secure SSH key pair - Shared your public key with the admin - Connected to the server - Verified your access

Congratulations! You now have full access to the EgyGeeks server.


What's Next?

Now that you have server access, let's understand what's running on the server.

Next Lesson: 2. Server Tour

Previous Lesson: Module Overview


Need Help?

Common Questions

Q: Is my private key safe if I press Enter (no passphrase)? A: It's less secure, but common for development. For production access, use a passphrase.

Q: Can I have multiple SSH keys? A: Yes! You can generate multiple keys for different servers or purposes.

Q: What if I lose my private key? A: You'll need to generate a new one and ask the admin to update it on the server.

Quick Reference

# Generate SSH key
ssh-keygen -t ed25519 -C "your-email@example.com"

# View your public key
cat ~/.ssh/id_ed25519.pub

# Connect to server
ssh username@50.3.85.110

# View key permissions (should be 600)
ls -la ~/.ssh/id_ed25519

Still Stuck?

Debug Common Issues with AI

SSH Key Setup Issues:

I'm having problems with my SSH key setup for server 50.3.85.110.

What I've done:
- Generated key with: ssh-keygen -t ed25519 -C "email@example.com"
- Sent public key (~/.ssh/id_ed25519.pub) to admin
- Admin confirmed it's added

Current issue:
[describe your problem]

Error message:
[paste error here]

How do I debug this SSH key setup?

Connection/Access Issues:

I can't connect to the EgyGeeks server.

Command: ssh username@50.3.85.110
Error: [paste your error]

Verified with admin:
- Username: [your username]
- IP: 50.3.85.110
- Key added: yes

What should I check next?


Tags: Getting Started, SSH, Access, Server Setup

Module: 1 of 4 | Page: 1 of 3