today i will show you how you can change ower and group with the chown command in linux

very simple, lets say i have a file called myfriends.txt and the owner is OldUser and group is OldGruop and i want to change the owership to NewUser and NewGroup. to so change:

FROM:
OldUser OldGroup myfriends.txt

TO:
OldUser OldGroup myfriends.txt

i would use this command:
LINUX SHELL COMMAND:
chown OldUser:OldGroup myfriends.txt


if i had a directory called myfriends/ i would change all the files in that directory with this command:

COMMAND:
chown -R OldUser:OldGroup myfriends/


hope that helps