Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #226605

Re: Why can't I move the document root for a site in Apache 2? [SOLVED]

From Dan Ritter <dsr@randomstring.org>
Newsgroups linux.debian.user
Subject Re: Why can't I move the document root for a site in Apache 2? [SOLVED]
Date 2020-09-01 15:40 +0200
Message-ID <AKeFY-3bZ-11@gated-at.bofh.it> (permalink)
References (3 earlier) <AJXvs-1kZ-9@gated-at.bofh.it> <AJYhQ-1Sd-5@gated-at.bofh.it> <AJZ4e-2cf-5@gated-at.bofh.it> <AK9ZE-pj-7@gated-at.bofh.it> <AKecV-32K-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


elvis wrote: 
> 
> On 1/9/20 6:29 pm, tomas@tuxteam.de wrote:
> > On Mon, Aug 31, 2020 at 04:57:28PM -0400, Gary Dale wrote:
> > 
> > [...]
> > 
> > > Just to be clear, the folder I had to change permissions on is the
> > > <folder containing all the web sites. This is many levels above the
> > > document root,
> > To be able to access a file given its path, you need to have read
> > access to each directory [1] along that path. There isn't another
> > way, and this is a Good Thing [TM]
> 
> I don't know if this is a silly question or not, but can you access a file
> not given its path?
> 
> 
> I have the same problem as the OP sometimes and wonder what rules there are
> for allowing access to directories further along the path.

A file can only have one set of ownership and permissions
(modulo extended attributes), but it can appear in multiple
paths.

There are two ways of doing this: a hard link, and a symbolic
link. Both are created with ln.

A hard link is a new actual name for the same file. It must
exist on the same underlying filesystem. Moving the original
file does not invalidate a hard link. Deleting the original
filename does not invalidate a hard link; the file itself
continues to exist as long as at least one hard link exists
somewhere. If you can create a hard link to a file, you can get
to it from the new link's path.

A symbolic link points to the original file's path location.
It's an alias to the location and name, not to the underlying
file. If you delete the file, the symlink becomes invalid; if
you move the file, the symlink is invalid. If you delete the
file and create a new one in the same path with the same name,
the symlink is valid again for the new file.

-dsr-

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Why can't I move the document root for a site in Apache 2? Gary Dale <gary@extremeground.com> - 2020-08-30 18:30 +0200
  Re: Why can't I move the document root for a site in Apache 2? john doe <johndoe65534@mail.com> - 2020-08-30 19:10 +0200
    Re: Why can't I move the document root for a site in Apache 2? john doe <johndoe65534@mail.com> - 2020-08-30 19:30 +0200
      Re: Why can't I move the document root for a site in Apache 2? Gary Dale <gary@extremeground.com> - 2020-08-31 21:20 +0200
        Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] Gary Dale <gary@extremeground.com> - 2020-08-31 22:10 +0200
          Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] Gary Dale <gary@extremeground.com> - 2020-08-31 23:00 +0200
            Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] mick crane <mick.crane@gmail.com> - 2020-09-01 07:50 +0200
            Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] <tomas@tuxteam.de> - 2020-09-01 10:40 +0200
              folders (was Re: Why can't I move the document root for a site in  Apache 2? [SOLVED]) The Wanderer <wanderer@fastmail.fm> - 2020-09-01 12:50 +0200
                Re: folders (was Re: Why can't I move the document root for a site  in Apache 2? [SOLVED]) <tomas@tuxteam.de> - 2020-09-01 16:00 +0200
                Re: folders (was Re: Why can't I move the document root for a site  in Apache 2? [SOLVED]) Andrei POPESCU <andreimpopescu@gmail.com> - 2020-09-02 11:50 +0200
                Re: folders (was Re: Why can't I move the document root for a site  in Apache 2? [SOLVED]) <tomas@tuxteam.de> - 2020-09-02 12:00 +0200
                Re: folders (was Re: Why can't I move the document root for a site  in Apache 2? [SOLVED]) Marek Mosiewicz <marek.mosiewicz@jotel.com.pl> - 2020-09-01 21:10 +0200
              Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] Greg Wooledge <wooledg@eeg.ccf.org> - 2020-09-01 14:10 +0200
                Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] Greg Wooledge <wooledg@eeg.ccf.org> - 2020-09-01 15:40 +0200
                Re: Why can't I move the document root for a site in Apache 2? [SOLVED] Kenneth Parker <sea7kenp@gmail.com> - 2020-09-01 16:10 +0200
                Re: Why can't I move the document root for a site in Apache 2? [SOLVED] Kenneth Parker <sea7kenp@gmail.com> - 2020-09-01 15:40 +0200
                Folders [was: Why can't I move the document root for a site in  Apache 2? [SOLVED]] <tomas@tuxteam.de> - 2020-09-01 16:00 +0200
              Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] elvis <elvis@dogonfire.com> - 2020-09-01 15:10 +0200
                Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] Dan Ritter <dsr@randomstring.org> - 2020-09-01 15:40 +0200
                Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] <tomas@tuxteam.de> - 2020-09-01 16:10 +0200
                Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] Greg Wooledge <wooledg@eeg.ccf.org> - 2020-09-01 16:40 +0200
                Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] <tomas@tuxteam.de> - 2020-09-01 16:50 +0200
              Re: Why can't I move the document root for a site in Apache 2? [SOLVED] rhkramer@gmail.com - 2020-09-01 16:10 +0200
                Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] <tomas@tuxteam.de> - 2020-09-01 16:20 +0200
                Re: Why can't I move the document root for a site in Apache 2?  [SOLVED] John Crawley <john@bunsenlabs.org> - 2020-09-02 02:30 +0200

csiph-web