Hot answers tagged

118

All you need is to place an empty file named 'ssh' onto the boot (FAT) partition of your SD card (no need to mount ext3). Tested with 2016-11-25-raspbian-jessie-lite.img. Source: https://www.raspberrypi.org/documentation/remote-access/ssh/ More info about Nov '16 security update: https://www.raspberrypi.org/blog/a-security-update-for-raspbian-pixel/


85

Quoting the documentation: As of the November 2016 release, Raspbian has the SSH server disabled by default. You will have to enable it manually. To enable SSH on machines through console: Enter sudo raspi-config in the terminal, first select Interfacing Options, then navigate to ssh, press Enter and select Enable or disable ssh server. To enable ...


71

You have to use avahi-daemon (zeroconf) if you want to connect via a hostname instead of an IP address. From the Raspberry Pi documentation on RPi Advanced Setup: Install avahi with the following commands on the Raspberry Pi: sudo apt-get install avahi-daemon Update boot startup for avahi-daemon sudo insserv avahi-daemon Apply the new configuration with:...


70

To enable ssh at startup, backup boot.rc on the boot partition on the SD image and replace it with boot_enable_ssh.rc I don't know about your router, but you may be able to configure it to reserve a fixed IP address for the MAC address of your Pi.


62

From https://www.raspberrypi.org/documentation/remote-access/ssh/ As of the November 2016 release, Raspbian has the SSH server disabled by default. You will have to enable it manually. This is done using raspi-config: Enter sudo raspi-config in the terminal, first select Interfacing options, then navigate to ssh, press Enter and select Enable or ...


52

Copy boot_enable_ssh.rc to boot.rc from /boot in the Raspberry Pi's rootfs (SD card) Still in the Raspberry Pi's rootfs, edit /etc/network/interfaces in order to have a fixed IP address assigned (so no DHCP server is needed). For example, auto lo eth0 iface lo inet loopback iface eth0 inet static address 192.168.0.202 netmask 255.255.255.0 ...


45

Although Raspbian used to enable ssh by default, from December 2016 it no longer does so. While there is still no boot_enable_ssh.rc file as the OP requested in 2012, ssh can be enabled on first boot by creating a file called “ssh” in /boot. As /boot can be written to by any OS that understands SD cards, this extra step is easily done on first installation. ...


38

If you want to login as root using SSH or WinSCP you need to edit the config of SSHD, do this: Login, and edit this file: sudo nano /etc/ssh/sshd_config Find this line: PermitRootLogin without-password Edit: PermitRootLogin yes Close and save file reboot or restart sshd service using: /etc/init.d/ssh restart Set a root password if there isn't one already: ...


36

None of the boot_enable_ssh.rc stuff exists in current Raspian builds. You boot, a nice graphical menu gives you some options (including whether SSHD should load at boot) and then dumps you out on a command line. That's great if... you're a graphical user. If you're not, you're left in the position where you have to somehow externally run update-rc.d. All ...


30

