I was wondering if there was a way to make a script that logouts of root or takes the automatic root login and logs in a user. This is for security reason so that the user cannot change important files. I am using Ubuntu 12.04 or a EMB-3500 freescale board(i.mx6 chip)(ARM).

Note* I do not have a bootloader or inittab file. My opening console that logs in as root is ttymxc0 which is specific to the board.


Could try: su -l user;exit;

That would switch to the user, then drop the root session if the user logs out.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.