Questions tagged [devices]

devices refers to questions about the Unix/Linux device special files, normally these are under /dev. Do not use this tag for physical devices (for that use e.g. usb or pci).

Filter by
Sorted by
Tagged with
5
votes
2answers
18k views

ttyUSB0 permission changes after restart

I'm trying to install a device. I plug in the device which creates a ttyUSB0 file. When I open it in the program I need it for, it says the permission is denied. I type in terminal sudo chmod 666 /...
15
votes
4answers
34k views

How can I tell whether a network interface is physical (device) or virtual (alias)?

I have a small home router running OpenWrt (Kind of embedded Linux for routers). It has five Ethernet ports, one labeled WAN and four labeld LAN 1 to 4. It has the following Network Interfaces defined ...
0
votes
1answer
730 views

Slackware64 14.2 - GRUB2 - How set default <UUID> instead <DEVICE>?

i am trying the grub configuration file "/boot/grub/grub.cfg" in the kernel line, set "root=UUID=" instead "root=/dev/" for example when i ran : grub-mkconfig -o /boot/grub/grub.cfg the file /boot/...
2
votes
0answers
414 views

Accessing I2C slave devices that are specified in Device Tree

I'm trying to communicate with a device over I2C from my BeagleBone Black, and I'm a bit curious as to the device tree's interpretation of I2C. I see that there are a couple of device nodes within ...
16
votes
3answers
29k views

How to grant non-root user access to device files

I have device file that appears in /dev when a specific board is plugged in. The read and write operations to it work just fine, but in order to open the device file the program needs to be executed ...
8
votes
2answers
23k views

Allow non-root user to read/write /dev files

In my /dev folder, I would like the following files to be user readable and writable: /dev/ttyUSB0 /dev/gpib0 How do I do this without using chgrp? I can edit /etc/udev/rules.d but I do not know the ...
11
votes
3answers
33k views

How do I find out which process is using my V4L2 webcam?

I tried to run the following: $ vlc -I dummy v4l2:///dev/video0 --video-filter scene --no-audio --scene-path webcam.png --scene-prefix image_prefix --scene-format png vlc://quit --run-time=1 ...
1
vote
0answers
938 views

USB touch screen not working with debian 3.8.13 (BeagleBone Black)

I have a waveshare 7" HDMI touch screen display rev 2.1(touch over USB port and HDMI display) (link for the product) and I want to interface it with BeagleBone Black. The manufacturer says the 7" ...
0
votes
1answer
568 views

PCI Device Missing After Reboot

I have a DVBSky T9580 PCI tuner card. My problem is that after rebooting,, the device dissapears, lspci does not list it any more. I tried rebooting with reboot command as well as shutdown -r 0. ...
0
votes
1answer
87 views

Use /dev/ramX as their corresponding special devices?

With ls -l, I found a series of devices like ram0, ram1 etc. I looked at the output closely and (for example) brw------- 1 root root 1, 3 Jan 6 11:34 /dev/ram3 crw-rw-rw- 1 root root 1, 3 Jul 15 ...
0
votes
1answer
278 views

Identify devices like virtio2 and virtio3 in QEmu

I'm running a virtual machine in QEmu. The following command in the guest VM cat /proc/interrupts | egrep 'virtio.*(input|output)' gives me the following output: 26: 0 3376 0 ...
3
votes
1answer
2k views

Is it possible to simulate/force/fake an USB device unplug and replug on Linux?

So I've got a strange problem that I've been running onto. I've got a bitcoin usb miner, Bitfury, and I'm using CGMiner to mine. When I start the application, as root, the USB device is not detected ...
0
votes
1answer
174 views

Linux: How to create and attach a RamDisk without mounting it?

