{"id":6332,"date":"2021-04-22T13:49:34","date_gmt":"2021-04-22T08:19:34","guid":{"rendered":"https:\/\/www.skynats.com\/?p=6332"},"modified":"2025-10-30T12:44:29","modified_gmt":"2025-10-30T07:14:29","slug":"guest-unable-to-reach-host-using-macvtap","status":"publish","type":"post","link":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/","title":{"rendered":"Guest unable to reach host by using macvtap interface"},"content":{"rendered":"\n<p>Guest unable to reach host using macvtap interface: Typically, guest virtual machines can communicate with other guests. However, when configured to use a macvtap (also known as type=&#8217;direct&#8217;) network interface, the guest cannot connect to the host machine.<\/p>\n\n\n\n<p>Need assistance to fix the guest virtual machine and similar issues which are done under our <a href=\"https:\/\/www.skynats.com\/linux-server-management\/\" target=\"_blank\" rel=\"noreferrer noopener\"><span style=\"color:#0174a5\" class=\"has-inline-color\">server management services<\/span><\/a> plan.<\/p>\n\n\n\n<h2 class=\"wp-block-heading has-small-font-size\" id=\"h-reason-for-the-guest-unable-reach-to-the-host-using-macvtap-interface\"><strong>Reason for the guest unable reach to the host<\/strong> <strong>using macvtap interface<\/strong><\/h2>\n\n\n\n<p>When you use the type=&#8217;direct&#8217; network interface such as macvtap to configure a guest virtual machine. Where it has the ability to communicate with other guest and the other external hosts on a network, whereas the guest unable to communicate with its own host.<\/p>\n\n\n\n<p>It usually defines as a behaviour of macvtap but not an error. it&#8217;s because of the way the host&#8217;s Ethernet is attached to the <a href=\"https:\/\/en.wikipedia.org\/wiki\/MacVTap\">macvtap<\/a> bridge and the traffic that drives in to bridge is from the guests that will be forwarded to the physical interface which cannot be bounced back up to the host&#8217;s IP stack.<\/p>\n\n\n\n<p>Additionally, traffic from the host\u2019s IP stack that is sent to the physical interface cannot be bounced back up to the Macvtap Bridge for forwarding to the guests.<\/p>\n\n\n\n<h2 class=\"wp-block-heading has-normal-font-size\" id=\"h-methods-to-fix-the-issue\"><strong>Methods to fix the issue:<\/strong><\/h2>\n\n\n\n<p>Following are the two methods that will fix the error.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Creating a separate macvtap interface for the host<\/strong><\/li>\n<\/ol>\n\n\n\n<p>On the physical ethernet where you can create a separate macvtap interface for the host and give IP configuration. Through this way, the host would be peer attached to macvlap bridge and thus guest and host could communicate directly.<\/p>\n\n\n\n<p><strong>Using libvirt for creating an isolated network&nbsp;<\/strong><\/p>\n\n\n\n<p>By using the libvirt where you can create an isolated network as well as the second interface for each guest virtual machine that is connected to this network. Later, the guest and the host will communicate directly with this isolated network, while also maintaining compatibility with NetworkManager.<\/p>\n\n\n\n<p><strong>Following are the steps for creating an isolated network with libvirt<\/strong><\/p>\n\n\n\n<p><strong>1.<\/strong> First, we need to add and save the following XML in the \/tmp\/isolated.xml file. If the 192.168.254.0\/24 network is already in use elsewhere on our network, you can choose a different network.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>...\n&lt;network&gt;\n&lt;name&gt;isolated&lt;\/name&gt;\n&lt;ip address='192.168.254.1' netmask='255.255.255.0'&gt;\n&lt;dhcp&gt;\n&lt;range start='192.168.254.2' end='192.168.254.254'\/&gt;\n&lt;\/dhcp&gt;\n&lt;\/ip&gt;\n&lt;\/network&gt;\n...\n<\/code><\/pre>\n\n\n\n<p><strong>2.<\/strong> Follow the commands to create the network<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>virsh net-define \/tmp\/isolated.xml<\/code><\/pre>\n\n\n\n<p><strong>3.<\/strong> Run the following command to set the network to autostart.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>virsh net-autostart isolated<\/code><\/pre>\n\n\n\n<p><strong>4.<\/strong> Run command and start the network.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>virsh net-start isolated<\/code><\/pre>\n\n\n\n<p><strong>5.<\/strong> Edit the configuration of each guest that uses macvtap for its network connection using the following command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>virsh edit name_of_guest<\/code><\/pre>\n\n\n\n<p>Add a new &lt;interface&gt; in the &lt;devices&gt; section similar to the following (note the &lt;model type=\u2019virtio\u2019\/&gt; line is optional to include):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>...\n&lt;interface type='network' trustGuestRxFilters='yes'&gt;\n&lt;source network='isolated'\/&gt;\n&lt;model type='virtio'\/&gt;\n&lt;\/interface&gt;\n<\/code><\/pre>\n\n\n\n<p>Then finally you need to restart each of the guests.<\/p>\n\n\n\n<p>Since all the new network is isolated to host and the guests, all other communication from the guests will use the macvtap interface.<\/p>\n\n\n\n<p><strong>Conclusion<\/strong><\/p>\n\n\n\n<p>In brief, follow the steps to fix the issue with Guest unable to reach host using macvtap interface. If you need any assistance you can take our <a href=\"https:\/\/www.skynats.com\/contact-us\/\" target=\"_blank\" rel=\"noreferrer noopener\"><span style=\"color:#0575a5\" class=\"has-inline-color\">technical team<\/span><\/a> support to fix any sort of issues.&nbsp;<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Guest unable to reach host using macvtap interface: Typically, guest virtual machines can communicate with other guests. However, when configured to use a macvtap (also known as type=&#8217;direct&#8217;) network interface, the guest cannot connect to the host machine. Need assistance to fix the guest virtual machine and similar issues which are done under our server [&hellip;]<\/p>\n","protected":false},"author":7,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[507,297,319],"class_list":["post-6332","post","type-post","status-publish","format-standard","hentry","category-blog","tag-cannot-reach-host-when-using-macvtap-interface","tag-libvirtd","tag-macvtap"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v25.9 (Yoast SEO v27.4) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Guest Unable to Reach Host Using Macvtap Interface<\/title>\n<meta name=\"description\" content=\"Learn why Guest unable to reach host using macvtap interface and how to resolve connectivity issues with this network configuration.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Guest unable to reach host by using macvtap interface\" \/>\n<meta property=\"og:description\" content=\"Learn why Guest unable to reach host using macvtap interface and how to resolve connectivity issues with this network configuration.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/\" \/>\n<meta property=\"og:site_name\" content=\"Server Management Services | Cloud Management | Skynats\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/skynats\" \/>\n<meta property=\"article:published_time\" content=\"2021-04-22T08:19:34+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-10-30T07:14:29+00:00\" \/>\n<meta name=\"author\" content=\"Nabeela\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@skynatstech\" \/>\n<meta name=\"twitter:site\" content=\"@skynatstech\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Nabeela\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/guest-unable-to-reach-host-using-macvtap\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/guest-unable-to-reach-host-using-macvtap\\\/\"},\"author\":{\"name\":\"Nabeela\",\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#\\\/schema\\\/person\\\/2968118a72bea0868796abf1237ab3e0\"},\"headline\":\"Guest unable to reach host by using macvtap interface\",\"datePublished\":\"2021-04-22T08:19:34+00:00\",\"dateModified\":\"2025-10-30T07:14:29+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/guest-unable-to-reach-host-using-macvtap\\\/\"},\"wordCount\":514,\"publisher\":{\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#organization\"},\"keywords\":[\"cannot reach host when using macvtap interface\",\"libvirtd\",\"macvtap\"],\"articleSection\":[\"Blog\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/guest-unable-to-reach-host-using-macvtap\\\/\",\"url\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/guest-unable-to-reach-host-using-macvtap\\\/\",\"name\":\"Guest Unable to Reach Host Using Macvtap Interface\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#website\"},\"datePublished\":\"2021-04-22T08:19:34+00:00\",\"dateModified\":\"2025-10-30T07:14:29+00:00\",\"description\":\"Learn why Guest unable to reach host using macvtap interface and how to resolve connectivity issues with this network configuration.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/guest-unable-to-reach-host-using-macvtap\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.skynats.com\\\/blog\\\/guest-unable-to-reach-host-using-macvtap\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/guest-unable-to-reach-host-using-macvtap\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Guest unable to reach host by using macvtap interface\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/\",\"name\":\"Server Management Services | Cloud Management | Skynats\",\"description\":\"Server Management and Cloud Management\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#organization\",\"name\":\"Skynats Technologies\",\"url\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/wp-content\\\/uploads\\\/2021\\\/08\\\/Sknats-Logo-New-whole.png\",\"contentUrl\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/wp-content\\\/uploads\\\/2021\\\/08\\\/Sknats-Logo-New-whole.png\",\"width\":989,\"height\":367,\"caption\":\"Skynats Technologies\"},\"image\":{\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/skynats\",\"https:\\\/\\\/x.com\\\/skynatstech\",\"https:\\\/\\\/www.instagram.com\\\/skynatstech\\\/\",\"https:\\\/\\\/www.linkedin.com\\\/company\\\/skynats-technologies\",\"https:\\\/\\\/www.youtube.com\\\/channel\\\/UCvTAjrFJ4_E2MJKwlDHomlg\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.skynats.com\\\/blog\\\/#\\\/schema\\\/person\\\/2968118a72bea0868796abf1237ab3e0\",\"name\":\"Nabeela\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/12a999d0e3cd16cf2383c5551b39d00d6ddc2d035a2581ce5d85fce0762d0372?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/12a999d0e3cd16cf2383c5551b39d00d6ddc2d035a2581ce5d85fce0762d0372?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/12a999d0e3cd16cf2383c5551b39d00d6ddc2d035a2581ce5d85fce0762d0372?s=96&d=mm&r=g\",\"caption\":\"Nabeela\"}}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Guest Unable to Reach Host Using Macvtap Interface","description":"Learn why Guest unable to reach host using macvtap interface and how to resolve connectivity issues with this network configuration.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/","og_locale":"en_US","og_type":"article","og_title":"Guest unable to reach host by using macvtap interface","og_description":"Learn why Guest unable to reach host using macvtap interface and how to resolve connectivity issues with this network configuration.","og_url":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/","og_site_name":"Server Management Services | Cloud Management | Skynats","article_publisher":"https:\/\/www.facebook.com\/skynats","article_published_time":"2021-04-22T08:19:34+00:00","article_modified_time":"2025-10-30T07:14:29+00:00","author":"Nabeela","twitter_card":"summary_large_image","twitter_creator":"@skynatstech","twitter_site":"@skynatstech","twitter_misc":{"Written by":"Nabeela","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/#article","isPartOf":{"@id":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/"},"author":{"name":"Nabeela","@id":"https:\/\/www.skynats.com\/blog\/#\/schema\/person\/2968118a72bea0868796abf1237ab3e0"},"headline":"Guest unable to reach host by using macvtap interface","datePublished":"2021-04-22T08:19:34+00:00","dateModified":"2025-10-30T07:14:29+00:00","mainEntityOfPage":{"@id":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/"},"wordCount":514,"publisher":{"@id":"https:\/\/www.skynats.com\/blog\/#organization"},"keywords":["cannot reach host when using macvtap interface","libvirtd","macvtap"],"articleSection":["Blog"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/","url":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/","name":"Guest Unable to Reach Host Using Macvtap Interface","isPartOf":{"@id":"https:\/\/www.skynats.com\/blog\/#website"},"datePublished":"2021-04-22T08:19:34+00:00","dateModified":"2025-10-30T07:14:29+00:00","description":"Learn why Guest unable to reach host using macvtap interface and how to resolve connectivity issues with this network configuration.","breadcrumb":{"@id":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.skynats.com\/blog\/guest-unable-to-reach-host-using-macvtap\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.skynats.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Guest unable to reach host by using macvtap interface"}]},{"@type":"WebSite","@id":"https:\/\/www.skynats.com\/blog\/#website","url":"https:\/\/www.skynats.com\/blog\/","name":"Server Management Services | Cloud Management | Skynats","description":"Server Management and Cloud Management","publisher":{"@id":"https:\/\/www.skynats.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.skynats.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.skynats.com\/blog\/#organization","name":"Skynats Technologies","url":"https:\/\/www.skynats.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.skynats.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.skynats.com\/blog\/wp-content\/uploads\/2021\/08\/Sknats-Logo-New-whole.png","contentUrl":"https:\/\/www.skynats.com\/blog\/wp-content\/uploads\/2021\/08\/Sknats-Logo-New-whole.png","width":989,"height":367,"caption":"Skynats Technologies"},"image":{"@id":"https:\/\/www.skynats.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/skynats","https:\/\/x.com\/skynatstech","https:\/\/www.instagram.com\/skynatstech\/","https:\/\/www.linkedin.com\/company\/skynats-technologies","https:\/\/www.youtube.com\/channel\/UCvTAjrFJ4_E2MJKwlDHomlg"]},{"@type":"Person","@id":"https:\/\/www.skynats.com\/blog\/#\/schema\/person\/2968118a72bea0868796abf1237ab3e0","name":"Nabeela","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/12a999d0e3cd16cf2383c5551b39d00d6ddc2d035a2581ce5d85fce0762d0372?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/12a999d0e3cd16cf2383c5551b39d00d6ddc2d035a2581ce5d85fce0762d0372?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/12a999d0e3cd16cf2383c5551b39d00d6ddc2d035a2581ce5d85fce0762d0372?s=96&d=mm&r=g","caption":"Nabeela"}}]}},"_links":{"self":[{"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/posts\/6332","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/users\/7"}],"replies":[{"embeddable":true,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/comments?post=6332"}],"version-history":[{"count":1,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/posts\/6332\/revisions"}],"predecessor-version":[{"id":16534,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/posts\/6332\/revisions\/16534"}],"wp:attachment":[{"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/media?parent=6332"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/categories?post=6332"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.skynats.com\/blog\/wp-json\/wp\/v2\/tags?post=6332"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}