99 lines
5.1 KiB
Markdown
99 lines
5.1 KiB
Markdown
# Raspberry PI exercises
|
|
|
|
## GUI installation
|
|
|
|
This is a bit of an *exploration* exercise.
|
|
Go to the [Raspberry PI OS](https://www.raspberrypi.org/) website and download the Desktop OS.
|
|
Find a way to flash the OS to your SD card.
|
|
There are multiple options to do so so feel free to look for the way that looks the most straight forward to you.
|
|
Once up and running have a look around the OS and see if you recognise the *desktop environment*.
|
|
Configure the desktop environment to your liking such as keyboard, language, timezone etc.
|
|
Connect to internet and perform an upgrade of the system so that all software is up to date.
|
|
(You can connect either over Wifi of over ethernet, your choice.)
|
|
Was everything already up to date?
|
|
If not, why would a fresh install have updates?
|
|
Do you recognise any of the packages that need upgrading?
|
|
|
|
I would like you to take some notes concerning the topics above, preferably with a markdown file on your gitea account. (you'll need the notes later for debrief)
|
|
You might have to install some things, maybe not.
|
|
Which text editor did you choose?
|
|
Are you visualising your markdown file before pushing?
|
|
If so, how are you doing this?
|
|
|
|
Can you tell me a bit more about this computer?
|
|
Some *details* about the system such as RAM, CPU type/count, how many users are known to the system, ip address, kernel version, temperature, etc. (the more the better)
|
|
Which programs are you using to find out about the system?
|
|
Are there multiple ways of discovering this information?
|
|
|
|
### Extra challenge
|
|
|
|
Can you connect to our matrix server and send us a message from this computer?
|
|
|
|
For the next part you will have to setup the same Raspberry PI but without graphical interface.
|
|
I advise you to make do some research on how to configure all the system setting you did but *without* a GUI.
|
|
Best to keep track of this research.
|
|
Power down the PI in a *clean* manner and move on to the next challenge.
|
|
|
|
## Headless installation
|
|
|
|
On the same website as before you can also download an image without a desktop environment.
|
|
Which one would it be?
|
|
Find it, download it and flash it to your sd card.
|
|
Once the PI is up and running log in and find a way to connect to the internet over Wifi and confirm you have an actual internet connection.
|
|
You can do this any way you deem fit but please keep a note on how you do it and if you know multiple ways, please write them down.
|
|
Clone the repository you made during the previous install to this one and note some of the differences you spot between this installation and the previous one.
|
|
Is this system up to date?
|
|
If not, is it a big difference?
|
|
What services are running?
|
|
What's the memory usage difference?
|
|
How annoying is multitasking on this installation?
|
|
Can you think of an *easy* way to be more productive?
|
|
|
|
Next up I would like you to install an ssh server on this Raspberry PI.
|
|
Confirm it's running and accepting connections.
|
|
(I'm very willing to debug your connection from my computer but you'll have to tell me what to do)
|
|
You can again do this in any way you can think of but keep track of what works and what doesn't.
|
|
|
|
Your next step will be to log into this machine without screen and keyboard connected so write down any information you might need to do so.
|
|
How will you find your Raspberry PI on the network?
|
|
|
|
Once you're confident the ssh server is up and running turn off the Raspberry PI, again in a *clean* manner, and disconnect the screen and keyboard.
|
|
|
|
## Time go fully headless
|
|
|
|
Get your windows machine back up and running and log into your Raspberry PI over ssh.
|
|
Does windows have a built in ssh client?
|
|
You might need to download one.
|
|
|
|
Are you sure this is your Raspberry PI?
|
|
Can you *accidentally* log into the wrong PI?
|
|
How would you make it more clear for yourself (and others) that your PI is yours?
|
|
|
|
If you made it this far you should know your IP address.
|
|
There is a webserver running on my raspberry pi who you can find at `172.30.6.96` this webserver is serving a file called `accounts.csv`.
|
|
Please download it and create user accounts for all these people.
|
|
The username should be the `$USERNAME` part of their matrix handle and as a password their `$FIRSTNAME$LASTNAME`.
|
|
|
|
### Extra challenge
|
|
|
|
If the lack of multitasking is driving you crazy, how would you go about fixing it?
|
|
Can you connect to our matrix server and send us a message from this computer?
|
|
|
|
How can we exchange files between this computer and our windows machine?
|
|
Some sort of FTP server would be handy no?
|
|
Can you set one up for all our users?
|
|
|
|
## Setting up a fileserver
|
|
|
|
Have a look at the accounts.cvs file again.
|
|
The last collumn is a *teams* collumn.
|
|
Please add all the users to either the *red* or the *blue* team group.
|
|
You probably need to create these groups first no?
|
|
|
|
You are yourself in one of the groups and you consider the people in the same group to be your trustworthy friends.
|
|
The other team you consider them less trustworthy so you don't want to give them shell access.
|
|
There is a feature in the sftp server included into the ssh server that allows you to do this.
|
|
How do you make the sshd daemon aware of changes in the config file?
|
|
|
|
Test all of this out with people from your team and the other team.
|