I have suns machine that holds two hard drives. I only used one. I tryed to make a lan network with my windows xp. When I tryed to restart the machine it wanted to a password. when before I just typed root to log in. So i edited the etc dir. big mistake. So now the machine will not read the hard... (2 Replies)
:confused: ........I have a new hard drive and I need to copy ALL info from the old to the new. I would like to use the dd command. I know the command is as follows......
dd if=/dev/rdsk/c1t1d0s0 of=/dev/rdsk/????????
Where I have the question marks is the problem.
How do I find out what the... (4 Replies)
Hi
I have 2 75GB SCSI hard drives and 2 250GB SATA hard drives which are using RAID Level 1 respectively. I wana have both FTP and Apache installed on them as services. I'm wondering what's the best partitioning schem? I wana use FC3 as my OS, so, I thought I can use the 75GB hard drive as the /... (0 Replies)
Hi
When I installed opensolaris, I installed it on a 20GB partition. How do I make use of the other 300GB I have spare?
format shows:-
-bash-3.2# format
Searching for disks...done
AVAILABLE DISK SELECTIONS:
0. c3d0 <DEFAULT cyl 2607 alt 2 hd 255 sec 63>
... (12 Replies)
Hi, I just downloaded and installed Ubuntu yesterday. It's the first time I have used it, so bear with me. I think I figured out how to get my sound drivers to work (X-Fi)... I had downloaded some OSS drivers, bout to go test them.
But what I really want to know is... I have 2 hard drive,... (2 Replies)
I am working on an Ubuntu Linux 8.10 system that I do not want to reboot. For some reason, USB flash drives (mass storage devices) now no longer automount. I want to restore that functionality without rebooting. I can manually mount and unmount these things by doing:
cd /media
sudo mkdir thing... (4 Replies)
Hi
I am using SUSE 11 linux
I have couple of "nfs" entries in /etc/fstab which are automatically loaded after system restart.
One of the entry is windows drive mounted using cifs as shown below
//IP-Address/Partition /mnt/x cifs credentials=/creds/.creds,rw,uid=<name> 0 0
I want to... (1 Reply)
Im trying to install a fresh version of Fedora 17. I keep getting formating errors when trying to reformat the hard drive. I recieve errors as well I I try to use the entire disk for the install instead of creat new partitions from scratch. I even tried fromatting the disk using PartedMagic and... (7 Replies)
Discussion started by: Fingerz
7 Replies
LEARN ABOUT DEBIAN
setfsent
GETFSENT(3) Linux Programmer's Manual GETFSENT(3)NAME
getfsent, getfsspec, getfsfile, setfsent, endfsent - handle fstab entries
SYNOPSIS
#include <fstab.h>
void endfsent(void);
struct fstab *getfsent(void);
struct fstab *getfsfile(const char *mount_point);
struct fstab *getfsspec(const char *special_file);
int setfsent(void);
DESCRIPTION
These functions read from the file /etc/fstab. The struct fstab is defined by:
struct fstab {
char *fs_spec; /* block device name */
char *fs_file; /* mount point */
char *fs_vfstype; /* file-sysem type */
char *fs_mntops; /* mount options */
const char *fs_type; /* rw/rq/ro/sw/xx option */
int fs_freq; /* dump frequency, in days */
int fs_passno; /* pass number on parallel dump */
};
Here the field fs_type contains (on a *BSD system) one of the five strings "rw", "rq", "ro", "sw", "xx" (read-write, read-write with quota,
read-only, swap, ignore).
The function setfsent() opens the file when required and positions it at the first line.
The function getfsent() parses the next line from the file. (After opening it when required.)
The function endfsent() closes the file when required.
The function getfsspec() searches the file from the start and returns the first entry found for which the fs_spec field matches the spe-
cial_file argument.
The function getfsfile() searches the file from the start and returns the first entry found for which the fs_file field matches the
mount_point argument.
RETURN VALUE
Upon success, the functions getfsent(), getfsfile(), and getfsspec() return a pointer to a struct fstab, while setfsent() returns 1. Upon
failure or end-of-file, these functions return NULL and 0, respectively.
CONFORMING TO
These functions are not in POSIX.1-2001. Several operating systems have them, e.g., *BSD, SunOS, Digital UNIX, AIX (which also has a getf-
stype()). HP-UX has functions of the same names, that however use a struct checklist instead of a struct fstab, and calls these functions
obsolete, superseded by getmntent(3).
NOTES
These functions are not thread-safe.
Since Linux allows mounting a block special device in several places, and since several devices can have the same mount point, where the
last device with a given mount point is the interesting one, while getfsfile() and getfsspec() only return the first occurrence, these two
functions are not suitable for use under Linux.
SEE ALSO getmntent(3), fstab(5)COLOPHON
This page is part of release 3.44 of the Linux man-pages project. A description of the project, and information about reporting bugs, can
be found at http://www.kernel.org/doc/man-pages/.
GNU 2002-02-28 GETFSENT(3)