rushin010
Posts: 70
Joined: Mon Sep 19, 2016 8:02 am

raspberry pi 3 without ethernet cable

Wed Nov 30, 2016 5:44 am

hello, i have raspberry pi 3. in raspberry pi 3 has in built wifi. i am using putty with ethernet cable. can we use wifi for putty??

Heater
Posts: 13111
Joined: Tue Jul 17, 2012 3:02 pm

Re: raspberry pi 3 without ethernet cable

Wed Nov 30, 2016 5:51 am

Yes.

My Pi 3 has never seen an ethernet cable. Always accessed using SSH over WIFI.

rushin010
Posts: 70
Joined: Mon Sep 19, 2016 8:02 am

Re: raspberry pi 3 without ethernet cable

Wed Nov 30, 2016 6:37 am

can you tell me how to do it??

User avatar
HawaiianPi
Posts: 4534
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: raspberry pi 3 without ethernet cable

Wed Nov 30, 2016 7:00 am

rushin010 wrote:can you tell me how to do it??
Connect to your router using the built-in WiFi, and then the procedure is the same as it was with Ethernet (ssh user@hostname, or ssh user@ip-address).

SSH doesn't care how you are connected to the network. It doesn't even know how you are connected. It's just connecting to an address on the network.

If you are asking how to connect using WiFi, then that depends. If you have a monitor, keyboard and mouse on the Pi you can use the GUI. If the Pi is headless, then before you pull the Ethernet cable, connect with SSH and edit the wpa_supplicant.conf file.

Code: Select all

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf
The contents should look like this (add any missing lines manually):

Code: Select all

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=US

network={
	ssid="your-network-service-set-identifier"
	psk="your-network-WPA/WPA2-passphrase"
	key_mgmt=WPA-PSK
}
Edit your country code, the ssid and the passphrase then save the file.

Now you can reboot the Pi and it should connect using WiFi. Once you have verified it's connected wirelessly you can remove the Ethernet cable and reboot again.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

broe23
Posts: 903
Joined: Thu Jan 28, 2016 9:35 pm
Location: Central IL
Contact: Website

Re: raspberry pi 3 without ethernet cable

Wed Nov 30, 2016 8:00 am

rushin010 wrote:hello, i have raspberry pi 3. in raspberry pi 3 has in built wifi. i am using putty with ethernet cable. can we use wifi for putty??
You can use either or. Just depends on how strong of a wifi signal you have. I just use Terminal for remote sessions between my Macbook or my wife's Linux Mint laptop. If you are using Windows, use WINSCP if needing to change or move files.
Ren: Now listen, Cadet. I've got a job for you. See this button? Ren: Don't touch it! It's the History Eraser button, you fool! Stimpy: So what'll happen? Ren: That's just it. We don't know. Maybe something bad, maybe something good.

davesteele
Posts: 57
Joined: Wed Nov 30, 2016 4:16 pm

Re: raspberry pi 3 without ethernet cable

Wed Nov 30, 2016 4:25 pm

The Comitup boot image will let you connect your Pi 3 to your wifi remotely, without editing the SD card or using any wires on the PI (except for the power cord). It is a Raspbian image with packages included to manage wifi connections via HTTP.

https://davesteele.github.io/comitup/

Per the recent Pixel security announcement, you should 'sudo touch /boot/wifi' before doing an OS update.

h.jha
Posts: 1
Joined: Sun Jun 17, 2018 5:23 am

Re: raspberry pi 3 without ethernet cable

Sun Jun 17, 2018 5:29 am

Heater wrote:
Wed Nov 30, 2016 5:51 am
Yes.

My Pi 3 has never seen an ethernet cable. Always accessed using SSH over WIFI.

how did you install raspbian or setup wifi without ethernet? i have just began can you point me to a direction?

User avatar
HawaiianPi
Posts: 4534
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: raspberry pi 3 without ethernet cable

Sun Jun 17, 2018 4:08 pm

