Two home folders and permissions

All Gurus once were Newbies
Forum rules

Two home folders and permissions

Postby idc on Tue Jan 01, 2013 8:03 am

Hi,
I have managed to end up with two home folders (because I mucked up the first when I restored all my files from my previous Mint 11 system and included backed up config files). Creating a new user solved that one, but now thanks to Unix permissions I find I cannot gain access to my files in the old home/Documents folder from the new user. I would like to simply copy across all the files from /home/old_user/ to /home/new_user and change their permissions from 'old_user' to 'new_user' so that I can access them. (After which I can delete the old_user account altogether.) Is there a straightforward way to do this? I thought I'd be able to nail it by copying across as root and then changing permissions, but doing that with a GUI was a. long-winded (the changing permissions only seemed to work for the folder and the next level down in the hierarchy) and b. doesn't seem to work for all files. (In particular I use a program called scrivener which appears to store all the files for a project in a folder called 'whatever.scriv'--I don't seem to be able to change any of the permissions in the crucial folders within this folder.)

I could simply restore again from the BackinTime backup to the new home folder. However the new_user has a different name to the old_user, so I am not sure that that would work. (Experimenting just now appeared to show that it does not, with the restored files having 'root' as the user.) Basically, there is, I hope, some set of commands that will allow me to access my work from the new, working new_user account. Any advice gratefully received.

Ian

UPDATE: I managed now to restore the key scrivener file I wanted to work on from BackinTime. Turned out the problem was I copied back into a filemanager window with superuser permissions (open because I'd been trying to copy across from the other home folder) instead of a regular filemanager window--hence the incorrect permissions issue. I would still be interested to know whether there is a straightforward way to copy all the files over from the other home folder whilst changing the permissions to work with the new user? Thanks. Ian
idc
Level 1
Level 1
 
Posts: 18
Joined: Sat Dec 10, 2011 11:11 am

Linux Mint is funded by ads and donations.
 

Re: Two home folders and permissions

Postby viking777 on Tue Jan 01, 2013 10:35 am

Code: Select all
sudo chown -R ian: /home/old_user


Is what I would try. (though you would have to substitute the correct username and folder address of course).
Fujitsu Lifebook AH532. Intel i5 processor, 6Gb ram, Intel HD3000 graphics, Intel Audio/wifi. Realtek RTL8111/8168B Ethernet.Lubuntu 13.10,Ubuntu12.10 (Unity), Mint16 (Cinnamon), Manjaro (Xfce).
User avatar
viking777
Level 14
Level 14
 
Posts: 5152
Joined: Mon Dec 01, 2008 11:21 am

Re: Two home folders and permissions

Postby idc on Tue Jan 01, 2013 10:52 am

Thank you. I'll (cautiously) try that out.
Much obliged for your response.
Ian
idc
Level 1
Level 1
 
Posts: 18
Joined: Sat Dec 10, 2011 11:11 am


Return to Newbie Questions

Who is online

Users browsing this forum: No registered users and 3 guests