On Linux, how can a RAM disk be created and attached without being mounted? Moreover, how can the device name like /dev/sdb assigned to the RAM disk be found? Finally, how can the RAM disk (which is ...
2
votes
1answer
806 views

How to write to a character special device?

Due to a broken udev setup on a machine from which I'm trying to rescue data (see this post of mine) I'm trying to write to a "character special" device corresponding to a USB flash drive, but am ...
1
vote
1answer
1k views

Where to get information on failed disk?

I have a disk inside my server which has failed and I'm trying to figure out which one it is. I did not make a list of all serial numbers as I should have. I plan on doing this but in the meantime, ...
0
votes
2answers
87 views

OpenSuse USB HDD gets device node name “/dev/sdb” of internal HDD

OS: OpenSuse Leap 42.2, Kernel 4.4.76-1-default I have the following problem: When I attach my USB Storage Device during runtime it gets the device node name /dev/sdk assigned which is fine. If I ...
3
votes
2answers
6k views

How to create device files manually use mknod?

Linux 2.6.26.5 embedded. I need manually mount the root file system from busybox shell (initramfs). Because this Linux kernel not use devtmpfs, I have to create the basic device nodes manually, use ...
2
votes
2answers
95 views

How does 'eject' get processes to close file handles?

On my Mac, when I 'eject' a network-mounted share, my Mac presents me with the following message, and attempts to get processes to close open file handles and cleanly dismount the share. My question ...
1
vote
0answers
1k views

How to get the specific serial port on usb-serial hub in Linux

I have a Linux machine with a connected USB hub (5 ports), and I also have a serial hub (8 serial ports) connected to this USB hub. It looks as follows: Linux -> usb hub -> usb-serial hub -> serial ...
1
vote
2answers
296 views

Why does Fedora have two `ptmx` files?

I know that the file /dev/ptmx is used to generate a master file for a pseudo-terminal. But I have found out that Fedora has another ptmx file (/dev/pts/ptmx): What is the purpose of this second file?...
1
vote
2answers
150 views

Disconnected block device remains in /dev/, sync commands unkillable

I'm running Linux Mint 18/2 with 4.10.0-38-lowlatency kernel and KDE5 desktop. I'm testing lots of USB flash memory with a custom bash script and f3 and I had a strange situation today. One drive ...
3
votes
0answers
354 views

Loading a kernel module at run time using “compatible” property of device node in device-tree

If I know the "compatible" property string of a device(from the device tree), can I use it at runtime to load the corresponding kernel driver module? I do not have access to the driver source. I am ...
2
votes
0answers
624 views

/dev/random entropy on readonly file system

My hostapd works very well on my raspberry Pi3. But if I put root filesystem in readonly, it does not work. I have put some folders like /var/run and /tmp in a ramdisk filesystem. I have seen ...
0
votes
1answer
705 views

How to interpret SCSI device (sd) timeout logs

In /var/log/messages, I find the following log: Oct 23 21:48:53 localhost kernel: sd 3:0:0:0: timing out command, waited 180s Please explain the values that are separated by colons. Also where ...
0
votes
1answer
32 views

How can I setup a read/write device that spawns a program?

I don't know if this is possible but I had no idea how to research this concept. Is it possible and if how do I... create a device file (i.e. /dev/remoteclip) that will, when written to or read from, ...
20
votes
2answers
10k views

Manipulating /dev/video

I'd like to take the video stream from /dev/video0, apply some effects or changes and make the result available on /dev/video1. /dev/video0 ---> Apply Effects ---> /dev/video1 For example, mplayer ...
1
vote
0answers
137 views

Identify device by its handler

I'm looking for a robust method for identifying a device's type (mouse, keyboard, joystick) by its input event handler. There are parameters which cannot be trusted, such as device name/vendor-id etc....
5
votes
1answer
21k views

Kali Linux and RTL8812AU

Currently I am running into an issue where I can't seem to find a way to identify which WiFi adapter I want to use as my primary in Kali (v 2017.1) My laptop has a normal PCI WiFi card inside however ...
2
votes
1answer
566 views

Device Node not created

I am trying to connect a new device (Keysight U2722A) and it does not appear in /dev. I have tried this in Ubuntu, Fedora, and openSuse, all with the same results. Currently working in Fedora. When ...
1
vote
0answers
332 views

Remove extra non-working scanners

I tried to add a USB scanner to my system without any luck and now when I start XSane or Image Scan! for Linux I get a list of non-working scanners. How these can be removed? I've tried: # pacman -...
3
votes
1answer
2k views

How do you determine the capabilities of a WebCam?

I have a collection of WebCam's lying around. Some of them are new, some go back a decade -- have to love not having to "upgrade" devices in Linux! Somehow I've developed the impression that ...
4
votes
2answers
2k views

Debian USB automount

Got my USB flash automount broken after reboot. Using Debian 6, GNOME 2 My NTFS hard disk is still mounting correctly. When i connect my Android smartphone (with SD and local drive) my messages log ...
0
votes
1answer
147 views

fdisk with option '-l' - how does it get info about device?

I'm experimenting with a software defined device, trying to force it to work with block size = 512 bytes, but it looks like the Linux doesn't want that. I've forced the device to report minimal ...
8
votes
1answer
3k views

How to debug a driver failing to bind to a device on Linux?

I am trying to figure out why the following device is not setup to its driver on my Creator CI20. For reference I am using a Linux kernel v4.13.0 and doing the compilation locally: make ARCH=mips ...
2
votes
0answers
545 views

Why does md5sum give inconsistent results on device files?

Backing up some USB flash-drives on Lubuntu 16.04.3 LTS. Plug USB drive into laptop. Automounter does its stuff. I remount all partitions as read-only sudo mount -o remount,ro /dev/sdxn Copy USB ...
32
votes
1answer
105k views

How to find which serial port is in use?

The Question: I plugged in a device (i.e. GSM modem) through a serial port (a.k.a. RS-232), and I need to see with which file in /dev/ filesystem this device was tied up, to be able to communicate ...
3
votes
1answer
2k views

Editing a device tree to disable driver loading

Below is a section of device tree. ps7_ethernet_0: ps7-ethernet@e000b000 { #address-cells = <1>; #size-cells = <0>; clock-names = "ref_clk", "aper_clk"; clocks = <&...
1
vote
0answers
55 views

How to mount a drive to a location that does not exist?

When I insert a drive, it automatically mounts to /media/homeuser/drivename. If I unmount it, I can always remount it by clicking the device again, and it remounts to the exact same spot. However, ...
0
votes
1answer
153 views

umount -l: Kernel is referring to removed, non-existent device

I am getting messages such as: kernel: Buffer I/O error on dev sdb1, logical block 107390598, async page read In actuality, the USB HDD sdb has been removed: lsblk also shows no mention of sdb. I ...
1
vote
2answers
351 views

List processes accessing device after `umount --lazy`

I want to remove my external HDD as safely as possible. I want to use umount --lazy: Lazy unmount. Detach the filesystem from the file hierarchy now, and clean up all references to this ...
3
votes
1answer
573 views

What are the implications of setting the baud rate of a terminal from userspace?

Sometimes I just need to read from a serial device, so I skip the complexities of minicom or screen and just cat. However, this only works if I first set the baud rate of the terminal using stty <...
1
vote
0answers
629 views

Accessing a serial device from LXC guest

I have a Fedora 26 host running a privileged Ubuntu 16.04 guest in an LXC container. My goal is to connect to a serial device (/dev/ttyACM0) from the LXC guest. I created the guest OS with the ...
24
votes
2answers
14k views

What’s the difference between a “raw” and a “cooked” device driver?

Does this concept only apply to terminal drivers (which is what most sites cover) or to any driver in general?
1
vote
0answers
923 views

How can I set device rw permissions permanently on ubuntu 16.04?

I am using an embedded device that is running ubuntu. Normally only root has read and write permissions for i2c devices. I'm using this command to add i2c r/w permissions for normal user (me): sudo ...
1
vote
3answers
2k views

IO utilization for /dev/null redirection?

I always use nohup to start my system. However, the output to nohup is so big that I'm thinking to redirect it to /dev/null. My concern is, will redirecting to /dev/null also incur some I/O operations ...
11
votes
4answers
2k views

Why do special device files have inodes?

Device files are not files per se. They're an I/O interface to use the devices in Unix-like operating systems. They use no space on disk, however, they still use an inode as reported by the stat ...
111
votes
7answers
37k views

How are “/dev” Linux files created?

There are special files in Linux that are not really files. The most notable and clear examples of these are in the dev folder, "files" like: /dev/null - Ignores anything you write to the file /dev/...
1
vote
1answer
1k views

No such device or address

What does it mean if I get this message during scp ? scp: /dev/fd/3/fd/3/fd/3/fd/3/fd/3/fd/3/fd/3/fd/3/fd/3/fd/3/fd/3/fd/3/fd/5/31/rd/c6d16: No such device or address What I'm doing is scp -r root@...
5
votes
2answers
668 views

what are /dev/sdxx nodes?

This image from TLDP is pretty awesome. It shows that before giving user space actual read, write, open access to the filesystem the blocks get mapped onto the virtual filesystem. and Wikipedia says ...
7
votes
1answer
861 views

How to rename devices for graphical output such as VGA0

On my Laptop the names of my graphical outputs change depending on what chip is activated in the BIOS. This leads to problems in some scripts where outputs such as VGA-0 or LVDS-0 are specified. So I ...