Sponsored Content
Special Forums Hardware Filesystems, Disks and Memory Export a file system with write permissions Post 302195826 by jredx on Friday 16th of May 2008 03:09:02 AM
Old 05-16-2008
Export a file system with write permissions

Hi,

Is there a way we can export a file system with write permissions for only one user.

For eg. we have many users on the network, but only user2 should have write permissions on the exported file system and for others it should be read-only.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Write system variables into file

Hi everyone, I was told, i my job, to do a script that creates the backup of all the files that are important to us. So i created the script, put it in the crontab and it works great. Now what i want is to write to a file what directories have being copied with date and time. How can i... (3 Replies)
Discussion started by: jorge.ferreira
3 Replies

2. HP-UX

nfs export permissions

Hello, If I have an export like: /usr/temp -rw=ram:alligator means that /usr/temp has "rw" permissions to ram and alligator machines and has "ro" to everyone else? (1 Reply)
Discussion started by: psimoes79
1 Replies

3. Filesystems, Disks and Memory

Is it possible to re-export a exported NFS file system?

Hi... Is it possible to re-export a exported NFS file system? If no, Why? Let me know, if any further details are required about the question. Thanks in advance Adams:) (5 Replies)
Discussion started by: Adams Nave
5 Replies

4. AIX

How to export AIX File system NFS to Windows ?

Hello, Can someone please point to an easy document or steps how to export AIX file system /whatever to Windows O/S Basically Windows should see this filesystem / directory and should be able to write in this filesystem / directory Thanks (2 Replies)
Discussion started by: filosophizer
2 Replies

5. SCO

file system not getting mounted in read write mode after system power failure

After System power get failed File system is not getting mounted in read- write mode (1 Reply)
Discussion started by: gtkpmbpl
1 Replies

6. UNIX for Dummies Questions & Answers

Creating a File system with required permissions for all DIR's created in

Hello All, I am application admin. I need to clear all the temporary files cleared by the applications. I need help/suggestion that is there any way to create a file system such that every Dir created in by any user will have 775 permissions. So, that i can simply clear the temporary file which... (6 Replies)
Discussion started by: firestar
6 Replies

7. SCO

Read and write into file system from SCO

hi Knows someone what kind of file system uses SCO Unix 5.0.6? Which linux or unix LIVE CD can read and write into file system from SCO Unix? I've tried to boot SCO using Knoppix 6.2.1 LIVE CD, but cannot mount. # mount -t sysv /dev/sda1 /mnt mount: wrong fs type, bad option, bad superblock... (2 Replies)
Discussion started by: ccc
2 Replies

8. AIX

Write once on NFS file system

Hello Guru's We are trying to save some data for 10 -15 yrs. so we created a NFS share file system and mounted on AIX 5.3 servers, keeping in mind that we might need to replace the expired disk/bad disk every 2 yrs or 4 yrs. Now we are trying to solve. How to protect it from getting deleted... (6 Replies)
Discussion started by: Beginner123
6 Replies

9. Red Hat

List full File system permissions

I am attempting to get a baseline of deployed RHEL 6.5 servers and need to produce a full filesystem permission settings list.....but I forgot the bloody command and am racking my brain and now have a migraine. I just need a simple list starting at "/" right down the tree, listing the folder,... (3 Replies)
Discussion started by: strykergli250hp
3 Replies

10. UNIX for Beginners Questions & Answers

How to give permissions to read write but not delete the file?

i want to give users the ability to create write and read files in other user directory , but not to have option to delete the file after created ( sticky bit not going to work here ... ) for example : i have user : manager with directory repository i have user : worker1 that need to write... (4 Replies)
Discussion started by: umen
4 Replies
exportfs(2)							System Calls Manual						       exportfs(2)

