P0: My First Kernel Mod
You will add a kernel boot log message to Reptilian. You will then take a screenshot of the terminal displaying the added boot message with your name/UFID and a personal message visible and create a short video to demonstrate your code. You’ll submit the project via Canvas.
The project is broken into four main parts:
1) Modify the kernel to print your name, UFID, and a personal message to the default boot (and rebuild).
Copyright By PowCoder代写 加微信 powcoder
2) Take a screenshot displaying your name and UFID in the debug boot message
3) Create a unified patch file
The system must print “##### FirstName LastName (UFID: 0000-0000) My Personal Message #####” using the log system with one new line above and below (while booting with the default configuration) just before the message “Detecting Reptilian system partition”. The personal message can be appropriate message you like (see example screenshots). It can be added in source near the call to the rcu_end_inkernel_boot() function, which wraps up the kernel’s boot tasks and hands off execution to the system initialization routines.
For extra credit (+4%), students may modify the GRUB menu to add “(FirstName LastName)” next to the default “Reptilian 20.08-A9.0-r2” option; see the Example Screenshots section below for an example of what the modified menu should look like. This will not be included in the patch; just take a screenshot and talk about what you did in the report and screencast. Note that the GRUB utilities cannot be used for this – just a text editor.
Log Levels
Many systems use level-based log systems. The Linux kernel has eight (8) levels that are used for log messages. Anything less severe than the KERN_ERR log level will only show up on the screen in verbose or debug mode.
You should test your code by starting your VM after rebuilding. Make sure it displays your message while booting in default mode (not verbose or debug). You should also apply your patch to a “clean” VM to make sure it works.
Submissions
You will submit the following at the end of this project on Canvas (Do NOT zip files):
Screenshot of added log message with name & UFID visible (plus screenshot of GRUB if doing EC) Report containing link to unlisted screencast
Unified Patch File
Your report will explain how you modified the boot message, including what changes were made to which files and why each change was made. It will include description of how testing was performed. It will also contain a link to an unlisted web resource for the screencast (such as a YouTube video link). It should be named “p0.txt” and should be no more than 500 words. You must include your name on the report. It should cover all relevant aspects of the project and be organized and formatted professionally – this is not a memo!
Screencast
You should submit a screencast (with audio) walking through the changes you make to the operating system (~2 minutes) as part of the report (see “Report”). Audio speed-up is prohibited. The video must be unlisted!
Patch File
The patch file will include all changes to all files in a single patch. Applying the patches and remaking the necessary parts of Reptilian, then rebooting should modify the boot message as described above.
To create the patch file follow these commands:
$ cd /usr/rep/src/reptilian-kernel
$ git add -u
$ git add ‘*.c’ ‘*.h’ ‘*Makefile*’ ‘*.tbl’
$ git diff remotes/origin/os-latest > p0.diff
This is merely an example that includes specific file types; you will need to ensure that all of your changes appear in patch files you generate and submit for this course. Always test your patches!
We will test your project applying the patch and running these commands from the kernel source directory:
$ git apply p0.diff
$ make && sudo make install && sudo make modules_install
Example Screenshots
Below you can see an example of what acceptable screenshots look like for the project and the extra credit (You don’t need to circle what you added):
Figure 1. Added Boot Message Figure 2. Modified GRUB Menu (Extra Credit)
程序代写 CS代考 加微信: powcoder QQ: 1823890830 Email: powcoder@163.com