h.jha wrote:
Sun Jun 17, 2018 5:29 am
how did you install raspbian or setup wifi without ethernet? i have just began can you point me to a direction?
This is the procedure I use for setting up headless boot with SSH and wireless network. It works with Raspbian Jessie or Stretch, Desktop or Lite, and with the built-in WiFi on the Pi3B(+) & Pi Zero W, or a Raspbian compatible USB WiFi dongle on other models. Everything is done before you boot, and can be done on a Windows or Mac computer which only has access to the small FAT32 "boot" partition of a Raspbian imaged SD card.
  1. Grab the latest Raspbian image from https://www.raspberrypi.org/downloads/raspbian/
  2. Grab the Etcher software from https://etcher.io/
  3. Use Etcher to write the Raspbian image to your SD card.
    • You don't need to extract the image or format the card prior to writing.
    • Just run Etcher, choose the Raspbian .zip you downloaded, pick your SD card and write.
    • If you have trouble, verify the SHA256 checksum of the download.
    • Writing an image to your card will erase everything previously on it!
  4. Remove and reinsert the SD card so that your Windows or Mac PC can see the small FAT32 partition on the card (labelled "boot").
    • If you get a message telling you the card must be formatted, cancel it.
  5. On that small FAT32 partition, create a file with the name ssh (or ssh.txt). It can be empty, the contents don't matter.
  6. To connect to a wireless network, create another file on the card called wpa_supplicant.conf, which has the following inside:

    Code: Select all

    ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
    update_config=1
    country=US
    
    network={
         ssid="Your network name/SSID"
         psk="Your WPA/WPA2 security key"
         key_mgmt=WPA-PSK
    }
    • Edit country=, ssid= and psk= with your information and save the file.
    • Use the 2 letter country abbreviation in CAPS (without this you will have no WiFi).
    • Use a pure text editor, not a word processor, to edit the wpa_supplicant.conf file.
  7. Make sure that both files are in the main directory of the small FAT32 partition, not in any folder.
  8. Safely eject the card from your PC and use it to boot the Pi.
If Raspbian finds an ssh file it will enable SSH and delete the file. If it finds a wpa_supplicant.conf file, it will move it to its correct location and connect to your wireless network. Give your Pi some time to boot and connect to your network (the first boot always takes longer), then you should be able to SSH into the Pi and configure it how you like.

If you have a Zeroconf network service installed you can SSH into pi@raspberrypi.local (provided you don't have any other Pi computers on your network with the same default hostname). Otherwise you must SSH into your Pi's IP address, which you can find by logging into your router and checking the list of connected clients, or using a network scanner app (like Fing for smartphones).

To login using SSH from Windows, you can use an app called PuTTY, which looks like this (click picture for download link).
Image

In the Host Name (or IP address) field, enter either,

Code: Select all

pi@raspberrypi.local
or
pi@your.pi.IP.address
make sure SSH is selected (it should be by default) and click on Open.

If you have done everything correctly, a terminal window will open and you should see a password request. Although, if it's the first time you've connected to your Pi, you may have to answer "yes" to a security question, and then you'll get the password prompt. After login you'll get a warning about having SSH enabled with the default password, so type passwd[Enter] and enter a new password (twice). And now you can do whatever you need to configure your little Raspberry Pi computer.

Code: Select all

sudo raspi-config
Will bring up the Raspbian configuration utility. If you have more than one Raspberry Pi computer on your network it's a good idea to change the hostnames to something unique so that they can easily be identified.

Note:
If you have attempted this and failed, then unplugged power to turn off your Pi, you should start over with a freshly imaged card. Improperly powering down the Pi can cause SSH key generation to fail, which will prevent SSH logins (even if everything else is correct).

Alternatives to PuTTY:
If your main PC has the Windows 10 OS, there are 2 alternatives to PuTTY. The Windows 10 Fall Creators Update (2017) added the ability to install the Windows Subsystem for Linux, which is a Linux Bash shell for Windows (there are a few different versions of Linux in the Microsoft Store). And the recent Windows 10 Spring Update (2018) added OpenSSH directly to the Windows command and powershell utilities.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?

davesteele
Posts: 57
Joined: Wed Nov 30, 2016 4:16 pm

Re: raspberry pi 3 without ethernet cable

Sun Jun 17, 2018 4:24 pm

Alternatively, try Comitup. Setup is via a web interface on a hotspot made by the pi.

hippy
Posts: 5790
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: raspberry pi 3 without ethernet cable

Sun Jun 17, 2018 6:50 pm

h.jha wrote:
Sun Jun 17, 2018 5:29 am
how did you install raspbian or setup wifi without ethernet? i have just began can you point me to a direction?
If you have HDMI, keyboard and mouse connected; if you install using NOOBS, and I believe PINN, there's an option to allow the Pi to connect to your WiFi router.

If headless then follow the above suggestions.

Man in a van
Posts: 130
Joined: Sat Dec 27, 2014 2:41 pm
Location: Staffordshire, UK.

Re: raspberry pi 3 without ethernet cable

Sun Jun 17, 2018 9:21 pm

Here is a link for the two letter country code

https://en.wikipedia.org/wiki/ISO_3166- ... e_elements

Return to “General discussion”