Solved

Linux, how to configure a script that will start at boot up

Posted on 2013-11-19
2
228 Views
Last Modified: 2013-11-19
In RHEL 6.4

How do I configure a script that will execute upon bootup

(This script will only contain "su - mqm")
0
Comment
Question by:Los Angeles1
2 Comments
 
LVL 31

Assisted Solution

by:farzanj
farzanj earned 250 total points
ID: 39660500
Normally you can put your script inside

/etc/rc.local

That will cause it to execute at run time.

However, you are using a command that is to change user.  This would not work this way.


Can you elaborate what exactly are you trying to achieve?
0
 
LVL 19

Accepted Solution

by:
xterm earned 250 total points
ID: 39660503
You can either edit /etc/rc.d/rc.local and put the command directly in there, or you can call the script name from rc.local

So either put in:

/path/to/command <command arguments>

or put in:

/usr/local/bin/myscript

(example name above, and be sure you make it excecutable by doing chmod 755)
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Linux Mint 18 31 89
PHP Apache application gives "Forbidden" message 5 55
linux installs 6 59
Quickest way to query Windows Event ID from a Linux Device 3 23
Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
Fine Tune your automatic Updates for Ubuntu / Debian
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now