LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   how do you edit fstab (https://www.linuxquestions.org/questions/linux-newbie-8/how-do-you-edit-fstab-666895/)

Redbug 09-01-2008 12:37 PM

how do you edit fstab
 
What steps are used to edit fstab?
su is an issue.

checkmate3001 09-01-2008 12:45 PM

Well you have to have privileges. Either become root or use sudo.
Of course then you'll likely have to be root to edit sudo to allow your user to use sudo.

Why is su an issue?

I just su root
then vim /etc/fstab

PTrenholme 09-01-2008 02:08 PM

What is your su issue?

For what reason do you wish to edit /etc/fstab? (The point in this question is that there may be some other way to achieve your objective -- whatever it is -- which does not require any change to fstab. For example, the fuse (File system in User Space) system may let you do what you want to do without your needing any root access.)

onebuck 09-01-2008 02:51 PM

Hi,
Quote:

Originally Posted by Redbug (Post 3266312)
What steps are used to edit fstab?
su is an issue.

Code:

excerpt from 'man su'

NAME
      su - change user ID or become super-user

SYNOPSIS
      su [-] [username [args]]

DESCRIPTION
      su is used to become another user during a login session. Invoked with-
      out a username, su defaults to becoming the super  user.  The  optional
      argument  -  may be used to provide an environment similiar to what the
      user would expect had the user logged in directly.

Is the issue that you can't become root or that you don't know how?

In order to make changes to the '/etc/fstab' you must be root and use a text editor to edit the '/etc/fstab' file;

Code:

excerpt from 'man fstab'
NAME
      fstab - static information about the filesystems

SYNOPSIS
      #include <fstab.h>

DESCRIPTION
      The  file fstab contains descriptive information about the various file
      systems.  fstab is only read by programs, and not written;  it  is  the
      duty  of  the system administrator to properly create and maintain this
      file.  Each filesystem is described on a separate line; fields on  each
      line are separated by tabs or spaces.  Lines starting with '#' are com-
      ments.  The order of records in fstab  is  important  because  fsck(8),
      mount(8),  and umount(8) sequentially iterate through fstab doing their
      thing.

'fstab' is a static file of information that should only be changed by the 'superuser' or 'root'. If you would provide us with more information as to what you are attempting to do then we could possibly direct you.

brianL 09-01-2008 03:10 PM

In the terminal:
gksu gedit /etc/fstab
Easy, huh?


All times are GMT -5. The time now is 02:26 PM.