[SOLVED]Accessing an usb pendrive

General discussion about LÖVE, Lua, game development, puns, and unicorns.
User avatar
BrotSagtMist
Party member
Posts: 655
Joined: Fri Aug 06, 2021 10:30 pm

Re: [SOLVED]Accessing an usb pendrive

Post by BrotSagtMist »

Nothing of this tells you if its a thumbdrive or not. I already told you to read the connection type in /dev/disk/by-id.
But actually there is an even easier way, simply read "dmesg" and scan for "USB Mass Storage device detected".
obey
User avatar
pgimeno
Party member
Posts: 3637
Joined: Sun Oct 18, 2015 2:58 pm

Re: [SOLVED]Accessing an usb pendrive

Post by pgimeno »

dmesg is root-only in some systems.
https://bugs.debian.org/cgi-bin/bugrepo ... =842226#15
DjPoke
Prole
Posts: 11
Joined: Fri Apr 15, 2022 10:41 am
Location: Corsica (France)
Contact:

Re: [SOLVED]Accessing an usb pendrive

Post by DjPoke »

BrotSagtMist wrote: Sat Apr 16, 2022 9:14 pm Nothing of this tells you if its a thumbdrive or not. I already told you to read the connection type in /dev/disk/by-id.
But actually there is an even easier way, simply read "dmesg" and scan for "USB Mass Storage device detected".
I'll search about /dev/disk/by-id.
User avatar
milon
Party member
Posts: 472
Joined: Thu Jan 18, 2018 9:14 pm

Re: [SOLVED]Accessing an usb pendrive

Post by milon »

FYI, dmesg also doesn't seem to give the mountpoint or device path, so that doesn't seem like a solution either - at least for me on Linux Mint, which is based off Debian/Ubuntu.
Any code samples/ideas by me should be considered Public Domain (no attribution needed) license unless otherwise stated.
Post Reply

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 2 guests