mesos-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Harold Dost III (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MESOS-8897) ROOT_XFS_QuotaTest.DiskUsageExceedsQuotaWithKill is flaky
Date Wed, 09 May 2018 17:45:00 GMT

    [ https://issues.apache.org/jira/browse/MESOS-8897?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16469186#comment-16469186
] 

Harold Dost III commented on MESOS-8897:
----------------------------------------

[~jpeach@apache.org] Do we want to round up then? Or do we want to modify the test to check
for greater than or equal to?

To round up we can do 
{code}
409     // If the soft limit is exceeded the container should be killed.
410     if (quotaInfo->used > quotaInfo->softLimit) {
411       Resource resource;
412       resource.set_name("disk");
413       resource.set_type(Value::SCALAR);
414       resource.mutable_scalar()->set_value(
415--         quotaInfo->used.bytes() / Bytes::MEGABYTES);
415++         quotaInfo->used.bytes() / Bytes::MEGABYTES +
416++         (quotaInfo->used.bytes() % Bytes::MEGABYTES > 0 ? 1 : 0)
417++       );
418       info->limitation.set(
419           protobuf::slave::createContainerLimitation(
420               Resources(resource),
421               "Disk usage (" + stringify(quotaInfo->used) +
422               ") exceeds quota (" +
423               stringify(quotaInfo->softLimit) + ")",
424               TaskStatus::REASON_CONTAINER_LIMITATION_DISK));
425     }
426   }
{code}

> ROOT_XFS_QuotaTest.DiskUsageExceedsQuotaWithKill is flaky
> ---------------------------------------------------------
>
>                 Key: MESOS-8897
>                 URL: https://issues.apache.org/jira/browse/MESOS-8897
>             Project: Mesos
>          Issue Type: Bug
>          Components: flaky, test
>            Reporter: Yan Xu
>            Priority: Major
>
> {noformat:title=}
> [ RUN ] ROOT_XFS_QuotaTest.DiskUsageExceedsQuotaWithKill
> meta-data=/dev/loop0 isize=256 agcount=2, agsize=5120 blks
>  = sectsz=512 attr=2, projid32bit=1
>  = crc=0
> data = bsize=4096 blocks=10240, imaxpct=25
>  = sunit=0 swidth=0 blks
> naming =version 2 bsize=4096 ascii-ci=0
> log =internal log bsize=4096 blocks=1200, version=2
>  = sectsz=512 sunit=0 blks, lazy-count=1
> realtime =none extsz=4096 blocks=0, rtextents=0
> I0508 17:55:12.353438 13453 exec.cpp:162] Version: 1.7.0
> I0508 17:55:12.370332 13451 exec.cpp:236] Executor registered on agent 49668ffa-2a69-4867-b31a-4972b4ac13d2-S0
> I0508 17:55:12.376093 13447 executor.cpp:178] Received SUBSCRIBED event
> I0508 17:55:12.376771 13447 executor.cpp:182] Subscribed executor on mesos.vagrant
> I0508 17:55:12.377038 13447 executor.cpp:178] Received LAUNCH event
> I0508 17:55:12.381901 13447 executor.cpp:665] Starting task edb798b4-1b16-4de4-828c-0db132df70ab
> I0508 17:55:12.387936 13447 executor.cpp:485] Running '/tmp/mesos-build/mesos/build/src/mesos-containerizer
launch <POSSIBLY-SENSITIVE-DATA>'
> I0508 17:55:12.392854 13447 executor.cpp:678] Forked command at 13456
> 2+0 records in
> 2+0 records out
> 2097152 bytes (2.1 MB) copied, 0.00404074 s, 519 MB/s
> ../../src/tests/containerizer/xfs_quota_tests.cpp:618: Failure
> Expected: (limit.disk().get()) > (Megabytes(1)), actual: 1MB vs 1MB
> [ FAILED ] ROOT_XFS_QuotaTest.DiskUsageExceedsQuotaWithKill (1182 ms)
> {noformat}
> [~jpeach@apache.org] mentioned that 
> {code}
> 409     // If the soft limit is exceeded the container should be killed.
> 410     if (quotaInfo->used > quotaInfo->softLimit) {
> 411       Resource resource;
> 412       resource.set_name("disk");
> 413       resource.set_type(Value::SCALAR);
> 414       resource.mutable_scalar()->set_value(
> 415         quotaInfo->used.bytes() / Bytes::MEGABYTES);
> 416
> 417       info->limitation.set(
> 418           protobuf::slave::createContainerLimitation(
> 419               Resources(resource),
> 420               "Disk usage (" + stringify(quotaInfo->used) +
> 421               ") exceeds quota (" +
> 422               stringify(quotaInfo->softLimit) + ")",
> 423               TaskStatus::REASON_CONTAINER_LIMITATION_DISK));
> 424     }
> 425   }
> {code}
> Converting to MB is rounding down, so we report less space than was actually used.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message