NAME
exportfs - Exports an NFS file system SYNOPSIS
#include <nfs/nfs.h> exportfs(access, cookie, exdata) int access; int *cookie; struct exportfsdata *exdata; DESCRIPTION
The exportfs system call allows the specified local file system to be mounted remotely by an NFS client. This system call is usually called from mountd. The system call allows access to the kernels export database. The method of access is specified by the access flag as follows: #define EXPORTFS_CREATE 0x01 /* create a new export record */ #define EXPORTFS_REMOVE 0x02 /* remove an old export record */ #define EXPORTFS_READ 0x03 /* read an export record */ Each entry in the export database has the following structure: struct exportfsdata { dev_t e_dev; /* ID of device containing the directory */ ino_t e_ino; /* File serial number */ uint_t e_gen; /* File generation number */ char e_path[MAXPATHLEN]; /* Name of the path to export */ int e_flags; /* Export flags */ uid_t e_rootmap; /* Map root to this uid (either 0 or -2) */ uid_t e_anon; /* Map anonymous users to this uid */ struct exportfsaddrlist e_rootaddrs; /* List of hosts where root can be mapped * to uid 0 */ struct exportfsaddrlist e_writeaddrs; /* List of hosts allowed write access to * read mostly export */ int e_more; /* Used in EXPORTFS_READ */ }; struct exportfsaddrlist { unsigned naddrs; struct sockaddr addrvec[EXMAXADDRS]; }; The e_path argument is a pointer to a null-terminated string containing the path name of the file system or directory being exported. The e_dev, e_ino, and e_gen fields are inputs to the system call for creating an entry. They are returned when an entry is read. Security on the exported file systems can be improved by setting the root mapped user ID in, e_rootmap and the anonymous user id in e_anon to user id -2. Setting the rootmap field to 0 specifies that all client superusers will be mapped to 0 and thus will have the same rights as the local superuser. Anonymous remote users are those without UNIX credentials and superusers on client systems. Setting anon to a user id other than -2 will map all anonymous users to that uid. Use of the rootmap field overrides values in e_anon for client superusers. Finally, to grant superuser privileges to only a select group of clients, set rootmap to -2 and use the e_rootaddrs structure to specify the list of privileged systems. The export permissions flags are set in e_flags for the local file system path. The following flags are the only possible flags accepted by exportfs: #define M_EXRDONLY /* export read-only */ #define M_EXRDMOSTLY /* export read-write to hosts in e_writeaddrs */ #define M_EXPUBLIC /* exported for WebNFS public access */ #define M_EXPUBINDEX /* WebNFS access with index */ By default, exports are read-write. To export a filesystem or directory read-only, set the M_EXRDONLY flag. To export a filesystem or directory read-only to most clients and read-write to a select group, set the M_EXRDMOSTLY flag and include the list of clients in e_writeaddrs. To export a filesystem or directory for WebNFS public access, set the M_EXPUBLIC flag. Note that only one exported filesystem can have this flag set. By default, the filesystem is exported read-write. The M_EXPUBINDEX flag enables the WebNFS server to look for an index.html file when given a directory name. This flag is used in conjunc- tion with the M_EXPUBLIC flag. The e_more field is used in conjunction with the cookie parameter to sequentially read the kernel's export database using EXPORTFS_READ. The contents of cookie should be set to zero to read the first record. After reading the record into exdata, the system call will set e_more to a non-zero value if there are more records to read and will update the value of cookie. If there are no more records in the data- base, e_more will be zero after the system call completes. The exportfs system call returns a value of 0 upon successful completion of an operation, and -1 upon failure. ERRORS
Not superuser. Not enough memory in the system to service the request. Bad address for exdata or cookie. Access is EXPORTFS_CREATE or EXPORTFS_REMOVE and e_path does not exist, or access is EXPORTFS_REMOVE and e_path is not an exported path, or access is EXPORTFS_READ and there are no exportfsdata records to read. Access is EXPORTFS_CREATE and e_path is an NFS mounted directory. Only local directories can be exported. The exdata pointer is NULL, the cookie value is negative, or the access flag is invalid. SEE ALSO
Files: exports(4) Daemons: mountd(8) exportfs(2)
All times are GMT -4. The time now is 07:12 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy