Please check under which user your litespeed virtual host is running, it probably isn’t www-data.
After you have found out which user actually serves your nextcloud instance you can execute those commands again with the right user and group.
In this thread you can find a good starting point for a nextcloud setup with litespeed webserver. Please check that you have setup everything correctly.