Operating System - HP-UX
1830220 Members
2280 Online
109999 Solutions
New Discussion

unable to create or touch file

 
ramesh_35
Occasional Contributor

unable to create or touch file


1) i have 2 servers A & B
2) A-Server, B-Client
3) i have exported the needed filesystem
through nfs (i.e /backup) and mounted
on /backup on client server (i.e server-B)
4) Problem i am unable to create or touch file
on Server-B

can any one tell me is there any issuse with
/backup filesystem permission or something else

permission
server-A /backup drwxr-xr-x
server-B /backup drwxr-xr-x


waiting for valuable reply

thanks
Regard
Ramash
8 REPLIES 8
Pupil_1
Trusted Contributor

Re: unable to create or touch file

showmount -e . to check the permission of the share.

If you have not specified the options when sharing, then the default 'read-only' is used and hence the error.
There is always something new to learn everyday !!
ramesh_35
Occasional Contributor

Re: unable to create or touch file

dhanish thanks for reply

but in /etc/exports file i have mentioned
as follow

/backup -rw=ram1

is something wrong with the above statement


regards
Ramesh
Jonathan Fife
Honored Contributor

Re: unable to create or touch file

If you do an 'id', is your uid the same as the one that owns the directory?
Decay is inherent in all compounded things. Strive on with diligence
A. Clay Stephenson
Acclaimed Contributor

Re: unable to create or touch file

Note that the permissions on the directory are 755 this means that only the owner of the directory will be able to create files in that directory. Secondly, you have said nothing about which the UID's and GID's on the two machines are the same. User "mickey" might have UID 105 on "A" and 234 on "B". Permissions are tied to UID's and GID's rather than the corresponding name for them.

If it ain't broke, I can fix that.
Dave Olker
Neighborhood Moderator

Re: unable to create or touch file

Hi Ramesh,

There are many reasons why you might get a permission denied error. The two most common reasons are:

1) You're logged in as the root user on the NFS client and trying to create a file in a filesystem that has not been exported to allow root users to create files (i.e. your exporting with -rw=ram1 but you have not specifically allowed root users on ram1 to create files). This will cause the create request to go over-the-wire with the permissions of UID=-2, GID=-2. Unless your directory permissions on the server are wide open and allow *everyone* to create files, this user won't be allowed to create files with these re-mapped uid/gid numbers.

2) Your NFS client has multiple IP interfaces and is sending the NFS request to the server using an interface that does not map to the name "ram1". This is typical in environments with multiple NIC cards in each system, where the system might be called "ram1" but the interface might resolve to a name "ram1-eth1" or "ram1-gige", etc. You have to export the filesystem using the hostname or IP address that matches the hostname/IP that the request came from or the request will fail.

If you check both of these and they turn out to not be the problem let us know and we'll offer more places to look.

Regards,

Dave


I work at HPE
HPE Support Center offers support for your HPE services and products when and how you need it. Get started with HPE Support Center today.
[Any personal opinions expressed are mine, and not official statements on behalf of Hewlett Packard Enterprise]
Accept or Kudo
ramesh_35
Occasional Contributor

Re: unable to create or touch file


thanks friends for giving your valuable time for solving my problem

coming to the point


as you had said 'uid' and 'gid' are same i.e i am using ' root' user on both server


Ramesh
A. Clay Stephenson
Acclaimed Contributor

Re: unable to create or touch file

It really helps when you (finally) provide enough data. You need a root=Bhostname exports entry.

Do a man exportfs and look under the "root=hostname" section. It will explain exactly your problem.
If it ain't broke, I can fix that.
Dave Olker
Neighborhood Moderator

Re: unable to create or touch file

Or you could just refer to item #1 of my previous post. :)

Dave


I work at HPE
HPE Support Center offers support for your HPE services and products when and how you need it. Get started with HPE Support Center today.
[Any personal opinions expressed are mine, and not official statements on behalf of Hewlett Packard Enterprise]
Accept or Kudo