You are on page 1of 8

01.

[10p] Rotational delay - IOPS calculations

[10p] Task A - Calculate rotational delay

Sadly, I do not own paper, so here are my calculations:

- Divide RPM by 60 seconds: 5400 / 60 = 90RPS


- Rotation duration: 1 / 90 = 0.011s = each rotation takes 11ms
- Divide in half: 11ms / 2 = 5.5ms
- Consider seek time ~ 3ms + 5.5ms = 8.5ms
- Consider internal transfer latency 2ms + 8.5ms = 10.5 ms
- Get IOPS: 1000ms / 10.5ms = 95.23 IOPS, worse than the 10K RPM
disk

02. [30p] iostat & iotop

[15p] Task A - Monitoring the behaviour with Iostat

There are indeed a lot of loop devices on my computer due to snaps


and their incorrigible behaviour. I’ve removed them from the above
output because they would make it even more unreadable - to keep it
as simple as possible, I’ve selected only one partition of my main
disk which appears to be the mail partition.

In the second to last output, there is 0 reading going on and some


writing, with the wkB/s / w/s ratio at 15.11. On the last output, we
see a read ratio of 128 and a write ratio of 17.45. While I can’t
comment on the progress of reads, I can comment on the progress of
writes, which increased to 17.45 bytes/write.
[15p] Task B - Monitoring the behaviour with Iotop

There we go again destroying my computer sigh.

I know I’m supposed to be smarter about this but htop is also quick
and easy ahaha.
Took us some tries but we did it, boys!

03. [30p] RAM disk


There we go destroying my system… again… :(

[15p] Task B - Pipe View & RAM Disk

The RAM works nice with 324 Mib/s, while the disk is only slightly
(let’s be real) behind with 282 Mib/s. I honestly expected a bigger
difference but oh well.
04. [30p] Perf & fuzzing

[10p] Task A - Fuzzing with AFL

Seems to be working!

[10p] Task B - Profile AFL

Ah yes, love to see the pid haha.


Huh…

Also, this thing takes ages to run through 1.7 gigs. Maybe i
shouldn’t have let afl run for so long. Hopefully that number it was
showing in the previous command truly was the PID.

It was indeed the pid! We see that afl really loves


“save_if_interesting” as it spends most of its time there.
Seems this function is meant to save the input/status of a test case
for future reference (rerunning it, looking deeper into it etc.)

[10p] Task C - Flame Graph

Man, this is taking a long time… I’m starting to think we should


have just gone through CLion and saved ourselves the blind hunt
through the terminals with tools that have to be compiled from
source. It really feels like we’re more interested in cosplaying as
90’s linux devs than actually learning something practical and
useful and accessible here.

Yeah, I can’t get it to work. I have some perf output looking like
this:

But, for some reason, the FlameGraph script is not reacting at all
to the input. I’m unsure what’s causing this issue.
05. [10p] Feedback

You might also like