px4 service issue
-
I have an issue with the px4 service where the px4 service starts at stop status on the drone boot. In my short time debugging this I looked at the body of the service and I see it requires another service to end:
[Unit] Description=px4 After=sscrpcd.service Requires=sscrpcd.service [Service] ExecStartPre=/bin/sleep 2 ExecStart=/usr/bin/voxl-px4 Restart=on-failure [Install] WantedBy=multi-user.target
but I can't find this service on the system nor can I find it online.
Am I missing something?
I would love some help with this. -
@giladWDS I'm not sure I understand what you mean by "starts at stop status". Can you explain the issue? And what service can't you find? sscrpcd.service?
voxl2:/$ sudo find . -name sscrpcd.service ./lib/systemd/system/multi-user.target.wants/sscrpcd.service ./lib/systemd/system/sscrpcd.service find: './sys/kernel/slab': Input/output error ./sys/fs/cgroup/pids/system.slice/sscrpcd.service ./sys/fs/cgroup/devices/system.slice/sscrpcd.service ./sys/fs/cgroup/systemd/system.slice/sscrpcd.service ./sys/fs/cgroup/unified/system.slice/sscrpcd.service
-
@Eric-Katzfey
never knew that there are services outside of/etc/systemd/system
andsystemctl status voxl-px4
gives disable. I will bring the full argument as soon as I have access to the machine -
@giladWDS To enable it just enter
systemctl enable voxl-px4
-
@Eric-Katzfey
I did. The issue is that the drone is supposed to be autonomous at the end. and I would like to avoid constantly checking whether the px4 service is alive or not.
from my understanding the service is supposed to be alive on boot so it seems to be a bag that I would want to fix. -
@giladWDS Okay, so the issue is that the service starts but px4 is not actually running? Can you include the output of the command
systemctl status -l voxl-px4
? And alsojournalctl -b -u voxl-px4
? -
@Eric-Katzfey I saw a similar symptom last Friday on a voxl2 that seemed to have a corrupt partition for
/dev/sda8
.
Flashing to 1.3.5 wrote/data
to/
without sda8 mounted.
voxl-px4
failed depending onsscrpcd.service
which failed depending ondata.mount
voxl2:/$ mount /dev/disk/by-partlabel/userdata /data
mount: /data: wrong fs type, bad option, bad superblock on /dev/sda8, missing codepage or helper program, or other error.voxl2:/$ fsck.ext4 /dev/sda8
e2fsck 1.44.3 (10-July-2018)
ext2fs_open2: Bad magic number in super-block
fsck.ext4: Superblock invalid, trying backup blocks...
fsck.ext4: Bad magic number in super-block while trying to open /dev/sda8voxl2:/$ fdisk -l |grep sda8
The backup GPT table is corrupt, but the primary appears OK, so that will be used.
/dev/sda8 41480 16818695 16777216 64G unknownReflashing with
./install.sh --wipe-persistent
fixedsda8
and made everything work.@giladWDS could be worth checking
/dev/sda8
is being mounted as/data
without any errors. -
@ben-grocholsky This is very interesting, not something I've seen before. Out of curiosity what OS on your host machine are you using for the flashing process?
-
@tom that was from ubuntu 20.04. Looking back up the terminal history I see the install script stopped at:
[ERROR] missing /data/modalai/sku.txt
[ERROR] please run voxl-configure-sku to make a new one
and didn't run the next setup steps. I didn't realize the flashing failed until seeingvoxl-px4
couldn't start. And digging into that found this thread.