[vox-tech] Permission Denied Error

Matthew Holland mdholland at ucdavis.edu
Thu Jul 8 21:13:55 PDT 2010


You need to learn about UNIX permissions.  There is no reason you
shouldn't be able to change the permissions on the file with sudo
commands.  As Jeff suggested, there are plenty of reasons why this may
not be a good thing to do, but it could be fine.  No one can really
tell from what you have told us whether it's in the Very Bad Idea
category, or not.  If this header belongs to the system (e.g., it's in
/usr/include or /Library, or pretty much anywhere but /Users), then
modifying it is probably not a good idea.

You should read the man pages for "chown" and "chmod" and read about
UNIX permissions in general.  If the user that you are logged in as is
an administrator, you should be able to change the ownership of the
file with a command like:

$ sudo chown file username

where "file" is the name of the file, and "username" is the name of
the user to whom you want to transfer ownership of the file.  It's
possible that the file is still read-only at this point, depending on
the file permissions.  If so, and you really want to do this, you can
issue a command like

$ chmod u+w file

Keep in mind that a little knowledge can be dangerous, and think
clearly about what you're doing before you change the ownership or
permissions of any file owned by root.  Usually there is a good reason
for root ownership.  This is probably why you haven't received a lot
of help, because no one wants to help you break system-owned files.

Matt

On Thu, Jul 8, 2010 at 8:54 PM, Anahita Yazdi <atyazdi at ucdavis.edu> wrote:
> I need to make changes on a header file but the file is read only for me. I
> need to enable the root user account. How would I be able to do that?
>
> On Thu, Jul 8, 2010 at 8:09 PM, Jeff Newmiller <jdnewmil at dcn.davis.ca.us>
> wrote:
>>
>> In order to obtain more detailed help you must provide a more detailed
>> question.
>>
>> "Anahita Yazdi" <atyazdi at ucdavis.edu> wrote:
>>
>> >I am confused then so what should I do to overcome the problem. I will
>> >really be appreciated for more detailed help please
>> >Thanks a lot
>> >Anahita
>> >
>> >On Thu, Jul 8, 2010 at 5:26 PM, Jeff Newmiller
>> > <jdnewmil at dcn.davis.ca.us>wrote:
>> >
>> >> Sounds to me like the file is read-only and I would strongly encourage
>> >> you
>> >> to desist in your attempts to modify it. You are very unlikely to
>> >> obtain the
>> >> results you desire by making such a change.
>> >>
>> >> "Anahita Yazdi" <atyazdi at ucdavis.edu> wrote:
>> >>
>> >> >Hi,
>> >> >I am working on a Mac OS X 10.6.2, I installed a software program
>> >> > through
>> >> >terminal and wanted to change some details on one of its header files
>> >> >(extension *.h) however I am getting a permission denied error in
>> >> > terminal
>> >> >when I open it as a "vi" file. I tried "sudo" but it is still not
>> >> > working.
>> >> >It is a file that is apparently owned by the root. I tried to
>> >> disable/enable
>> >> >the root on this system from apple's official discussion page but the
>> >> option
>> >> >"edit" in "Open Directory Utility" is missing. Where else would I be
>> >> > able
>> >> to
>> >> >perform such task on my system?
>> >> >Thanks a bunch,
>> >> >Anahita
>> >> >_______________________________________________
>> >> >vox-tech mailing list
>> >> >vox-tech at lists.lugod.org
>> >> >http://lists.lugod.org/mailman/listinfo/vox-tech
>> >>
>> >>
>> >> ---------------------------------------------------------------------------
>> >> Jeff Newmiller                        The     .....       .....  Go
>> >> Live...
>> >> DCN:<jdnewmil at dcn.davis.ca.us>        Basics: ##.#.       ##.#.  Live
>> >> Go...
>> >>                                      Live:   OO#.. Dead: OO#..  Playing
>> >> Research Engineer (Solar/Batteries            O.O#.       #.O#.  with
>> >> /Software/Embedded Controllers)               .OO#.       .OO#.
>> >>  rocks...1k
>> >>
>> >> ---------------------------------------------------------------------------
>> >> Sent from my phone. Please excuse my brevity.
>> >> _______________________________________________
>> >> vox-tech mailing list
>> >> vox-tech at lists.lugod.org
>> >> http://lists.lugod.org/mailman/listinfo/vox-tech
>> >>
>> >> 7.7/5.0
>> >> This incoming message has been identified by the UCD central filters as
>> >> possible spam.  This attachment is provided so that you can review the
>> >> reasons the message was tagged, and to assist with additional filtering
>> >> if you wish to supplement the central filters with your own local
>> >> rules.
>> >>
>> >> If you have further questions please email ithelp at ucdavis.edu for
>> >> assistance.
>> >>
>> >> Content analysis details:   (7.7 points, 5.0 required)
>> >>
>> >>  pts rule name              description
>> >> ---- ----------------------
>> >> --------------------------------------------------
>> >>  4.1 BAYES_99               BODY: Bayesian spam probability is 99 to
>> >> 100%
>> >>                            [score: 0.9992]
>> >>  3.5 RCVD_IN_UCDXBL         RBL: Appears in XBL
>> >>                            [208.54.5.71 listed in xbl.ucdavis.edu]
>> >>  0.1 RDNS_DYNAMIC           Delivered to trusted network by host with
>> >>                            dynamic-looking rDNS
>> >>
>> >>
>> >>
>> >>
>> >_______________________________________________
>> >vox-tech mailing list
>> >vox-tech at lists.lugod.org
>> >http://lists.lugod.org/mailman/listinfo/vox-tech
>>
>>
>> ---------------------------------------------------------------------------
>> Jeff Newmiller                        The     .....       .....  Go
>> Live...
>> DCN:<jdnewmil at dcn.davis.ca.us>        Basics: ##.#.       ##.#.  Live
>> Go...
>>                                      Live:   OO#.. Dead: OO#..  Playing
>> Research Engineer (Solar/Batteries            O.O#.       #.O#.  with
>> /Software/Embedded Controllers)               .OO#.       .OO#.
>>  rocks...1k
>>
>> ---------------------------------------------------------------------------
>> Sent from my phone. Please excuse my brevity.
>> _______________________________________________
>> vox-tech mailing list
>> vox-tech at lists.lugod.org
>> http://lists.lugod.org/mailman/listinfo/vox-tech
>
>
> _______________________________________________
> vox-tech mailing list
> vox-tech at lists.lugod.org
> http://lists.lugod.org/mailman/listinfo/vox-tech
>
>


More information about the vox-tech mailing list