Right off the bat, let me say that there is not a way to recover a password (without some actual cracking/hacking which I don't know how to do). Resetting your password is your best bet. So the first step will be to determine if you have any way to log in to the Raspbery Pi. If you're able to log in with a user that has 'sudo' rights (this includes SSH... ...


30

The Raspberry Pi 2 will give BCM2709 hardware and ~1 GB of RAM like this: pi@raspberrypi:~ $ cat /proc/cpuinfo | grep Hardware Hardware : BCM2709 pi@raspberrypi:~ $ cat /proc/meminfo | grep MemTotal MemTotal: 947756 kB while the Pi 1 reports BCM2708 hardware and definitely less than 1 GB: pi@raspberrypi:~ $ cat /proc/cpuinfo | grep Hardware ...


27

It could be that your Pi is trying to do a reverse DNS lookup of the client's connecting hostname for security reasons, which is okay, but leads to the timeouts if you don't have a working reverse DNS. when you do finally login, try adding UseDNS no to your /etc/ssh/sshd_config file, and see if that helps improve things, of course don't forget to reload ...


26

Use the command ncdu. It is a console program to display disc usage. It has a ncurses GUI. I usually run ncdu -x <some folder>, the x switch is there to not cross filesystem boundaries. apt-get install ncdu ncdu man page


24

You can lookup the IP address by hostname. Assuming the hostname of your Pi is "raspberrypi" Here is how you obtain the IP address using ping command and hostname. From Linux: ping raspberrypi From Windows: ping raspberrypi From OS X: ping raspberrypi.local In order for the command to work from Windows, you need to have Samba running on your Pi. You can ...


23

If look at the /etc/init.d/skeleton script, in the beginning of it there are two marks : ### BEGIN INIT INFO and ### END INIT INFO. All the data inside those marks is the configuration for runtime dependences and you can look them up in the Debian Wiki. Your script is missing these tags and configuration so insserv just uses some defaults. This is just a ...


22

ssh is installed but not started by default on runlevel 2, the default for raspbian. Rename /etc/rc2.d/ssh/K??ssh to /etc/rc2.d/ssh/S02ssh EDIT The sd card comes with 2 partitions. The 1st is vfat; the 2nd is ext3. You need some utility to access it from macosx. 1st google result for ext2 macosx: http://blog.applegrew.com/2011/12/access-ext3ext2-file-...


20

Mount the SD card, go into the file system, and edit /etc/passwd. Find the line starting with "pi" that begins like this: pi:x:1000:1000... Get rid of the x; leave the colons on either side. This will eliminate the need for a password. You probably then want to create a new password by using the passwd command after you log in.


20

Here are the steps I used (on debian) which you might find useful. 1.Setting Static IP for the Pi. a.Open the interfaces file using the command sudo nano /etc/network/interfaces b.Change the interfaces file to the following (This works for me I am not sure if a few of the lines can be excluded). auto lo iface lo inet loopback iface eth0 inet static ...


20

How To Geek has a good article that covers this issue. In a nutshell .local domains are self-reported by each host (via Multicast DNS), and other machines on the network have to listen for them. Windows comes with such a service (LLMNR) however it's non-standard and therefore doesn't work terribly well. Instead you should install Apple's Bonjour service (...


20

That's a tough one. The WiFi won't automatically connect. So I would try the following: Image a micro SD card with the Raspbian OS image using Win32DiskImager. Manually configure your WiFi from another computer. In another computer running Linux (or PC with Live CD) you could edit the following file: /etc/wpa_supplicant/wpa_supplicant.conf And add the ...


19

To start, you will need to install pptpclient, this can be achieved by: sudo apt-get install pptp-linux Next, Create a file in /etc/ppp/peers with arbitrary name and the following contents: pty "pptp $VPNHOSTNAME --nolaunchpppd --debug" name $USERNAME password $PASSWORD remotename PPTP require-mppe-128 require-mschap-v2 refuse-eap refuse-pap refuse-chap ...


19

So after a lot of googling I found the codes that setterm should be sending to the tty and these two command unblank the screen every time. sudo chmod 666 /dev/tty1 echo -ne "\033[9;0]" >/dev/tty1 The only reason I can think of all the other commands (that should have worked) failing was because the Pi is connected via svideo to a tv and not HDMI or a ...


19

Try Pi Finder for Mac to discover the RPi's IP with a headless RPi unit. Though in your edited question, it appears the IP is listed under en0 as 192.168.91.16, assuming that your ifconfig output is coming from the RPi.


17

I used ftp to solve my problem (as noted above), but recently discovered another method, which other Mac users may find useful. sudo apt-get install netatalk Installs the appletalk protocol on the Pi. This lets you use the following (at the terminal prompt on the Mac) to connect to the Pi open afp://10.1.1.10 (replace this with your Raspberry Pi IP ...


17

As of November 2016, SSH is disabled by default on raspbian. The easiest way to get around this is to place a file called "SSH" on the SD card (notice no file extension). SSH will then be enabled. Adding Notes for users with monitor access from this link: Apparently, the SSH server is now disabled by default. If there is no server listening for ...


17

The easiest way to do this for a headless setup is to create a file named ssh on the boot partition of the SD card. This will enable the SSH daemon immediately after first boot and will be deleted. Official SSH guide: https://www.raspberrypi.org/documentation/remote-access/ssh/README.md#3-enable-ssh-on-a-headless-raspberry-pi-add-file-to-sd-card-on-another-...


16

Linux If you've never heard of ssh-keys before, you'll need to generate one like this $ ssh-keygen -t dsa This creates a directory ~/.ssh/ and stores the key files $ ls -l .ssh/ -rw------- 1 gnibbler gnibbler 668 Aug 22 2004 .ssh/id_dsa -rw------- 1 gnibbler gnibbler 603 Aug 22 2004 .ssh/id_dsa.pub You need to copy id_dsa.pub to the RPi. There is a ...


15

If you start Xming on your Windows computer, then you already have an X server running. You don't have to start the X server of your Raspberry Pi using startx. Your X applications will run on the Raspberry Pi but the application will draw onto Windows' Xming X server. The documentation you linked, states that you have to start X server on Windows, and it ...


15

One can start the ssh server using the boot.rc. Below is an explanation of how that works. Configuring the boot.rc Insert an SD-Card with the Debian OS on it back into the machine, you copied over the image on. The operating system of that machine should mount the boot partition which is the first partition of the the SD-card. If it does not try something ...


Only top voted, non community-wiki answers of a minimum length are eligible