# Raspberry pi 3 B camera issues after upgrade

**URL:** https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280
**Category:** Troubleshooting
**Created:** [18 April 2025 11:19 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280 "2025-04-18T11:19:24Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![Vidar](https://dietpi.com/forum/letter_avatar_proxy/v4/letter/v/e36b37/32.png) [@Vidar](https://dietpi.com/forum/u/Vidar)
#### Post date: [18 April 2025 11:19 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/1 "2025-04-18T11:19:24Z")

</div>

### Creating a bug report/issue

I have searched the existing open and closed issues

#### Required Information

- DietPi version | G\_DIETPI\_VERSION\_CORE=9  
G\_DIETPI\_VERSION\_SUB=11  
G\_DIETPI\_VERSION\_RC=2  
G\_GITBRANCH=‘master’  
G\_GITOWNER=‘MichaIng’
- Distro version | bookworm 0
- Kernel version | Linux DietPi 6.12.20+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.12.20-1+rpt1~bpo12+1 (2025-03-19) aarch64 GNU/Linux
- Architecture | arm64
- SBC model | RPi 3 Model B+ (aarch64)
- Power supply used | several
- SD card used | One boots from USB drive the other from SD card

#### Additional Information (if applicable)

- Software title | motioneye
- Was the software title installed freshly or updated/migrated? Both
- Can this issue be replicated on a fresh installation of DietPi? Yes

#### Steps to reproduce

1. Install HW camera, install fresh dietpi, install motioneye
2. make sure camera is active in dietpi-config
3. Can not add camera to motioneye

#### Expected behaviour

- Camera available in motioneye

#### Actual behaviour

- No camera available

#### Extra details

Let me tell you the whole story.

I have one raspberry pi 3B that runs pihole and motioneye (with official raspberry pi camera (i think v2)). It has been doing this permanently for years. I have another 3B that only acts as a camera when we are on holiday. It has a chinese bought camera (ali express) which works just fine.

Two weeks ago, I took out the second pi and did all the upgrades needed. Suddenly the camera stopped working (it was working before the upgrades). /dev/video0 was not available anymore. When I rebooted the pi it said ‘hwmon hwmon1 : Undervoltage detected!’ right after the ‘systemd-shutdown : Rebooting’ but it did not reboot. I thought that the power supply (official) gave out but it did not. I tried with the powersupply of the working other one and that gave the same. When I disconnected the ribbon cable of the camera, it stopped saying that and it would just reboot normally. Maybe something went wrong during a patch so I reinstalled a new dietpi image and did the setup again but that also did not solve it. So I ordered a new camera and ribbon cable (also not an official one) and waited. I also upgraded the software of the second (working) one to the last version and that seemed fine. So I waited.

A few days ago, I logged in to the working one his motioneye and it seemed like that it also stopped working. The last recordings are from a few days after I did the upgrade. It behaves in much the same way. It stops when rebooting (although it did not give the Undervoltage error) and in this case motioneye says: v4l2\_device\_open: Failed to open video device /dev/video0: No such file or directory.

I tried the new camera and ribbon cable and it changed nothing.

Some extra command results that are the same on both systems:  
vcgencmd get\_camera : supported=1 detected=1, libcamera interfaces=0  
rpicam-hello --list-cameras : No cameras available!  
libcamera-hello --list-cameras: No cameras available!  
I do not know if it is related but I also get this error in journalctl: systemd-udevd[177]: bcm2835-camera: Worker [180] terminated by signal 11 (SEGV)

I am a bit stomped. I could try another operating system but I do not want to. I really really like dietpi. I have a feeling that it is related with the new kernel somehow but I dont understand.

---

<div class="post-metadata">

### Author: ![Vidar](https://dietpi.com/forum/letter_avatar_proxy/v4/letter/v/e36b37/32.png) [@Vidar](https://dietpi.com/forum/u/Vidar)
#### Post date: [19 April 2025 20:35 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/2 "2025-04-19T20:35:38Z")

</div>

Hey,

This is an update to my own problem.

I was investigating it quite a lot more and although I do not know why it works but i got it working.

First thing I had to do was to add ‘camera\_auto\_detect=1’ to /boot/config.txt. That resolved the undervoltage detection on reboot/shutdown and also made available /dev/video0. I kept reading that this is on by default but it is obviously not in dietpi. It is in raspbian lite.

At this point I could add the camera to motioneye (on the new install, it did not give any visible changes on the existing install). It still says that it can not connect to the camera afterwards.

In order to get that working I had to do the following

apt-get -y install libcamera-v4l2 libcamera-tools  
sed -i ‘s//usr/local/bin/meyectl//usr/bin/libcamerify /usr/local/bin/meyectl/’ /etc/systemd/system/motioneye.service

Which I found here:

> <https://github.com/motioneye-project/motioneye/issues/2812>
>
> Hello Motioneyeteam!
> How long will it be before Motioneye also supports the new …camera drivers for RPi?
> Sonnige Grüße aus Ulm, Germany

Then I see the image. I dont know if everything works. I will have to have some days to really test it but it seems to be working so far.

Can this be implemented automatically somehow? The first thing (config.txt) should be implemented as soon as the camera is put to on in the dietpi-config. The second thing might be good to add when motioneye gets installed (unless it breaks something or is not stable, I am not a good judge in that)

---

<div class="post-metadata">

### Author: ![mkdjns](https://dietpi.com/forum/user_avatar/dietpi.com/mkdjns/32/7810_2.png) [@mkdjns](https://dietpi.com/forum/u/mkdjns)
#### Post date: [23 April 2025 18:52 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/3 "2025-04-23T18:52:42Z")

</div>

I had this issue where a previously working camera on Dietpi 9.10.0 stopped working after updating to Dietpi 9.12.1. Restoring a backup to 9.10.0 got the camera working again.

---

<div class="post-metadata">

### Author: ![Joulinar](https://dietpi.com/forum/user_avatar/dietpi.com/joulinar/32/57_2.png) [@Joulinar](https://dietpi.com/forum/u/Joulinar)
#### Post date: [23 April 2025 19:27 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/4 "2025-04-23T19:27:08Z")

</div>

Did you tried running `apt update && apt upgrade`? This should update all Debian packages but keep current DietPi version. Would be interesting how this behaves.

---

<div class="post-metadata">

### Author: ![Vidar](https://dietpi.com/forum/letter_avatar_proxy/v4/letter/v/e36b37/32.png) [@Vidar](https://dietpi.com/forum/u/Vidar)
#### Post date: [23 April 2025 19:39 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/5 "2025-04-23T19:39:36Z")

</div>

I did. It was fully up to date both times (after the initial upgrade and on the fresh install).

---

<div class="post-metadata">

### Author: ![Joulinar](https://dietpi.com/forum/user_avatar/dietpi.com/joulinar/32/57_2.png) [@Joulinar](https://dietpi.com/forum/u/Joulinar)
#### Post date: [23 April 2025 20:41 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/6 "2025-04-23T20:41:07Z")

</div>

Maybe @MichaIng has an idea

---

<div class="post-metadata">

### Author: ![MichaIng](https://dietpi.com/forum/user_avatar/dietpi.com/michaing/32/7_2.png) [@MichaIng](https://dietpi.com/forum/u/MichaIng)
#### Post date: [27 April 2025 17:15 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/7 "2025-04-27T17:15:23Z")

</div>

@Vidar with “after upgrade” you mean after migrating to the new RPi firmware stack, right? Yeah that removed the MMAL library … ah actually AFAIK it was removed on latest legacy kernel as well.

If `camera_auto_detect=1` works, KMS/DRM seems to be enabled, which implicitly disables the legacy camera API. If it works at all, one must disable KMS/DRM and enable legacy camera support e.g. via `dietpi-config` or:

```sh
/boot/dietpi/func/dietpi-set_hardware rpi-opengl disable
/boot/dietpi/func/dietpi-set_hardware rpi-camera enable

```

However, camera module v3 does not support the legacy API and AFAIK all recent RPi kernel builds do not ship the MMAL library anymore.

To enable the modern camera API:

```sh
/boot/dietpi/func/dietpi-set_hardware rpi-camera disable
/boot/dietpi/func/dietpi-set_hardware rpi-opengl vc4-kms-v3d
G_CONFIG_INJECT 'camera_auto_detect=' 'camera_auto_detect=1' /boot/config.txt

```

This creates `/dev/video0` as well, but along with a lot of other `/dev/video*` devices which do not work on their own like with the old API or genetic V4L2 cameras, but via libcamera API, which `motion` (the backend utility used by motionEye) does not support. `libcamerify` is the shim to provide the legacy API on top of the new API.

We do really need to add native support for this to `dietpi-config`, I agree, even more importantly as/if the legacy camera driver/API does not work anymore at all, at least not on Bookworm systems even with legacy kernel: [DietPi-Config | RPi: Add modern RPi camera module support · Issue #5127 · MichaIng/DietPi · GitHub](https://github.com/MichaIng/DietPi/issues/5127)

---

<div class="post-metadata">

### Author: ![mkdjns](https://dietpi.com/forum/user_avatar/dietpi.com/mkdjns/32/7810_2.png) [@mkdjns](https://dietpi.com/forum/u/mkdjns)
#### Post date: [16 May 2025 00:47 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/8 "2025-05-16T00:47:32Z")

</div>

Updating my experience- Today I re-updated to dietpi 9.12.1, and the camera is working as expected.

---

<div class="post-metadata">

### Author: ![system](https://dietpi.com/forum/uploads/default/original/1X/7e1021de2213860bce185915ce2c1786e56490ec.png) [@system](https://dietpi.com/forum/u/system)
#### Post date: [10 November 2025 12:47 UTC](https://dietpi.com/forum/t/raspberry-pi-3-b-camera-issues-after-upgrade/23280/9 "2025-11-10T12:47:46Z")

</div>

This topic was automatically closed 178 days after the last reply. New replies are no longer allowed.
