ynroberts / anarchyape

Other
4 stars 6 forks source link

AnarchyApe #1

Open amiraljaberi opened 11 years ago

amiraljaberi commented 11 years ago

Hi Nathan, I am currently working on my final year thesis at National ICT Australia. The main focus of this thesis is to investigate how an AWS-based Hadoop ecosystem behaves under different types of faults which occur in public cloud.

I came across your repo which was really helpful to get my project started. I have successfully compiled AnachyApe but I am not sure how to use it. So I was hoping if you would be able to share your source code or documents of how your team used it.

Regards,

Amer Abdalamer

ynroberts commented 11 years ago

Hi Amer,

Great to hear it's helping you get a start. Unfortunately there isn't a lot of documentation around it and we haven't had a chance yet to really crank up its use.

Here is a quick example of one of our test cases we used with Ape:

!/home/y/bin/perl5.10

use Ape;

while (true) {

Get a random slaves

    $host = Ape::getRandomSlave("slaves");
    # Corrupt 5 hdfs blocks on that slave
    Ape::ape([true, $host, "-C", "ord 1024 10"]);
    Ape::ape([true, $host, "-C", "ord 1024 10"]);
    Ape::ape([true, $host, "-C", "ord 1024 10"]);
    Ape::ape([true, $host, "-C", "ord 1024 10"]);
    Ape::ape([true, $host, "-C", "ord 1024 10"]);

    $port = '8020';
    $duration = '10';

    @slaves = Ape::getSlaves("slaves");

    $slavestring = join(" ", @slaves);

    # Emulate high network traffic
    Ape::ape([true, $slavestring, "-u", "<namenode hostname>" . ' ' . $port . ' ' . $duration]);

    sleep int(rand(60));

}

This script corrupts 5 random hdfs data blocks on a single host, then bombards the NameNode with a DDoS?http://twiki.corp.yahoo.com/edit/Hadoop/DDoS?topicparent=Hadoop.FaultInjectionTestingJournal;nowysiwyg=1 attack originating from each DataNode.

From: amiraljaberi notifications@github.com<mailto:notifications@github.com> Reply-To: ynroberts/anarchyape reply@reply.github.com<mailto:reply@reply.github.com> Date: Tuesday, September 24, 2013 11:55 PM To: ynroberts/anarchyape anarchyape@noreply.github.com<mailto:anarchyape@noreply.github.com> Subject: [anarchyape] AnarchyApe (#1)

Hi Nathan, I am currently working on my final year thesis at National ICT Australia. The main focus of this thesis is to investigate how an AWS-based Hadoop ecosystem behaves under different types of faults which occur in public cloud.

I came across your repo which was really helpful to get my project started. I have successfully compiled AnachyApe but I am not sure how to use it. So I was hoping if you would be able to share your source code or documents of how your team used it.

Regards,

Amer Abdalamer

— Reply to this email directly or view it on GitHubhttps://github.com/ynroberts/anarchyape/issues/1.

amiraljaberi commented 11 years ago

Thanks Nathan. I tried the script but I am getting this error: Executing: ape --remote slave-2 -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x1550d68) Executing: ape --remote slave-2 -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x1550d98) Executing: ape --remote slave-2 -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x1550d80) Executing: ape --remote slave-2 -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x1550d08) Executing: ape --remote slave-2 -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Unable to open file [No such file or directory] ubuntu@ip-172-31-24-164:~/anarchyape/src/perl$ nano ./ape_case.pl ubuntu@ip-172-31-24-164:~/anarchyape/src/perl$ sudo perl ape_case.pl Argument: ARRAY(0x2511998) Executing: ape --remote -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x252ebe8) Executing: ape --remote -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x252ec18) Executing: ape --remote -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x252ec00) Executing: ape --remote -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x252eb88) Executing: ape --remote -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x252eb70) Executing: ape --remote master slave slave-2 slave-3 -u 172.31.24.164 8020 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x2511998) Executing: ape --remote master -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x2687158) Executing: ape --remote master -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x2687140) Executing: ape --remote master -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x2687128) Executing: ape --remote master -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x252f1b8) Executing: ape --remote master -C ord 1024 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58. Argument: ARRAY(0x252f158) Executing: ape --remote master slave slave-2 slave-3 -u 172.31.24.164 8020 10 Can't exec "ape": No such file or directory at /usr/local/share/perl/5.14.2/Ape.pm line 58.