How to write as a root to external storage

Posted on 2010-11-08
Medium Priority
Last Modified: 2012-05-10
Hello Everyone,

Let me explain my situation. I have bought WD Storage 2TB, and i created user in it to connect from another server,

I have mounted it to my server,
// /backup cifs username=xxx,password=xxxx 0 0  there is no problem..

The problem is files owner is not root, different numbers like 98 1000 or something..

How can i mount this external disk to write in it as a root. Because i need to write in it as a root.

Is there any suggestion?

Question by:ArneIT
  • 3
  • 2
LVL 10

Expert Comment

ID: 34090172
Where you have "username=xxx,password=xxxx", change that to "username=xxx,password=xxxx,uid=0,gid=0"

The problem with CIFS is that it's being logged into as a certain user (username/password), so all file/directory ownerships are actually by that username.  Adding the "uid=0,gid=0" option makes it appear as if the owner/group is root/root.

It would be much better if they had the option of using NFS, then you could have real multi-user ownership instead of the limits SMB puts on it.

Author Comment

ID: 34090813
Hi TRW-Consulting,

Thanks for your help, and yes i can do that with NFS but how?

Author Comment

ID: 34090998
I have tried to mount with NFS,         /backup                 nfs     defaults        0 0

It didnt worked out, getting this error.

mount: failed, reason given by server: Permission denied

Can you help me what should i do on WD Storage Side?

LVL 10

Accepted Solution

TRW-Consulting earned 1500 total points
ID: 34098439
Setting up NFS is a bit more complicated than SMB, and without seeing the administrative interface pages I couldn't say how your particular system does it.  But a general overview is that users/groups have to be set up, and shared locations defined as to what external sites have access to them and with what permissions.

If this is for personal use and not going to be accessed by more than 2 or 3 people/systems, I wouldn't bother with NFS and just use cifs (SMB).

Author Closing Comment

ID: 34118657

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Microsoft will be releasing the Windows 10 Creators Update in just a matter of weeks. Are you prepared? Follow these steps to ensure everything goes smoothly and you don't lose valuable data on your PC.
Microsoft Jet database engine errors can crop up out of nowhere to disrupt the working of the Exchange server. Decoding why a particular error occurs goes a long way in determining the right solution for it.
This tutorial will walk an individual through the steps necessary to enable the VMware\Hyper-V licensed feature of Backup Exec 2012. In addition, how to add a VMware server and configure a backup job. The first step is to acquire the necessary licen…
This tutorial will walk an individual through setting the global and backup job media overwrite and protection periods in Backup Exec 2012. Log onto the Backup Exec Central Administration Server. Examine the services. If all or most of them are stop…

600 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question