I have a big external USB HDD, which is device-encrypted with Veracrypt. That means when I plug it in, Ubuntu just sees an empty, unpartitioned raw device.
> lsblk -h
sdb 8:16 0 2,7T 0 disk
Question is now, how do I safely remove it from my computer? Back when it was unencrypt it, I would just eject it from nautilus and it would shutdown. Now I have to forcefully pull the plug, and the HDD screams in agony when I do.
After much googling I came across this command:
udisksctl power-off -b /dev/sdb
A bit cumbersome. But it works - sdb is powered down. For a split second. And then it is powered up immediately again...
eject
,eject /dev/sdb
.