Score:1

Webcam not working - works on Windows

ge flag

My webcam is not working. On Windows 10 it works fine, no problems. lsusb shows no webcam. Cheese says there is an error.

I am running Ubuntu 20.04 LTS. I am new to Ubuntu so my webcam has never worked, as far as I know.

EDIT: This is a laptop, model ThinkPad X1 Tablet G2. It is an integrated webcam.

Output of ls -lah /dev/video*:

crw-rw----+ 1 root video 81,  0 nov.   1 21:00 /dev/video0
crw-rw----+ 1 root video 81,  1 nov.   1 21:00 /dev/video1
crw-rw----+ 1 root video 81, 14 nov.   1 21:00 /dev/video10
crw-rw----+ 1 root video 81, 15 nov.   1 21:00 /dev/video11
crw-rw----+ 1 root video 81, 16 nov.   1 21:00 /dev/video12
crw-rw----+ 1 root video 81, 17 nov.   1 21:00 /dev/video13
crw-rw----+ 1 root video 81,  2 nov.   1 21:00 /dev/video2
crw-rw----+ 1 root video 81,  3 nov.   1 21:00 /dev/video3
crw-rw----+ 1 root video 81,  8 nov.   1 21:00 /dev/video4
crw-rw----+ 1 root video 81,  9 nov.   1 21:00 /dev/video5
crw-rw----+ 1 root video 81, 10 nov.   1 21:00 /dev/video6
crw-rw----+ 1 root video 81, 11 nov.   1 21:00 /dev/video7
crw-rw----+ 1 root video 81, 12 nov.   1 21:00 /dev/video8
crw-rw----+ 1 root video 81, 13 nov.   1 21:00 /dev/video9

Output of lsusb:

Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 005: ID 8087:0a2b Intel Corp. 
Bus 001 Device 004: ID 17ef:60a3 Lenovo ThinkPad X1 Tablet Thin Keyboard Gen 2
Bus 001 Device 003: ID 046d:c52f Logitech, Inc. Unifying Receiver
Bus 001 Device 002: ID 1199:9079 Sierra Wireless, Inc. Sierra Wireless EM7455 Qualcomm Snapdragon X7 LTE-A
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Thanks a lot!

cocomac avatar
cn flag
Please [edit] your question to include the model of the webcam. Also, and I realize this may seem silly... is the webcam plugged in all the way? Also, [edit] your question to include the output of `ls -lah /dev/video*`
cocomac avatar
cn flag
Thanks for including the webcam model! Can you also include the output of typing `ls -lah /dev/video*` into a terminal and pressing enter? Thanks! This will make it easier for us to solve your issue
Knut avatar
ge flag
@cocomac done! Sorry for the lack of information!
mchid avatar
bo flag
What error does cheese show? Also, have you tried guvcview?
Knut avatar
ge flag
@mchid guvcview says "no video device found" - but says I have video drivers installed... but none of the ones seem to work. https://imgur.com/a/ycgdmFq
Score:1
it flag

Many device access problems can be resolved through group membership changes.

Specifically, since ls -l shows that the group permissions (the second "rwx" triplet) is "rw" (e.g."-rw-rw----"), then, adding oneself to the group that owns the device will grant rw access.

Here's how:

device="/dev/video0"
sudo adduser $USER $(stat -c "%G" $device)

This allows you membership in the group that can rw the device, but there is one more step.

To make all your processes members of the new group, logout and login. Group memberships are set up at login time.

To create a single process in the new group (for testing, prior to logout/login):

newgrp $(stat -c "%G" $device)  

or, just type the group name. See man newgrp.

Knut avatar
ge flag
`device="/dev/video" sudo adduser $USER $(stat -c "%G" $device)` what do you mean with this? I write it in the terminal and I get that `stat: cannot stat '/dev/video': No such file or directory`. This is probably just a beginner error, got no idea what that means.
waltinator avatar
it flag
Sorry, typo, fixed Use `device="/dev/video0"`. Read `man adduser stat sudo bash`.
waltinator avatar
it flag
Please click the checkmark to "accept" my answer, if it solved your problem, and might help others.
Knut avatar
ge flag
Sadly it didn't work. I added myself to the group "video" like you said... but camera still doesn't work. Even after a restart.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.