Re: Fresh install (ubuntu) permissions issues

[email protected] Sun, 10 May 2026 12:49:00 -0400
Newsgroups gmane.comp.sysutils.backup.backuppc.general
Message-ID <[email protected]>
--===============8357979436018343814==
Content-Type: multipart/alternative;
 boundary=486e85707ca3bd459c1b9eda1e4d79995fecdac2

--486e85707ca3bd459c1b9eda1e4d79995fecdac2
Content-Type: text/plain
Content-Transfer-Encoding: 7bit



On Sun, May 10, 2026, at 10:18 AM, G.W. Haywood wrote:
> > ...
> > the CGI interface can't write config files, getting "TextFileWrite:
> > Failed to write /etc/backuppc/localhost.pl.new" when I try to save
> > ...
> > ...
> > I saw the apache user group (www-data) didn't have write access so
> > I added group write access to the directory and some files:
> > ...
> > But still isn't working.
> 
> I'm not sure if you have told us the user:group ownership of directory
> /etc/backuppc, but if as I suspect it's backuppc:backuppc then adding
> group write won't allow apache2 - running as www-data:www-data - to
> write in there unless you also add the www-data user to the backuppc
> group.  Plus it's trying to write "localhost.pl.new" that fails, not
> "localhost.pl", so changing the perms on "localhost.pl" won't help
> either.  (BackupPC in this case writes a new file, and then moves it
> into place over the original, to make the operation more 'atomic'.)

/etc/backuppc directory is user backuppc, group www-data (backuppc:www-data).  Permissions are drwxrwxr-x so www-data should be able to write to it.

> > Apache is running as www-data (user and group):
> > ...
> > Any suggestions?
> > ...
> 

--486e85707ca3bd459c1b9eda1e4d79995fecdac2
Content-Type: text/html
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE html><html><head><title></title></head><body><div style=3D"fon=
t-family:Verdana;"><br></div><div style=3D"font-family:Verdana;"><br></d=
iv><div>On Sun, May 10, 2026, at 10:18 AM, G.W. Haywood wrote:</div><blo=
ckquote type=3D"cite" id=3D"qt" style=3D""><div style=3D"font-family:Ver=
dana;">&gt; ...</div><div style=3D"font-family:Verdana;">&gt; the CGI in=
terface can't write config files, getting "TextFileWrite:</div><div styl=
e=3D"font-family:Verdana;">&gt; Failed to write /etc/backuppc/localhost.=
pl.new" when I try to save</div><div style=3D"font-family:Verdana;">&gt;=
 ...</div><div style=3D"font-family:Verdana;">&gt; ...</div><div style=3D=
"font-family:Verdana;">&gt; I saw the apache user group (www-data) didn'=
t have write access so</div><div style=3D"font-family:Verdana;">&gt; I a=
dded group write access to the directory and some files:</div><div style=
=3D"font-family:Verdana;">&gt; ...</div><div style=3D"font-family:Verdan=
a;">&gt; But still isn't working.</div><div style=3D"font-family:Verdana=
;"><br></div><div style=3D"font-family:Verdana;">I'm not sure if you hav=
e told us the user:group ownership of directory</div><div style=3D"font-=
family:Verdana;">/etc/backuppc, but if as I suspect it's backuppc:backup=
pc then adding</div><div style=3D"font-family:Verdana;">group write won'=
t allow apache2 - running as www-data:www-data - to</div><div style=3D"f=
ont-family:Verdana;">write in there unless you also add the www-data use=
r to the backuppc</div><div style=3D"font-family:Verdana;">group.&nbsp; =
Plus it's trying to write "localhost.pl.new" that fails, not</div><div s=
tyle=3D"font-family:Verdana;">"localhost.pl", so changing the perms on "=
localhost.pl" won't help</div><div style=3D"font-family:Verdana;">either=
.&nbsp; (BackupPC in this case writes a new file, and then moves it</div=
><div style=3D"font-family:Verdana;">into place over the original, to ma=
ke the operation more 'atomic'.)</div></blockquote><div style=3D"font-fa=
mily:Verdana;"><br></div><div style=3D"font-family:Verdana;">/etc/backup=
pc directory is user backuppc, group www-data (backuppc:www-data).&nbsp;=
 Permissions are&nbsp;drwxrwxr-x so www-data should be able to write to =
it.</div><div style=3D"font-family:Verdana;"><br></div><blockquote type=3D=
"cite" id=3D"qt" style=3D""><div style=3D"font-family:Verdana;">&gt; Apa=
che is running as www-data (user and group):</div><div style=3D"font-fam=
ily:Verdana;">&gt; ...</div><div style=3D"font-family:Verdana;">&gt; Any=
 suggestions?</div><div style=3D"font-family:Verdana;">&gt; ...</div><di=
v style=3D"font-family:Verdana;"><br></div></blockquote><div style=3D"fo=
nt-family:Verdana;"><br></div></body></html>
--486e85707ca3bd459c1b9eda1e4d79995fecdac2--


--===============8357979436018343814==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline


--===============8357979436018343814==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
BackupPC-users mailing list
[email protected]
List:    https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki:    https://github.com/backuppc/backuppc/wiki
Project: https://backuppc.github.io/backuppc/

--===============8357979436018343814==--