LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-29-2016, 06:47 PM   #1
iFunction
Member
 
Registered: Nov 2015
Posts: 248

Rep: Reputation: Disabled
Second hard drive permissions revert to root on boot up


Hi there,

I have an Ubuntu system here, with an SSD and a second HDD for storage. I have managed to get the HDD to mount on boot up, however, the permissions are always set to root.

The file system is ext4 and I have tried:
Code:
sudo chown user:user /dev/sdb1
but it still keeps going back to root when I reboot. How can I change this, as I am planning on trying to use that drive as my home folder.

Kind regards
iFunc
 
Old 06-29-2016, 07:34 PM   #2
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,779

Rep: Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212
The permissions on the device inode have nothing to do with the permissions on the filesystem. While the filesystem is mounted, do the chown on the mount point directory.
 
1 members found this post helpful.
Old 06-29-2016, 09:23 PM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
And once you mount at /home, everything should be "correct" (after you copy everything over).
 
1 members found this post helpful.
Old 06-30-2016, 09:29 AM   #4
iFunction
Member
 
Registered: Nov 2015
Posts: 248

Original Poster
Rep: Reputation: Disabled
@rknichols - ah, yes, of course, it mounts on /mnt/blahblahblah, I need to change ownership there then, thank you.
 
Old 07-02-2016, 07:55 AM   #5
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,912

Rep: Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513
BTW, the reason the ownership changed back to root is that /dev is not a permanent filesystem. It is a virtual filesystem (devtmpfs) that shows kernel data structures for the devices. Since the kernel rescans the controllers, the contents of the /dev filesystem get recreated on each boot.

Last edited by jpollard; 07-02-2016 at 07:56 AM.
 
1 members found this post helpful.
  


Reply

Tags
permissions



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
I want to copy my hard drive to a larger hard drive and boot from the new drive. lpmorgan1 Ubuntu 8 09-07-2009 11:26 PM
How to revert the permissions set on chmod as a root user prashsharma Linux - Security 2 01-05-2009 10:29 PM
New root hard drive hangs on boot GTBlackwell Linux - Software 4 11-16-2008 09:04 AM
New root hard drive in Hardy = boot trouble GTBlackwell Linux - Hardware 4 11-15-2008 03:50 PM
Ubuntu: Installed to external hard drive; boot to primary hard drive gives error 22 dcorb62 Linux - General 7 09-04-2007 11:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:19 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration