I have a cellphone that has internal storage that I can mount using PCManFM-Qt.
I have a few files that all begin with the name “Screenshot_”.
I want to rename them all to remove the prefix.
I tried: sudo rename 's/Screenshot_//' *
but I get a bunch of Can't rename Screenshot_20250517_083608_x.jpg 20250517_083608_x.jpg: Permission denied
I tried sudo -s and then rename 's/Screenshot_//' *
but ls: cannot open directory '.': Permission denied before the rename.
I tried find . -exec rename 's/Screenshot_//' {} \;
but I get a bunch of Can't rename ./Screenshot_20250517_083608_x.jpg ./20250517_083608_x.jpg: Input/output error
I tried sudo find . -exec rename 's/Screenshot_//' {} \;
but I get: find: ‘.’: Permission denied find: Failed to restore initial working directory: /run/user/1000/gvfs/mtp:host=SAMSUNG_SAMSUNG_Android_R5CY50MYGQP/SD card/DCIM/: Permission denied
You might be able to get something to work using jmtpfs (available in the repos, at least for 24.04) to mount the phone’s drive. I can recall successfully using it to access files on an ancient phone some years ago, but I don’t remember the details. On the other hand, it’s fairly old and may no longer work with the newer versions of Ubuntu.
Otherwise, I suspect you’d be better off asking for help on a forum related to your phone’s OS.