February 7, 201313 yr When sshing into unraid what is the best way for me to persist my home folder on reboots? Can I move the home folder for root to my cache drive? Should I be logging in as an alternate user instead of root and then I create his home folder on a separate drive? Should I somehow cp the data away from the home folder and then back in my go script? I ssh into the box a lot and would like to run some command line stuff. I'm assuming someone else around here has been in the same boat at some point.
February 7, 201313 yr I cp stuff into the home directory from the flash using the go file. To copy stuff back you'll have to modify one of the shutdown scripts.
February 8, 201313 yr Author Cool thanks. Can you elaborate as to which script I should add the cp commands to when I'm shutting down (assuming it happens cleanly). I guess I could always add it to the cache drive script that gets ran every night right?
February 8, 201313 yr Hi My solution to this problem was as follows Create a folder on the cache drive called 'home', so /mnt/cache/home - make it a cache only share, no need to share it (well I didn't want to) add the following to your 'go' script # Copy and Create user home directories home='/mnt/cache/home/' for u in $(cat /etc/passwd | grep /home | cut -d: -f1) do if [ ! -d "$home$u" ]; then echo Directory $home$u does not exist - creating mkdir $home$u chown $u:users $home$u chmod 700 $home$u fi usermod -d $home$u $u done Then any user in the passwd file that has a home directory defined (which would normally be /home/???) will have it moved to the /mnt/cache/home version (creating it if necessary). Obviously you can change the variable definition in the script above to point to wherever you create your 'home' folders! May not be the most elegant manner of doing this - but it works perfectly for me and allows me to have the .ssh folder in the appropriate places for access You can't move root in this manner but then it encourages me to prevent root from logging in full stop:)
February 8, 201313 yr unRAID is not designed as a user login system. The Linux permissions required for SMB, AFP, and NFS integration mean that there is no internal user-to-user security. Every account will have access to most of the share files and there is no way to fix this without breaking the share system.
February 8, 201313 yr True and I'm not trying to resolve that. I just wanted to have my ssh key maintained across boots for the ssh user and having a generic solution was just as easy as a bespoke file copy
February 9, 201313 yr Author Thanks for that stourwalk. I'll check that out. I know unraid wasn't designed to be a user login system but I like to access it via the shell and do different things. Currently I'm running a direct connect client (microdc2) and also a cli twitter client (ttytter). Perhaps I just need to figure out how to install a full distro and then run unraid on top of that?
February 9, 201313 yr Perhaps I just need to figure out how to install a full distro and then run unraid on top of that? There is a wiki article covering how to do that.
February 11, 201313 yr Author Yeah, I've ran across it before which is how I know it's possible. In the meantime I found an openSSH plugin that looks like it's going to do the trick: http://lime-technology.com/forum/index.php?topic=20848.0
Archived
This topic is now archived and is closed to further replies.