
{"id":2962,"date":"2014-02-06T09:31:17","date_gmt":"2014-02-06T09:31:17","guid":{"rendered":"http:\/\/ubuntuhandbook.org\/?p=2962"},"modified":"2024-04-22T09:46:46","modified_gmt":"2024-04-22T09:46:46","slug":"wifi-hotspot-ubuntu-laptop-android","status":"publish","type":"post","link":"https:\/\/ubuntuhandbook.org\/index.php\/2014\/02\/wifi-hotspot-ubuntu-laptop-android\/","title":{"rendered":"Create Wifi Hotspot in Ubuntu Laptop For Android Phones"},"content":{"rendered":"<p><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2013\/12\/Ubuntu-Wifi-security.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2682\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2013\/12\/Ubuntu-Wifi-security.jpg\" alt=\"Wireless access point for Android\" width=\"240\" height=\"238\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2013\/12\/Ubuntu-Wifi-security.jpg 240w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2013\/12\/Ubuntu-Wifi-security-150x150.jpg 150w\" sizes=\"auto, (max-width: 240px) 100vw, 240px\" \/><\/a><\/p>\n<p>If you have a single wired Internet connection, you can easily setup an ad-hoc wireless network with Ubuntu and share the Internet connection among multiple devices. Unfortunately, some devices including <b>Android &amp; Windows Phones may not support ad-hoc wireless networks<\/b>.<\/p>\n<p><b>UPDATE 2024: This tutorial is outdated! It may no longer works in current Ubuntu releases!<\/b><\/p>\n<p><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/ubuntu-create-ad-hoc.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2963\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/ubuntu-create-ad-hoc.png\" alt=\"ubuntu ad-hoc wifi hotspot\" width=\"468\" height=\"260\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/ubuntu-create-ad-hoc.png 468w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/ubuntu-create-ad-hoc-300x166.png 300w\" sizes=\"auto, (max-width: 468px) 100vw, 468px\" \/><\/a><\/p>\n<p>So this tutorial is going to show you how to turn your Ubuntu laptop into a wireless access point in another way with Android phones support.<\/p>\n<div class=\"arconix-box arconix-box-red\"><i class='fa fa-2x pull-left fa-exclamation-triangle'><\/i><div class=\"arconix-box-content\"><b>UPDATE 2: Seems that Ap-hotspot is not working good on Ubuntu 14.04, please try <a href=\"https:\/\/ubuntuhandbook.org\/index.php\/2014\/06\/share-internet-with-android-ubuntu-1404\/\">this post using KDE&#8217;s network manager<\/a>.<\/b><\/p>\n<p>Or use <a href=\"https:\/\/ubuntuhandbook.org\/index.php\/2014\/09\/3-ways-create-wifi-hotspot-ubuntu\/\" target=\"_blank\" rel=\"noopener\">the default Network Manager with a little hack.<\/a><\/div><\/div>\n<p><b>To get started<\/b>, press Ctrl+Alt+T on keyboard to open the terminal. When it opens, run the commands below one by one to install ap-hotspot.<\/p>\n<p><b>Ap-hotspot<\/b> is an open-source project that automatically creates an infrastructure (Access Point mode) wireless hotspot in Ubuntu that should work with Android and Windows Phone devices<\/p>\n<pre style=\"border: none;\">sudo add-apt-repository ppa:nilarimogard\/webupd8\r\n\r\nsudo apt-get update\r\n\r\nsudo apt-get install ap-hotspot<\/pre>\n<p>Supports for Ubuntu 13.10, Ubuntu 13.04, Ubuntu 12.10, Ubuntu 12.04 and Ubuntu 14.04. <del>download &amp; install the ap-hotspot deb for saucy at <a title=\"ap-hotspot in launchpad page\" href=\"https:\/\/launchpad.net\/~nilarimogard\/+archive\/webupd8\/+packages\" target=\"_blank\" rel=\"noopener\">this page<\/a><\/del>.<\/p>\n<p><b>For Ubuntu 14.04,<\/b> due to bug you need to downgrade <code>hostapd<\/code> to make ap-hotspot work.<\/p>\n<ol>\n<li>First uninstall the buggy <code>hostapd<\/code> in Ubuntu 14.04 via:\n<pre style=\"border: none;\">sudo apt-get remove hostapd<\/pre>\n<\/li>\n<li>Copy and paste the command below into terminal that matches your OS type &#8211; check out via System Setting -&gt; Details &#8211; and hit run to download, install, and hold the old version of hostapd.While running the commands below, type in your user password in terminal when prompt.\n<p>For 64-bit system:<\/p>\n<pre style=\"border: none;\">cd \/tmp &amp;&amp; wget http:\/\/archive.ubuntu.com\/ubuntu\/pool\/universe\/w\/wpa\/hostapd_1.0-3ubuntu2.1_amd64.deb &amp;&amp; sudo dpkg -i hostapd*.deb &amp;&amp; sudo apt-mark hold hostapd<\/pre>\n<p>For 32-bit system:<\/p>\n<pre style=\"border: none;\">cd \/tmp &amp;&amp; wget http:\/\/archive.ubuntu.com\/ubuntu\/pool\/universe\/w\/wpa\/hostapd_1.0-3ubuntu2.1_i386.deb &amp;&amp; sudo dpkg -i hostapd*.deb &amp;&amp; sudo apt-mark hold hostapd<\/pre>\n<\/li>\n<\/ol>\n<p>Once installed, execute below command to configure your wifi hotspot:<\/p>\n<pre style=\"border: none;\">sudo ap-hotspot configure<\/pre>\n<p>It will detect the wired &amp; wireless interfaces and ask you to confirm that if they are correct (run <code>ifconfig<\/code> if you&#8217;re not sure). Then you&#8217;ll be asked to enter a wifi hotspot name and setup a password.<\/p>\n<p><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/ap-hotspot.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2964\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/ap-hotspot.jpg\" alt=\"ap-hotspot config\" width=\"580\" height=\"296\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/ap-hotspot.jpg 580w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/ap-hotspot-300x153.jpg 300w\" sizes=\"auto, (max-width: 580px) 100vw, 580px\" \/><\/a><\/p>\n<p>Finally start the wireless hotspot via:<\/p>\n<pre style=\"border: none;\">sudo ap-hotspot start<\/pre>\n<p>Now you&#8217;re able to connect to wifi hotspot via your Android phone!<\/p>\n<p><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/shared-network.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2965\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/shared-network.png\" alt=\"ubuntu wifi hotspot android phone\" width=\"260\" height=\"434\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/shared-network.png 260w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2014\/02\/shared-network-179x300.png 179w\" sizes=\"auto, (max-width: 260px) 100vw, 260px\" \/><\/a><\/p>\n<p>To stop the wireless hotspot, execute this command in Ubuntu terminal:<\/p>\n<pre style=\"border: none;\">sudo ap-hotspot stop<\/pre>\n<p><b>UPDATE<\/b>: Please report issues at: <a href=\"https:\/\/github.com\/hotice\/AP-Hotspot\/\" target=\"_blank\" rel=\"noopener\">https:\/\/github.com\/hotice\/AP-Hotspot\/<\/a>.<\/p>\n<p><b>Tip:<\/b> For the error &#8220;Access Point Mode is not supported by this device&#8221;, you may take a look at <a href=\"https:\/\/ubuntuhandbook.org\/index.php\/2014\/09\/wifi-hotspot-access-point-not-supported\/\" target=\"_blank\" rel=\"noopener\">this page<\/a>.<\/p>","protected":false},"excerpt":{"rendered":"<p>If you have a single wired Internet connection, you can easily setup an ad-hoc wireless network with Ubuntu and share the Internet connection among multiple devices. Unfortunately, some devices including Android &amp; Windows Phones may not support ad-hoc wireless networks. UPDATE 2024: This tutorial is outdated! It may no longer works in current Ubuntu releases! [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[1016],"class_list":["post-2962","post","type-post","status-publish","format-standard","hentry","category-howtos","tag-wifi-hotspot-with-android-support"],"_links":{"self":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts\/2962","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/comments?post=2962"}],"version-history":[{"count":0,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts\/2962\/revisions"}],"wp:attachment":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/media?parent=2962"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/categories?post=2962"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/tags?post=2962"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}