Hi I just complete my exam, question is, when task was asked me to write output . . .

Esra:
Hi I just complete my exam, question is, when task was asked me to write output to file, no permission to write to file as student, and I executed as root. but I worry if that should not be the way. Do you have an idea?

Vasu P:
Hi, switching to root is not a problem. I gave my exam recently and did the samething.

Vasu P:
Normal user has no write permission to those files.

Esra:
@Vasu P thanks Vasu

Vasu P:
Wish you all the best

Ravi Singh:
Hi Guys, will sudo su - do the work?

Vasu P:
Yes, sudo su works

Krishnaprasad:
so, did you do a sudo -i before every task ?

Vasu P:
Most of the tasks doesn’t require sudo, for the tasks like copy logs to a file or copy command to a file for these one I switched to root.
But it is okay to execute all the commands as a root user.