4.1.0-rc3-bone1.2 trapped in board - no SSH or serial

Hi - my weekend experiment was to build a Debian Jessie with 4.1.0-rc3-bone1.2 kernel image to play with; sadly, while it appears to be running, I have no way to communicate with it. Pings to its IP address are responded to promptly, but SSH login attempts are rejected immediately, and there is no apparent serial path either.
I checked the SSH entries in /etc/init on the SD image; they appear to be set to enable the sshd server.
Anyone able to coax the beast out of its shell?

Thx, Mike

Did you build using Robert guide on eewiki ? If so, you probably did not install an ssh server such as openssh-server . . .

william@eee-pc:~$ ssh debian@192.168.7.2
Debian GNU/Linux 7

BeagleBoard.org Debian Image 2015-03-01

Support/FAQ: http://elinux.org/Beagleboard:BeagleBoneBlack_Debian

default username:password is [debian:temppwd]

debian@192.168.7.2’s password:
Last login: Tue May 12 16:34:45 2015 from 192.168.7.1
debian@beaglebone:~$ uname -r
4.1.0-rc3-bone0

Slightly older kernel here, but it should be the same. Well actually, I’m running SYSV init daemon, so I suppose that could be systemd giving you “problems”. e.g. A systemd service may need to be enabled to get your ssh server running at boot ? Knowing the process you went through to get a working image would be helpful in nailing down what your issue is . . .

and there is no apparent serial path either

For this, you would need g_serial.ko located in the kernel version+modules directory. For me the path is:

/lib/modules/4.1.0-rc3-bone0/kernel/drivers/usb/gadget/legacy/g_serial.ko

You would need to add “g_serial” to the file located at /etc/modules, assuming systemd does not stand in your way. Which supposedly systemd is supposed to be backwards compatible with SYSV LSB init scripts, etc.

You would possibly also have to either setup a systemd service to start up an agetty or similar connection. or modify /etc/inittab to reflect that change. Which ever works for your use case.

Yes, I was running Robert’s BBB instructions. I agree it’s probably a systemd startup issue, but haven’t been able to find setup instructions that merely altered file contents - which I can do while burning the SD - rather than using systemctl on a running system. Can’t start SSH without SSH… although the full openssh-server package seems to have been installed in the debian-8.0-minimal… rootfs.

There’s my question - how does one set up a systemd service to start up anything without running systemctl on the system?

You just symlink the *.service.

but ssh is running by default in the image.

more then likely, you have a board that needs the phy-search patch,
that's currently disabled in my v4.1.0-rcX tree..

login over serial thru the debug header to verify..

Regards,

Better yet, enable g_serial, or g_ether.

@Robert, does systemd get in the way when trying to enable either of those gadget drivers ? I know for me it was pretty easy, but don’t think I dd’d over a Jessie image. Wheezy 7.8 I’m thinking, and all I did in preparation was comment out the systemd init line in uEnv.txt

systemd actually does the right thing, even when it has to wait for us
to decide g_multi vs g_ether....

btw, here's how the systemd serial-getty service was enabled for
ttyGS0 (without systemctr).. (when we modprobe g_multi and the
usb-slave device starts: usb flash, usb ether, & usb serial)

cp /lib/systemd/system/serial-getty@.service
/etc/systemd/system/serial-getty@ttyGS0.service
ln -s /etc/systemd/system/serial-getty@ttyGS0.service
/etc/systemd/system/getty.target.wants/serial-getty@ttyGS0.service

after g_multi is loaded, systemd correctly fires up the getty service
for usb serial...

Regards,

Yeah Wheezy 7.8 is was. Pretty sure this would not work on Jessie. As Jessie needs SYSV packages installed in order to use SYSV( uses systemd as default ). However, systemd is supposed to be backwards compatible with SYSV, so if you do not comment out the line i suggest below in uEnv.txt, it may just work.

william@eee-pc:~/downloads/linux-images$ sudo dd if=/dev/zero of=/dev/sdb bs=1024 count=22+0 records in
2+0 records out
2048 bytes (2.0 kB) copied, 0.255138 s, 8.0 kB/s

william@eee-pc:~/downloads/linux-images$ sudo dd if=/home/william/downloads/linux-images/bone-debian-7.8-console-armhf-2015-03-01-2gb.img of=/dev/sdb
3481600+0 records in
3481600+0 records out
1782579200 bytes (1.8 GB) copied, 560.021 s, 3.2 MB/s

OPTIONAL:

If like me you wish to disable systemd . . .period.

william@eee-pc:~$ mkdir tmp
william@eee-pc:~$ sudo mount /dev/sdb1 /home/wiliam/tmp
william@eee-pc:~$ sudo nano ~/tmp/boot/uEnv.txt

And change:
cmdline=quiet init=/lib/systemd/systemd
to
#cmdline=quiet init=/lib/systemd/systemd

If you then wish to have USB networking . . .

william@eee-pc:~$ sudo nano /etc/network/interfaces

Ethernet/RNDIS gadget (g_ether)

… or on host side, usbnet and random hwaddr

Note on some boards, usb0 is automaticly setup with an init script

Add “auto usb0” if not using systemd

auto usb0
iface usb0 inet static
address 192.168.7.2
netmask 255.255.255.0
network 192.168.7.0
gateway 192.168.7.1

william@eee-pc:~$ sudo nano /etc/modules

/etc/modules: kernel modules to load at boot time.

err, wow just realized my noted are riddled with mistakes . . . paths are wrong, etc.

@Robert, ah cool, but the idea was to help this person enable one of the USB gadget devices via his / her dev machine. As it does not seem as though he/she has access to a serial debug cable.

With sysv, I’ve done this, and know how to go about it, but with systemd . . . yeah no idea.

So sounds as though maybe you’re saying if “we” edit /etc/modules, and add “g_serial” or “g_ether” or “g_multi”. The respective service would start ?

I dropped back to 3.14 in the meantime; ssh is healthy there, as my main intent was to mess with kernel modules.

Thanks.