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

Pavel commented on MESOS-8800:
------------------------------

After some code reading the following was found in port_mapping.cpp
{code}
Try<string> value = os::read("/proc/sys/net/ipv4/ip_local_port_range");
// value is splitting into begin and env both uint16_t type
Interval<uint16_t> hostEphemeralPorts =
    (Bound<uint16_t>::closed(begin.get()),
     Bound<uint16_t>::closed(end.get()));
{code}
if /proc/sys/net/ipv4/ip_local_port_range upper bound is 65535 than 
hostEphemeralPorts is empty, becuase it converts closed interval [begin, 65535] 
into close-opened interval [begin, 65536), which does not fit unit16_t.
 I would suggest change types into int32_t with assertions.

As a workaround you may set host ip_local_port_range upper bound to 65533.

> start failed after add "network/port_mapping" to isolation
> ----------------------------------------------------------
>
>                 Key: MESOS-8800
>                 URL: https://issues.apache.org/jira/browse/MESOS-8800
>             Project: Mesos
>          Issue Type: Task
>    Affects Versions: 1.5.0
>            Reporter: stevenlee
>            Priority: Major
>
> when i add 
> "cgroups/cpu,cgroups/mem,disk/du,filesystem/linux,docker/runtime,network/port_mapping"
>  to islotion and add 
> "cpus:24;mem:128000;ports:[31000-32000];disk:100000;ephemeral_ports:[32768-57344]"
>  to resources,then i systemctl start mesos-slave,report this:
> Log file created at: 2018/04/18 15:15:56
> Running on machine: test.machine.net
> Log line format: [IWEF]mmdd hh:mm:ss.uuuuuu threadid file:line] msg
> I0418 15:15:56.583765 21945 logging.cpp:201] INFO level logging started!
> I0418 15:15:56.584277 21945 main.cpp:365] Build: 2018-04-14 13:33:38 by root
> I0418 15:15:56.584306 21945 main.cpp:366] Version: 1.5.0
> I0418 15:15:56.615106 21945 systemd.cpp:240] systemd version `219` detected
> I0418 15:15:56.615202 21945 main.cpp:468] Initializing systemd state
> I0418 15:15:56.623399 21945 systemd.cpp:328] Started systemd slice 
> `mesos_executors.slice`
> I0418 15:15:56.626150 21945 resolver.cpp:69] Creating default secret resolver
> I0418 15:15:56.713505 21945 containerizer.cpp:304] Using isolation \{ 
> environment_secret, volume/image, volume/host_path, cgroups/cpu, cgroups/mem, 
> docker/runtime, volume/sandbox_path, disk/du, filesystem/linux, 
> network/port_mapping }
> I0418 15:15:56.725468 21945 linux_launcher.cpp:146] Using 
> /sys/fs/cgroup/freezer as the freezer hierarchy for the Linux launcher
> I0418 15:15:56.812513 21945 fetcher.cpp:69] Skipping URI fetcher plugin 
> 'hadoop' as it could not be created: Failed to create HDFS client: Hadoop 
> client is not available, exit status: 32512
> I0418 15:15:56.818392 21945 provisioner.cpp:299] Using default backend 'copy'



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

Reply via email to