What is the group of the Apache process? I think that group needs to be there like chown lamp:www-data test_file.txt chmod 775 test_file.txt Its working when you set 777 because that's making it writable to everyone. --- Thanks, Alexander Sent from my Google Pixel 7 Pro On Thu, Dec 5, 2024, 09:46 Keith Smith via PLUG-discuss < plug-discuss@lists.phxlinux.org> wrote: > Hello; > > I have a private net that runs non-rountable domain names of .internal. > I use the hosts files for DNS. > > This is for PHP development and testing. > > Desktop is Kubuntu. Have installed Virtual Studio Code (VSC). > > I have a Win10 laptop running VirtualBox and multiple VMs of which only > one runs at a time. As I complete a configuration I clone the last > successful VM to take it to the next level. > > The Goal is to be able to remote edit using VSC. > > My config > > Ubuntu 24.04lts > Apache2 > PHP 8.3 > MySQL > PHP-FPM > > I think I have a complete PHP-FPM config, user is lamp, group is lamp. > > PHP Info shows Server API FPM/FastCGI which I understand the config is > correct. > > I can access the server using VSC and am able to add/edit/delete/save > code files. > > My permissions and ownership is: > > - sudo chown -R lamp:lamp /var/www/lamp.internal > – sudo find /var/www/lamp.internal -type d -exec chmod 755 {} \; > – sudo find /var/www/lamp.internal -type f -exec chmod 644 {} \; > > When I run : http://lamp.internal/php-write-edit-delete.php it reports: > > The file does not exist. It will be created shortly. > > Error writing to the file. > > Error appending to the file. > > Error deleting the file. > > --- > > When I change permissions : sudo find /var/www/lamp.internal -type d > -exec chmod 777 {} \; > > The script reports: > > The file does not exist. It will be created shortly. > > Successfully written to the file: 'test_file.txt' > > Successfully appended content to the file: 'test_file.txt' > File Content (After Modifying): > > This is the initial content of the file. > Appended content: 2024-12-05 16:37:21 > > Successfully deleted the file: 'test_file.txt' > > --- > > Interestingly I can edit files using VSC however I have difficulty > running a script from a browser. > > Any help much appreciated!! > > Thanks!! > > Keith > > --------------------------------------------------- > PLUG-discuss mailing list: PLUG-discuss@lists.phxlinux.org > To subscribe, unsubscribe, or to change your mail settings: > https://lists.phxlinux.org/mailman/listinfo/plug-discuss >