Forum Stats

  • 3,728,470 Users
  • 2,245,631 Discussions
  • 7,853,548 Comments

Discussions

switch user rc.local

Robeen
Robeen Member Posts: 1,993 Silver Badge

Redhat Hat Linux 7

Hello Team,


I would like to aotoexecute a script after server reboot. I have scheduled it in /etc/rc.d/rc.local.


But I see it is executing as root user.


rc.local entry:

sh /home/ora12c/scripts/autostart.sh

How do I execute as ora12c user?

content of autostart.sh:

nohup ./server.sh &

Thanks,


Roshan

Answers

Sign In or Register to comment.