[Question] 3D Slicing Software Cura doesn't have permissions to save to SD card in USB adapter
I'm trying to move over to Linux for everything. As such, I'm trying to run Cura and save the sliced files to my SD card. Cura tells me I can't save to the SD card because of permissions. This was my first time mounting a USB stick, but I followed the wiki for both root access and user access. Neither worked, same issue. I tried running Cura with sudo from teeminal. I tried in Rofi. Idk. Can't figure it out.
I'm going to try saving to a local directory and mv it to the SD card, but that's a bandaid to this issue. Asking here first before /r/Cura because it could be a me and Linux issue, not a Cura issue.
Thank you.
About this post
- Posted
- Archived
- Score
- 21 · 100% up
- Kind
- Text
- ID
- cusnbf
12 comments
How did you mount the USB stick? What command did you use?
After you've mounted it, how does
ls -ld /mntlook like, where/mntis the place you've mounted the stick?Sudo mount /Dev/sdd1 /mnt/sdcard
Sudo mount -o gid=users,fmask=113,dmask=002 /dev/sdd1 /mnt/sdcard
Both allowed me to access the sdcard. Just couldn't write to it from Cura. As I said, I'm going to try to mv a file to it and see how that works.
I think you need to set mount
uidoption too. I personally use this alias:alias mountusb="sudo mount --options utf8,uid=$UID,nodev,nosuid"Then I just do
mountusb /dev/sdd1 /mntto mount something.utf8means it properly reads unicode characters,uidsets the owner of the USB stick (which would be me), andnodevwithnosuidare a security thing that prevent special block device files and SUID flags on files, basically preventing privelege escalation or other messups.Whenever I want to mount something where I can access it as my user I would use something like
udisksctl mount -b /dev/sdb1to mount it for the current user (udisksctl is provided by the packageudisks2). If the filesystem on the drive is FAT or NTFS, you should be able to not have to fiddle with file/directory permissions on the mounted drive. But if it is using ext4 or btrfs, you may have to change directory/file permissions on the mounted drive with chmod/chown.I gotcha. I did read that there were utils for it, but it doesn't seem like much to do it myself.
Also, thank you. I didn't see anything on the filesystem format before so I'll pay attention to that when I try again later.
This doesn't really solve your problem per se, but I've always saved the gcode file somewhere to my hard drive and then copied it over with a file manager. I think it's supposed to be safer in that you are more sure that some weird issue won't interrupt the thread writing the file to disk in removable media, and you'll think it is complete. Whereas a file manager will fault if it can't or doesn't copy the whole file. You should still make sure to either run "sync" or use your disto's properly remove the device to ensure the whole file gets flushed to the disk, I've had that bite me before.
Yah, it probably wouldn't be a bad idea to do that, I just thought I'd avoid having all the gcode saved on my computer. I just need to get better about making sure all the names are the same of parts and gcode so it's easy to identify.
I was going go run sync, but since it didn't write, I didn't bother. I will when I try again later. Thank you.
Is your SD card lock on?
No lock. Saw a post about that and checked. It's a microsd that came with the card. There was also still space on the card, as I moved to windows and was able to use it just fine.
I always use udisks2 (with udiskie for automounting) for removable media, then I don't need root for mounting.
Someone else has also mentioned that. I'll be sure to take a look when I sit down next. Thank you.