Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2024 changes from ETH + Restart script #1

Open
wants to merge 4 commits into
base: commnet24
Choose a base branch
from

Commits on Aug 28, 2024

  1. Bring in changes from the 2024 lecture. (nsg-ethz#44)

    For the 2024 iteration of our lecture, we made some significant improvements to the mini Internet, which we now port back to the main branch.
    
    Most notably:
    - We removed the Open vSwitch connecting the containers and replaced it with direct virtual links. Adding links to the virtual switch scaled very badly to large topologies, resulting in multi-hour setup times. With the new implementation, setup takes at most tens of minutes, even for large topologies. Already "battle-tested" the new implementation earlier this year with over 100 students.
    - Rewrote the restart scripts to work with the new implementation.
    - Added a `HISTORY` service that starts with the mini-Internet and collects regular snapshots of all configs. This has two main purposes:
      - Even if students forget to save their config, we have a snapshot.
      - One can create a neat gif in the end that shows how connectivity evolved over time. The scripts to create this gif are in `utils/history_gif`
      - It can be disabled if space is a concern, but we found it to take a few hundred MB max, even after a long time.
    - Added a `variables.sh` file in config. All configurable parameters have been removed from the scripts in `setup` and moved into `variables.sh` to make it easier to configure the Mini-Internet services in one place. This includes the webserver, matrix, and the new history service.
    
    ---------
    
    Co-authored-by: CommNet Team <[email protected]>
    Co-authored-by: yuchen14 <[email protected]>
    3 people authored Aug 28, 2024
    Configuration menu
    Copy the full SHA
    7ecd6b7 View commit details
    Browse the repository at this point in the history

Commits on Sep 19, 2024

  1. Added standalone restart script for accidental host reboot/shutdown (n…

    …sg-ethz#43)
    
    Original message on the pull-request for usage reference below.
    
    I had used several months ago for our education environment, and we felt a problem when do restoring all container after an host accidental shutdown (e.g. power outage) to the working state.
    
    To resolve this specific case, I just created a new standalone shell script that located in `platform/utils/save_and_restore/restart_mini_internet.sh` that will performs these mechanisms below:
    
    1. The script will use all backuped configurations that compressed as `.tar.gz` archive in the `students_config` directory with the format should be `configs-as-<as number>.tar.gz`  
    ![Correct example of ](https://github.com/nsg-ethz/mini_internet_project/assets/34955926/3aeeb867-0d49-4a57-a009-422dc748b20f)
    2. Script will perform hard cleanup, by executing `./cleanup/clean.up` and ` ./cleanup/hard_reset.sh`
    3. Script will perform the startup the project, executing `./startup.sh`, then `./utils/ssh/portforwarding.sh`, and finally `./utils/iptables/filters.sh`, and unpausing the MATRIX container, and show the new AS SSH login password (due to perform startup.sh again).
    4. Script will perform config restoration which are based on config defined at point 1, the script is able to store router's FRR config, end-host such as server configuration with IPv4, IPv6, and also able to restore the switch configuration (VLAN etc.). The full usage of the configuration will being described later.
    
    The usage of the `restart_mini_internet.sh` described at the `-h` flag, that explained below image.
    ![Script usage documentation](https://github.com/nsg-ethz/mini_internet_project/assets/34955926/65947821-fa4a-43d8-9578-4d1b1354d678)
    
    Considerations when using this script:
    - When do a backup, the script **WILL WIPES ALL THE FILES CONTAINED IN THE `students_config` to overwrite with the new configuration, so please move your backuped config in the another location**
    - To perform restore, please make sure the format is same as the point 1 describes.
    - Currently, this script isn't able to store regarding RPKI configurations such as Krill.
    
    Regards,
    anandadfoxx
    anandadfoxx authored Sep 19, 2024
    Configuration menu
    Copy the full SHA
    3dba389 View commit details
    Browse the repository at this point in the history

Commits on Sep 21, 2024

  1. Configuration menu
    Copy the full SHA
    3ab290b View commit details
    Browse the repository at this point in the history

Commits on Oct 1, 2024

  1. Configuration menu
    Copy the full SHA
    cb582dd View commit details
    Browse the repository at this point in the history