LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-30-2005, 05:05 PM   #1
rrrssssss
Member
 
Registered: Mar 2005
Posts: 284

Rep: Reputation: 33
Newbee Emacs Question


Hello forum,

Does anybody know how to edit a file using emacs when emacs says the buffer is read only? The file to be edited seems to be +rwx and seems to be a sym-link.

I am an extreme newbee with emacs and still learning the ropes with Linux.

Thanks,
Roy S. Smith
 
Old 11-30-2005, 06:35 PM   #2
Mad Scientist
Member
 
Registered: May 2003
Posts: 167

Rep: Reputation: 30
Hi Roy,

What file is it that you are trying to edit? Could you perform a "ls -hl filename" and post the results? I'm not sure, but Emacs might give you trouble editing via symlink, as opposed to editing the original file itself. The symlink will likely have permissions of "rwxrwxrwx" whereas the original file could have different permissions. The "-l" behind the "ls" command will tell you where that symlink is pointing.
 
Old 12-01-2005, 12:43 AM   #3
big_mac126
Member
 
Registered: Oct 2004
Location: Toronto
Distribution: Fedora Core 4
Posts: 58

Rep: Reputation: 15
instead of using emacs (if you find it too different), check out gedit, kedit, or nedit (personal preference). You will likely have to install the latter depending on your system configuration.
 
Old 12-01-2005, 01:31 AM   #4
rrrssssss
Member
 
Registered: Mar 2005
Posts: 284

Original Poster
Rep: Reputation: 33
Thanks for the reply Mad Scientist,

Below is the terminal window's readout using the ls -hl command. I am trying to disable fstab-sync from HAL (Hardware Abstraction Layer) by replacing the word fstab-sync with the word false.

The instructions for disabling HAL are as follows:

DISABLING FSTAB-SYNC
Automatic updates of the /etc/fstab file by the fstab-sync program from
the HAL daemon can be disabled by changing the 50-fstab-sync.hal sym-
link in /etc/hal/device.d directory to point to /bin/false





[root@localhost hal]# dir
device.d hald.conf
[root@localhost hal]# ls -ls device.d
total 0
0 lrwxrwxrwx 1 root root 32 Nov 12 09:42 40-hal-hotplug-map.hal -> ../../../usr/lib/hal-hotplug-map*
0 lrwxrwxrwx 1 root root 28 Nov 12 09:42 50-fstab-sync.hal -> ../../../usr/sbin/fstab-sync*
[root@localhost hal]#

Thanks much,
Roy S. Smith

Last edited by rrrssssss; 12-01-2005 at 01:37 AM.
 
Old 12-01-2005, 07:53 AM   #5
enemorales
Member
 
Registered: Jul 2004
Location: Santiago, Chile
Distribution: Ubuntu
Posts: 410

Rep: Reputation: 31
[quote]
DISABLING FSTAB-SYNC
Automatic updates of the /etc/fstab file by the fstab-sync program from
the HAL daemon can be disabled by changing the 50-fstab-sync.hal sym-
link in /etc/hal/device.d directory to point to /bin/false
{/quote]

Hi,

You are not supposed to edit the file, but to make the symlink to point to other place. For that, you have to remove the link and then create a new one. This is done with the next two commands (in the ....device.d folder)

Code:
rm 50-fstab-sync.hal
ln -s /bin/false 50-fstab-sync.hal
HTH!
 
Old 12-01-2005, 09:09 AM   #6
rrrssssss
Member
 
Registered: Mar 2005
Posts: 284

Original Poster
Rep: Reputation: 33
Followup

Thank you enemorales,

I think I did the same thing by renaming the fstab-sync file in /usr/bin/sbin (before I read your response). So far, I haven't had any problems doing it this way plus, fstab-sync is disabled just the same.

I needed to disable fstab-sync so it would allow me to make changes in the fstab file without it automatically reverting it back to its original state (autoregenerate) upon reboot.

Roy S. Smith

Last edited by rrrssssss; 12-01-2005 at 09:10 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Emacs question tuananhbirm Linux - General 6 07-20-2005 03:55 AM
Linux distro choice (Newbee question) paped1 Linux - Distributions 3 01-25-2005 01:59 AM
emacs question greg108 Programming 3 09-25-2004 10:16 AM
emacs question Midknight Programming 2 02-04-2003 12:33 AM
For a newbee, cause newbee is a friend, and we must take care of friends. neo77777 Linux - Newbie 4 01-20-2002 01:01 AM


All times are GMT -5. The time now is 11:05 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration